From nobody Mon Jul 15 07:13:33 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WMths3dcnz5QlZg; Mon, 15 Jul 2024 07:13: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WMths35twz4g91; Mon, 15 Jul 2024 07:13:33 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721027613; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6NLI1vSoh5+wH/QXV1GRZ1xEYEfmOn+QK4q9yR8h4/k=; b=KRoKjmSvzwZy4TwIKJ4wqp5NNW5InjPW3edYb6DlJg5pez+3u46eqpo1litxwLa5mHrPIc j5k3vpH07NoefCibSS4CvyczcANJsaDTXk4h7TsDIEp85BemEGAzzgcVSqZs3Lyl1GbQH4 2rl5t0OA66i96iQHZd4mktsVzHUnpZltkEnkX7pDtEVcZaEy2qJS1kufMsV5PyvXDDHnnS P3A4UmGoBmUQ5Pld1KlB2ikcYXz82+piWw4MsMhppp4e2RqlTsvx+EjAXNZFPcnO3ZrHxk 4Nb3yqYuXhqNzpntnr/bDy+/ROdv+y48SqSwA4wFYvnnPDD34HrrJ5VPCLWJTQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721027613; a=rsa-sha256; cv=none; b=VA+CpjsDpp8Brao41uG/qEKIIeoCf45QNSZ5bTI/oaZC7LrYCS7/GPOP1ogpspv52XpL4D RgOlXdeQBCtSDxQWlCjqW//F7TjYIJ2XeFuuD5TbsTKMcOfvmc/uC1Yn10HW4LDay9Z4pI XFgKD0emPBOzAxGljBGcDX5hLXXhu5zFSmgJ5TFbXwnD4BFckJaF0yPf+U6kQGq6Flu2N4 jIqHi9Dm1g7XdUr58WwjUO3LabmvgBPfm6voa6uxtiMufrqbCAaow5+e4+7irQRbbr+iZ2 OKJMWUG6Ti8ND6T7be+ueL6znURG53SYhUKSs8T7Lhzw5SG8qDINxbBrQqd6qQ== 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=1721027613; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6NLI1vSoh5+wH/QXV1GRZ1xEYEfmOn+QK4q9yR8h4/k=; b=HA2xEOsbmSYsHEvZYKQ1xVi351phyuG66BF4Y3Surb37k/ZAdWH2Ib33drkk+rWUJ8kSOw q3+woPym1P0bPnFTCMWToE/mgvk7yDx/TJAKJT93ezdLPUpb6fsu5EZewTbbQP1Pm10bUM Mk6RqsM/cmHA+BHOVRrGL5QV3BXF/YC/UMW1eZ4FDAJoqAcK0/UF+2DRjCmYXRriBUBqua o+qgj1YDm95jjO6a5Z6npR946gpTaMgfGRRdEFQNOZEZ0g6K/Ius5ojN6gg3/Zkm0BsZXl EuJwnKbgL9f1RwDzUJVcLYNesZsPCeCpofWSA1MMT3R8TMJfORrFK19sGYb8Dw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WMths2ft6zjH9; Mon, 15 Jul 2024 07:13:33 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46F7DXOk015433; Mon, 15 Jul 2024 07:13:33 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46F7DXo3015430; Mon, 15 Jul 2024 07:13:33 GMT (envelope-from git) Date: Mon, 15 Jul 2024 07:13:33 GMT Message-Id: <202407150713.46F7DXo3015430@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: 45cde0e43918 - main - vm_page: add vm_page_clearref() helper List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 45cde0e439188589ca2511f6fd76829cbf68267e Auto-Submitted: auto-generated The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=45cde0e439188589ca2511f6fd76829cbf68267e commit 45cde0e439188589ca2511f6fd76829cbf68267e Author: Konstantin Belousov AuthorDate: 2024-07-08 17:45:33 +0000 Commit: Konstantin Belousov CommitDate: 2024-07-15 06:15:50 +0000 vm_page: add vm_page_clearref() helper It is supposed to be used for ref_count manipulations when the pages are owned by an object, but ref_count is used for something else than the wiring, e.g. PTE population count on the page table page. Reviewed by: markj Sponsored by: Advanced Micro Devices (AMD) Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D45910 --- sys/vm/vm_page.h | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/sys/vm/vm_page.h b/sys/vm/vm_page.h index f419ba8e3d34..49f4c0fbc0cb 100644 --- a/sys/vm/vm_page.h +++ b/sys/vm/vm_page.h @@ -947,6 +947,17 @@ vm_page_in_laundry(vm_page_t m) return (queue == PQ_LAUNDRY || queue == PQ_UNSWAPPABLE); } +static inline void +vm_page_clearref(vm_page_t m) +{ + u_int r; + + r = m->ref_count; + while (atomic_fcmpset_int(&m->ref_count, &r, r & (VPRC_BLOCKED | + VPRC_OBJREF)) == 0) + ; +} + /* * vm_page_drop: * From nobody Mon Jul 15 07:13:34 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WMtht4ng0z5QljL; Mon, 15 Jul 2024 07:13: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WMtht49nzz4gFn; Mon, 15 Jul 2024 07:13:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721027614; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=qyn869qAXcD2XwfjMwsS84HtqzMfEjCykzTiTIa71pA=; b=Jjzjepvu5D1iy8SfVAZy8y5V1B/QZXlgMJ82oS3/JZFAxixx9xZmDBxHlF90hYo6Z/vK4i +KC1xpcEg1e+qcSBpvDdOEqHNs4yQbwj2zzm4QWFmtyrP6eED7m2OqUeU/hMS5lPA24m8P WxGnf8Hs9SCmUI/SjXB+HKfSdLOYi0OvO2fivKOvnj6E+tGnPIi8MODMzYf8F3TZXO+MZp FK5ebfd51esln0pqKjhaEPr8p+TzII04+DKhJVUNljr6EB2XuLqvLxYktJV4mdEy/7cozg pUJRlBCfckK1ovWBQ7/rK8N0z10Jycbk0Pi3JFHolJAPH3PKtO9tLzy0zzdxnA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721027614; a=rsa-sha256; cv=none; b=Xx0YRnuFbcg5J+JbrVsqsUfnQI1lr64PPaJZ6kNnnEk07GWaYbbx66TuLNfh51O2degm6M xS3FcUgCauS/P03C1YcJgCc7fnXwFyCY6m5h3MVOi+U060v2GqhhcJQP+fhKov/4YT3vGs 9GNeSRFX+LKeJBUTVTBW+s0LaEcc+DD8+UIvy9rcGMcrtUg7kohor6L1FBSRwLHsYNkite BIkmPKAu6r3r7Vg+0B/3x0GuMpnvTGaWYt7PG4rSR0swHnf7UGJd2k/hshlwv1KC1hFo7X +GANFFSJTrsxVhU+HVkiEoA3NVIYjezXO03wTJE5rPl/kOpLcH6EKi2PttFHDg== 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=1721027614; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=qyn869qAXcD2XwfjMwsS84HtqzMfEjCykzTiTIa71pA=; b=mb0eo0bE97Xf1QGJBGuxZRiAaIAsN3gSjXB3vCzuogczmLdVq5wc4sVlvDtxqF8SU7KnOw J/cB2rsNRSiolztGBT2WZsqxU51amLuQ0nYj4BJgSiQuLwaQ19yG3LoPa6sNbgpU/BBUoZ 3YKJ7xoolSU9mU+wARVTgVjJQEsakmASezxGy8clQyXGXfg0zH91en3jKu9g/AVIJTREz6 3+ZHypaWnQyDyKRAR+hihhYiV99sal3SSC/eUjN+JvKNQmsBoA8qaSkQ4FpcduxWwJojIh ZmGQoc20aMjiHUVDHarUX8IIHuMO5yS06DXdg5opM8iV3ogIpWIamn/jIJkvJQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WMtht3b0Jzjlh; Mon, 15 Jul 2024 07:13:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46F7DYbV015482; Mon, 15 Jul 2024 07:13:34 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46F7DYLm015479; Mon, 15 Jul 2024 07:13:34 GMT (envelope-from git) Date: Mon, 15 Jul 2024 07:13:34 GMT Message-Id: <202407150713.46F7DYLm015479@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: 7773023b72de - main - DMAR pagetables pages: handle ref_count special references List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 7773023b72de19c6c9a47fd04ac955ec52773f0f Auto-Submitted: auto-generated The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=7773023b72de19c6c9a47fd04ac955ec52773f0f commit 7773023b72de19c6c9a47fd04ac955ec52773f0f Author: Konstantin Belousov AuthorDate: 2024-07-07 23:26:57 +0000 Commit: Konstantin Belousov CommitDate: 2024-07-15 06:15:53 +0000 DMAR pagetables pages: handle ref_count special references Preserve object reference and block bit during refcount arithmetic and obliteration, by using vm_page_wire()/unwire_noq(). Reviewed by: markj Sponsored by: Advanced Micro Devices (AMD) Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D45910 --- sys/x86/iommu/intel_idpgtbl.c | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) diff --git a/sys/x86/iommu/intel_idpgtbl.c b/sys/x86/iommu/intel_idpgtbl.c index 157afaec75ef..de38a6fece94 100644 --- a/sys/x86/iommu/intel_idpgtbl.c +++ b/sys/x86/iommu/intel_idpgtbl.c @@ -47,6 +47,7 @@ #include #include #include +#include #include #include #include @@ -390,7 +391,7 @@ retry: * pte write and clean while the lock is * dropped. */ - m->ref_count++; + vm_page_wire(m); sfp = NULL; ptep = domain_pgtbl_map_pte(domain, base, lvl - 1, @@ -398,7 +399,7 @@ retry: if (ptep == NULL) { KASSERT(m->pindex != 0, ("loosing root page %p", domain)); - m->ref_count--; + vm_page_unwire_noq(m); iommu_pgfree(domain->pgtbl_obj, m->pindex, flags); return (NULL); @@ -406,8 +407,8 @@ retry: dmar_pte_store(&ptep->pte, DMAR_PTE_R | DMAR_PTE_W | VM_PAGE_TO_PHYS(m)); dmar_flush_pte_to_ram(domain->dmar, ptep); - sf_buf_page(sfp)->ref_count += 1; - m->ref_count--; + vm_page_wire(sf_buf_page(sfp)); + vm_page_unwire_noq(m); iommu_unmap_pgtbl(sfp); /* Only executed once. */ goto retry; @@ -486,7 +487,7 @@ domain_map_buf_locked(struct dmar_domain *domain, iommu_gaddr_t base, dmar_pte_store(&pte->pte, VM_PAGE_TO_PHYS(ma[pi]) | pflags | (superpage ? DMAR_PTE_SP : 0)); dmar_flush_pte_to_ram(domain->dmar, pte); - sf_buf_page(sf)->ref_count += 1; + vm_page_wire(sf_buf_page(sf)); } if (sf != NULL) iommu_unmap_pgtbl(sf); @@ -592,8 +593,7 @@ domain_unmap_clear_pte(struct dmar_domain *domain, iommu_gaddr_t base, int lvl, iommu_unmap_pgtbl(*sf); *sf = NULL; } - m->ref_count--; - if (m->ref_count != 0) + if (!vm_page_unwire_noq(m)) return; KASSERT(lvl != 0, ("lost reference (lvl) on root pg domain %p base %jx lvl %d", @@ -709,7 +709,7 @@ domain_alloc_pgtbl(struct dmar_domain *domain) m = iommu_pgalloc(domain->pgtbl_obj, 0, IOMMU_PGF_WAITOK | IOMMU_PGF_ZERO | IOMMU_PGF_OBJL); /* No implicit free of the top level page table page. */ - m->ref_count = 1; + vm_page_wire(m); DMAR_DOMAIN_PGUNLOCK(domain); DMAR_LOCK(domain->dmar); domain->iodom.flags |= IOMMU_DOMAIN_PGTBL_INITED; @@ -741,8 +741,10 @@ domain_free_pgtbl(struct dmar_domain *domain) /* Obliterate ref_counts */ VM_OBJECT_ASSERT_WLOCKED(obj); - for (m = vm_page_lookup(obj, 0); m != NULL; m = vm_page_next(m)) - m->ref_count = 0; + for (m = vm_page_lookup(obj, 0); m != NULL; m = vm_page_next(m)) { + vm_page_clearref(m); + vm_wire_sub(1); + } VM_OBJECT_WUNLOCK(obj); vm_object_deallocate(obj); } From nobody Mon Jul 15 12:37:49 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1v16m08z5QrP8; Mon, 15 Jul 2024 12:37: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1v16SZqz4Gfr; Mon, 15 Jul 2024 12:37:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047069; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=r8SUdfyBvos4rCx8xEjK0RBIXyNoa5lRIGJ1TVB268s=; b=p4TBGyI1FplVW9iUkl7Ezz1ld8JJm/xgMNKf+krFeRgz8tXoi2kbZ2rRT4NE+oyVmbCZDf Io7RCPhn42d0JB8pTkD5204Ub9MS+2/JYPi1WvaExb1EvPTjpDbDm1UOx5WJe2ErA9YqjA xF8x53D+CEj6QYSR14tepAhDIZcGH3QPMSuVDmuxyeBFpJw9glV7S0Er6W/Kzt+iL9bp8Q P3z/CdxDQuHNCJ/eidapI9+KmqD2g8WpQf/r5HExriBI69cE1FwOXYcfpVypAnMPVc8tz3 iRxHgvG07QIEZL7WrS6TcGuknNLcF9oE5EMERZXgkL2ZF2fcwzn3wYd/8xYCag== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047069; a=rsa-sha256; cv=none; b=UrHbHgbGM2e0/agmOO+GXEYqUYU5rvPfFtTsKfPVrYSVaoBYuoLA4Old44G1cKLw9opLU3 X1WanR/Dhj7oHNoZDxgnGBp4nMaCcecq8OEHLsZ8FjIr687YULthVtQOEIWmRWi59RGcg/ zzOIZB9tEq0zMpLj39AZZmIhozYzvaPfyxP4SSIfI7nCh9aPmlKkJe8qsnD4r4t93Tp07v iOzVNrbvg3oFHM78Mfk1ccdlydHR9WwyRS+RkOrz16GTex+3fHpeLy6f02ftnDAIC5FGYE z8oJAV3QC9z6GHVlBubQA8/E16YASIZzVpSYqkrhlc8DkJIVC6H1LzdRMyDn8w== 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=1721047069; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=r8SUdfyBvos4rCx8xEjK0RBIXyNoa5lRIGJ1TVB268s=; b=fJZBQ0NcwInEMOSc+2lJOABQ51yNx1LnUPzy2goi/92E9m5bcbE4L5B8WatHFQBj+n42Hb NzDX15d5eTE1Q/9IexGK9asS7gdWNDRPgt0g2fdJTfYgz+S8jBww7mqe0rMZQ5F84ndNpw y1zJJ7OCpjqbrWClSscJx48XMn2+JpLyKqsbLIB9eNCHidy9nJ+qjqaikDKdbPHE40BgDt JHS8+2qAUUPcCgyeL+QvR2WigKGsyvYF953RLR2dXXAtBBjtmAi6x2/x/l/IL7VHq6xAZW imA3rgYRwcMxWIUw+zqeBGnkbyHPoeGNPxWgKdElesAfWsM3Txv4FqKiksSS1g== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1v15v00zsrm; Mon, 15 Jul 2024 12:37:49 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCbnul058213; Mon, 15 Jul 2024 12:37:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCbnrU058210; Mon, 15 Jul 2024 12:37:49 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:37:49 GMT Message-Id: <202407151237.46FCbnrU058210@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: c06a19447954 - stable/14 - aarch64: support BTI and pointer authentication in assembly List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: c06a194479548c6f24bc67f04b8974554e549f56 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=c06a194479548c6f24bc67f04b8974554e549f56 commit c06a194479548c6f24bc67f04b8974554e549f56 Author: Russ Butler AuthorDate: 2021-08-28 18:57:09 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 08:09:43 +0000 aarch64: support BTI and pointer authentication in assembly This change adds optional support for - Armv8.3-A Pointer Authentication (PAuth) and - Armv8.5-A Branch Target Identification (BTI) features to the perl scripts. Both features can be enabled with additional compiler flags. Unless any of these are enabled explicitly there is no code change at all. The extensions are briefly described below. Please read the appropriate chapters of the Arm Architecture Reference Manual for the complete specification. Scope ----- This change only affects generated assembly code. Armv8.3-A Pointer Authentication -------------------------------- Pointer Authentication extension supports the authentication of the contents of registers before they are used for indirect branching or load. PAuth provides a probabilistic method to detect corruption of register values. PAuth signing instructions generate a Pointer Authentication Code (PAC) based on the value of a register, a seed and a key. The generated PAC is inserted into the original value in the register. A PAuth authentication instruction recomputes the PAC, and if it matches the PAC in the register, restores its original value. In case of a mismatch, an architecturally unmapped address is generated instead. With PAuth, mitigation against ROP (Return-oriented Programming) attacks can be implemented. This is achieved by signing the contents of the link-register (LR) before it is pushed to stack. Once LR is popped, it is authenticated. This way a stack corruption which overwrites the LR on the stack is detectable. The PAuth extension adds several new instructions, some of which are not recognized by older hardware. To support a single codebase for both pre Armv8.3-A targets and newer ones, only NOP-space instructions are added by this patch. These instructions are treated as NOPs on hardware which does not support Armv8.3-A. Furthermore, this patch only considers cases where LR is saved to the stack and then restored before branching to its content. There are cases in the code where LR is pushed to stack but it is not used later. We do not address these cases as they are not affected by PAuth. There are two keys available to sign an instruction address: A and B. PACIASP and PACIBSP only differ in the used keys: A and B, respectively. The keys are typically managed by the operating system. To enable generating code for PAuth compile with -mbranch-protection=: - standard or pac-ret: add PACIASP and AUTIASP, also enables BTI (read below) - pac-ret+b-key: add PACIBSP and AUTIBSP Armv8.5-A Branch Target Identification -------------------------------------- Branch Target Identification features some new instructions which protect the execution of instructions on guarded pages which are not intended branch targets. If Armv8.5-A is supported by the hardware, execution of an instruction changes the value of PSTATE.BTYPE field. If an indirect branch lands on a guarded page the target instruction must be one of the BTI flavors, or in case of a direct call or jump it can be any other instruction. If the target instruction is not compatible with the value of PSTATE.BTYPE a Branch Target Exception is generated. In short, indirect jumps are compatible with BTI and while indirect calls are compatible with BTI and . Please refer to the specification for the details. Armv8.3-A PACIASP and PACIBSP are implicit branch target identification instructions which are equivalent with BTI c or BTI jc depending on system register configuration. BTI is used to mitigate JOP (Jump-oriented Programming) attacks by limiting the set of instructions which can be jumped to. BTI requires active linker support to mark the pages with BTI-enabled code as guarded. For ELF64 files BTI compatibility is recorded in the .note.gnu.property section. For a shared object or static binary it is required that all linked units support BTI. This means that even a single assembly file without the required note section turns-off BTI for the whole binary or shared object. The new BTI instructions are treated as NOPs on hardware which does not support Armv8.5-A or on pages which are not guarded. To insert this new and optional instruction compile with -mbranch-protection=standard (also enables PAuth) or +bti. When targeting a guarded page from a non-guarded page, weaker compatibility restrictions apply to maintain compatibility between legacy and new code. For detailed rules please refer to the Arm ARM. Compiler support ---------------- Compiler support requires understanding '-mbranch-protection=' and emitting the appropriate feature macros (__ARM_FEATURE_BTI_DEFAULT and __ARM_FEATURE_PAC_DEFAULT). The current state is the following: ------------------------------------------------------- | Compiler | -mbranch-protection | Feature macros | +----------+---------------------+--------------------+ | clang | 9.0.0 | 11.0.0 | +----------+---------------------+--------------------+ | gcc | 9 | expected in 10.1+ | ------------------------------------------------------- Available Platforms ------------------ Arm Fast Model and QEMU support both extensions. https://developer.arm.com/tools-and-software/simulation-models/fast-models https://www.qemu.org/ Implementation Notes -------------------- This change adds BTI landing pads even to assembly functions which are likely to be directly called only. In these cases, landing pads might be superfluous depending on what code the linker generates. Code size and performance impact for these cases would be negligible. Interaction with C code ----------------------- Pointer Authentication is a per-frame protection while Branch Target Identification can be turned on and off only for all code pages of a whole shared object or static binary. Because of these properties if C/C++ code is compiled without any of the above features but assembly files support any of them unconditionally there is no incompatibility between the two. Useful Links ------------ To fully understand the details of both PAuth and BTI it is advised to read the related chapters of the Arm Architecture Reference Manual (Arm ARM): https://developer.arm.com/documentation/ddi0487/latest/ Additional materials: "Providing protection for complex software" https://developer.arm.com/architectures/learn-the-architecture/providing-protection-for-complex-software Arm Compiler Reference Guide Version 6.14: -mbranch-protection https://developer.arm.com/documentation/101754/0614/armclang-Reference/armclang-Command-line-Options/-mbranch-protection?lang=en Arm C Language Extensions (ACLE) https://developer.arm.com/docs/101028/latest Addional Notes -------------- This patch is a copy of the work done by Tamas Petz in boringssl. It contains the changes from the following commits: aarch64: support BTI and pointer authentication in assembly Change-Id: I4335f92e2ccc8e209c7d68a0a79f1acdf3aeb791 URL: https://boringssl-review.googlesource.com/c/boringssl/+/42084 aarch64: Improve conditional compilation Change-Id: I14902a64e5f403c2b6a117bc9f5fb1a4f4611ebf URL: https://boringssl-review.googlesource.com/c/boringssl/+/43524 aarch64: Fix name of gnu property note section Change-Id: I6c432d1c852129e9c273f6469a8b60e3983671ec URL: https://boringssl-review.googlesource.com/c/boringssl/+/44024 Change-Id: I2d95ebc5e4aeb5610d3b226f9754ee80cf74a9af Reviewed-by: Paul Dale Reviewed-by: Tomas Mraz (Merged from https://github.com/openssl/openssl/pull/16674) Reviewed by: emaste, Pierre Pronchery Obtained from: OpenSSL 19e277dd19f2 Differential Revision: https://reviews.freebsd.org/D41940 (cherry picked from commit 1bd9ca8b7548e5f573ae8186f3519f4bedff3a92) --- crypto/openssl/crypto/aes/asm/aesv8-armx.pl | 18 +++++- crypto/openssl/crypto/aes/asm/vpaes-armv8.pl | 39 +++++++------ crypto/openssl/crypto/aes/build.info | 1 + crypto/openssl/crypto/arm64cpuid.pl | 10 ++++ crypto/openssl/crypto/arm_arch.h | 58 ++++++++++++++++++++ crypto/openssl/crypto/bn/asm/armv8-mont.pl | 19 +++++-- crypto/openssl/crypto/chacha/asm/chacha-armv8.pl | 18 +++--- crypto/openssl/crypto/ec/asm/ecp_nistz256-armv8.pl | 64 +++++++++++++--------- .../openssl/crypto/modes/asm/aes-gcm-armv8_64.pl | 6 ++ crypto/openssl/crypto/modes/asm/ghashv8-armx.pl | 11 ++++ .../openssl/crypto/poly1305/asm/poly1305-armv8.pl | 17 +++++- crypto/openssl/crypto/sha/asm/keccak1600-armv8.pl | 30 +++++----- crypto/openssl/crypto/sha/asm/sha1-armv8.pl | 5 +- crypto/openssl/crypto/sha/asm/sha512-armv8.pl | 11 +++- crypto/openssl/crypto/sha/build.info | 1 + 15 files changed, 228 insertions(+), 80 deletions(-) diff --git a/crypto/openssl/crypto/aes/asm/aesv8-armx.pl b/crypto/openssl/crypto/aes/asm/aesv8-armx.pl index d0e0be6187bd..30dad3d03456 100755 --- a/crypto/openssl/crypto/aes/asm/aesv8-armx.pl +++ b/crypto/openssl/crypto/aes/asm/aesv8-armx.pl @@ -120,6 +120,8 @@ ${prefix}_set_encrypt_key: .Lenc_key: ___ $code.=<<___ if ($flavour =~ /64/); + AARCH64_VALID_CALL_TARGET + // Armv8.3-A PAuth: even though x30 is pushed to stack it is not popped later. stp x29,x30,[sp,#-16]! add x29,sp,#0 ___ @@ -295,7 +297,7 @@ $code.=<<___; ${prefix}_set_decrypt_key: ___ $code.=<<___ if ($flavour =~ /64/); - .inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-16]! add x29,sp,#0 ___ @@ -339,7 +341,7 @@ $code.=<<___ if ($flavour !~ /64/); ___ $code.=<<___ if ($flavour =~ /64/); ldp x29,x30,[sp],#16 - .inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret ___ $code.=<<___; @@ -359,6 +361,11 @@ $code.=<<___; .type ${prefix}_${dir}crypt,%function .align 5 ${prefix}_${dir}crypt: +___ +$code.=<<___ if ($flavour =~ /64/); + AARCH64_VALID_CALL_TARGET +___ +$code.=<<___; ldr $rounds,[$key,#240] vld1.32 {$rndkey0},[$key],#16 vld1.8 {$inout},[$inp] @@ -442,6 +449,7 @@ $code.=<<___; ${prefix}_ecb_encrypt: ___ $code.=<<___ if ($flavour =~ /64/); + AARCH64_VALID_CALL_TARGET subs $len,$len,#16 // Original input data size bigger than 16, jump to big size processing. b.ne .Lecb_big_size @@ -1236,6 +1244,8 @@ $code.=<<___; ${prefix}_cbc_encrypt: ___ $code.=<<___ if ($flavour =~ /64/); + AARCH64_VALID_CALL_TARGET + // Armv8.3-A PAuth: even though x30 is pushed to stack it is not popped later. stp x29,x30,[sp,#-16]! add x29,sp,#0 ___ @@ -1764,6 +1774,8 @@ $code.=<<___; ${prefix}_ctr32_encrypt_blocks: ___ $code.=<<___ if ($flavour =~ /64/); + AARCH64_VALID_CALL_TARGET + // Armv8.3-A PAuth: even though x30 is pushed to stack it is not popped later. stp x29,x30,[sp,#-16]! add x29,sp,#0 ___ @@ -2256,6 +2268,7 @@ $code.=<<___ if ($flavour =~ /64/); ${prefix}_xts_encrypt: ___ $code.=<<___ if ($flavour =~ /64/); + AARCH64_VALID_CALL_TARGET cmp $len,#16 // Original input data size bigger than 16, jump to big size processing. b.ne .Lxts_enc_big_size @@ -2930,6 +2943,7 @@ $code.=<<___ if ($flavour =~ /64/); .type ${prefix}_xts_decrypt,%function .align 5 ${prefix}_xts_decrypt: + AARCH64_VALID_CALL_TARGET ___ $code.=<<___ if ($flavour =~ /64/); cmp $len,#16 diff --git a/crypto/openssl/crypto/aes/asm/vpaes-armv8.pl b/crypto/openssl/crypto/aes/asm/vpaes-armv8.pl index dcd5065e68c0..49988e9c2b29 100755 --- a/crypto/openssl/crypto/aes/asm/vpaes-armv8.pl +++ b/crypto/openssl/crypto/aes/asm/vpaes-armv8.pl @@ -53,6 +53,8 @@ open OUT,"| \"$^X\" $xlate $flavour \"$output\"" *STDOUT=*OUT; $code.=<<___; +#include "arm_arch.h" + .text .type _vpaes_consts,%object @@ -259,7 +261,7 @@ _vpaes_encrypt_core: .type vpaes_encrypt,%function .align 4 vpaes_encrypt: - .inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-16]! add x29,sp,#0 @@ -269,7 +271,7 @@ vpaes_encrypt: st1 {v0.16b}, [$out] ldp x29,x30,[sp],#16 - .inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size vpaes_encrypt,.-vpaes_encrypt @@ -492,7 +494,7 @@ _vpaes_decrypt_core: .type vpaes_decrypt,%function .align 4 vpaes_decrypt: - .inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-16]! add x29,sp,#0 @@ -502,7 +504,7 @@ vpaes_decrypt: st1 {v0.16b}, [$out] ldp x29,x30,[sp],#16 - .inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size vpaes_decrypt,.-vpaes_decrypt @@ -673,7 +675,7 @@ _vpaes_key_preheat: .type _vpaes_schedule_core,%function .align 4 _vpaes_schedule_core: - .inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29, x30, [sp,#-16]! add x29,sp,#0 @@ -838,7 +840,7 @@ _vpaes_schedule_core: eor v6.16b, v6.16b, v6.16b // vpxor %xmm6, %xmm6, %xmm6 eor v7.16b, v7.16b, v7.16b // vpxor %xmm7, %xmm7, %xmm7 ldp x29, x30, [sp],#16 - .inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size _vpaes_schedule_core,.-_vpaes_schedule_core @@ -1051,7 +1053,7 @@ _vpaes_schedule_mangle: .type vpaes_set_encrypt_key,%function .align 4 vpaes_set_encrypt_key: - .inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-16]! add x29,sp,#0 stp d8,d9,[sp,#-16]! // ABI spec says so @@ -1067,7 +1069,7 @@ vpaes_set_encrypt_key: ldp d8,d9,[sp],#16 ldp x29,x30,[sp],#16 - .inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size vpaes_set_encrypt_key,.-vpaes_set_encrypt_key @@ -1075,7 +1077,7 @@ vpaes_set_encrypt_key: .type vpaes_set_decrypt_key,%function .align 4 vpaes_set_decrypt_key: - .inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-16]! add x29,sp,#0 stp d8,d9,[sp,#-16]! // ABI spec says so @@ -1095,7 +1097,7 @@ vpaes_set_decrypt_key: ldp d8,d9,[sp],#16 ldp x29,x30,[sp],#16 - .inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size vpaes_set_decrypt_key,.-vpaes_set_decrypt_key ___ @@ -1108,11 +1110,11 @@ $code.=<<___; .type vpaes_cbc_encrypt,%function .align 4 vpaes_cbc_encrypt: + AARCH64_SIGN_LINK_REGISTER cbz $len, .Lcbc_abort cmp w5, #0 // check direction b.eq vpaes_cbc_decrypt - .inst 0xd503233f // paciasp stp x29,x30,[sp,#-16]! add x29,sp,#0 @@ -1135,15 +1137,16 @@ vpaes_cbc_encrypt: st1 {v0.16b}, [$ivec] // write ivec ldp x29,x30,[sp],#16 - .inst 0xd50323bf // autiasp .Lcbc_abort: + AARCH64_VALIDATE_LINK_REGISTER ret .size vpaes_cbc_encrypt,.-vpaes_cbc_encrypt .type vpaes_cbc_decrypt,%function .align 4 vpaes_cbc_decrypt: - .inst 0xd503233f // paciasp + // Not adding AARCH64_SIGN_LINK_REGISTER here because vpaes_cbc_decrypt is jumped to + // only from vpaes_cbc_encrypt which has already signed the return address. stp x29,x30,[sp,#-16]! add x29,sp,#0 stp d8,d9,[sp,#-16]! // ABI spec says so @@ -1185,7 +1188,7 @@ vpaes_cbc_decrypt: ldp d10,d11,[sp],#16 ldp d8,d9,[sp],#16 ldp x29,x30,[sp],#16 - .inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size vpaes_cbc_decrypt,.-vpaes_cbc_decrypt ___ @@ -1195,7 +1198,7 @@ $code.=<<___; .type vpaes_ecb_encrypt,%function .align 4 vpaes_ecb_encrypt: - .inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-16]! add x29,sp,#0 stp d8,d9,[sp,#-16]! // ABI spec says so @@ -1229,7 +1232,7 @@ vpaes_ecb_encrypt: ldp d10,d11,[sp],#16 ldp d8,d9,[sp],#16 ldp x29,x30,[sp],#16 - .inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size vpaes_ecb_encrypt,.-vpaes_ecb_encrypt @@ -1237,7 +1240,7 @@ vpaes_ecb_encrypt: .type vpaes_ecb_decrypt,%function .align 4 vpaes_ecb_decrypt: - .inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-16]! add x29,sp,#0 stp d8,d9,[sp,#-16]! // ABI spec says so @@ -1271,7 +1274,7 @@ vpaes_ecb_decrypt: ldp d10,d11,[sp],#16 ldp d8,d9,[sp],#16 ldp x29,x30,[sp],#16 - .inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size vpaes_ecb_decrypt,.-vpaes_ecb_decrypt ___ diff --git a/crypto/openssl/crypto/aes/build.info b/crypto/openssl/crypto/aes/build.info index 271015e35e1b..dec340779281 100644 --- a/crypto/openssl/crypto/aes/build.info +++ b/crypto/openssl/crypto/aes/build.info @@ -116,6 +116,7 @@ INCLUDE[aes-mips.o]=.. GENERATE[aesv8-armx.S]=asm/aesv8-armx.pl INCLUDE[aesv8-armx.o]=.. GENERATE[vpaes-armv8.S]=asm/vpaes-armv8.pl +INCLUDE[vpaes-armv8.o]=.. GENERATE[aes-armv4.S]=asm/aes-armv4.pl INCLUDE[aes-armv4.o]=.. diff --git a/crypto/openssl/crypto/arm64cpuid.pl b/crypto/openssl/crypto/arm64cpuid.pl index ac76dd449f37..11f0e5027942 100755 --- a/crypto/openssl/crypto/arm64cpuid.pl +++ b/crypto/openssl/crypto/arm64cpuid.pl @@ -31,6 +31,7 @@ $code.=<<___; .globl _armv7_neon_probe .type _armv7_neon_probe,%function _armv7_neon_probe: + AARCH64_VALID_CALL_TARGET orr v15.16b, v15.16b, v15.16b ret .size _armv7_neon_probe,.-_armv7_neon_probe @@ -38,6 +39,7 @@ _armv7_neon_probe: .globl _armv7_tick .type _armv7_tick,%function _armv7_tick: + AARCH64_VALID_CALL_TARGET #ifdef __APPLE__ mrs x0, CNTPCT_EL0 #else @@ -49,6 +51,7 @@ _armv7_tick: .globl _armv8_aes_probe .type _armv8_aes_probe,%function _armv8_aes_probe: + AARCH64_VALID_CALL_TARGET aese v0.16b, v0.16b ret .size _armv8_aes_probe,.-_armv8_aes_probe @@ -56,6 +59,7 @@ _armv8_aes_probe: .globl _armv8_sha1_probe .type _armv8_sha1_probe,%function _armv8_sha1_probe: + AARCH64_VALID_CALL_TARGET sha1h s0, s0 ret .size _armv8_sha1_probe,.-_armv8_sha1_probe @@ -63,6 +67,7 @@ _armv8_sha1_probe: .globl _armv8_sha256_probe .type _armv8_sha256_probe,%function _armv8_sha256_probe: + AARCH64_VALID_CALL_TARGET sha256su0 v0.4s, v0.4s ret .size _armv8_sha256_probe,.-_armv8_sha256_probe @@ -70,6 +75,7 @@ _armv8_sha256_probe: .globl _armv8_pmull_probe .type _armv8_pmull_probe,%function _armv8_pmull_probe: + AARCH64_VALID_CALL_TARGET pmull v0.1q, v0.1d, v0.1d ret .size _armv8_pmull_probe,.-_armv8_pmull_probe @@ -77,6 +83,7 @@ _armv8_pmull_probe: .globl _armv8_sha512_probe .type _armv8_sha512_probe,%function _armv8_sha512_probe: + AARCH64_VALID_CALL_TARGET .long 0xcec08000 // sha512su0 v0.2d,v0.2d ret .size _armv8_sha512_probe,.-_armv8_sha512_probe @@ -84,6 +91,7 @@ _armv8_sha512_probe: .globl _armv8_cpuid_probe .type _armv8_cpuid_probe,%function _armv8_cpuid_probe: + AARCH64_VALID_CALL_TARGET mrs x0, midr_el1 ret .size _armv8_cpuid_probe,.-_armv8_cpuid_probe @@ -92,6 +100,7 @@ _armv8_cpuid_probe: .type OPENSSL_cleanse,%function .align 5 OPENSSL_cleanse: + AARCH64_VALID_CALL_TARGET cbz x1,.Lret // len==0? cmp x1,#15 b.hi .Lot // len>15 @@ -123,6 +132,7 @@ OPENSSL_cleanse: .type CRYPTO_memcmp,%function .align 4 CRYPTO_memcmp: + AARCH64_VALID_CALL_TARGET eor w3,w3,w3 cbz x2,.Lno_data // len==0? cmp x2,#16 diff --git a/crypto/openssl/crypto/arm_arch.h b/crypto/openssl/crypto/arm_arch.h index ec4a087fede2..7bedb385d971 100644 --- a/crypto/openssl/crypto/arm_arch.h +++ b/crypto/openssl/crypto/arm_arch.h @@ -121,4 +121,62 @@ extern unsigned int OPENSSL_armv8_rsa_neonized; # define MIDR_IS_CPU_MODEL(midr, imp, partnum) \ (((midr) & MIDR_CPU_MODEL_MASK) == MIDR_CPU_MODEL(imp, partnum)) + +#if defined(__ASSEMBLER__) + + /* + * Support macros for + * - Armv8.3-A Pointer Authentication and + * - Armv8.5-A Branch Target Identification + * features which require emitting a .note.gnu.property section with the + * appropriate architecture-dependent feature bits set. + * Read more: "ELF for the ArmĀ® 64-bit Architecture" + */ + +# if defined(__ARM_FEATURE_BTI_DEFAULT) && __ARM_FEATURE_BTI_DEFAULT == 1 +# define GNU_PROPERTY_AARCH64_BTI (1 << 0) /* Has Branch Target Identification */ +# define AARCH64_VALID_CALL_TARGET hint #34 /* BTI 'c' */ +# else +# define GNU_PROPERTY_AARCH64_BTI 0 /* No Branch Target Identification */ +# define AARCH64_VALID_CALL_TARGET +# endif + +# if defined(__ARM_FEATURE_PAC_DEFAULT) && \ + (__ARM_FEATURE_PAC_DEFAULT & 1) == 1 /* Signed with A-key */ +# define GNU_PROPERTY_AARCH64_POINTER_AUTH \ + (1 << 1) /* Has Pointer Authentication */ +# define AARCH64_SIGN_LINK_REGISTER hint #25 /* PACIASP */ +# define AARCH64_VALIDATE_LINK_REGISTER hint #29 /* AUTIASP */ +# elif defined(__ARM_FEATURE_PAC_DEFAULT) && \ + (__ARM_FEATURE_PAC_DEFAULT & 2) == 2 /* Signed with B-key */ +# define GNU_PROPERTY_AARCH64_POINTER_AUTH \ + (1 << 1) /* Has Pointer Authentication */ +# define AARCH64_SIGN_LINK_REGISTER hint #27 /* PACIBSP */ +# define AARCH64_VALIDATE_LINK_REGISTER hint #31 /* AUTIBSP */ +# else +# define GNU_PROPERTY_AARCH64_POINTER_AUTH 0 /* No Pointer Authentication */ +# if GNU_PROPERTY_AARCH64_BTI != 0 +# define AARCH64_SIGN_LINK_REGISTER AARCH64_VALID_CALL_TARGET +# else +# define AARCH64_SIGN_LINK_REGISTER +# endif +# define AARCH64_VALIDATE_LINK_REGISTER +# endif + +# if GNU_PROPERTY_AARCH64_POINTER_AUTH != 0 || GNU_PROPERTY_AARCH64_BTI != 0 + .pushsection .note.gnu.property, "a"; + .balign 8; + .long 4; + .long 0x10; + .long 0x5; + .asciz "GNU"; + .long 0xc0000000; /* GNU_PROPERTY_AARCH64_FEATURE_1_AND */ + .long 4; + .long (GNU_PROPERTY_AARCH64_POINTER_AUTH | GNU_PROPERTY_AARCH64_BTI); + .long 0; + .popsection; +# endif + +# endif /* defined __ASSEMBLER__ */ + #endif diff --git a/crypto/openssl/crypto/bn/asm/armv8-mont.pl b/crypto/openssl/crypto/bn/asm/armv8-mont.pl index 54d2e8245f15..21ab12bdf07e 100755 --- a/crypto/openssl/crypto/bn/asm/armv8-mont.pl +++ b/crypto/openssl/crypto/bn/asm/armv8-mont.pl @@ -67,8 +67,8 @@ $n0="x4"; # const BN_ULONG *n0, $num="x5"; # int num); $code.=<<___; +#include "arm_arch.h" #ifndef __KERNEL__ -# include "arm_arch.h" .extern OPENSSL_armv8_rsa_neonized .hidden OPENSSL_armv8_rsa_neonized #endif @@ -78,6 +78,7 @@ $code.=<<___; .type bn_mul_mont,%function .align 5 bn_mul_mont: + AARCH64_SIGN_LINK_REGISTER .Lbn_mul_mont: tst $num,#3 b.ne .Lmul_mont @@ -288,6 +289,7 @@ bn_mul_mont: mov x0,#1 ldp x23,x24,[x29,#48] ldr x29,[sp],#64 + AARCH64_VALIDATE_LINK_REGISTER ret .size bn_mul_mont,.-bn_mul_mont ___ @@ -309,6 +311,8 @@ $code.=<<___; .type bn_mul8x_mont_neon,%function .align 5 bn_mul8x_mont_neon: + // Not adding AARCH64_SIGN_LINK_REGISTER here because bn_mul8x_mont_neon is jumped to + // only from bn_mul_mont which has already signed the return address. stp x29,x30,[sp,#-80]! mov x16,sp stp d8,d9,[sp,#16] @@ -649,6 +653,7 @@ $code.=<<___; ldp d10,d11,[sp,#32] ldp d8,d9,[sp,#16] ldr x29,[sp],#80 + AARCH64_VALIDATE_LINK_REGISTER ret // bx lr .size bn_mul8x_mont_neon,.-bn_mul8x_mont_neon @@ -671,7 +676,8 @@ __bn_sqr8x_mont: cmp $ap,$bp b.ne __bn_mul4x_mont .Lsqr8x_mont: - .inst 0xd503233f // paciasp + // Not adding AARCH64_SIGN_LINK_REGISTER here because __bn_sqr8x_mont is jumped to + // only from bn_mul_mont which has already signed the return address. stp x29,x30,[sp,#-128]! add x29,sp,#0 stp x19,x20,[sp,#16] @@ -1425,7 +1431,8 @@ $code.=<<___; ldp x25,x26,[x29,#64] ldp x27,x28,[x29,#80] ldr x29,[sp],#128 - .inst 0xd50323bf // autiasp + // x30 is loaded earlier + AARCH64_VALIDATE_LINK_REGISTER ret .size __bn_sqr8x_mont,.-__bn_sqr8x_mont ___ @@ -1449,7 +1456,8 @@ $code.=<<___; .type __bn_mul4x_mont,%function .align 5 __bn_mul4x_mont: - .inst 0xd503233f // paciasp + // Not adding AARCH64_SIGN_LINK_REGISTER here because __bn_mul4x_mont is jumped to + // only from bn_mul_mont (or __bn_sqr8x_mont from bn_mul_mont) which has already signed the return address. stp x29,x30,[sp,#-128]! add x29,sp,#0 stp x19,x20,[sp,#16] @@ -1883,7 +1891,8 @@ __bn_mul4x_mont: ldp x25,x26,[x29,#64] ldp x27,x28,[x29,#80] ldr x29,[sp],#128 - .inst 0xd50323bf // autiasp + // x30 loaded earlier + AARCH64_VALIDATE_LINK_REGISTER ret .size __bn_mul4x_mont,.-__bn_mul4x_mont ___ diff --git a/crypto/openssl/crypto/chacha/asm/chacha-armv8.pl b/crypto/openssl/crypto/chacha/asm/chacha-armv8.pl index dcdc4a04e367..e1a8b8159421 100755 --- a/crypto/openssl/crypto/chacha/asm/chacha-armv8.pl +++ b/crypto/openssl/crypto/chacha/asm/chacha-armv8.pl @@ -132,8 +132,8 @@ my ($a3,$b3,$c3,$d3)=map(($_&~3)+(($_+1)&3),($a2,$b2,$c2,$d2)); } $code.=<<___; +#include "arm_arch.h" #ifndef __KERNEL__ -# include "arm_arch.h" .extern OPENSSL_armcap_P .hidden OPENSSL_armcap_P #endif @@ -153,6 +153,7 @@ $code.=<<___; .type ChaCha20_ctr32,%function .align 5 ChaCha20_ctr32: + AARCH64_SIGN_LINK_REGISTER cbz $len,.Labort cmp $len,#192 b.lo .Lshort @@ -165,7 +166,6 @@ ChaCha20_ctr32: #endif .Lshort: - .inst 0xd503233f // paciasp stp x29,x30,[sp,#-96]! add x29,sp,#0 @@ -285,8 +285,8 @@ $code.=<<___; ldp x25,x26,[x29,#64] ldp x27,x28,[x29,#80] ldp x29,x30,[sp],#96 - .inst 0xd50323bf // autiasp .Labort: + AARCH64_VALIDATE_LINK_REGISTER ret .align 4 @@ -342,7 +342,7 @@ $code.=<<___; ldp x25,x26,[x29,#64] ldp x27,x28,[x29,#80] ldp x29,x30,[sp],#96 - .inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ChaCha20_ctr32,.-ChaCha20_ctr32 ___ @@ -432,8 +432,8 @@ $code.=<<___; .type ChaCha20_neon,%function .align 5 ChaCha20_neon: + AARCH64_SIGN_LINK_REGISTER .LChaCha20_neon: - .inst 0xd503233f // paciasp stp x29,x30,[sp,#-96]! add x29,sp,#0 @@ -667,7 +667,7 @@ $code.=<<___; ldp x25,x26,[x29,#64] ldp x27,x28,[x29,#80] ldp x29,x30,[sp],#96 - .inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .align 4 @@ -799,7 +799,7 @@ $code.=<<___; ldp x25,x26,[x29,#64] ldp x27,x28,[x29,#80] ldp x29,x30,[sp],#96 - .inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ChaCha20_neon,.-ChaCha20_neon ___ @@ -844,7 +844,7 @@ $code.=<<___; .type ChaCha20_512_neon,%function .align 5 ChaCha20_512_neon: - .inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-96]! add x29,sp,#0 @@ -1268,7 +1268,7 @@ $code.=<<___; ldp x25,x26,[x29,#64] ldp x27,x28,[x29,#80] ldp x29,x30,[sp],#96 - .inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ChaCha20_512_neon,.-ChaCha20_512_neon ___ diff --git a/crypto/openssl/crypto/ec/asm/ecp_nistz256-armv8.pl b/crypto/openssl/crypto/ec/asm/ecp_nistz256-armv8.pl index 81ee3947d7e4..6c5d0e8b3cf0 100755 --- a/crypto/openssl/crypto/ec/asm/ecp_nistz256-armv8.pl +++ b/crypto/openssl/crypto/ec/asm/ecp_nistz256-armv8.pl @@ -122,7 +122,7 @@ $code.=<<___; .type ecp_nistz256_to_mont,%function .align 6 ecp_nistz256_to_mont: - .inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-32]! add x29,sp,#0 stp x19,x20,[sp,#16] @@ -138,7 +138,7 @@ ecp_nistz256_to_mont: ldp x19,x20,[sp,#16] ldp x29,x30,[sp],#32 - .inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ecp_nistz256_to_mont,.-ecp_nistz256_to_mont @@ -147,7 +147,7 @@ ecp_nistz256_to_mont: .type ecp_nistz256_from_mont,%function .align 4 ecp_nistz256_from_mont: - .inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-32]! add x29,sp,#0 stp x19,x20,[sp,#16] @@ -163,7 +163,7 @@ ecp_nistz256_from_mont: ldp x19,x20,[sp,#16] ldp x29,x30,[sp],#32 - .inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ecp_nistz256_from_mont,.-ecp_nistz256_from_mont @@ -173,7 +173,7 @@ ecp_nistz256_from_mont: .type ecp_nistz256_mul_mont,%function .align 4 ecp_nistz256_mul_mont: - .inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-32]! add x29,sp,#0 stp x19,x20,[sp,#16] @@ -188,7 +188,7 @@ ecp_nistz256_mul_mont: ldp x19,x20,[sp,#16] ldp x29,x30,[sp],#32 - .inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ecp_nistz256_mul_mont,.-ecp_nistz256_mul_mont @@ -197,7 +197,7 @@ ecp_nistz256_mul_mont: .type ecp_nistz256_sqr_mont,%function .align 4 ecp_nistz256_sqr_mont: - .inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-32]! add x29,sp,#0 stp x19,x20,[sp,#16] @@ -211,7 +211,7 @@ ecp_nistz256_sqr_mont: ldp x19,x20,[sp,#16] ldp x29,x30,[sp],#32 - .inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ecp_nistz256_sqr_mont,.-ecp_nistz256_sqr_mont @@ -221,7 +221,7 @@ ecp_nistz256_sqr_mont: .type ecp_nistz256_add,%function .align 4 ecp_nistz256_add: - .inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-16]! add x29,sp,#0 @@ -235,7 +235,7 @@ ecp_nistz256_add: bl __ecp_nistz256_add ldp x29,x30,[sp],#16 - .inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ecp_nistz256_add,.-ecp_nistz256_add @@ -244,7 +244,7 @@ ecp_nistz256_add: .type ecp_nistz256_div_by_2,%function .align 4 ecp_nistz256_div_by_2: - .inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-16]! add x29,sp,#0 @@ -256,7 +256,7 @@ ecp_nistz256_div_by_2: bl __ecp_nistz256_div_by_2 ldp x29,x30,[sp],#16 - .inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ecp_nistz256_div_by_2,.-ecp_nistz256_div_by_2 @@ -265,7 +265,7 @@ ecp_nistz256_div_by_2: .type ecp_nistz256_mul_by_2,%function .align 4 ecp_nistz256_mul_by_2: - .inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-16]! add x29,sp,#0 @@ -281,7 +281,7 @@ ecp_nistz256_mul_by_2: bl __ecp_nistz256_add // ret = a+a // 2*a ldp x29,x30,[sp],#16 - .inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ecp_nistz256_mul_by_2,.-ecp_nistz256_mul_by_2 @@ -290,7 +290,7 @@ ecp_nistz256_mul_by_2: .type ecp_nistz256_mul_by_3,%function .align 4 ecp_nistz256_mul_by_3: - .inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-16]! add x29,sp,#0 @@ -317,7 +317,7 @@ ecp_nistz256_mul_by_3: bl __ecp_nistz256_add // ret += a // 2*a+a=3*a ldp x29,x30,[sp],#16 - .inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ecp_nistz256_mul_by_3,.-ecp_nistz256_mul_by_3 @@ -327,7 +327,7 @@ ecp_nistz256_mul_by_3: .type ecp_nistz256_sub,%function .align 4 ecp_nistz256_sub: - .inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-16]! add x29,sp,#0 *** 544 LINES SKIPPED *** From nobody Mon Jul 15 12:37:50 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1v3197jz5QrTR; Mon, 15 Jul 2024 12:37: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1v30CHwz4GQH; Mon, 15 Jul 2024 12:37:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047071; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=4yoHhdZs6bA1aTTKj1nsT+sJKa7/cxKb8AnSJMhsgVw=; b=y3vNyJ7Dp6Y/rjQXmJt0/ovNl3E+sXK3Ntq//lkYXOOXYVBtJr7/Uwc+LsD5BHC/IGLkvf sJKD/Wa5YrIX/xZLv8HSsF0IXSkoYHgBz7eLv1WERpN9vy0akbLdyV4bfxIsFxJn0LXNlD Sw8f0zheoow3TK0MOEof+E/muTnK0t14lX52oX1L8aZ4Cyjib70SwGJ9QkBX7m34DPE9fg RPkkGBMdi3sM52C9gI8m5b4Uz7W32j95AtYc4bLPgAHSSlIpbbqi82/9KCn4/Die66L2RP h/6h9mJCZZHJKjrG/mUThH6lHca1ocyC8htxRhF7zWeISpQTARLrnTIlYwlLpQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047071; a=rsa-sha256; cv=none; b=ucYXWZ7AlvzXk8B7kgvURd9dpjHuf/0pMrniXXEVjzVZthw1qMfa3DoiVaOT3xy+RNYaKY 2qH5y5hJkGaffuYLcgWwwH12IhDwENgxC3iqFjlSm0o/q7CmSW3j3AjB0Yvmen5ZNnShAN HxfYup92AMFSe6zyp7DIg1T+MpNNUDLYbXewpf6qPe3aHk611EfptTk9q498wwuFkRDDxS wEkQ1NQplrnDd8L5QLgSP/D2fp1DJmgJs640A+rZ5kL7+bMVkCNuvu1c345pkyjS+8BvgY HkTmern2zDw+MDJEK08Q0gTL5a3GYb50NZ9hyis6rsgtyYTXcMZIWroTv6Pj6A== 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=1721047071; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=4yoHhdZs6bA1aTTKj1nsT+sJKa7/cxKb8AnSJMhsgVw=; b=nYZm2g/KiVm9PwYnW2otmsRbfjnEY3RONO4/DJHM4vioGYf7Ivhq3G1ncsx7XfFkbvZOuG b4kfTAQgOH4TyATSSratyWBDP0UfZCawQPpkJy8SUrUrSF/PZxNpSwT4/fElZH3JGP+Mys pBbNikfVQqxtdHUnCY1kFULqCAI0PeBioomeBKgDvx1fiN5hSFl+m+yaRwY1YfRCsrXnRE KRxTMmFOoEbiwVKyqY4unGApvyYaBoleUSPv3y5OB4BwfL3CrzEMk7yc0iIOuliXZzuF+j b2OGy5kQ3mK3F6sL7f1zTjT4pQR3pMsYD+8eKZ36aaHBkHqGA+LHydHvjV5IZg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1v26wbTzscZ; Mon, 15 Jul 2024 12:37:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCboVb058268; Mon, 15 Jul 2024 12:37:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCboID058265; Mon, 15 Jul 2024 12:37:50 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:37:50 GMT Message-Id: <202407151237.46FCboID058265@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: c9dc783efbab - stable/14 - aarch64: fix branch target indications in arm64cpuid.pl and keccak1600 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: c9dc783efbab0fc6dd29cd58343c92699661cf98 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=c9dc783efbab0fc6dd29cd58343c92699661cf98 commit c9dc783efbab0fc6dd29cd58343c92699661cf98 Author: Tom Cosgrove AuthorDate: 2022-02-07 14:44:56 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 08:09:43 +0000 aarch64: fix branch target indications in arm64cpuid.pl and keccak1600 Add missing AARCH64_VALID_CALL_TARGET to armv8_rng_probe(). Also add these to the functions defined by gen_random(), and note that this Perl sub prints the assembler out directly, not going via the $code xlate mechanism (and therefore coming before the include of arm_arch.h). So fix this too. In KeccakF1600_int, AARCH64_SIGN_LINK_REGISTER functions as AARCH64_VALID_CALL_TARGET on BTI-only builds, so it needs to come before the 'adr' line. Change-Id: If241efe71591c88253a3e36647ced00300c3c1a3 Reviewed-by: Tomas Mraz Reviewed-by: Paul Dale (Merged from https://github.com/openssl/openssl/pull/17653) Obtained from: OpenSSL 3a23f01268ec (cherry picked from commit 41777819236110907dd4cff98ef70dfd0629f744) --- crypto/openssl/crypto/sha/asm/keccak1600-armv8.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crypto/openssl/crypto/sha/asm/keccak1600-armv8.pl b/crypto/openssl/crypto/sha/asm/keccak1600-armv8.pl index cf54b62c636a..40f7aa7a695a 100755 --- a/crypto/openssl/crypto/sha/asm/keccak1600-armv8.pl +++ b/crypto/openssl/crypto/sha/asm/keccak1600-armv8.pl @@ -126,8 +126,8 @@ $code.=<<___; .type KeccakF1600_int,%function .align 5 KeccakF1600_int: - adr $C[2],iotas AARCH64_SIGN_LINK_REGISTER + adr $C[2],iotas stp $C[2],x30,[sp,#16] // 32 bytes on top are mine b .Loop .align 4 From nobody Mon Jul 15 12:37:51 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1v42Bwpz5QrFn; Mon, 15 Jul 2024 12:37: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1v41Qqfz4GVh; Mon, 15 Jul 2024 12:37:52 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047072; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=i4SiZxjW9LerZPxwNufrxAjK99mudGOiln/I38Et0nQ=; b=Q+o7d8tLnwJn/2p7dUwAhPQ0D2AnY+K9RvFfbQ/WIjxxbWIOmBTL2oDCBUVQkAJzZfm16M tPQXPe/uu5DZ97v9iG2+1aK4qSZ9wHb++fqhATpFIjvG8Qt3wPfLBwcB54z5pACZFTKs7+ lmyEMoDYF1/OWLdm6ivlhuvt8sFbFycYuUa2mk1ssP6H7Fru40xRNd0qreoaKT/MN/6b/j xrT20tZVnMHRMb1fGmkX3N4Rsp1Kv7Gh687p7x2ie7ao8ypSh5ikOuWAui0bID+GuN1oal NTWBQ8r4AOZ00cN0G1iaG/zQoscFT775cn3Copgbe4PTHpduU8N/O7xmiBtVXg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047072; a=rsa-sha256; cv=none; b=bvnPXQZuOzYuU9gJB7hzys0AxkRNDTFoOZvjx2Mfk4SZMmXuDJYivPiaH9u0P/iMyO1Tts p1AyfLjsdeHi2hsmzpNrR4AZTFK3tvnoGGqCOCXWeVWTc+koCZaKaHJEXtRdB7iHR0s+/K Q9lq8eNYw0tS02/NlgHDFl2AwTX3Kp4rbl4/6hVtIDnwYg8lkv4kxZs27hms7ix0EL6kZY FL+zWmymfnl1SqBUCik1SPeryfFOUnhpo8deuLU3hZTyn99QXJpyBMSgsfLrxrRdG69LY5 9DEPcJD2C2m3SfxvxwAT+enL8Vgo69AeNbJJ81CIFGA0WHWWXbRqHjA6Vfg/bA== 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=1721047072; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=i4SiZxjW9LerZPxwNufrxAjK99mudGOiln/I38Et0nQ=; b=bp5Yx3QD3P7GXkaqOZ9VTm4s1xsGTysBj4OQLYq/GppKjT8bLN8sZFbK0+lhM1f2NMlk7y WtgmemvuDHRe3oY0oDj8IIQevSTFWj3P0r3HMBJ2wBH8o/9VU2XOlkRoefdYoYt1seLy8E 5See616ibGk95G/VUYHldYJcwlVDnKdSE5tLbR1sJGYOvKA96MJpqyMWZFajMn8rbqZK+d G24QBsQBGMXDG/Yd2aeycatQrQLvAdMA9pBj7K3Kpak6ItOQwWFHfIJxgA/JXSeDUXaEvJ VVhDxzRBXRlui/AzyaDxiAa7uHExicT+lPYvotYVhc5KTltc+NqSdfXr42XjNg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1v40SNzzsJG; Mon, 15 Jul 2024 12:37:52 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCbqeh058310; Mon, 15 Jul 2024 12:37:52 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCbpW9058307; Mon, 15 Jul 2024 12:37:51 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:37:51 GMT Message-Id: <202407151237.46FCbpW9058307@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 98768d6870cc - stable/14 - ossl: Rebuild the openssl asm List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 98768d6870cc30303a80d2d8c888f0daa3f1ad4a Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=98768d6870cc30303a80d2d8c888f0daa3f1ad4a commit 98768d6870cc30303a80d2d8c888f0daa3f1ad4a Author: Andrew Turner AuthorDate: 2023-09-21 13:06:54 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 08:09:43 +0000 ossl: Rebuild the openssl asm This adds the new BTI instructions when needed to the arm64 assembly. Sponsored by: Arm Ltd Reviewed by: Pierre Pronchery (earlier version) Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D41941 (cherry picked from commit bd9588bca05f5cbdeac6e5f9f426b2589301d7c6) --- sys/crypto/openssl/aarch64/aes-gcm-armv8_64.S | 6 +++ sys/crypto/openssl/aarch64/aesv8-armx.S | 15 +++++- sys/crypto/openssl/aarch64/arm64cpuid.S | 10 ++++ sys/crypto/openssl/aarch64/armv8-mont.S | 19 ++++++-- sys/crypto/openssl/aarch64/chacha-armv8.S | 18 +++---- sys/crypto/openssl/aarch64/ecp_nistz256-armv8.S | 64 +++++++++++++++---------- sys/crypto/openssl/aarch64/ghashv8-armx.S | 3 ++ sys/crypto/openssl/aarch64/keccak1600-armv8.S | 30 ++++++------ sys/crypto/openssl/aarch64/poly1305-armv8.S | 17 ++++++- sys/crypto/openssl/aarch64/sha1-armv8.S | 5 +- sys/crypto/openssl/aarch64/sha256-armv8.S | 10 ++-- sys/crypto/openssl/aarch64/sha512-armv8.S | 8 ++-- sys/crypto/openssl/aarch64/vpaes-armv8.S | 39 ++++++++------- sys/crypto/openssl/arm_arch.h | 58 ++++++++++++++++++++++ 14 files changed, 219 insertions(+), 83 deletions(-) diff --git a/sys/crypto/openssl/aarch64/aes-gcm-armv8_64.S b/sys/crypto/openssl/aarch64/aes-gcm-armv8_64.S index eb85dbc9f996..55856548fa6f 100644 --- a/sys/crypto/openssl/aarch64/aes-gcm-armv8_64.S +++ b/sys/crypto/openssl/aarch64/aes-gcm-armv8_64.S @@ -8,6 +8,7 @@ .type aes_gcm_enc_128_kernel,%function .align 4 aes_gcm_enc_128_kernel: + AARCH64_VALID_CALL_TARGET cbz x1, .L128_enc_ret stp x19, x20, [sp, #-112]! mov x16, x4 @@ -990,6 +991,7 @@ aes_gcm_enc_128_kernel: .type aes_gcm_dec_128_kernel,%function .align 4 aes_gcm_dec_128_kernel: + AARCH64_VALID_CALL_TARGET cbz x1, .L128_dec_ret stp x19, x20, [sp, #-112]! mov x16, x4 @@ -1982,6 +1984,7 @@ aes_gcm_dec_128_kernel: .type aes_gcm_enc_192_kernel,%function .align 4 aes_gcm_enc_192_kernel: + AARCH64_VALID_CALL_TARGET cbz x1, .L192_enc_ret stp x19, x20, [sp, #-112]! mov x16, x4 @@ -3039,6 +3042,7 @@ aes_gcm_enc_192_kernel: .type aes_gcm_dec_192_kernel,%function .align 4 aes_gcm_dec_192_kernel: + AARCH64_VALID_CALL_TARGET cbz x1, .L192_dec_ret stp x19, x20, [sp, #-112]! mov x16, x4 @@ -4106,6 +4110,7 @@ aes_gcm_dec_192_kernel: .type aes_gcm_enc_256_kernel,%function .align 4 aes_gcm_enc_256_kernel: + AARCH64_VALID_CALL_TARGET cbz x1, .L256_enc_ret stp x19, x20, [sp, #-112]! mov x16, x4 @@ -5230,6 +5235,7 @@ aes_gcm_enc_256_kernel: .type aes_gcm_dec_256_kernel,%function .align 4 aes_gcm_dec_256_kernel: + AARCH64_VALID_CALL_TARGET cbz x1, .L256_dec_ret stp x19, x20, [sp, #-112]! mov x16, x4 diff --git a/sys/crypto/openssl/aarch64/aesv8-armx.S b/sys/crypto/openssl/aarch64/aesv8-armx.S index 7666667e4782..015c2eea6dbb 100644 --- a/sys/crypto/openssl/aarch64/aesv8-armx.S +++ b/sys/crypto/openssl/aarch64/aesv8-armx.S @@ -15,6 +15,8 @@ .align 5 aes_v8_set_encrypt_key: .Lenc_key: + AARCH64_VALID_CALL_TARGET + // Armv8.3-A PAuth: even though x30 is pushed to stack it is not popped later. stp x29,x30,[sp,#-16]! add x29,sp,#0 mov x3,#-1 @@ -186,7 +188,7 @@ aes_v8_set_encrypt_key: .type aes_v8_set_decrypt_key,%function .align 5 aes_v8_set_decrypt_key: -.inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-16]! add x29,sp,#0 bl .Lenc_key @@ -220,13 +222,14 @@ aes_v8_set_decrypt_key: eor x0,x0,x0 // return value .Ldec_key_abort: ldp x29,x30,[sp],#16 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size aes_v8_set_decrypt_key,.-aes_v8_set_decrypt_key .globl aes_v8_encrypt .type aes_v8_encrypt,%function .align 5 aes_v8_encrypt: + AARCH64_VALID_CALL_TARGET ldr w3,[x2,#240] ld1 {v0.4s},[x2],#16 ld1 {v2.16b},[x0] @@ -256,6 +259,7 @@ aes_v8_encrypt: .type aes_v8_decrypt,%function .align 5 aes_v8_decrypt: + AARCH64_VALID_CALL_TARGET ldr w3,[x2,#240] ld1 {v0.4s},[x2],#16 ld1 {v2.16b},[x0] @@ -285,6 +289,7 @@ aes_v8_decrypt: .type aes_v8_ecb_encrypt,%function .align 5 aes_v8_ecb_encrypt: + AARCH64_VALID_CALL_TARGET subs x2,x2,#16 // Original input data size bigger than 16, jump to big size processing. b.ne .Lecb_big_size @@ -1031,6 +1036,8 @@ aes_v8_ecb_encrypt: .type aes_v8_cbc_encrypt,%function .align 5 aes_v8_cbc_encrypt: + AARCH64_VALID_CALL_TARGET + // Armv8.3-A PAuth: even though x30 is pushed to stack it is not popped later. stp x29,x30,[sp,#-16]! add x29,sp,#0 subs x2,x2,#16 @@ -1506,6 +1513,8 @@ aes_v8_cbc_encrypt: .type aes_v8_ctr32_encrypt_blocks,%function .align 5 aes_v8_ctr32_encrypt_blocks: + AARCH64_VALID_CALL_TARGET + // Armv8.3-A PAuth: even though x30 is pushed to stack it is not popped later. stp x29,x30,[sp,#-16]! add x29,sp,#0 ldr w5,[x3,#240] @@ -1855,6 +1864,7 @@ aes_v8_ctr32_encrypt_blocks: .type aes_v8_xts_encrypt,%function .align 5 aes_v8_xts_encrypt: + AARCH64_VALID_CALL_TARGET cmp x2,#16 // Original input data size bigger than 16, jump to big size processing. b.ne .Lxts_enc_big_size @@ -2496,6 +2506,7 @@ aes_v8_xts_encrypt: .type aes_v8_xts_decrypt,%function .align 5 aes_v8_xts_decrypt: + AARCH64_VALID_CALL_TARGET cmp x2,#16 // Original input data size bigger than 16, jump to big size processing. b.ne .Lxts_dec_big_size diff --git a/sys/crypto/openssl/aarch64/arm64cpuid.S b/sys/crypto/openssl/aarch64/arm64cpuid.S index 5ee467c7f129..52c6ee5b65d3 100644 --- a/sys/crypto/openssl/aarch64/arm64cpuid.S +++ b/sys/crypto/openssl/aarch64/arm64cpuid.S @@ -8,6 +8,7 @@ .globl _armv7_neon_probe .type _armv7_neon_probe,%function _armv7_neon_probe: + AARCH64_VALID_CALL_TARGET orr v15.16b, v15.16b, v15.16b ret .size _armv7_neon_probe,.-_armv7_neon_probe @@ -15,6 +16,7 @@ _armv7_neon_probe: .globl _armv7_tick .type _armv7_tick,%function _armv7_tick: + AARCH64_VALID_CALL_TARGET #ifdef __APPLE__ mrs x0, CNTPCT_EL0 #else @@ -26,6 +28,7 @@ _armv7_tick: .globl _armv8_aes_probe .type _armv8_aes_probe,%function _armv8_aes_probe: + AARCH64_VALID_CALL_TARGET aese v0.16b, v0.16b ret .size _armv8_aes_probe,.-_armv8_aes_probe @@ -33,6 +36,7 @@ _armv8_aes_probe: .globl _armv8_sha1_probe .type _armv8_sha1_probe,%function _armv8_sha1_probe: + AARCH64_VALID_CALL_TARGET sha1h s0, s0 ret .size _armv8_sha1_probe,.-_armv8_sha1_probe @@ -40,6 +44,7 @@ _armv8_sha1_probe: .globl _armv8_sha256_probe .type _armv8_sha256_probe,%function _armv8_sha256_probe: + AARCH64_VALID_CALL_TARGET sha256su0 v0.4s, v0.4s ret .size _armv8_sha256_probe,.-_armv8_sha256_probe @@ -47,6 +52,7 @@ _armv8_sha256_probe: .globl _armv8_pmull_probe .type _armv8_pmull_probe,%function _armv8_pmull_probe: + AARCH64_VALID_CALL_TARGET pmull v0.1q, v0.1d, v0.1d ret .size _armv8_pmull_probe,.-_armv8_pmull_probe @@ -54,6 +60,7 @@ _armv8_pmull_probe: .globl _armv8_sha512_probe .type _armv8_sha512_probe,%function _armv8_sha512_probe: + AARCH64_VALID_CALL_TARGET .long 0xcec08000 // sha512su0 v0.2d,v0.2d ret .size _armv8_sha512_probe,.-_armv8_sha512_probe @@ -61,6 +68,7 @@ _armv8_sha512_probe: .globl _armv8_cpuid_probe .type _armv8_cpuid_probe,%function _armv8_cpuid_probe: + AARCH64_VALID_CALL_TARGET mrs x0, midr_el1 ret .size _armv8_cpuid_probe,.-_armv8_cpuid_probe @@ -69,6 +77,7 @@ _armv8_cpuid_probe: .type OPENSSL_cleanse,%function .align 5 OPENSSL_cleanse: + AARCH64_VALID_CALL_TARGET cbz x1,.Lret // len==0? cmp x1,#15 b.hi .Lot // len>15 @@ -100,6 +109,7 @@ OPENSSL_cleanse: .type CRYPTO_memcmp,%function .align 4 CRYPTO_memcmp: + AARCH64_VALID_CALL_TARGET eor w3,w3,w3 cbz x2,.Lno_data // len==0? cmp x2,#16 diff --git a/sys/crypto/openssl/aarch64/armv8-mont.S b/sys/crypto/openssl/aarch64/armv8-mont.S index 4bdba95f80f8..8b85fb080aba 100644 --- a/sys/crypto/openssl/aarch64/armv8-mont.S +++ b/sys/crypto/openssl/aarch64/armv8-mont.S @@ -1,6 +1,6 @@ /* Do not modify. This file is auto-generated from armv8-mont.pl. */ +#include "arm_arch.h" #ifndef __KERNEL__ -# include "arm_arch.h" .hidden OPENSSL_armv8_rsa_neonized #endif @@ -10,6 +10,7 @@ .type bn_mul_mont,%function .align 5 bn_mul_mont: + AARCH64_SIGN_LINK_REGISTER .Lbn_mul_mont: tst x5,#3 b.ne .Lmul_mont @@ -220,11 +221,14 @@ bn_mul_mont: mov x0,#1 ldp x23,x24,[x29,#48] ldr x29,[sp],#64 + AARCH64_VALIDATE_LINK_REGISTER ret .size bn_mul_mont,.-bn_mul_mont .type bn_mul8x_mont_neon,%function .align 5 bn_mul8x_mont_neon: + // Not adding AARCH64_SIGN_LINK_REGISTER here because bn_mul8x_mont_neon is jumped to + // only from bn_mul_mont which has already signed the return address. stp x29,x30,[sp,#-80]! mov x16,sp stp d8,d9,[sp,#16] @@ -917,6 +921,7 @@ bn_mul8x_mont_neon: ldp d10,d11,[sp,#32] ldp d8,d9,[sp,#16] ldr x29,[sp],#80 + AARCH64_VALIDATE_LINK_REGISTER ret // bx lr .size bn_mul8x_mont_neon,.-bn_mul8x_mont_neon @@ -926,7 +931,8 @@ __bn_sqr8x_mont: cmp x1,x2 b.ne __bn_mul4x_mont .Lsqr8x_mont: -.inst 0xd503233f // paciasp + // Not adding AARCH64_SIGN_LINK_REGISTER here because __bn_sqr8x_mont is jumped to + // only from bn_mul_mont which has already signed the return address. stp x29,x30,[sp,#-128]! add x29,sp,#0 stp x19,x20,[sp,#16] @@ -1677,13 +1683,15 @@ __bn_sqr8x_mont: ldp x25,x26,[x29,#64] ldp x27,x28,[x29,#80] ldr x29,[sp],#128 -.inst 0xd50323bf // autiasp + // x30 is loaded earlier + AARCH64_VALIDATE_LINK_REGISTER ret .size __bn_sqr8x_mont,.-__bn_sqr8x_mont .type __bn_mul4x_mont,%function .align 5 __bn_mul4x_mont: -.inst 0xd503233f // paciasp + // Not adding AARCH64_SIGN_LINK_REGISTER here because __bn_mul4x_mont is jumped to + // only from bn_mul_mont (or __bn_sqr8x_mont from bn_mul_mont) which has already signed the return address. stp x29,x30,[sp,#-128]! add x29,sp,#0 stp x19,x20,[sp,#16] @@ -2117,7 +2125,8 @@ __bn_mul4x_mont: ldp x25,x26,[x29,#64] ldp x27,x28,[x29,#80] ldr x29,[sp],#128 -.inst 0xd50323bf // autiasp + // x30 loaded earlier + AARCH64_VALIDATE_LINK_REGISTER ret .size __bn_mul4x_mont,.-__bn_mul4x_mont .byte 77,111,110,116,103,111,109,101,114,121,32,77,117,108,116,105,112,108,105,99,97,116,105,111,110,32,102,111,114,32,65,82,77,118,56,44,32,67,82,89,80,84,79,71,65,77,83,32,98,121,32,60,97,112,112,114,111,64,111,112,101,110,115,115,108,46,111,114,103,62,0 diff --git a/sys/crypto/openssl/aarch64/chacha-armv8.S b/sys/crypto/openssl/aarch64/chacha-armv8.S index 609e34f422a2..4f9d6bd372f7 100644 --- a/sys/crypto/openssl/aarch64/chacha-armv8.S +++ b/sys/crypto/openssl/aarch64/chacha-armv8.S @@ -1,6 +1,6 @@ /* Do not modify. This file is auto-generated from chacha-armv8.pl. */ +#include "arm_arch.h" #ifndef __KERNEL__ -# include "arm_arch.h" .hidden OPENSSL_armcap_P #endif @@ -21,6 +21,7 @@ .type ChaCha20_ctr32,%function .align 5 ChaCha20_ctr32: + AARCH64_SIGN_LINK_REGISTER cbz x2,.Labort cmp x2,#192 b.lo .Lshort @@ -33,7 +34,6 @@ ChaCha20_ctr32: #endif .Lshort: -.inst 0xd503233f // paciasp stp x29,x30,[sp,#-96]! add x29,sp,#0 @@ -245,8 +245,8 @@ ChaCha20_ctr32: ldp x25,x26,[x29,#64] ldp x27,x28,[x29,#80] ldp x29,x30,[sp],#96 -.inst 0xd50323bf // autiasp .Labort: + AARCH64_VALIDATE_LINK_REGISTER ret .align 4 @@ -302,7 +302,7 @@ ChaCha20_ctr32: ldp x25,x26,[x29,#64] ldp x27,x28,[x29,#80] ldp x29,x30,[sp],#96 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ChaCha20_ctr32,.-ChaCha20_ctr32 @@ -312,8 +312,8 @@ ChaCha20_ctr32: .type ChaCha20_neon,%function .align 5 ChaCha20_neon: + AARCH64_SIGN_LINK_REGISTER .LChaCha20_neon: -.inst 0xd503233f // paciasp stp x29,x30,[sp,#-96]! add x29,sp,#0 @@ -748,7 +748,7 @@ ChaCha20_neon: ldp x25,x26,[x29,#64] ldp x27,x28,[x29,#80] ldp x29,x30,[sp],#96 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .align 4 @@ -880,13 +880,13 @@ ChaCha20_neon: ldp x25,x26,[x29,#64] ldp x27,x28,[x29,#80] ldp x29,x30,[sp],#96 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ChaCha20_neon,.-ChaCha20_neon .type ChaCha20_512_neon,%function .align 5 ChaCha20_512_neon: -.inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-96]! add x29,sp,#0 @@ -2030,6 +2030,6 @@ ChaCha20_512_neon: ldp x25,x26,[x29,#64] ldp x27,x28,[x29,#80] ldp x29,x30,[sp],#96 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ChaCha20_512_neon,.-ChaCha20_512_neon diff --git a/sys/crypto/openssl/aarch64/ecp_nistz256-armv8.S b/sys/crypto/openssl/aarch64/ecp_nistz256-armv8.S index d297ac15605c..73c367bcf1fc 100644 --- a/sys/crypto/openssl/aarch64/ecp_nistz256-armv8.S +++ b/sys/crypto/openssl/aarch64/ecp_nistz256-armv8.S @@ -2396,7 +2396,7 @@ ecp_nistz256_precomputed: .type ecp_nistz256_to_mont,%function .align 6 ecp_nistz256_to_mont: -.inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-32]! add x29,sp,#0 stp x19,x20,[sp,#16] @@ -2412,7 +2412,7 @@ ecp_nistz256_to_mont: ldp x19,x20,[sp,#16] ldp x29,x30,[sp],#32 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ecp_nistz256_to_mont,.-ecp_nistz256_to_mont @@ -2421,7 +2421,7 @@ ecp_nistz256_to_mont: .type ecp_nistz256_from_mont,%function .align 4 ecp_nistz256_from_mont: -.inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-32]! add x29,sp,#0 stp x19,x20,[sp,#16] @@ -2437,7 +2437,7 @@ ecp_nistz256_from_mont: ldp x19,x20,[sp,#16] ldp x29,x30,[sp],#32 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ecp_nistz256_from_mont,.-ecp_nistz256_from_mont @@ -2447,7 +2447,7 @@ ecp_nistz256_from_mont: .type ecp_nistz256_mul_mont,%function .align 4 ecp_nistz256_mul_mont: -.inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-32]! add x29,sp,#0 stp x19,x20,[sp,#16] @@ -2462,7 +2462,7 @@ ecp_nistz256_mul_mont: ldp x19,x20,[sp,#16] ldp x29,x30,[sp],#32 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ecp_nistz256_mul_mont,.-ecp_nistz256_mul_mont @@ -2471,7 +2471,7 @@ ecp_nistz256_mul_mont: .type ecp_nistz256_sqr_mont,%function .align 4 ecp_nistz256_sqr_mont: -.inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-32]! add x29,sp,#0 stp x19,x20,[sp,#16] @@ -2485,7 +2485,7 @@ ecp_nistz256_sqr_mont: ldp x19,x20,[sp,#16] ldp x29,x30,[sp],#32 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ecp_nistz256_sqr_mont,.-ecp_nistz256_sqr_mont @@ -2495,7 +2495,7 @@ ecp_nistz256_sqr_mont: .type ecp_nistz256_add,%function .align 4 ecp_nistz256_add: -.inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-16]! add x29,sp,#0 @@ -2509,7 +2509,7 @@ ecp_nistz256_add: bl __ecp_nistz256_add ldp x29,x30,[sp],#16 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ecp_nistz256_add,.-ecp_nistz256_add @@ -2518,7 +2518,7 @@ ecp_nistz256_add: .type ecp_nistz256_div_by_2,%function .align 4 ecp_nistz256_div_by_2: -.inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-16]! add x29,sp,#0 @@ -2530,7 +2530,7 @@ ecp_nistz256_div_by_2: bl __ecp_nistz256_div_by_2 ldp x29,x30,[sp],#16 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ecp_nistz256_div_by_2,.-ecp_nistz256_div_by_2 @@ -2539,7 +2539,7 @@ ecp_nistz256_div_by_2: .type ecp_nistz256_mul_by_2,%function .align 4 ecp_nistz256_mul_by_2: -.inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-16]! add x29,sp,#0 @@ -2555,7 +2555,7 @@ ecp_nistz256_mul_by_2: bl __ecp_nistz256_add // ret = a+a // 2*a ldp x29,x30,[sp],#16 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ecp_nistz256_mul_by_2,.-ecp_nistz256_mul_by_2 @@ -2564,7 +2564,7 @@ ecp_nistz256_mul_by_2: .type ecp_nistz256_mul_by_3,%function .align 4 ecp_nistz256_mul_by_3: -.inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-16]! add x29,sp,#0 @@ -2591,7 +2591,7 @@ ecp_nistz256_mul_by_3: bl __ecp_nistz256_add // ret += a // 2*a+a=3*a ldp x29,x30,[sp],#16 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ecp_nistz256_mul_by_3,.-ecp_nistz256_mul_by_3 @@ -2601,7 +2601,7 @@ ecp_nistz256_mul_by_3: .type ecp_nistz256_sub,%function .align 4 ecp_nistz256_sub: -.inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-16]! add x29,sp,#0 @@ -2613,7 +2613,7 @@ ecp_nistz256_sub: bl __ecp_nistz256_sub_from ldp x29,x30,[sp],#16 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ecp_nistz256_sub,.-ecp_nistz256_sub @@ -2622,7 +2622,7 @@ ecp_nistz256_sub: .type ecp_nistz256_neg,%function .align 4 ecp_nistz256_neg: -.inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-16]! add x29,sp,#0 @@ -2637,7 +2637,7 @@ ecp_nistz256_neg: bl __ecp_nistz256_sub_from ldp x29,x30,[sp],#16 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ecp_nistz256_neg,.-ecp_nistz256_neg @@ -3015,7 +3015,7 @@ __ecp_nistz256_div_by_2: .type ecp_nistz256_point_double,%function .align 5 ecp_nistz256_point_double: -.inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-96]! add x29,sp,#0 stp x19,x20,[sp,#16] @@ -3150,14 +3150,14 @@ ecp_nistz256_point_double: ldp x19,x20,[x29,#16] ldp x21,x22,[x29,#32] ldp x29,x30,[sp],#96 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ecp_nistz256_point_double,.-ecp_nistz256_point_double .globl ecp_nistz256_point_add .type ecp_nistz256_point_add,%function .align 5 ecp_nistz256_point_add: -.inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-96]! add x29,sp,#0 stp x19,x20,[sp,#16] @@ -3404,14 +3404,14 @@ ecp_nistz256_point_add: ldp x25,x26,[x29,#64] ldp x27,x28,[x29,#80] ldp x29,x30,[sp],#96 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ecp_nistz256_point_add,.-ecp_nistz256_point_add .globl ecp_nistz256_point_add_affine .type ecp_nistz256_point_add_affine,%function .align 5 ecp_nistz256_point_add_affine: -.inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-80]! add x29,sp,#0 stp x19,x20,[sp,#16] @@ -3610,7 +3610,7 @@ ecp_nistz256_point_add_affine: ldp x23,x24,[x29,#48] ldp x25,x26,[x29,#64] ldp x29,x30,[sp],#80 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size ecp_nistz256_point_add_affine,.-ecp_nistz256_point_add_affine //////////////////////////////////////////////////////////////////////// @@ -3620,6 +3620,8 @@ ecp_nistz256_point_add_affine: .type ecp_nistz256_ord_mul_mont,%function .align 4 ecp_nistz256_ord_mul_mont: + AARCH64_VALID_CALL_TARGET + // Armv8.3-A PAuth: even though x30 is pushed to stack it is not popped later. stp x29,x30,[sp,#-64]! add x29,sp,#0 stp x19,x20,[sp,#16] @@ -3828,6 +3830,8 @@ ecp_nistz256_ord_mul_mont: .type ecp_nistz256_ord_sqr_mont,%function .align 4 ecp_nistz256_ord_sqr_mont: + AARCH64_VALID_CALL_TARGET + // Armv8.3-A PAuth: even though x30 is pushed to stack it is not popped later. stp x29,x30,[sp,#-64]! add x29,sp,#0 stp x19,x20,[sp,#16] @@ -4016,6 +4020,8 @@ ecp_nistz256_ord_sqr_mont: .type ecp_nistz256_scatter_w5,%function .align 4 ecp_nistz256_scatter_w5: + AARCH64_VALID_CALL_TARGET + // Armv8.3-A PAuth: even though x30 is pushed to stack it is not popped later. stp x29,x30,[sp,#-16]! add x29,sp,#0 @@ -4078,6 +4084,8 @@ ecp_nistz256_scatter_w5: .type ecp_nistz256_gather_w5,%function .align 4 ecp_nistz256_gather_w5: + AARCH64_VALID_CALL_TARGET + // Armv8.3-A PAuth: even though x30 is pushed to stack it is not popped later. stp x29,x30,[sp,#-16]! add x29,sp,#0 @@ -4155,6 +4163,8 @@ ecp_nistz256_gather_w5: .type ecp_nistz256_scatter_w7,%function .align 4 ecp_nistz256_scatter_w7: + AARCH64_VALID_CALL_TARGET + // Armv8.3-A PAuth: even though x30 is pushed to stack it is not popped later. stp x29,x30,[sp,#-16]! add x29,sp,#0 @@ -4199,6 +4209,8 @@ ecp_nistz256_scatter_w7: .type ecp_nistz256_gather_w7,%function .align 4 ecp_nistz256_gather_w7: + AARCH64_VALID_CALL_TARGET + // Armv8.3-A PAuth: even though x30 is pushed to stack it is not popped later. stp x29,x30,[sp,#-16]! add x29,sp,#0 diff --git a/sys/crypto/openssl/aarch64/ghashv8-armx.S b/sys/crypto/openssl/aarch64/ghashv8-armx.S index cb7aa9a3908b..42f053d664ef 100644 --- a/sys/crypto/openssl/aarch64/ghashv8-armx.S +++ b/sys/crypto/openssl/aarch64/ghashv8-armx.S @@ -8,6 +8,7 @@ .type gcm_init_v8,%function .align 4 gcm_init_v8: + AARCH64_VALID_CALL_TARGET ld1 {v17.2d},[x1] //load input H movi v19.16b,#0xe1 shl v19.2d,v19.2d,#57 //0xc2.0 @@ -98,6 +99,7 @@ gcm_init_v8: .type gcm_gmult_v8,%function .align 4 gcm_gmult_v8: + AARCH64_VALID_CALL_TARGET ld1 {v17.2d},[x0] //load Xi movi v19.16b,#0xe1 ld1 {v20.2d,v21.2d},[x1] //load twisted H, ... @@ -139,6 +141,7 @@ gcm_gmult_v8: .type gcm_ghash_v8,%function .align 4 gcm_ghash_v8: + AARCH64_VALID_CALL_TARGET cmp x3,#64 b.hs .Lgcm_ghash_v8_4x ld1 {v0.2d},[x0] //load [rotated] Xi diff --git a/sys/crypto/openssl/aarch64/keccak1600-armv8.S b/sys/crypto/openssl/aarch64/keccak1600-armv8.S index cf63318a8d08..08b3cc351213 100644 --- a/sys/crypto/openssl/aarch64/keccak1600-armv8.S +++ b/sys/crypto/openssl/aarch64/keccak1600-armv8.S @@ -1,4 +1,6 @@ /* Do not modify. This file is auto-generated from keccak1600-armv8.pl. */ +#include "arm_arch.h" + .text .align 8 // strategic alignment and padding that allows to use @@ -34,8 +36,8 @@ iotas: .type KeccakF1600_int,%function .align 5 KeccakF1600_int: + AARCH64_SIGN_LINK_REGISTER adr x28,iotas -.inst 0xd503233f // paciasp stp x28,x30,[sp,#16] // 32 bytes on top are mine b .Loop .align 4 @@ -199,14 +201,14 @@ KeccakF1600_int: bne .Loop ldr x30,[sp,#24] -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size KeccakF1600_int,.-KeccakF1600_int .type KeccakF1600,%function .align 5 KeccakF1600: -.inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-128]! add x29,sp,#0 stp x19,x20,[sp,#16] @@ -256,7 +258,7 @@ KeccakF1600: ldp x25,x26,[x29,#64] ldp x27,x28,[x29,#80] ldp x29,x30,[sp],#128 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size KeccakF1600,.-KeccakF1600 @@ -264,7 +266,7 @@ KeccakF1600: .type SHA3_absorb,%function .align 5 SHA3_absorb: -.inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-128]! add x29,sp,#0 stp x19,x20,[sp,#16] @@ -498,14 +500,14 @@ SHA3_absorb: ldp x25,x26,[x29,#64] ldp x27,x28,[x29,#80] ldp x29,x30,[sp],#128 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size SHA3_absorb,.-SHA3_absorb .globl SHA3_squeeze .type SHA3_squeeze,%function .align 5 SHA3_squeeze: -.inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-48]! add x29,sp,#0 stp x19,x20,[sp,#16] @@ -568,7 +570,7 @@ SHA3_squeeze: ldp x19,x20,[sp,#16] ldp x21,x22,[sp,#32] ldp x29,x30,[sp],#48 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size SHA3_squeeze,.-SHA3_squeeze .type KeccakF1600_ce,%function @@ -676,7 +678,7 @@ KeccakF1600_ce: .type KeccakF1600_cext,%function .align 5 KeccakF1600_cext: -.inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-80]! add x29,sp,#0 stp d8,d9,[sp,#16] // per ABI requirement @@ -717,14 +719,14 @@ KeccakF1600_cext: ldp d12,d13,[sp,#48] ldp d14,d15,[sp,#64] ldr x29,[sp],#80 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size KeccakF1600_cext,.-KeccakF1600_cext .globl SHA3_absorb_cext .type SHA3_absorb_cext,%function .align 5 SHA3_absorb_cext: -.inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-80]! add x29,sp,#0 stp d8,d9,[sp,#16] // per ABI requirement @@ -940,14 +942,14 @@ SHA3_absorb_cext: ldp d12,d13,[sp,#48] ldp d14,d15,[sp,#64] ldp x29,x30,[sp],#80 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size SHA3_absorb_cext,.-SHA3_absorb_cext .globl SHA3_squeeze_cext .type SHA3_squeeze_cext,%function .align 5 SHA3_squeeze_cext: -.inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-16]! add x29,sp,#0 mov x9,x0 @@ -1003,7 +1005,7 @@ SHA3_squeeze_cext: .Lsqueeze_done_ce: ldr x29,[sp],#16 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size SHA3_squeeze_cext,.-SHA3_squeeze_cext .byte 75,101,99,99,97,107,45,49,54,48,48,32,97,98,115,111,114,98,32,97,110,100,32,115,113,117,101,101,122,101,32,102,111,114,32,65,82,77,118,56,44,32,67,82,89,80,84,79,71,65,77,83,32,98,121,32,60,97,112,112,114,111,64,111,112,101,110,115,115,108,46,111,114,103,62,0 diff --git a/sys/crypto/openssl/aarch64/poly1305-armv8.S b/sys/crypto/openssl/aarch64/poly1305-armv8.S index bf1daa3adaff..8925984c3ee0 100644 --- a/sys/crypto/openssl/aarch64/poly1305-armv8.S +++ b/sys/crypto/openssl/aarch64/poly1305-armv8.S @@ -16,6 +16,7 @@ .type poly1305_init,%function .align 5 poly1305_init: + AARCH64_VALID_CALL_TARGET cmp x1,xzr stp xzr,xzr,[x0] // zero hash value stp xzr,xzr,[x0,#16] // [along with is_base2_26] @@ -63,6 +64,9 @@ poly1305_init: .align 5 poly1305_blocks: .Lpoly1305_blocks: + // The symbol .Lpoly1305_blocks is not a .globl symbol + // but a pointer to it is returned by poly1305_init + AARCH64_VALID_CALL_TARGET ands x2,x2,#-16 b.eq .Lno_data @@ -128,6 +132,9 @@ poly1305_blocks: .align 5 poly1305_emit: .Lpoly1305_emit: + // The symbol .poly1305_emit is not a .globl symbol + // but a pointer to it is returned by poly1305_init + AARCH64_VALID_CALL_TARGET ldp x4,x5,[x0] // load hash base 2^64 ldr x6,[x0,#16] ldp x10,x11,[x2] // load nonce @@ -223,13 +230,16 @@ poly1305_splat: .align 5 poly1305_blocks_neon: .Lpoly1305_blocks_neon: + // The symbol .Lpoly1305_blocks_neon is not a .globl symbol + // but a pointer to it is returned by poly1305_init + AARCH64_VALID_CALL_TARGET ldr x17,[x0,#24] cmp x2,#128 b.hs .Lblocks_neon cbz x17,.Lpoly1305_blocks .Lblocks_neon: -.inst 0xd503233f // paciasp + AARCH64_SIGN_LINK_REGISTER stp x29,x30,[sp,#-80]! add x29,sp,#0 @@ -799,7 +809,7 @@ poly1305_blocks_neon: .Lno_data_neon: ldr x29,[sp],#80 -.inst 0xd50323bf // autiasp + AARCH64_VALIDATE_LINK_REGISTER ret .size poly1305_blocks_neon,.-poly1305_blocks_neon @@ -807,6 +817,9 @@ poly1305_blocks_neon: .align 5 poly1305_emit_neon: .Lpoly1305_emit_neon: + // The symbol .Lpoly1305_emit_neon is not a .globl symbol + // but a pointer to it is returned by poly1305_init + AARCH64_VALID_CALL_TARGET ldr x17,[x0,#24] cbz x17,poly1305_emit diff --git a/sys/crypto/openssl/aarch64/sha1-armv8.S b/sys/crypto/openssl/aarch64/sha1-armv8.S index a9e1d81d5817..9e2d86072394 100644 --- a/sys/crypto/openssl/aarch64/sha1-armv8.S +++ b/sys/crypto/openssl/aarch64/sha1-armv8.S @@ -1,6 +1,6 @@ /* Do not modify. This file is auto-generated from sha1-armv8.pl. */ +#include "arm_arch.h" #ifndef __KERNEL__ -# include "arm_arch.h" .hidden OPENSSL_armcap_P #endif @@ -11,11 +11,13 @@ .type sha1_block_data_order,%function .align 6 sha1_block_data_order: + AARCH64_VALID_CALL_TARGET adrp x16,OPENSSL_armcap_P ldr w16,[x16,#:lo12:OPENSSL_armcap_P] tst w16,#ARMV8_SHA1 b.ne .Lv8_entry + // Armv8.3-A PAuth: even though x30 is pushed to stack it is not popped later. stp x29,x30,[sp,#-96]! add x29,sp,#0 stp x19,x20,[sp,#16] @@ -1075,6 +1077,7 @@ sha1_block_data_order: .align 6 sha1_block_armv8: .Lv8_entry: + // Armv8.3-A PAuth: even though x30 is pushed to stack it is not popped later. stp x29,x30,[sp,#-16]! *** 349 LINES SKIPPED *** From nobody Mon Jul 15 12:37:53 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1v54vHMz5QrD0; Mon, 15 Jul 2024 12:37: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1v51ZSLz4GW0; Mon, 15 Jul 2024 12:37:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047073; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=5wK+1abqPHhxglksiRDMJxnqUt0MItAexzxemMzb2hc=; b=XiQCGCswdA6NMVGqOKab+PhqB0Xpijj1MVPh7HW27dvYgolgi8vRHF6/ITOmr0I4D3M8yQ xQYlSSsye8JloRmbmE+x4Z9kn0gZ9liSxVLY2azt5O9I6zeC4SzISVtZGzDfC4oEwdrFUe 8a4p5NlxhoRdKuB6RdnpR1Tt2NNPYmT4vc5nvavSHvGf37odhtdHbEncmiqpN4sB1mT7ft H3HFUuhxHQEJmP87tBoX3s7QmqX9m9FU45O7w1V13No54cdc94KUjiStHTGiTe19YYxq0y C7XlibQ0Wh7LdY1O3IswkUWqxcuBKSK0bmqwssx2jPGhz77h30HkJ/a/gpJXDQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047073; a=rsa-sha256; cv=none; b=LUgYV4fvNIumlm4j/3nIN3/qPc8Fo+s6QfWaMpezoMkAbeVMUBtQkAJbJta3atNBSzU+zZ N5gLUIQ93A+1qbVfHjZ2F6GOwm1B7T5gzqp0352CUsZ+7gE/E5LCrlT3L27YAzKn04bx/R RdGaCW9w+BxAxJT9n8Q5cdkAOXLsbQ9XxgSfJOE9NSDg9OiN8nIZwKrHDikYSzEi4ryfzY YZGi39OCWWYRbvfyzUsbcrmn7QYj/PM66rFk8L6L5oB/Vu3GFK05XP98dyN1acdJHalUOL 7SU2oBKyZvUGxc79Vt2aLpB7ZaCSkaDmwNhRGo3dlnpj4LQnJPFjIHwwl/BZfQ== 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=1721047073; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=5wK+1abqPHhxglksiRDMJxnqUt0MItAexzxemMzb2hc=; b=LL5RHalHgeziF2tJZ6sA78t1yhHbYHU6k5aahEJdSEtguzraUNavjcBvntFiogsk3NhZcH rFEQxURCPReoh6SMmwlquORyriNPiICBC+xgKrW12NAC1JSFq5I+jagqG8Ojo6C+moydWJ rOFv/BfJ+AlVfif1Z3NL5XylUWojuXf9ehmCYGyoHwLtHij6MMGlVSNCi/qJMXyyTiLJZE j3duN2y8mTwSu0PNggdrVBKkH2Skt6XlO5ZibBW+Nwm0vkMVB5RKCL6NpP/PGvr6pVnomv Lm/r9imHQXclgBLu7gcYmCheUvuT8ex3NALvZCJ2PRFHDI6H7zKS8sMRf/gIEw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1v519CYzt1L; Mon, 15 Jul 2024 12:37:53 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCbr5I058361; Mon, 15 Jul 2024 12:37:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCbrvL058358; Mon, 15 Jul 2024 12:37:53 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:37:53 GMT Message-Id: <202407151237.46FCbrvL058358@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 9f575dadfe14 - stable/14 - arm64: Add CurrentEL register definitions List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 9f575dadfe149ec14072b63ead9c31eb4e6e5992 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=9f575dadfe149ec14072b63ead9c31eb4e6e5992 commit 9f575dadfe149ec14072b63ead9c31eb4e6e5992 Author: Andrew Turner AuthorDate: 2024-02-19 14:57:34 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:21:29 +0000 arm64: Add CurrentEL register definitions Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D43971 (cherry picked from commit 5e7941b6c979a55dc67baf316db6932c09b14022) --- sys/arm64/include/armreg.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index 953c9af220b9..7b3835474ae5 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -190,6 +190,14 @@ #define CTR_ILINE_VAL(reg) ((reg) & CTR_ILINE_MASK) #define CTR_ILINE_SIZE(reg) (4 << (CTR_ILINE_VAL(reg) >> CTR_ILINE_SHIFT)) +/* CurrentEL - Current Exception Level */ +#define CURRENTEL_EL_SHIFT 2 +#define CURRENTEL_EL_MASK (0x3 << CURRENTEL_EL_SHIFT) +#define CURRENTEL_EL_EL0 (0x0 << CURRENTEL_EL_SHIFT) +#define CURRENTEL_EL_EL1 (0x1 << CURRENTEL_EL_SHIFT) +#define CURRENTEL_EL_EL2 (0x2 << CURRENTEL_EL_SHIFT) +#define CURRENTEL_EL_EL3 (0x3 << CURRENTEL_EL_SHIFT) + /* DAIFSet/DAIFClear */ #define DAIF_D (1 << 3) #define DAIF_A (1 << 2) From nobody Mon Jul 15 12:37:54 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1v64pKHz5QrTT; Mon, 15 Jul 2024 12:37: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1v62Mxwz4GhN; Mon, 15 Jul 2024 12:37:54 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047074; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=fqQId9AE6wjKwtn3Zqvul7Kh7IbFyVjBqzeBYLKtJiI=; b=ipFbgSh2PepXuStG9eIwsPyQm0MCL7V9K9MgNpiRI6+c896WAqIiQmsa/gWSwUcPrNmGyb R3Lw8yu/Q7x3QDpWZPBnOQ44waZpaj58A+szGXEq0DDhn8SZ+8zlg5WHmZ/yrppFpR38vK zsjlQRIA1bwa/8hZS49pU14hp5pU5CbkGWb5aKqUrTKeOOrbx1JtBRvI6wHgvPtYE1yQt0 /mUs5qxFViFuU8aHnTNLZave+STUJ0o88drkYIxrGvc4kOLIeY4XhgCV0oBrJX1g8vF5vB grg4wMY1Uwe9imlajUUnlQiS+6C+Hocy6QpE4fI8bFzP5eazlIiHfOlwGndwmQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047074; a=rsa-sha256; cv=none; b=LSmttiRkoOGSeRN+VUWcdMZKeuW74Hjgk3de7KKdlqwNstMfUGRS3RMw55oJf6laSEeG8D rl3Px3A7zq5gIwrvBb15VtdSUpxoKh2bsZE02KogcKsZqv+R+A85ZVjLehvNBCiMKojY2Q pfjfyZYWUXLdcsaCT7bOOX979GE7pUFzD5KYanLtZpBrOIFyZSIkxYC5ZzIKlVWmiFzHoJ 3ve0/wjTsfiCRTHQ56vIC2lZsf8RbKTOehk0j7SS7Lf4mpJvCAbEh/lzkr4Voeja2O+zAT oVEFv2+xNrMZe9Fh7ZFwATQ5VJo8iUd4lD/uXjDaOTLxigeOWu2gQxwVuegkbw== 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=1721047074; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=fqQId9AE6wjKwtn3Zqvul7Kh7IbFyVjBqzeBYLKtJiI=; b=pb3uE0+XCqzBzlUA6USvgn+tjUWiGD4LHd7JJMkHmFtTbfZmWPP64Afxn8UbjQ18YEEywj tuMEu5NdKf6RY4y4Ae+ABlRpNyxoiE6BEh8/qCZrvEAmJRmOuydQZ/9i3LJyImhn/ycqW1 rrAKhK4tFRF+/MwojdI6rzHQxhtgY78r2J5/aLw0H210nGnSSkZvoPZ8ZJsYCAulrPin2K jVgBZOVS6PWJXDZLv5mW+4f2k7tDjHMM7qd8X9n9isAx5gK5GZbtH/RVsiyaPhtVFOpakv 0zXUb3+FD2yBSMjOC1Bb/NmgrFgRYbcWPE+ESFzlEma9Tn6yLnV+COmwNCGZ3w== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1v61xVbzsp4; Mon, 15 Jul 2024 12:37:54 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCbsCn058427; Mon, 15 Jul 2024 12:37:54 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCbsQv058424; Mon, 15 Jul 2024 12:37:54 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:37:54 GMT Message-Id: <202407151237.46FCbsQv058424@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 39ae01d39b55 - stable/14 - arm64: Add more spsr_el1 register values List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 39ae01d39b55a8cf225b4ab27ccecad30740e761 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=39ae01d39b55a8cf225b4ab27ccecad30740e761 commit 39ae01d39b55a8cf225b4ab27ccecad30740e761 Author: Andrew Turner AuthorDate: 2024-02-21 15:58:20 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:21:36 +0000 arm64: Add more spsr_el1 register values Sponsored by: Arm Ltd (cherry picked from commit 64963dd2f0a2a47e94fb3f7c56198c475b9821a3) --- sys/arm64/include/armreg.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index 7b3835474ae5..f3af9edec4c4 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -2068,8 +2068,15 @@ #define PSR_DAIF (PSR_D | PSR_A | PSR_I | PSR_F) /* The default DAIF mask. These bits are valid in spsr_el1 and daif */ #define PSR_DAIF_DEFAULT (PSR_F) +#define PSR_BTYPE 0x00000c00UL +#define PSR_SSBS 0x00001000UL +#define PSR_ALLINT 0x00002000UL #define PSR_IL 0x00100000UL #define PSR_SS 0x00200000UL +#define PSR_PAN 0x00400000UL +#define PSR_UAO 0x00800000UL +#define PSR_DIT 0x01000000UL +#define PSR_TCO 0x02000000UL #define PSR_V 0x10000000UL #define PSR_C 0x20000000UL #define PSR_Z 0x40000000UL From nobody Mon Jul 15 12:37:54 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1v71F8mz5QrPC; Mon, 15 Jul 2024 12:37: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1v6666Lz4Gn1; Mon, 15 Jul 2024 12:37:54 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047074; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=UpYnPcK8AlJUumTYJrSU9Rpl/27gYozz+CMI9e1IPFE=; b=ZY5q+4E+TEixK2GX/XmgFeOAI+kDeWxcTVCw0h08UiDtfEu78J0ikpiR6xWm3oixum2N43 vOCRh56qDIllXXfxH68RcUjXtKm1ruTxyICXmUSB6c8DOd0HIIG0QaUSPEGEihBk7HZK6V BIUSDwp7tyGinaIsLUd3rpccDOx0LFAosnse8NzLRUM7eeFWHZ+EYBUBWQntEL5BtNJ37P UhERwSUKNVYvY5jRFNuAB5wVIoQt1mrllX3GnT4x37tfO2gcosuWjRyme2qAMHWYB7T3av 3AiCLwgN5t6hIFENAVoid0aWgu9J9LUu3SdVFk6zANNNzXIGOPQyPjgG2Cgilg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047074; a=rsa-sha256; cv=none; b=P55oQYZCAHne621LhQQ/aYBqw4ZCLkpPPZ5L1WuMNsJj0uDXS6YNZ8cwckZzWYzLswk8AL m1QjaHo7xdV2GKndmwHxNec5ZvFIXJLsGmSUvNd7V/4j8aMvCBMz04asSOXmeUVUpMXkCO qturkxzKdVDZ+XdKj897l9KYEdis8Gxak6rQV9FIo0GKfjYHabxyafwDu8sWOovMaUp5Sf fZ1DyqJsSeHefJxOxdcJ3bJfJw5Hr1ek05O70/G3NJlxuj3QNLwU/k0mdswRiuv0+6crvX tzGiUxng6EeyYFsRtL8MAGyAaO57tdUS7Ga6jF++wOGqJ8roeFyfkpF7pc+Qnw== 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=1721047074; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=UpYnPcK8AlJUumTYJrSU9Rpl/27gYozz+CMI9e1IPFE=; b=O+NwT5bxVXw4KCt85nJ/9oClgZRoeODoQwqV1k8HPMbfcMpG3vmoG2boxn38FuWeNSqH6A TPlX1QbXh1q+67mZM13/4nwexzmFmRpLNxMuWG9NGMFSuHdyjj56WJ4VzClQEUDtiA29U7 WqTT3OeI7FaVvGGuHDpHaRi7OaVzIxNXtPUUf5NbtbbYclnSL7bM6yrOWFSbl+kHcT9pgd I8ZU7WY9SNrlODpUb0vIa6kkpAJcJLf5frdhiVDEmqZKYwdZ6DyNJifMvvrUZByfvWaf4g xt1EBtr+PzZhPOwun5iUwC33ok5bl6Je6sQSAcxHMsPxenlmic1kDQ2d76D1hg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1v64LJgzsp5; Mon, 15 Jul 2024 12:37:54 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCbscB058662; Mon, 15 Jul 2024 12:37:54 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCbslM058659; Mon, 15 Jul 2024 12:37:54 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:37:54 GMT Message-Id: <202407151237.46FCbslM058659@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 2b3cf14a5152 - stable/13 - arm64: Decode the ID_AA64MMFR3_EL1 register List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 2b3cf14a5152049303bc7d22de954af99324f859 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=2b3cf14a5152049303bc7d22de954af99324f859 commit 2b3cf14a5152049303bc7d22de954af99324f859 Author: Andrew Turner AuthorDate: 2023-07-06 13:28:23 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 08:09:50 +0000 arm64: Decode the ID_AA64MMFR3_EL1 register Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D40893 (cherry picked from commit c65679143f82e28b3aa078f16311350c31a33776) --- sys/arm64/arm64/identcpu.c | 39 +++++++++++++++++++++++++++++++++++++++ sys/arm64/include/armreg.h | 28 ++++++++++++++++++++++++++++ 2 files changed, 67 insertions(+) diff --git a/sys/arm64/arm64/identcpu.c b/sys/arm64/arm64/identcpu.c index 60c40c84f965..2750f400fb66 100644 --- a/sys/arm64/arm64/identcpu.c +++ b/sys/arm64/arm64/identcpu.c @@ -129,6 +129,7 @@ struct cpu_desc { uint64_t id_aa64mmfr0; uint64_t id_aa64mmfr1; uint64_t id_aa64mmfr2; + uint64_t id_aa64mmfr3; uint64_t id_aa64pfr0; uint64_t id_aa64pfr1; uint64_t id_aa64zfr0; @@ -1211,6 +1212,37 @@ static const struct mrs_field id_aa64mmfr2_fields[] = { }; +/* ID_AA64MMFR2_EL1 */ +static const struct mrs_field_value id_aa64mmfr3_spec_fpacc[] = { + MRS_FIELD_VALUE_NONE_IMPL(ID_AA64MMFR3, Spec_FPACC, NONE, IMPL), + MRS_FIELD_VALUE_END, +}; + +static const struct mrs_field_value id_aa64mmfr3_mec[] = { + MRS_FIELD_VALUE_NONE_IMPL(ID_AA64MMFR3, MEC, NONE, IMPL), + MRS_FIELD_VALUE_END, +}; + +static const struct mrs_field_value id_aa64mmfr3_sctlrx[] = { + MRS_FIELD_VALUE_NONE_IMPL(ID_AA64MMFR3, SCTLRX, NONE, IMPL), + MRS_FIELD_VALUE_END, +}; + +static const struct mrs_field_value id_aa64mmfr3_tcrx[] = { + MRS_FIELD_VALUE_NONE_IMPL(ID_AA64MMFR3, TCRX, NONE, IMPL), + MRS_FIELD_VALUE_END, +}; + +static const struct mrs_field id_aa64mmfr3_fields[] = { + MRS_FIELD(ID_AA64MMFR3, Spec_FPACC, false, MRS_EXACT, + id_aa64mmfr3_spec_fpacc), + MRS_FIELD(ID_AA64MMFR3, MEC, false, MRS_EXACT, id_aa64mmfr3_mec), + MRS_FIELD(ID_AA64MMFR3, SCTLRX, false, MRS_EXACT, id_aa64mmfr3_sctlrx), + MRS_FIELD(ID_AA64MMFR3, TCRX, false, MRS_EXACT, id_aa64mmfr3_tcrx), + MRS_FIELD_END, +}; + + /* ID_AA64PFR0_EL1 */ static const struct mrs_field_value id_aa64pfr0_csv3[] = { MRS_FIELD_VALUE(ID_AA64PFR0_CSV3_NONE, ""), @@ -1747,6 +1779,7 @@ static const struct mrs_user_reg user_regs[] = { USER_REG(ID_AA64MMFR0_EL1, id_aa64mmfr0), USER_REG(ID_AA64MMFR1_EL1, id_aa64mmfr1), USER_REG(ID_AA64MMFR2_EL1, id_aa64mmfr2), + USER_REG(ID_AA64MMFR3_EL1, id_aa64mmfr3), USER_REG(ID_AA64PFR0_EL1, id_aa64pfr0), USER_REG(ID_AA64PFR1_EL1, id_aa64pfr1), @@ -2443,6 +2476,11 @@ print_cpu_features(u_int cpu) print_id_register(sb, "Memory Model Features 2", cpu_desc[cpu].id_aa64mmfr2, id_aa64mmfr2_fields); + /* AArch64 Memory Model Feature Register 3 */ + if (SHOULD_PRINT_REG(id_aa64mmfr3)) + print_id_register(sb, "Memory Model Features 3", + cpu_desc[cpu].id_aa64mmfr3, id_aa64mmfr3_fields); + /* AArch64 Debug Feature Register 0 */ if (SHOULD_PRINT_REG(id_aa64dfr0)) print_id_register(sb, "Debug Features 0", @@ -2555,6 +2593,7 @@ identify_cpu(u_int cpu) cpu_desc[cpu].id_aa64mmfr0 = READ_SPECIALREG(id_aa64mmfr0_el1); cpu_desc[cpu].id_aa64mmfr1 = READ_SPECIALREG(id_aa64mmfr1_el1); cpu_desc[cpu].id_aa64mmfr2 = READ_SPECIALREG(id_aa64mmfr2_el1); + cpu_desc[cpu].id_aa64mmfr3 = READ_SPECIALREG(id_aa64mmfr3_el1); cpu_desc[cpu].id_aa64pfr0 = READ_SPECIALREG(id_aa64pfr0_el1); cpu_desc[cpu].id_aa64pfr1 = READ_SPECIALREG(id_aa64pfr1_el1); diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index 098c55361913..1a5863b82535 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -1088,6 +1088,34 @@ #define ID_AA64MMFR2_E0PD_NONE (UL(0x0) << ID_AA64MMFR2_E0PD_SHIFT) #define ID_AA64MMFR2_E0PD_IMPL (UL(0x1) << ID_AA64MMFR2_E0PD_SHIFT) +/* ID_AA64MMFR3_EL1 */ +#define ID_AA64MMFR3_EL1 MRS_REG(ID_AA64MMFR3_EL1) +#define ID_AA64MMFR3_EL1_op0 3 +#define ID_AA64MMFR3_EL1_op1 0 +#define ID_AA64MMFR3_EL1_CRn 0 +#define ID_AA64MMFR3_EL1_CRm 7 +#define ID_AA64MMFR3_EL1_op2 3 +#define ID_AA64MMFR3_TCRX_SHIFT 0 +#define ID_AA64MMFR3_TCRX_MASK (UL(0xf) << ID_AA64MMFR3_TCRX_SHIFT) +#define ID_AA64MMFR3_TCRX_VAL(x) ((x) & ID_AA64MMFR3_TCRX_MASK) +#define ID_AA64MMFR3_TCRX_NONE (UL(0x0) << ID_AA64MMFR3_TCRX_SHIFT) +#define ID_AA64MMFR3_TCRX_IMPL (UL(0x1) << ID_AA64MMFR3_TCRX_SHIFT) +#define ID_AA64MMFR3_SCTLRX_SHIFT 4 +#define ID_AA64MMFR3_SCTLRX_MASK (UL(0xf) << ID_AA64MMFR3_SCTLRX_SHIFT) +#define ID_AA64MMFR3_SCTLRX_VAL(x) ((x) & ID_AA64MMFR3_SCTLRX_MASK) +#define ID_AA64MMFR3_SCTLRX_NONE (UL(0x0) << ID_AA64MMFR3_SCTLRX_SHIFT) +#define ID_AA64MMFR3_SCTLRX_IMPL (UL(0x1) << ID_AA64MMFR3_SCTLRX_SHIFT) +#define ID_AA64MMFR3_MEC_SHIFT 28 +#define ID_AA64MMFR3_MEC_MASK (UL(0xf) << ID_AA64MMFR3_MEC_SHIFT) +#define ID_AA64MMFR3_MEC_VAL(x) ((x) & ID_AA64MMFR3_MEC_MASK) +#define ID_AA64MMFR3_MEC_NONE (UL(0x0) << ID_AA64MMFR3_MEC_SHIFT) +#define ID_AA64MMFR3_MEC_IMPL (UL(0x1) << ID_AA64MMFR3_MEC_SHIFT) +#define ID_AA64MMFR3_Spec_FPACC_SHIFT 60 +#define ID_AA64MMFR3_Spec_FPACC_MASK (UL(0xf) << ID_AA64MMFR3_Spec_FPACC_SHIFT) +#define ID_AA64MMFR3_Spec_FPACC_VAL(x) ((x) & ID_AA64MMFR3_Spec_FPACC_MASK) +#define ID_AA64MMFR3_Spec_FPACC_NONE (UL(0x0) << ID_AA64MMFR3_Spec_FPACC_SHIFT) +#define ID_AA64MMFR3_Spec_FPACC_IMPL (UL(0x1) << ID_AA64MMFR3_Spec_FPACC_SHIFT) + /* ID_AA64PFR0_EL1 */ #define ID_AA64PFR0_EL1 MRS_REG(ID_AA64PFR0_EL1) #define ID_AA64PFR0_EL1_op0 3 From nobody Mon Jul 15 12:37:55 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1v80jCrz5QrR3; Mon, 15 Jul 2024 12:37: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1v75pXFz4GTP; Mon, 15 Jul 2024 12:37:55 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047075; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=bUgFhkuI2SQxSaasgX2BRebr7Ul62RMmxY4byOxOhM0=; b=I9ut2cwFXILLM1XCVVf3pMur6TUUVBIr46IX/LbWekHdzz0kIudFGUPjlbwPEeNdlxK+BC 2eBx+PSE8a83y7lgCYIkqitNCPrmkMZKyswv2hkZ/Rr6vlCL/myS1CxOpnA0EIyDViTzW/ QJtW/l0+Iz/yf5e6Qlcte+j66VHCgx9ie3ZnFETPoodwtT6dPsPArkwbzOZWBN0vmb/nli nLtL9BuZyXdOMc3xI+Zz/cVFhbzyUzYU3bmraPVcv0gy/vEytmcnVHzIHQC/mVEB6SEykM bLKsFSgxcQ7+VIBVe5GnIu9qWyYmmVfNgJdVoPDmm4fQQl3iji8NznFesPP7qw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047075; a=rsa-sha256; cv=none; b=eHIzmkKPY/NI/+6lOpA5yaJIJAIoRv4WklZg3ZqCjjARaYfOMdA5O/7tYNfBa7PzuyGGzD scrkCHuhyP/rvHbzMFt3w0cc+YLwC9EK3buSCSXcmIz181KQVNtcgI9Xh1V1CL9+LiZ4Hr Wb544sKQqDXynUNAYeIaLRGHqBLaHjDDmOvty6p7iWlsHtVdE5gjjubyvPmHxC5Eq8ZHb7 BXh1lq/Uk2B2EYxSNyEe0edcMgi2V9X9VW+RobirdzfhCtTzENOyOz82ufn2Rz0BCacSFO fQ3Im6NMBbfPV7EHKlGehM9VJTQHS3NXfTZR4FZUIUoaNviWVElfXHkWeufj+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=1721047075; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=bUgFhkuI2SQxSaasgX2BRebr7Ul62RMmxY4byOxOhM0=; b=OObRaLe9aul+IZGxRk1XYnpImcqCOIJL3n3hvNurFlncCWLnMImfqKVm9z74d2s/KG4k+q jn5xIIUCxkMjs2Fi1PgU/Tvx0qu0N5Xp46AKCkuF/qpGg7BqwW/XHXQKGYesbEK0tsnUtg U1/UBGla/LpxYoND224N5pIzClFVrYSnNgxTYVJ0VR9z7ZqieaLVOJLcQLrS3nBUmZ8Nyd DC/Pt0pReEy/Cj0sHMk2uKqu1tKpapulrf0xqwX5BAnJdf63miETfRn4rLELsv4PUdDTE3 zFM1lWV77xSU5HUnPnEDbfNQGqKr68NJmQw5eI+OwTgSlm1KtpABEdN8QbJI1g== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1v752Rczsp6; Mon, 15 Jul 2024 12:37:55 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCbtag058749; Mon, 15 Jul 2024 12:37:55 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCbtXC058746; Mon, 15 Jul 2024 12:37:55 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:37:55 GMT Message-Id: <202407151237.46FCbtXC058746@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 2b5827fbbae7 - stable/13 - arm64: Decode the ID_AA64MMFR4_EL1 register List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 2b5827fbbae7b7de96221e966d8f676560120084 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=2b5827fbbae7b7de96221e966d8f676560120084 commit 2b5827fbbae7b7de96221e966d8f676560120084 Author: Andrew Turner AuthorDate: 2023-07-06 13:51:52 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 08:09:50 +0000 arm64: Decode the ID_AA64MMFR4_EL1 register No fields have been defined, but it has been documented in the Architecture Reference Manual. Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D40894 (cherry picked from commit 22235b631ba27d71090aa8f0d2794395feddbbe6) --- sys/arm64/arm64/identcpu.c | 14 ++++++++++++++ sys/arm64/include/armreg.h | 8 ++++++++ 2 files changed, 22 insertions(+) diff --git a/sys/arm64/arm64/identcpu.c b/sys/arm64/arm64/identcpu.c index 2750f400fb66..02dcfa326559 100644 --- a/sys/arm64/arm64/identcpu.c +++ b/sys/arm64/arm64/identcpu.c @@ -130,6 +130,7 @@ struct cpu_desc { uint64_t id_aa64mmfr1; uint64_t id_aa64mmfr2; uint64_t id_aa64mmfr3; + uint64_t id_aa64mmfr4; uint64_t id_aa64pfr0; uint64_t id_aa64pfr1; uint64_t id_aa64zfr0; @@ -1243,6 +1244,12 @@ static const struct mrs_field id_aa64mmfr3_fields[] = { }; +/* ID_AA64MMFR4_EL1 */ +static const struct mrs_field id_aa64mmfr4_fields[] = { + MRS_FIELD_END, +}; + + /* ID_AA64PFR0_EL1 */ static const struct mrs_field_value id_aa64pfr0_csv3[] = { MRS_FIELD_VALUE(ID_AA64PFR0_CSV3_NONE, ""), @@ -1780,6 +1787,7 @@ static const struct mrs_user_reg user_regs[] = { USER_REG(ID_AA64MMFR1_EL1, id_aa64mmfr1), USER_REG(ID_AA64MMFR2_EL1, id_aa64mmfr2), USER_REG(ID_AA64MMFR3_EL1, id_aa64mmfr3), + USER_REG(ID_AA64MMFR4_EL1, id_aa64mmfr4), USER_REG(ID_AA64PFR0_EL1, id_aa64pfr0), USER_REG(ID_AA64PFR1_EL1, id_aa64pfr1), @@ -2481,6 +2489,11 @@ print_cpu_features(u_int cpu) print_id_register(sb, "Memory Model Features 3", cpu_desc[cpu].id_aa64mmfr3, id_aa64mmfr3_fields); + /* AArch64 Memory Model Feature Register 4 */ + if (SHOULD_PRINT_REG(id_aa64mmfr4)) + print_id_register(sb, "Memory Model Features 4", + cpu_desc[cpu].id_aa64mmfr4, id_aa64mmfr4_fields); + /* AArch64 Debug Feature Register 0 */ if (SHOULD_PRINT_REG(id_aa64dfr0)) print_id_register(sb, "Debug Features 0", @@ -2594,6 +2607,7 @@ identify_cpu(u_int cpu) cpu_desc[cpu].id_aa64mmfr1 = READ_SPECIALREG(id_aa64mmfr1_el1); cpu_desc[cpu].id_aa64mmfr2 = READ_SPECIALREG(id_aa64mmfr2_el1); cpu_desc[cpu].id_aa64mmfr3 = READ_SPECIALREG(id_aa64mmfr3_el1); + cpu_desc[cpu].id_aa64mmfr4 = READ_SPECIALREG(id_aa64mmfr4_el1); cpu_desc[cpu].id_aa64pfr0 = READ_SPECIALREG(id_aa64pfr0_el1); cpu_desc[cpu].id_aa64pfr1 = READ_SPECIALREG(id_aa64pfr1_el1); diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index 1a5863b82535..4f99f50456ef 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -1116,6 +1116,14 @@ #define ID_AA64MMFR3_Spec_FPACC_NONE (UL(0x0) << ID_AA64MMFR3_Spec_FPACC_SHIFT) #define ID_AA64MMFR3_Spec_FPACC_IMPL (UL(0x1) << ID_AA64MMFR3_Spec_FPACC_SHIFT) +/* ID_AA64MMFR4_EL1 */ +#define ID_AA64MMFR4_EL1 MRS_REG(ID_AA64MMFR4_EL1) +#define ID_AA64MMFR4_EL1_op0 3 +#define ID_AA64MMFR4_EL1_op1 0 +#define ID_AA64MMFR4_EL1_CRn 0 +#define ID_AA64MMFR4_EL1_CRm 7 +#define ID_AA64MMFR4_EL1_op2 4 + /* ID_AA64PFR0_EL1 */ #define ID_AA64PFR0_EL1 MRS_REG(ID_AA64PFR0_EL1) #define ID_AA64PFR0_EL1_op0 3 From nobody Mon Jul 15 12:37:55 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1v74ts6z5QrWW; Mon, 15 Jul 2024 12:37: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1v73gbfz4Gq6; Mon, 15 Jul 2024 12:37:55 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047075; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=iTo6fAGA2QIHjvoL5JF8FamVXGP+p8swtzoQOr0/dJo=; b=sFLdujlkZ+V+LAfCd338WvAcg+TybVBIDmaQrq3H7knbdTbdruIKFipb2/TZjToEq1PQPK IhRkxuo5o0jc1jYE1Qjx9AuAPqwkkxboy7dXc/smGynWwrMG9v5aHwXbBbxjYFAbnn7Vtw tgyRwEresXKuaItbDY19g7RvsKPgbgZzh8r9HH5ZhQEbpNQQWEfmSaFS/VC2agNpQ48xod pJGVnLcFxHwadkaiwGAmTpeg43oaOR/X1PrfWCcF4D5rivBOqqFJrYPdFLPyL/LhXowAHi TXpspLG0XXx15Wzt1T1utKsne1hLSdM0PA+IsZYtu+oFD6PZF6fakA0QiE0rpw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047075; a=rsa-sha256; cv=none; b=hZorZyFLdyVYM9u9RvOJ7/W7DCEYtWpwHffOlleM/f+iKBk2j48+eZHm44FEsXboXNtAOj KeO9Ln6o+On0tFq2Zq3ca1f1QSZE811iuCao6y0ojIvavYZL1hWlEtNeoPY6KtB5tEOUG+ vB8HjEIFYi6VwgRMWZLM/a6a/4dJKZltcVVDXW4e+UzCB7eePuErZk2pFrgWeMQzLc47Hk ESmSWJ1mjl0FGctnlFbre6OhabqLeZbqSYa57zU8SjHZT0Ai3/SwsW9LWbLsYIcDZB1wyt vzqSHKGQ1yxlFSj5ecQZYMZ7BdQ7376fIyzZ/tcNcgB21YNnKEYjtcrYIs4zHg== 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=1721047075; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=iTo6fAGA2QIHjvoL5JF8FamVXGP+p8swtzoQOr0/dJo=; b=CTaiX1tpzjFKWiCjYBNa4TnZIX3EcfZgO+PVjpiuFwG7KJ5lzQsTeB9znSo8iFBNLt10Op 6SzEczPlRJLVL0OfgzBKOFcYeJkWJifw1osfJLfhTokFk7Gq/s0o8F9Ljac5TybbjImBpZ LBp6qYEvIQWCRKTu3G1otHzym0N2FWmVpy1VxNfz54zlR7MxYlWFgEJZ1i9BGouv1GkI6e gsiPZGDAJdL7shTGwJZ/qjEj4QPeHjRNUQB4GdNHfqHYH6VC20va9IFOob7e0hniPkk5Ym n9RlHqxCBj427smpHqM4OpgEZVKAjHVe9VvV0obLQ77yffj1b/tBnXwtlBiaDQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1v72gg7zt1M; Mon, 15 Jul 2024 12:37:55 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCbtKc058707; Mon, 15 Jul 2024 12:37:55 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCbtjw058704; Mon, 15 Jul 2024 12:37:55 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:37:55 GMT Message-Id: <202407151237.46FCbtjw058704@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 0ea3e76c4bae - stable/14 - arm64: Add ISS_MSR_REG for ESR_ELx.ISS values List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 0ea3e76c4baef06c344267209d45c778e2cab04d Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=0ea3e76c4baef06c344267209d45c778e2cab04d commit 0ea3e76c4baef06c344267209d45c778e2cab04d Author: Andrew Turner AuthorDate: 2024-02-21 18:10:19 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:21:45 +0000 arm64: Add ISS_MSR_REG for ESR_ELx.ISS values Add a macro to get the ESR_ELx ISS value when we trap accessing a special register. (cherry picked from commit 09ac9cf8971a0709bb8d5a3a703cd3dbff882b6f) --- sys/arm64/include/armreg.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index f3af9edec4c4..6f9e109f4b70 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -365,6 +365,12 @@ #define ISS_MSR_REG_MASK \ (ISS_MSR_OP0_MASK | ISS_MSR_OP2_MASK | ISS_MSR_OP1_MASK | \ ISS_MSR_CRn_MASK | ISS_MSR_CRm_MASK) +#define ISS_MSR_REG(reg) \ + (((reg ## _op0) << ISS_MSR_OP0_SHIFT) | \ + ((reg ## _op1) << ISS_MSR_OP1_SHIFT) | \ + ((reg ## _CRn) << ISS_MSR_CRn_SHIFT) | \ + ((reg ## _CRm) << ISS_MSR_CRm_SHIFT) | \ + ((reg ## _op2) << ISS_MSR_OP2_SHIFT)) #define ISS_DATA_ISV_SHIFT 24 #define ISS_DATA_ISV (0x01 << ISS_DATA_ISV_SHIFT) From nobody Mon Jul 15 12:37:56 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1v92fHvz5QrLc; Mon, 15 Jul 2024 12:37: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1v86hjWz4GnK; Mon, 15 Jul 2024 12:37:56 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047076; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=RqlmCaX0mfabu24Fwg1i0Rl6WsIhJh2qpSPneWzLbtI=; b=OpdofDDbS0huCFMdLcpU3ieAlN7cMYPvIoFpuNfW7yW1YnhFgczvZad4pyrpXCOt0SXnrR rEpBJz4BRTzXyHJmv8esvHelxMBuvbtL0lj6dHgZ7avCTUTPGAWw+ZV5+UqrHZR0TyhvgF AdlRFdbo5gvdiQ+QB2Ta3bqDNSO4//NBZRDvTipigLY7g5I8qvXFsN8K/R5icRPChWS2TD wBtIlB7KmLzrVRcExyg1s2S6BlwzVtmjDPXJKu8buRTvDZHM+SmHR+wBlNapX6uuIBxl43 XKzERkJNneAHXBhNf64bxmxafS/0lTkjjFoMAQptLSeHYU1mhmv+R0dpybDZyQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047076; a=rsa-sha256; cv=none; b=GrLfytzmx5/b09b4AFAyBb6PK22S627k/rguMaWU+t4urpfQledp07bhXnIJ623cwa9QOt ut/VIJqPVEJ17JK/gcDmg9eER5NAvvzu9Q6nc2mwRcMKZoPoNIlHA1I6HTuBo3YV9mXZY9 2YAbOH2rtkFO0Btp/3H88J3HL+X7VLOjg2T4iA1JvMNqr12kA4wRquYpmWCUz7EtMHWmT+ 0w3M0HlJSdkXaZ3oWBUL84S525hTxFEuVIVK26gkserSzDSLjLcDeFGq7BZBXYpzIH5Jb2 CN6DUDkwx2I9xclg7vQxhtNJhS1gt0tFhuW3UNl0zEWZrCl2NxivuezbEjbmXQ== 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=1721047076; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=RqlmCaX0mfabu24Fwg1i0Rl6WsIhJh2qpSPneWzLbtI=; b=xHMlUpTDGAQeM4rDR0ywCYlBmonVmHrdlGE/LrNh2UURa+00a+Fgl0sLy5YjdlPq4nYyz2 xot9bc21radfoX+WXt2konjBCPWoxJexAy+nXRet4fsGDyH8J1bop2Z4K4KCT8FkjJYBIb hjjacYFVyblYKPnOE+rE2MI1DxbjhydkzsTtEFwiB7AXOSYgLPm95WsMr8UgK1nodWKj1w H6zikuR/ANVMILu31tefXslbg8AI4JmWATUeXN9bVOQv5to98NIuFEf6nxwmmQzBd71Bc6 bHbHOQEmWjye39yupXJr8rnaZGlE5b8iUl403Dd/d4Vxi/yF2Wb5+svwosvyHw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1v86JRbzscb; Mon, 15 Jul 2024 12:37:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCbuqf058833; Mon, 15 Jul 2024 12:37:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCbugb058830; Mon, 15 Jul 2024 12:37:56 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:37:56 GMT Message-Id: <202407151237.46FCbugb058830@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: c9303e68d316 - stable/13 - arm64: Decode the ID_AA64PFR2_EL1 register List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: c9303e68d31695875e5ec6dd98862b5ee409b1d6 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=c9303e68d31695875e5ec6dd98862b5ee409b1d6 commit c9303e68d31695875e5ec6dd98862b5ee409b1d6 Author: Andrew Turner AuthorDate: 2023-07-06 14:48:42 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 08:09:50 +0000 arm64: Decode the ID_AA64PFR2_EL1 register No fields have been defined, but it has been documented in the Architecture Reference Manual. Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D40897 (cherry picked from commit 53e1af5a1094ec37412bc33b739de72ed723c428) --- sys/arm64/arm64/identcpu.c | 14 ++++++++++++++ sys/arm64/include/armreg.h | 8 ++++++++ 2 files changed, 22 insertions(+) diff --git a/sys/arm64/arm64/identcpu.c b/sys/arm64/arm64/identcpu.c index 02dcfa326559..fcbf607b8fef 100644 --- a/sys/arm64/arm64/identcpu.c +++ b/sys/arm64/arm64/identcpu.c @@ -133,6 +133,7 @@ struct cpu_desc { uint64_t id_aa64mmfr4; uint64_t id_aa64pfr0; uint64_t id_aa64pfr1; + uint64_t id_aa64pfr2; uint64_t id_aa64zfr0; uint64_t ctr; #ifdef COMPAT_FREEBSD32 @@ -1488,6 +1489,12 @@ static const struct mrs_field id_aa64pfr1_fields[] = { }; +/* ID_AA64PFR2_EL1 */ +static const struct mrs_field id_aa64pfr2_fields[] = { + MRS_FIELD_END, +}; + + /* ID_AA64ZFR0_EL1 */ static const struct mrs_field_value id_aa64zfr0_f64mm[] = { MRS_FIELD_VALUE_NONE_IMPL(ID_AA64ZFR0, F64MM, NONE, IMPL), @@ -1791,6 +1798,7 @@ static const struct mrs_user_reg user_regs[] = { USER_REG(ID_AA64PFR0_EL1, id_aa64pfr0), USER_REG(ID_AA64PFR1_EL1, id_aa64pfr1), + USER_REG(ID_AA64PFR2_EL1, id_aa64pfr2), USER_REG(ID_AA64ZFR0_EL1, id_aa64zfr0), @@ -2469,6 +2477,11 @@ print_cpu_features(u_int cpu) print_id_register(sb, "Processor Features 1", cpu_desc[cpu].id_aa64pfr1, id_aa64pfr1_fields); + /* AArch64 Processor Feature Register 2 */ + if (SHOULD_PRINT_REG(id_aa64pfr2)) + print_id_register(sb, "Processor Features 2", + cpu_desc[cpu].id_aa64pfr2, id_aa64pfr2_fields); + /* AArch64 Memory Model Feature Register 0 */ if (SHOULD_PRINT_REG(id_aa64mmfr0)) print_id_register(sb, "Memory Model Features 0", @@ -2610,6 +2623,7 @@ identify_cpu(u_int cpu) cpu_desc[cpu].id_aa64mmfr4 = READ_SPECIALREG(id_aa64mmfr4_el1); cpu_desc[cpu].id_aa64pfr0 = READ_SPECIALREG(id_aa64pfr0_el1); cpu_desc[cpu].id_aa64pfr1 = READ_SPECIALREG(id_aa64pfr1_el1); + cpu_desc[cpu].id_aa64pfr2 = READ_SPECIALREG(id_aa64pfr2_el1); /* * ID_AA64ZFR0_EL1 is only valid when at least one of: diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index 4f99f50456ef..b2d9d0926c8f 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -1280,6 +1280,14 @@ #define ID_AA64PFR1_NMI_NONE (UL(0x0) << ID_AA64PFR1_NMI_SHIFT) #define ID_AA64PFR1_NMI_IMPL (UL(0x1) << ID_AA64PFR1_NMI_SHIFT) +/* ID_AA64PFR2_EL1 */ +#define ID_AA64PFR2_EL1 MRS_REG(ID_AA64PFR2_EL1) +#define ID_AA64PFR2_EL1_op0 3 +#define ID_AA64PFR2_EL1_op1 0 +#define ID_AA64PFR2_EL1_CRn 0 +#define ID_AA64PFR2_EL1_CRm 4 +#define ID_AA64PFR2_EL1_op2 2 + /* ID_AA64ZFR0_EL1 */ #define ID_AA64ZFR0_EL1 MRS_REG(ID_AA64ZFR0_EL1) #define ID_AA64ZFR0_EL1_REG MRS_REG_ALT_NAME(ID_AA64ZFR0_EL1) From nobody Mon Jul 15 12:37:56 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1v92gvgz5QrWX; Mon, 15 Jul 2024 12:37: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1v842vnz4Gw7; Mon, 15 Jul 2024 12:37:56 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047076; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=dBI6kR67ObUE0z+6oJf1AiD4f3vS1NRuf8egtqbiGoU=; b=UT/FeJ+xhghDpvFGg9gqTcOrJX8obj/OVM3rt+pEGEvn5+3uOs+7qdJJHgSX4Po/AAWphk 6dQZDPWjAa1dJ6ArrULzdFjuLuydb7zEJ2TzQQeJ0UAILFTJCKGxMiF2DQgPJccan76kda Xr6Prry+L8gGPbqd++Zwtuck2SUihSyPTmGiZ/Q2+ZSBewuzjiFX+3Jl+VLhuPi0s7wYRk 3vqvnkZxUdVEMnQBbW6MEEBH4smxy87qw3S7KMrUWwCQKS/aPRHc3MyOqYQ2fsrP00pfEI rFufwYnrQ7PgpEMGI3CZ7o7XcxToWSYVTBlJbP1VzwqVROLw/RfSWWylDjb8NQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047076; a=rsa-sha256; cv=none; b=aMX3bGOK8zwjsncDEUnku2kMa1AW5zG4ok/AEAtRWbYWNMAZrTp5k9NynGj481Pqyz1MxW RDn1+de4m/o9+J77MPYthQeLis0p4Np9khgNtpYAnCfU6o5rnoOcmxTz7f3NqqiAr5tbKj vm9+KMpUK+7wisF9tPAbdeGp6XMNWnqoYjbuFL7YrXXftreRcbcNAXO8hOCODg4gFr+8L4 bSmBrfGRNoDBFAmW0vjNenTJ873c3u7bLeq8D2nhBdKgYIYb1ynEZDGV3ZfsVItuuSo0mD H/4xc7cRR5O/In8jg7qRdfwdigZMahcHER53123chfrZJP3y3ymeHbWO1yjqGw== 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=1721047076; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=dBI6kR67ObUE0z+6oJf1AiD4f3vS1NRuf8egtqbiGoU=; b=U2axDUeH/204sD9zTPi7zgfjQpPRKXIeG1EdrwhWUxrzJQSwmTIXRLNLT3sHlv51uPXiKf ID5a5EktDeFaErpaqIdDe/Ip0Y5SRwwepuDJZ4ZEKmkeKMFqY13yOlA8Y349SY6aW9JLnZ k0Xqm2uNMtpG5tMttgqAwCpB3jMPSH/BbfKJ/zd+urglgh2liF1dFCofo4pzVJhTvV1lon YmXasCJDEhBwJzUldPjbxnCKaLvfytJa/iurVHH8m4kvAhVtvciXD/dHSuBEO7RlSXRpfl 4Q0lnALSfl1TUwvMnj50adaNVV4bfJNGFQZDhXU637VkSYq+ZsDaOcJW9IyP4Q== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1v83dBpzsLv; Mon, 15 Jul 2024 12:37:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCbuud058791; Mon, 15 Jul 2024 12:37:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCbuSw058788; Mon, 15 Jul 2024 12:37:56 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:37:56 GMT Message-Id: <202407151237.46FCbuSw058788@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: f9878b9c8efa - stable/14 - arm64: Add the TCR_EL2.PS mask List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: f9878b9c8efa6c0cc43503851831d5525aa0a28e Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=f9878b9c8efa6c0cc43503851831d5525aa0a28e commit f9878b9c8efa6c0cc43503851831d5525aa0a28e Author: Andrew Turner AuthorDate: 2024-02-21 18:16:43 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:21:55 +0000 arm64: Add the TCR_EL2.PS mask (cherry picked from commit 9c52f98c9f1abfe6577335522b6007659f759adc) --- sys/arm64/include/hypervisor.h | 1 + 1 file changed, 1 insertion(+) diff --git a/sys/arm64/include/hypervisor.h b/sys/arm64/include/hypervisor.h index 589d6e9cbdbe..18f173c77720 100644 --- a/sys/arm64/include/hypervisor.h +++ b/sys/arm64/include/hypervisor.h @@ -169,6 +169,7 @@ #define TCR_EL2_TG0_64K (0x1UL << TCR_EL2_TG0_SHIFT) #define TCR_EL2_TG0_16K (0x2UL << TCR_EL2_TG0_SHIFT) #define TCR_EL2_PS_SHIFT 16 +#define TCR_EL2_PS_MASK (0xfUL << TCR_EL2_PS_SHIFT) #define TCR_EL2_PS_32BITS (0UL << TCR_EL2_PS_SHIFT) #define TCR_EL2_PS_36BITS (1UL << TCR_EL2_PS_SHIFT) #define TCR_EL2_PS_40BITS (2UL << TCR_EL2_PS_SHIFT) From nobody Mon Jul 15 12:37:57 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1v96sndz5QrTg; Mon, 15 Jul 2024 12:37: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1v95KVHz4GwD; Mon, 15 Jul 2024 12:37:57 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047077; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6zWI5/BvwJWBfzdY5pB6z5p1AAyVd90+5NQMyMgReKc=; b=Okk3Jg2GD6U9cPSfyemf3KyBzj91X7ANKq32bQ/DpVuE8C1cqEtz138RNRUtHs94DdRiQL HQRdcFJkJS13WX2JvCU2MveOUkBOocFZi9vqHXMnd1htfJFijsV8/o0FlmgbkcNnBr7ZwD GZYGfTv4OcJRR3fw/jbZTQ2ywfcwiAQNMv+hO9qiG0Vw64ae+A+8IPR8DwVojFqkntT4Up MbS3uQ1Xp2bVT+b8v21ZK3rxvwgQz2cFn0uXLJdSif5UttWjPsf+QfDeEWvSWB1NFbzfYD OyEPN1Xzr/M3O4Ipf7QkdXugdI3pZogqan67GFu/Ee4fli0nqDQ3l4Hj7kuYxg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047077; a=rsa-sha256; cv=none; b=hQMg7yXfmahgrF7go/GlePXYwwVAykXSsDXVPBpZfgHHIVpcpLTHwmB4jIyD5b9H+nTKp9 1m6m9K44uvHm7/I8yl9ooBXZrsiq7raKdPR0FFbqkuaPY1hiCOC40aGXxqTyMiJEPn8oeo VxMoxz/U9wm9QmIqJueMi8WCFFEmGIJjS15rVUU7bNFchdqmaHYC6ORj++n1FCqTR2ku/M g1sTH/nEpxiRaHhGQ+zjOodr/aFZMkvZWQx5l5pw406n32nfi8F2vkPNDkUIft5oPDWZo1 nhPpYCtpZDp9D183x0QcorDfWfJtWMC7sxg4Lk3SO4pWZ6yKBvjGI7OsCEqGzA== 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=1721047077; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6zWI5/BvwJWBfzdY5pB6z5p1AAyVd90+5NQMyMgReKc=; b=krlNWFS7fHLOslweR8n9nrir9WaaEThWsX+ZGa+1buQZOnW4r/T9Xqn1WT2KyyvcO93SIb HC41fR1GyApnlK+zFawFW5TeJSqMI6sG/iuFLv4KodXIS2nx7Ona0ZTZiDJhNSe95mhoHA 3g9aVy09XkDMYIYzyNL5MgB0/KyMb1QJ4JzKt78mPq3eckzrdtZkSH86loCwcgf0jpadQ7 FYGVx1C3CjC0zsTz1sm2BCgejDnO7jVq7sL1xNLmhz1FO1K8Xzm5PYI2o7gaAyqT60JuhT +SHNzZQ9ZCcLHP3Ui5ELnOp7KDPuXTJ7UtNIozTjmQ5PzFKQuaH9fc00Pk4UZA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1v94cbQzsnb; Mon, 15 Jul 2024 12:37:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCbvcb058890; Mon, 15 Jul 2024 12:37:57 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCbvPp058887; Mon, 15 Jul 2024 12:37:57 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:37:57 GMT Message-Id: <202407151237.46FCbvPp058887@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: c7c27e9ebfdb - stable/14 - arm64: Add a macro to find a VM fault address List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: c7c27e9ebfdbd8e46f7af9aeee2a4c407e102981 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=c7c27e9ebfdbd8e46f7af9aeee2a4c407e102981 commit c7c27e9ebfdbd8e46f7af9aeee2a4c407e102981 Author: Andrew Turner AuthorDate: 2024-02-21 18:17:47 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:22:07 +0000 arm64: Add a macro to find a VM fault address Add a macro to find which bits from far_el2 are needed to be copied to get the full intermediate physical address (IPA). The hpfar_el2 register only contains a 4k aligned fault address. We need to include the lower bits from far_el2 if we need the full faulting IPA. (cherry picked from commit b3bbec37ba039a46f7166f6fa3571f38da4253e9) --- sys/arm64/include/hypervisor.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sys/arm64/include/hypervisor.h b/sys/arm64/include/hypervisor.h index 18f173c77720..85ac5cda7037 100644 --- a/sys/arm64/include/hypervisor.h +++ b/sys/arm64/include/hypervisor.h @@ -126,6 +126,8 @@ /* HPFAR_EL2_FIPA holds the 4k page address */ #define HPFAR_EL2_FIPA_ADDR(x) \ (HPFAR_EL2_FIPA_GET(x) << 12) +/* The bits from FAR_EL2 we need to add to HPFAR_EL2_FIPA_ADDR */ +#define FAR_EL2_HPFAR_PAGE_MASK (0xffful) /* ICC_SRE_EL2 */ #define ICC_SRE_EL2_SRE (1UL << 0) From nobody Mon Jul 15 12:37:57 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vB3kvyz5QrLd; Mon, 15 Jul 2024 12:37: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vB0kYCz4GnZ; Mon, 15 Jul 2024 12:37:58 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047078; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=N/oJKwd/rUwb5ExGsuCX2xL3jNobxmZbZ6f/hyFz5Vg=; b=jBN6kW4N+5AGqzIqhWW4dmfbDciuyttYvA0SYsu03q15/KIMbTEqurVi7IevliNXmsL9ku VLoe3mHPzRAdGV0AsTevo/xPCzM3Kvrl8N8GNlgEQvxhs7mOzuYzUb1jxz6cm1JWNG2bI2 sAwLsZIGq9dFoYcX//VNH7xIJivt84KbVVFFIABDtzRVXD3PErjW2irb/zJjphFCIaWLxR mKsAmlstV/IrfrwpWjFUJKEHiBVzp9bSI5+ZQQqJw53M9gvACJzus8uip4Sf8WnZBxq5Ud YEV7r4xG00inw3Q5rGEKTb3UFd+t9DiP1ajG8egGxegzChBFo7/Qh7ad/SvEEQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047078; a=rsa-sha256; cv=none; b=JFTcQWMuoUxoKzBGF7t2Tt/HzuTCFgkznSSfvh9feLDUxdzdgFhooUgzzOWdyRIn7fss3F OP197ao5udrW1q+msAWKNA0u1be6V+mWwfMsWI464lwWez2ANlIaPIocspe3hLYfDwJBCu trQs5DNuxzY4JsFqEaI7qM6wBCLx92yB606KGANHsEunjkBsJvWF3E2aqLiT8EkS23wknn dXXV68dhxJtBgJmF0gbzTp3Jl9xhIZ7NIL1FSV3T2h221woKeDzF2WfgczA4wopo8x5S9T GYxvpRnD5Rkj/Tgqdupor9fckNEYpvk/78sNUgi44KicrXee9DmDd/IKJKh4vg== 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=1721047078; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=N/oJKwd/rUwb5ExGsuCX2xL3jNobxmZbZ6f/hyFz5Vg=; b=K30p3Rf9iQwYKL5qJd/ipXmSbc1IDZ27VpCPkaY4Hk+ICpW78T2CvRvmDvJJAtvYR1CuwD haS5jbMvIde8hjXHoPMEcMmmZj7376MbuqtbjHdxEFQnk3+Kj8V77G1LdGuuNNgVQE5BGu dfsDoTnyodQIWIMWlUB3nUkn367qPpZForYnKX/K0ImraI5wzq9N9bFoS2zrJdJ2i/tJg/ AmZXXQOAor/i+ts/l79F0Ca75xLj0NfRyW45x3afql340vYJGeljKaLswpE9h6GLKFCytq jQey4Ga0NIB4P1BXDdsp+WjOdxbXpp1C7H2UhuLAFO5jqlYs2RhH77yVfMeyMA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vB0C1Qzt39; Mon, 15 Jul 2024 12:37:58 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCbvuv058932; Mon, 15 Jul 2024 12:37:57 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCbv6k058929; Mon, 15 Jul 2024 12:37:57 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:37:57 GMT Message-Id: <202407151237.46FCbv6k058929@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: e7a9961870d9 - stable/13 - arm64: Add CurrentEL register definitions List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: e7a9961870d96676e65451102deb14470559d101 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=e7a9961870d96676e65451102deb14470559d101 commit e7a9961870d96676e65451102deb14470559d101 Author: Andrew Turner AuthorDate: 2024-02-19 14:57:34 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:28 +0000 arm64: Add CurrentEL register definitions Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D43971 (cherry picked from commit 5e7941b6c979a55dc67baf316db6932c09b14022) --- sys/arm64/include/armreg.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index b2d9d0926c8f..22bb71dbea51 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -193,6 +193,14 @@ #define CTR_ILINE_VAL(reg) ((reg) & CTR_ILINE_MASK) #define CTR_ILINE_SIZE(reg) (4 << (CTR_ILINE_VAL(reg) >> CTR_ILINE_SHIFT)) +/* CurrentEL - Current Exception Level */ +#define CURRENTEL_EL_SHIFT 2 +#define CURRENTEL_EL_MASK (0x3 << CURRENTEL_EL_SHIFT) +#define CURRENTEL_EL_EL0 (0x0 << CURRENTEL_EL_SHIFT) +#define CURRENTEL_EL_EL1 (0x1 << CURRENTEL_EL_SHIFT) +#define CURRENTEL_EL_EL2 (0x2 << CURRENTEL_EL_SHIFT) +#define CURRENTEL_EL_EL3 (0x3 << CURRENTEL_EL_SHIFT) + /* DAIFSet/DAIFClear */ #define DAIF_D (1 << 3) #define DAIF_A (1 << 2) From nobody Mon Jul 15 12:37:58 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vC1Jnhz5QrJd; Mon, 15 Jul 2024 12:37:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vC05J9z4Gt1; Mon, 15 Jul 2024 12:37:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047079; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=kwPpW2fN+OMXNAzP64Fvb4hCXSZ7smjCLbR9wTPuvxI=; b=TJ/HKPiTzKyjrOJ78kvD/ExJP0DsdrUX5tZkWRpSq2vYCvAJXGUumsoiJywj+dQhJJbkMb H1RWRK1tRtgDVV/knJuY2iJF5EKnEZFf3xPamCBu8V18nn15GXPHmReGLmr2FDXBjeAzta jISSROvvnFxF5lyx8p5iJGp7uoFLNEMjNW9AbNuL+pvFx42afkewHwYzw7Tzi/oXVlSkdx TdqgKVyrzwRAQVGbRlCHpEqgXQZ2zdClnuXhlkr8UdDLO0QWbS5Qz2N7ZgDWGgAiTgZTwH ts0bx0T1QwN5XKm+b0uR/Y54omAtx6R+HV1ppiGFZtwgSHrJF9/dXIWznMM1ng== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047079; a=rsa-sha256; cv=none; b=wntEbZ3fSGjyZNzqKtI7w7vICGtGnZzbvVGfcfWRHF/jv3sm6Jqpd5Nkmh2QvbLaR97ypI IMKx3Qb2H9ske4+neAd3LG7ycX5Jp5TEOrfUoMs3isyxXgHImzCNJHyFLGqEC9C2Gao7IP 2U78MLJyIoA13l5QGAuO6q/yOV+qkuchmczBJ8iu+xGeANt2Ud5TasZ6h8J6l7AcXZZpze wOKCD+oM/N+0gGMGT0X0VWkT+MXKo/iIVD6C5xieUO6w8mWQT1cQayGhKqf7LYIba0gXJa FhFrXQhRcNOaI5cpDwxevMrelMCtsN16tKnYqohgdJsEi031V/E/j8nM23w0oQ== 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=1721047079; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=kwPpW2fN+OMXNAzP64Fvb4hCXSZ7smjCLbR9wTPuvxI=; b=eHrV2z0aRlf/aD/HDnhtkN8MHT6FYURLirc0Vu12Z4AFCA0kpt0/1rHZOmKh5+BZkEUyEP W2dE5CD43oHJqInRYs5rdUaAhhDdr4x93wv079n7SCP2djG3jly41XIT09kgErcUuntN2c 99Wz81Tx9puP1AVvKocW0kEJNJ7hGisJ+DCOFg4S2Mhq7JTDSNHCn5p2yAUxbBxzd0Fqlc W/bzLdq8phkuFTn/pvSauNIiakyYayoJt7mkHFNZ7N+P65/yXYhck3KkYsXDrGRICD1ZJD Gi97EG/u3MdI2ER+zPX7dDyRrMHKIuZxUPRpS09FbQm2iavWkeCaD4sw004LuA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vB5vMQzt3B; Mon, 15 Jul 2024 12:37:58 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCbwn4058989; Mon, 15 Jul 2024 12:37:58 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCbwLI058986; Mon, 15 Jul 2024 12:37:58 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:37:58 GMT Message-Id: <202407151237.46FCbwLI058986@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 526ad0a15765 - stable/14 - arm64: Add TF_LR, it will be used by bhyve asm List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 526ad0a15765ea860b9bbba63a0038434d5a395d Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=526ad0a15765ea860b9bbba63a0038434d5a395d commit 526ad0a15765ea860b9bbba63a0038434d5a395d Author: Andrew Turner AuthorDate: 2024-02-21 18:24:04 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:22:17 +0000 arm64: Add TF_LR, it will be used by bhyve asm (cherry picked from commit 0f4071978e3dae6637d4988212661164115f6be8) --- sys/arm64/arm64/genassym.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sys/arm64/arm64/genassym.c b/sys/arm64/arm64/genassym.c index d4970177ab71..3ed3d5976d91 100644 --- a/sys/arm64/arm64/genassym.c +++ b/sys/arm64/arm64/genassym.c @@ -72,6 +72,7 @@ ASSYM(TD_MD_CANARY, offsetof(struct thread, td_md.md_canary)); ASSYM(TF_SIZE, sizeof(struct trapframe)); ASSYM(TF_SP, offsetof(struct trapframe, tf_sp)); +ASSYM(TF_LR, offsetof(struct trapframe, tf_lr)); ASSYM(TF_ELR, offsetof(struct trapframe, tf_elr)); ASSYM(TF_SPSR, offsetof(struct trapframe, tf_spsr)); ASSYM(TF_ESR, offsetof(struct trapframe, tf_esr)); From nobody Mon Jul 15 12:37:59 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vC4s2Gz5QrG4; Mon, 15 Jul 2024 12:37:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vC2r2rz4Gnn; Mon, 15 Jul 2024 12:37:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047079; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=CqxG+b5XnWqtLvfnclPm0DR7pfS2OxeqpK7z5m/RA/w=; b=igiJ/kK9WwPnDDipq9cQoAzZEDBw6arvjnfXxfikL1enQ+H0VuiaWNqPVPykg6nEuKPxhC Jse8nbA2A+gQYfbIK6YMAg15WT0cbA+u7ZY+wHwnytkvDoT8O/k39cC87WykhBjhNgiT3f e6k6S1dqMla33HGousNCegzMpLt/P3/domDlHHRrRniJXu7Agqm9M4ym01BLGhePS3rYv9 fAfr3lJbjIutYfvfzTRq0uRPaThqyRN3eFVMCdIlT8QN2SLiORnIKGKQ3dDsRpMKRhpF8A pQ/Ln+of7MFSvn9H5q8wscaR6X7B7hLCpXEKrVKtHtCPj5iq0yd3eQP/417iSw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047079; a=rsa-sha256; cv=none; b=gcF7t5+kF8CaFp5j1D6LGQ8pjfocSlo9Ee5VaEiwKAl74LeL2+V/FRWpX9Mf1X3M/VEhOd SXNlQNz7CvThz5+k+Do5cmpyIUl4yQBu1k/mavWBMdJ9795Pg7U2uIP+zBuTCOS7YXOzyZ thLYWr7hrAaUwLwWzxpy3nC63pbjDvROAR36ksJX3/sxYRmEOvEtUBmaU/3tMfAZJQJl60 Om9Wb+VNXeZOsiYmuPdiYWd2b9enzj5zFgwd16tX5LctKlilAEuqTAHbCjoGW7UtuBjR0S MJCvmOxI2amFMRBL7hDwPUUGdM5kHwjhLiyg2TqRv3Ruvj3H16BBhIz2c/iDTg== 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=1721047079; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=CqxG+b5XnWqtLvfnclPm0DR7pfS2OxeqpK7z5m/RA/w=; b=Cs1XFL07lYpGu5RJd7sW+YzSpB0w+7EcRNAEUDOc9Z4DDA4KzocsR40FZ+2JqMEB8nRF/0 uCq5hHQxxKrvEp0igf3G8dq9ur9MsL6yEIO6uXpODQG4rBZe8hGRO65N59se9sjAYQDU3P jdyyTxdXOvFZExS8I/Qwa2G/2QMfktleXy88RKF2z+UHDEePra3++d9LWV84gj18x5j18v lLNOSAO+NfJpHRyuGHVTVCTkB727BZJSQmWRZr7ycDoF4CDnEKsMV2IU3lMXV56GLKZqgw LcYNVSeSvwZGu4KfqbdzU+zZeJvkdDYsrCxzyeXGiW6K1HFFQx0REZKG4Em+vg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vC19rpzscc; Mon, 15 Jul 2024 12:37:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCbxCW059040; Mon, 15 Jul 2024 12:37:59 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCbxMj059037; Mon, 15 Jul 2024 12:37:59 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:37:59 GMT Message-Id: <202407151237.46FCbxMj059037@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: df3e8fcf651e - stable/13 - Mark the arm64 PSR register fields with UL List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: df3e8fcf651e8dc6c489ccb94fd777cd4511b1e3 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=df3e8fcf651e8dc6c489ccb94fd777cd4511b1e3 commit df3e8fcf651e8dc6c489ccb94fd777cd4511b1e3 Author: Andrew Turner AuthorDate: 2023-03-22 16:46:25 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:28 +0000 Mark the arm64 PSR register fields with UL These are for a 64 bit register. Make them 64 bit values on arm64. Sponsored by: Arm Ltd (cherry picked from commit 6a4f5fdd19d6de8612998eb7c62273fd8b8c3908) --- sys/arm64/include/armreg.h | 46 +++++++++++++++++++++++----------------------- 1 file changed, 23 insertions(+), 23 deletions(-) diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index 22bb71dbea51..3feb048b2bc8 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -2052,32 +2052,32 @@ * 0: always SP0 * 1: current ELs SP */ -#define PSR_M_EL0t 0x00000000 -#define PSR_M_EL1t 0x00000004 -#define PSR_M_EL1h 0x00000005 -#define PSR_M_EL2t 0x00000008 -#define PSR_M_EL2h 0x00000009 -#define PSR_M_64 0x00000000 -#define PSR_M_32 0x00000010 -#define PSR_M_MASK 0x0000000f - -#define PSR_T 0x00000020 - -#define PSR_AARCH32 0x00000010 -#define PSR_F 0x00000040 -#define PSR_I 0x00000080 -#define PSR_A 0x00000100 -#define PSR_D 0x00000200 +#define PSR_M_EL0t 0x00000000UL +#define PSR_M_EL1t 0x00000004UL +#define PSR_M_EL1h 0x00000005UL +#define PSR_M_EL2t 0x00000008UL +#define PSR_M_EL2h 0x00000009UL +#define PSR_M_64 0x00000000UL +#define PSR_M_32 0x00000010UL +#define PSR_M_MASK 0x0000000fUL + +#define PSR_T 0x00000020UL + +#define PSR_AARCH32 0x00000010UL +#define PSR_F 0x00000040UL +#define PSR_I 0x00000080UL +#define PSR_A 0x00000100UL +#define PSR_D 0x00000200UL #define PSR_DAIF (PSR_D | PSR_A | PSR_I | PSR_F) /* The default DAIF mask. These bits are valid in spsr_el1 and daif */ #define PSR_DAIF_DEFAULT (PSR_F) -#define PSR_IL 0x00100000 -#define PSR_SS 0x00200000 -#define PSR_V 0x10000000 -#define PSR_C 0x20000000 -#define PSR_Z 0x40000000 -#define PSR_N 0x80000000 -#define PSR_FLAGS 0xf0000000 +#define PSR_IL 0x00100000UL +#define PSR_SS 0x00200000UL +#define PSR_V 0x10000000UL +#define PSR_C 0x20000000UL +#define PSR_Z 0x40000000UL +#define PSR_N 0x80000000UL +#define PSR_FLAGS 0xf0000000UL /* PSR fields that can be set from 32-bit and 64-bit processes */ #define PSR_SETTABLE_32 PSR_FLAGS #define PSR_SETTABLE_64 (PSR_FLAGS | PSR_SS) From nobody Mon Jul 15 12:37:59 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vD29Rzz5QrTn; Mon, 15 Jul 2024 12:38:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vD11Swz4H2V; Mon, 15 Jul 2024 12:38:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047080; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=sCg+WdmKVdrP5leeJeeKp8QUViziRjVb/odVO12RNrE=; b=NKHpamlovcmws9dibAxqRL9gL9ixTV61a3IlqnybIy/ml5CTpH9Vz3GIEtG1tXKF06deUp e9mxkOl3LqUD2DldZSY2bdEuVLsCF9eDmPlaDcnVilIP1W8JKBCxuVfNOwnscFnq+9jm7o qxVC6uik1A8ZPnctu97yBMvWV4YirxpOHPhwk50UmkXp/Xo9WUAuW/UnKbgDXNIbeyMyXT /Nf7yd02HKyBSedzXDR13wcs4hi057cwPrvIzoFjpVmKxQboZsjGl6hjNPdUfdsoOvs7NS GdB1jjbP83b8CttRcglztvVVZQob1AQ2L5QkRVlBQuVQ3OK0eYhJQoB444eFzA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047080; a=rsa-sha256; cv=none; b=l/3AfEGimD28R7mBNU2/zI/TO2iKbvpbCnEJDwhc2NC2IoLcT0/IvIcA6PwtGj16FUrYyx DBd2EKaV1luJCXHMOgl+BlNN9nhNZZSY42cr7J8cgjNr/UDGclIHWlSkkXWKz4K0wkYXQp JU1g8BIDpB0/rkU0ffDAb7DvkQ9jTW5kAA+q5MBKMzwHs6ifDmdikZy0BNqEIBEOqKZBwM 2BecZVvPRtL91qeLmkM062jiOa9unM617u+cKFsL5VPNrf6uBPKPSR/FZK6wxsa6ox6EWD +zS4gvykwAhC84UP+FjQTfmKSA8uJ+1GIlehz47hvnoTysajnQq7cneDVbswIA== 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=1721047080; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=sCg+WdmKVdrP5leeJeeKp8QUViziRjVb/odVO12RNrE=; b=AxHxlpWZADpBUuozo0SM3qCXuL9PFCOyf/IqxC+WP5OqLq1/ONfUI5NzvfzzPOwVpuOwSu wKsCGvmtxwAXyQSh8tHklepsFDFaqIfvYvWDgC8DOK4jaKyOy8driq/Pcc2jPKLLrePdKh +x3dl0CYV9RLhMMSV88th62Pw8HodIcAcWH9rTKTe60Tohd6KowadoR3hlBSK9hsqChppP k+4OoYWNGlvU9HEldYzJXi41gGyBZmAWIupcH34Yne3G4Dqe43FTdXvr7JUmLfXxMzVpj0 NhYI31E0f06CtYqAhyLqGJ0W0ceHLfT6oq7ApzZOAGCTKkuifd/jsbyOe00dLA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vC6t0LzsLw; Mon, 15 Jul 2024 12:37:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCbx2G059083; Mon, 15 Jul 2024 12:37:59 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCbxwg059080; Mon, 15 Jul 2024 12:37:59 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:37:59 GMT Message-Id: <202407151237.46FCbxwg059080@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: cfba49ca49f6 - stable/14 - arm64: Rename drop_to_el1 to enter_kernel_el List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: cfba49ca49f6ac5e401a05148a71896ec2a8e6a7 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=cfba49ca49f6ac5e401a05148a71896ec2a8e6a7 commit cfba49ca49f6ac5e401a05148a71896ec2a8e6a7 Author: Andrew Turner AuthorDate: 2024-02-15 14:48:54 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:22:28 +0000 arm64: Rename drop_to_el1 to enter_kernel_el In the future we may not drop to EL1, e.g. when we support FEAT_VHE where the kernel runs in EL2. Reviewed by: emaste, imp Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D43976 (cherry picked from commit 801160f4c0a3afbd136a1a6402c9ca233dfdc1eb) --- sys/arm64/arm64/locore.S | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/sys/arm64/arm64/locore.S b/sys/arm64/arm64/locore.S index e97b393b90b4..9f3739c85534 100644 --- a/sys/arm64/arm64/locore.S +++ b/sys/arm64/arm64/locore.S @@ -62,8 +62,8 @@ */ ENTRY(_start) - /* Drop to EL1 */ - bl drop_to_el1 + /* Enter the kernel exception level */ + bl enter_kernel_el /* * Disable the MMU. We may have entered the kernel with it on and @@ -201,8 +201,8 @@ ENTRY(mpentry) /* Disable interrupts */ msr daifset, #DAIF_INTR - /* Drop to EL1 */ - bl drop_to_el1 + /* Enter the kernel exception level */ + bl enter_kernel_el /* Set the context id */ msr contextidr_el1, xzr @@ -265,7 +265,7 @@ END(mpentry) * If we are started in EL2, configure the required hypervisor * registers and drop to EL1. */ -LENTRY(drop_to_el1) +LENTRY(enter_kernel_el) mrs x23, CurrentEL lsr x23, x23, #2 cmp x23, #0x2 @@ -358,7 +358,7 @@ LENTRY(drop_to_el1) .align 3 .Lsctlr_res1: .quad SCTLR_RES1 -LEND(drop_to_el1) +LEND(enter_kernel_el) /* * Get the physical address the kernel was loaded at. From nobody Mon Jul 15 12:38:00 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vD6G26z5QrR8; Mon, 15 Jul 2024 12:38:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vD3lk2z4Gqh; Mon, 15 Jul 2024 12:38:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047080; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=T7zonJpnfjsS5X66aRuuMys4QIcrZqmPsIdPnJhdsAw=; b=PxqvOWOEvfMI6DFZ8CCzGpnk7h/eYBxpx/sfiOYaOnovr3o5c5iw3fOB3TVdrewl0uS9IS 0H4VKQckqyXdCCM3SBRfwXH0hB1C+QUCnTGynmZo1tQuPD+Q8PVK9QHRXL7XoJxWcxP0U9 kUzw8olMyQhi4X6Si4kTwCM3Wy+DmifnzGqcf0z9a2L1gGF1hf6/BfNpEvwom4pH7R3ohT Vkdo2c5JoZ/8+3CM8y1RfQKOrVT+jSIBU3USLzyXJXvztEUAEtsfjntj9zj6uY+aGAVUHD 7y05bGnsEXwXGc02KAsZhWTAmz3JI6GMlWO9u5l6QVjKj/eAjWPLXOZGn0pazQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047080; a=rsa-sha256; cv=none; b=FoZUhKov0V6ucqwXZUQhgCBPxsDU89LNACYnuECmiIpRb39Q4KcXVXdhGTTLwfhISVf/IV oQIG5/q64ZsMCkJcINEbyGsw237hWst3+On1X79vQ67U0im5pHa59VomzkG5KAhudts3/n KIGVLmXHg1QDM8bW/vesYgbEI2gnGv6lxbA3q5knYHGEuUEBgyj0LIewQKcGS69YsOEE1x S/c/oNTh8QOdE47U8ear/wC+XOgCoh6m9jB2XEBb/HmomJcwMi2FJxt8t3c9Jka5WI8RUw 7VjvDJ61FZaZZMKOK8yZN3mvS0ds6P8m7rx4SjQ+1cd/anstPXJhJvkotfWSZg== 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=1721047080; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=T7zonJpnfjsS5X66aRuuMys4QIcrZqmPsIdPnJhdsAw=; b=HzQkXqfSyzu8r9AnMv7eLPhG1BuRHAuAc0Zr1wqFyFNKUeN2ZJBmW3+Ne2lMDfLNdaDGD7 Nul4UBama8MyNsFGOfhjigiNiHiQuolpFyhIqwvjcSulVYGRNpoSw8WZygOXi+00qWgpzw MpquCirwv+kRPoGaTQL1e3oKrvjCEzgs/um56yC+csqrcdCFCw8Ghcx9smEKPJpy//Er/B n7nZHdCq26NUfn2nfC3Bdd1lBHrSYyG4Q69kz4TRpSQewANnCCvq5EY7N4eIRDfAwqzBnG TVwQ6TkUpCWc9BmcP6OJKrKO2HgU/VQXhafrFfq28YWe0vGjyzWl/rFd932KBw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vD23j8zscd; Mon, 15 Jul 2024 12:38:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCc0mf059138; Mon, 15 Jul 2024 12:38:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCc01J059135; Mon, 15 Jul 2024 12:38:00 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:00 GMT Message-Id: <202407151238.46FCc01J059135@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 144403f18ead - stable/13 - arm64: Add more spsr_el1 register values List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 144403f18ead786bf745635dd338e1a2953f80ba Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=144403f18ead786bf745635dd338e1a2953f80ba commit 144403f18ead786bf745635dd338e1a2953f80ba Author: Andrew Turner AuthorDate: 2024-02-21 15:58:20 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:28 +0000 arm64: Add more spsr_el1 register values Sponsored by: Arm Ltd (cherry picked from commit 64963dd2f0a2a47e94fb3f7c56198c475b9821a3) --- sys/arm64/include/armreg.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index 3feb048b2bc8..674d8fc6b68f 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -2071,8 +2071,15 @@ #define PSR_DAIF (PSR_D | PSR_A | PSR_I | PSR_F) /* The default DAIF mask. These bits are valid in spsr_el1 and daif */ #define PSR_DAIF_DEFAULT (PSR_F) +#define PSR_BTYPE 0x00000c00UL +#define PSR_SSBS 0x00001000UL +#define PSR_ALLINT 0x00002000UL #define PSR_IL 0x00100000UL #define PSR_SS 0x00200000UL +#define PSR_PAN 0x00400000UL +#define PSR_UAO 0x00800000UL +#define PSR_DIT 0x01000000UL +#define PSR_TCO 0x02000000UL #define PSR_V 0x10000000UL #define PSR_C 0x20000000UL #define PSR_Z 0x40000000UL From nobody Mon Jul 15 12:38:01 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vG0Nwvz5QrJr; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vF3kJXz4Gwt; Mon, 15 Jul 2024 12:38:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047081; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=n3qOs1Ze677vETHo7tmAQFogbhYvrtxg90cUSQ9ZyPo=; b=OxU/x2fttZ92N57XbAV3yhaLqufVDjBCN2y4Ls8rgn8I8J+QF9OX53Lwwr/GvSpK0LA+sR z1ZzpBj/gy0xgW1Wmmy0x4AV7yR9xXI1Cqt5E6eN69yjPvg5MI3DP5DZRt92AveRj6tsh3 Mt0Vtc13HmVmRVbG73wJT0J2sjgOMRC6iyu2IJaO4EJ8/3v+jVmAfMNBX8FLokOcazvNzi OKWiktmXvTD4RPSIJrSGzaSfLHmQU6dfY5b6NQIPQhG9I5zw7Gqq8phxkl+Pxs5zmtHia7 +jRL5ovl73d/IMikjipUffuypUyVifiHyKPXfPMEiAqpPnHv7hWhiyVuYyz3Vw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047081; a=rsa-sha256; cv=none; b=dOGVIJHpuSxUhBHMmcF2NlOyXM5JCjReJOiptbYHOBef+GpJsEKht90qTUW0nqBq49UA20 oyKg9pyyk8aS6zqoV8zEq16rYpf973vWxXk0ylT1KNZL082/LMWXpQOZUpmNp5I0Mj0XVP Hu9kblkOTL2RUkspVE5bm8Cop6eAWQ5x2SYMFgdJLcs//ttQr+EjtNtsfC7qfTXxeT02D7 NI4zJJOYPXAGQGn+xswiYXdNI6VkQln9a7QtmVUuWMzHJrwUF4TobOUM2sR78RgCcG53EH DpQWPfOpDsBfdGsZTLHsPKLDKHfQ/E8d0wBZMwBlFMhBMl76NYtHmnkEvCUTUQ== 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=1721047081; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=n3qOs1Ze677vETHo7tmAQFogbhYvrtxg90cUSQ9ZyPo=; b=Bb1OVVoCKpOC9vpxAGcSBqfuoWrmhqssuNpsQgFt9Fb/bTvViR8D8PlagiaQNJEtlCYeta 29OCAQWBbqo/IL8DSl6GDS6EFXVQfVy61pp3VIycpN41OiLKFRTO4NKkjrGY8QWekvjA+y sW1S7jM7A7v/bItDHaay/hIBVWmXK1TyYk2mmv4bAieCEpNG5zk/TohFDFK3cNmnFVDJOX Ot9h3fywOTlyGzXn9T3k8OH0X30UbkjnPUfGTZHIatyFWZplR4VDGNShoibvMpew3V52ZO 6E3+b5t3pYJAcmQJxC77INBeeliwW7OcXmXCE4s+ZuevvpHS4goxPWrSGqk7AQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vF33Jrzsrn; Mon, 15 Jul 2024 12:38:01 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCc1Ot059237; Mon, 15 Jul 2024 12:38:01 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCc1KM059234; Mon, 15 Jul 2024 12:38:01 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:01 GMT Message-Id: <202407151238.46FCc1KM059234@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 1eb9c65b124b - stable/13 - arm64: Add ISS_MSR_REG for ESR_ELx.ISS values List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 1eb9c65b124b12cf9d290716d481a7c155ad7a69 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=1eb9c65b124b12cf9d290716d481a7c155ad7a69 commit 1eb9c65b124b12cf9d290716d481a7c155ad7a69 Author: Andrew Turner AuthorDate: 2024-02-21 18:10:19 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:28 +0000 arm64: Add ISS_MSR_REG for ESR_ELx.ISS values Add a macro to get the ESR_ELx ISS value when we trap accessing a special register. (cherry picked from commit 09ac9cf8971a0709bb8d5a3a703cd3dbff882b6f) --- sys/arm64/include/armreg.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index 674d8fc6b68f..ffe19a5cc0ef 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -368,6 +368,12 @@ #define ISS_MSR_REG_MASK \ (ISS_MSR_OP0_MASK | ISS_MSR_OP2_MASK | ISS_MSR_OP1_MASK | \ ISS_MSR_CRn_MASK | ISS_MSR_CRm_MASK) +#define ISS_MSR_REG(reg) \ + (((reg ## _op0) << ISS_MSR_OP0_SHIFT) | \ + ((reg ## _op1) << ISS_MSR_OP1_SHIFT) | \ + ((reg ## _CRn) << ISS_MSR_CRn_SHIFT) | \ + ((reg ## _CRm) << ISS_MSR_CRm_SHIFT) | \ + ((reg ## _op2) << ISS_MSR_OP2_SHIFT)) #define ISS_DATA_ISV_SHIFT 24 #define ISS_DATA_ISV (0x01 << ISS_DATA_ISV_SHIFT) From nobody Mon Jul 15 12:38:01 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vF47J2z5QrJm; Mon, 15 Jul 2024 12:38:01 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vF2TCvz4GjH; Mon, 15 Jul 2024 12:38:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047081; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Hh4Kcs67m57d5Fxg56B4B+hREPK0bVr0HqffBuXDRts=; b=Z0/L3E/nFrJQYuMaFq1soaYDsLuYFD/8b7s1kyYUooG0H/Ax5EHFnPT+YPh8i/qro5GDlf 2l7WHfELoohgU/RQZivZ1LLRftAP9Vl+SnY5yP+0qzC+3eMSckSAQqliodGXGlpO7YbM1y 75nCKf6IkT1xu7KOTndorAYtpLVFZSYZsFuMdNN77VoNzKIOluEdpNJReyGnX1oIi/+lCx xntw5Q7SozNErlXxrZRBmBqOaWjVW8M/zm2ZFPheUfftzrjU7SPQcrVogA8fY0pJlMkJAo o4QmK17je5Nmi232SHWAs03PFJA7Q3Vo3PIU9uBfsjMq3foW++z9M/d4tlQ0eg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047081; a=rsa-sha256; cv=none; b=GyZVSpidhDV1DuEUjf8srFS0082YEb/pv+bLQTLO46vFDk4dBuDXtthtR2/lUj3jh5UCHb 39X2wX2MGyI7Uk49ywNuRjkrNGoFktsgzx7LulwnA/Isb/c87SEO/GBJjQ0CveJoV33ohm i2IX9p+s86ilPaSG4+hIkcZ+Ke6PI89kM6nCiiemhhI3HgOZM1gmyhv96XlZ8FhNJxWk/B Q274R/ApTsoGCHPH+inMP+9A1Idrn+VzcwlNEreWFBrj/lNoSWkSsNe9a3A7rbd8VDj2bm 27HqoS2G4Q3Xc0f7Qh9fVAJb1mVRRaX2skb67jmYXlGr4lxVPYJtEp7KfiW++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=1721047081; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Hh4Kcs67m57d5Fxg56B4B+hREPK0bVr0HqffBuXDRts=; b=EcTJvUHvyloMrX8kGfbM39c/pf32A+0sglNXt9n35HWS6FhcmR4/VjPF4IugSvULWIjr/0 3WKt/9CpjmEPw45Lu9Fi6CxaXJ9ZQjHbYcCc+xe6lFLbJXPfWbb8V32q7YlAxvVW3Sm3VF 8W9+9CijgAH6fvFF/mtq6ErQogxwIE2tlASCbWhw+63HouIHmIo0GRkIkbPu2sX9/3sTL5 RntRhHzGU2KsX1/ypk/Tv5LSr+C3ZPaJh3lj+4Xils5LWyimQQUVc9+z9S4JVhl5tqUrDb s2D1LK0rsjI36zm6AGqLQ90jqUH+SvO8JMljum8hjDQxFIWYWkvwGSkGnltx2g== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vF0nW0zscf; Mon, 15 Jul 2024 12:38:01 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCc1A6059192; Mon, 15 Jul 2024 12:38:01 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCc1xc059189; Mon, 15 Jul 2024 12:38:01 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:01 GMT Message-Id: <202407151238.46FCc1xc059189@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 1ac1e83f189f - stable/14 - arm64: Return all registers to gdb when able List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 1ac1e83f189fae2e6bd346ae1abd877ea584192e Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=1ac1e83f189fae2e6bd346ae1abd877ea584192e commit 1ac1e83f189fae2e6bd346ae1abd877ea584192e Author: Andrew Turner AuthorDate: 2024-03-14 17:31:39 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:22:50 +0000 arm64: Return all registers to gdb when able When the kdb thread is the current thread we read the registers from the trap frame. As this contains all general purpose registers we can use it to read these in the gdb stub. This allows us to include the non-callee saved registers, e.g. function arguments. Reviewed by: imp Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D44360 (cherry picked from commit 0a5f7918fc0e274a904b8fdd7c167bea7cdaf0f4) --- sys/arm64/arm64/gdb_machdep.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sys/arm64/arm64/gdb_machdep.c b/sys/arm64/arm64/gdb_machdep.c index f93d7f83bd9d..dcfc91b33eb7 100644 --- a/sys/arm64/arm64/gdb_machdep.c +++ b/sys/arm64/arm64/gdb_machdep.c @@ -55,6 +55,10 @@ gdb_cpu_getreg(int regnum, size_t *regsz) case GDB_REG_SP: return (&kdb_frame->tf_sp); case GDB_REG_PC: return (&kdb_frame->tf_elr); case GDB_REG_CSPR: return (&kdb_frame->tf_spsr); + default: + if (regnum >= GDB_REG_X0 && regnum <= GDB_REG_X29) + return (&kdb_frame->tf_x[regnum - GDB_REG_X0]); + break; } } switch (regnum) { From nobody Mon Jul 15 12:38:02 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vH1FM1z5QrLw; Mon, 15 Jul 2024 12:38:03 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vG4cr7z4Gly; Mon, 15 Jul 2024 12:38:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047082; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=k6HsXM4mRXg+h9zwkVLztV7Duk9IknU4fWs96OiuUag=; b=Xgfr0h413YHLFD69V1uxydMwjYg4+jt0CUjtoP2hscW/GKSRoielld5Lh4+e14s9D0IYtX FGL3OVoJuubKN6DV7ruHossTQ+kfh+puakdKO2UnW2RtNCY4EmnThMdNRzpnnWYp2y7FTs EKkLh5yjphcUHikBdDGxsdznukeVRXVXgNEDhSfqnQ+6VooK7P/yptfn1BG/mfdfsN7rJi /DkLNQqCfRvZQ/2nO+2wU/zMCg9AbcXEAHe7tKe0nstTf2jnkGJgU67h2SGAG5PMsRW6Aa avqUzuGG1UmZQJsaKo632q1S9e/Npqh8aUlEzrIBCYq3DWXnpxMPy+EsMG2Vgg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047082; a=rsa-sha256; cv=none; b=btGWZBeEWX3q2pBhj3KkigYZ/RS7d8FrsaGSyrsfdLY9PPQK5b3NNPCQRG0mCINsuogBpf eRsc92WIra+pEiVaD5BARGP62vDsCA69wfeafWCSMHGVbohFDDCrY59AQ6IC/3cbfG/j5e bqt7iGdq9jtGpfc35tfiitMeOuFleNSKOqETpuuNnQJaLsLWc/CUiaw4LQAGOH4vGOAZgw 9Hb7+h/VhIWEOHjOGJyTpAm37BQ63gMpWtwKYSSFcB94KG0iLb9rooHA6lKrpHtYYT48XD R3IqPJbbyOH+qsBC54r7B5LMEDbAFSWqGsefVMUiyAExf/+C6fCTXBblxQ9mWg== 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=1721047082; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=k6HsXM4mRXg+h9zwkVLztV7Duk9IknU4fWs96OiuUag=; b=tX6imR6kWV3NV97G+Tff2Aif6lRDCQaUj21r7Uf2rPoz5J1qBl6AcHdblS8pvUML1xeSCt Mwy/F/QmTitMjbxCiJ203Lqsql+nCjVa7hPnlk/wsWipZy/UZfezoB1DfnpQ1GIDJ3xJdx of6mbOEOIUXjYH0QomuMbVJBRtcQPQHpDo75LrcmKJtCm/R6A06Sl9Qu7XqNdyQzC1iUpA //hJgqVbxYKLMhV5QTT7AjEIDjR5Mwe9e3qN8Bju3J3INnZfi5SFhpYHaZmP2WAJkef1fa ZxSF097+e11hI+9G52vsGd1yO/YRNrLcruwCvih+osocRxr9e2uZO1R70mHMNA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vG42Zjzt3C; Mon, 15 Jul 2024 12:38:02 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCc2nW059327; Mon, 15 Jul 2024 12:38:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCc2Vx059324; Mon, 15 Jul 2024 12:38:02 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:02 GMT Message-Id: <202407151238.46FCc2Vx059324@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 2aa49fd3f019 - stable/13 - arm64: Add the TCR_EL2.PS mask List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 2aa49fd3f0193cc0dcf8c7505ebe63afaf95301d Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=2aa49fd3f0193cc0dcf8c7505ebe63afaf95301d commit 2aa49fd3f0193cc0dcf8c7505ebe63afaf95301d Author: Andrew Turner AuthorDate: 2024-02-21 18:16:43 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:28 +0000 arm64: Add the TCR_EL2.PS mask (cherry picked from commit 9c52f98c9f1abfe6577335522b6007659f759adc) --- sys/arm64/include/hypervisor.h | 1 + 1 file changed, 1 insertion(+) diff --git a/sys/arm64/include/hypervisor.h b/sys/arm64/include/hypervisor.h index 245b8a8b8b5a..f3c871191688 100644 --- a/sys/arm64/include/hypervisor.h +++ b/sys/arm64/include/hypervisor.h @@ -165,6 +165,7 @@ #define TCR_EL2_TG0_64K (0x1UL << TCR_EL2_TG0_SHIFT) #define TCR_EL2_TG0_16K (0x2UL << TCR_EL2_TG0_SHIFT) #define TCR_EL2_PS_SHIFT 16 +#define TCR_EL2_PS_MASK (0xfUL << TCR_EL2_PS_SHIFT) #define TCR_EL2_PS_32BITS (0UL << TCR_EL2_PS_SHIFT) #define TCR_EL2_PS_36BITS (1UL << TCR_EL2_PS_SHIFT) #define TCR_EL2_PS_40BITS (2UL << TCR_EL2_PS_SHIFT) From nobody Mon Jul 15 12:38:02 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vG471sz5QrJs; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vG27mRz4GpN; Mon, 15 Jul 2024 12:38:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047082; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=OYK+ss12/1ZMWopZCTBAX/M3im9G/f+pTBuZexPmTTw=; b=EIE4pf+rvd61taKcOIyS8p2JZfQ0V4qUN9cM/iNBdyestD8up9WpMB2iRRj3oZdN192ojl f4VBqP0fTR4ar+83E7aRBvLeyh4tk0vf+wXI/PyGtJo6PYJtw28ID0A1bOfzwEuCG/y0dz 0otws/cLi1ZXtlVGUCR0fQRvOvZJyNhgjPlUjYicQde6c/Id5GN0735mv6oalnEmFtRSd/ 6r81oaIGn4ATEWYpBWm/vgCZljd/fr+kvX6bHPmS+XmAiAhe52BMb9I+Ymg/lNoqg5J8XS zhNDDDxRgZBcqadrScBxis7zS8mPIviWt6K6A5itjiZ5GmcrFbmlgBNXP6r2mg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047082; a=rsa-sha256; cv=none; b=PSZfrHjsle48vW00F0li8XZMuIprRXt4DqZ6rVaKms+RV79XDYz6ZnzSSxs2XlANBMauUA FdU/ZmEyFECddb4efp0dyG5AHdR93Dg9rVy0RVkJXP5Gnq60NJOJYj3WA3B2k6NAeqD+YS 2JNyccdtjmkXZHJ8B2MqSlctSBE8ryaWEhvVZ/xHNAVgh+ZCGGLHg4mikN7q6CaQHcimfT x6/5KzXAVBjx8TsuzdAU4S818E1EQXZDW9RHD71KfA5F2ahM9agPLDRvp5xtzlAwF2Qokt jOjirxqLmCIdzCyzDulErGxhG5bjmrpBkZX22V3AKNpgdoBgqIpHPrZuVs3iKQ== 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=1721047082; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=OYK+ss12/1ZMWopZCTBAX/M3im9G/f+pTBuZexPmTTw=; b=kxy1ZJq4SczhszgvflcSBsH+8Vvf+mBJArsoCZclvaMytxG6gorHONdPghsjc9+uIMIPna jdsaasFPeREBWOD91nWwaSqEt1L+bbcm5xCnitWBoiV0rW1XV5MT1p0fHZPsArU2hD+/TO 7JxuIdsBtWjm+bnnRkJccldIWjF0TgSOKa0pJDIyz6c3xMgxndhd2JY0hgOUv6+BxcXoK9 3o3z/sCb7gV3IZj1atqHuhAIh6mXOtjL9PI8uGuONybGAiDXVAiAObUkYXD6B9IJOHCvS9 R/NMti0iTTrkF5xf+FNIeJoLgBPw2rZwJSMA3FJVgfu/J8cToV1hbMtaXwgUPQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vG1mSmzsp7; Mon, 15 Jul 2024 12:38:02 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCc2hs059285; Mon, 15 Jul 2024 12:38:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCc2eF059282; Mon, 15 Jul 2024 12:38:02 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:02 GMT Message-Id: <202407151238.46FCc2eF059282@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 64b0acf87c97 - stable/14 - arm64: Mask non-debug exceptions when single stepping List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 64b0acf87c97d02929f99a14e9d47a4eba2958b4 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=64b0acf87c97d02929f99a14e9d47a4eba2958b4 commit 64b0acf87c97d02929f99a14e9d47a4eba2958b4 Author: Andrew Turner AuthorDate: 2024-03-14 14:02:56 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:23:21 +0000 arm64: Mask non-debug exceptions when single stepping When an exception is pending when single stepping we may execute the handler for that exception rather than the single step handler. This could cause the scheduler to fire to run a new thread. This will mean we single step to a new thread causing unexpected results. Handle this by masking non-debug exceptions. This will cause issues when stepping over instructions that access the DAIF values so future work is needed to handle these cases, but for most code this now works as expected. Reviewed by: jhb Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D44350 (cherry picked from commit ed3c6cd76de8560c46607abe506a03568e9acab2) --- sys/arm64/arm64/debug_monitor.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/sys/arm64/arm64/debug_monitor.c b/sys/arm64/arm64/debug_monitor.c index 271f6fc47ea4..380915d5163a 100644 --- a/sys/arm64/arm64/debug_monitor.c +++ b/sys/arm64/arm64/debug_monitor.c @@ -194,6 +194,15 @@ kdb_cpu_set_singlestep(void) ("%s: debug exceptions are not masked", __func__)); kdb_frame->tf_spsr |= PSR_SS; + + /* + * TODO: Handle single stepping over instructions that access + * the DAIF values. On a read the value will be incorrect. + */ + kernel_monitor.dbg_flags &= ~PSR_DAIF; + kernel_monitor.dbg_flags |= kdb_frame->tf_spsr & PSR_DAIF; + kdb_frame->tf_spsr |= (PSR_A | PSR_I | PSR_F); + WRITE_SPECIALREG(mdscr_el1, READ_SPECIALREG(mdscr_el1) | MDSCR_SS | MDSCR_KDE); @@ -215,6 +224,9 @@ kdb_cpu_clear_singlestep(void) KASSERT((READ_SPECIALREG(daif) & PSR_D) == PSR_D, ("%s: debug exceptions are not masked", __func__)); + kdb_frame->tf_spsr &= ~PSR_DAIF; + kdb_frame->tf_spsr |= kernel_monitor.dbg_flags & PSR_DAIF; + WRITE_SPECIALREG(mdscr_el1, READ_SPECIALREG(mdscr_el1) & ~(MDSCR_SS | MDSCR_KDE)); From nobody Mon Jul 15 12:38:03 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vH4ds9z5QrPN; Mon, 15 Jul 2024 12:38:03 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vH30b6z4H0r; Mon, 15 Jul 2024 12:38:03 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047083; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=vIRPQ8BfX0AijCD9mDE/fQrTXkZwG/zsXVSSxJ8ENzg=; b=v5lMN5e8w+lDx7gtstUdXKUXOdeWZ3nS1o9t+h5jjrLVdHgKqeHXmTKBGJGs+hx5vOW/jM 3MNOZ44rQo+DByjDGszY0XKQswyic+fwsoB0lYxauCLxQQA0WvQg3PJQU1MHtONWQ8h2ql kPoIaIlDIG1mJsx7ekzpfuKHZY+qVU8GQHlL0DBGYnxtJdUGzG9685cINsHdeZKXMJVAIN vNnrHT84mfcJV6VlzxhAIeccIIusALvdoV1iSu0QS/NJqmrJiOgFEgHOj4L/nVCF8HH5wv nObtgRN6vtY87NjbBRlOctzFTQHcTc5WgS+k/zJ/B2HRNF8tAZc6pgny4NwhZg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047083; a=rsa-sha256; cv=none; b=O9qzzeW+3ZTI2eczp6F8YLCzfHCchJxAovaUVR5e3YPl2clM5jf4Dz/a+S0/kiXMGP9LGC Ph4WxUI5QclZu3TgvMKloQKDovH9ebUnjPsJlj8evSaZ/DU6pCBk3cL8JtUY4LIN4Bgfml jJHEYnCmpRO0uhKtJkMvp6WXVDiYLl/rfppegjzoCCTDzNd8UCbhq51DZwmPz+Eg7A+WTb dDKOvYtPJ10iEFU8iPTI9odgppc0Ue1bpL/KhzhxI5FThc4Eh9hvSJtBGa1395RXP991Oo 0hOzIkkGG/PqzFfOHKEtliB3Nxx6UKbInyo33O10QC6ZFDlzTCUc9GVxi/x4QQ== 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=1721047083; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=vIRPQ8BfX0AijCD9mDE/fQrTXkZwG/zsXVSSxJ8ENzg=; b=MrZgvj6L0R4OlWN+G2KzlN0+Zn4uMhEpA2AzRWAgR+cRZjj27rIQ69O7jzOLhJZJwJR0vT lv5jQf8xtxECYqJm6W8UpeU+VZA4aFhfhHLVTZH8GqnK3AS7FikUMPiErI80JcjZ8WSrDf 9B+RppKo1+6fhjuf1Ru/HkjkHix5QqE2lfurJWl3lSZ5esOMq6ndFym+/1eQqIQecaqZme T1et7NZWK2+em9t3pSkM+16WpYD73eDh6ksk4d7IEKGo1pzgRd1o4hEEFesQbZgvqLAGOQ uOZaRX/fQAzHwK/ePgHud0eqFu2Pt8OPlhcuYlnpccxoH2sbdopeLbeykbBvnA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vH2d7FzsLx; Mon, 15 Jul 2024 12:38:03 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCc3L5059381; Mon, 15 Jul 2024 12:38:03 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCc3MF059378; Mon, 15 Jul 2024 12:38:03 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:03 GMT Message-Id: <202407151238.46FCc3MF059378@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: c3d86d27c3aa - stable/14 - arm64: Always set the debug control and value regs List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: c3d86d27c3aa5308bc1d9d1a8a95da7efaf34773 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=c3d86d27c3aa5308bc1d9d1a8a95da7efaf34773 commit c3d86d27c3aa5308bc1d9d1a8a95da7efaf34773 Author: Andrew Turner AuthorDate: 2024-03-12 16:34:41 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:23:38 +0000 arm64: Always set the debug control and value regs When listing watchpoints we read the raw registers. To ensure we print an accurate list always set the watchpoint and breakpoint registers. Sponsored by: Arm Ltd Reviewed by: jhb Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D44351 (cherry picked from commit 2e2c983d5234cb5457548fc75608d93b2309b254) --- sys/arm64/arm64/debug_monitor.c | 27 ++++++++++++++------------- 1 file changed, 14 insertions(+), 13 deletions(-) diff --git a/sys/arm64/arm64/debug_monitor.c b/sys/arm64/arm64/debug_monitor.c index 380915d5163a..f3e4b504f15e 100644 --- a/sys/arm64/arm64/debug_monitor.c +++ b/sys/arm64/arm64/debug_monitor.c @@ -496,23 +496,24 @@ dbg_register_sync(struct debug_monitor_state *monitor) if (monitor == NULL) monitor = &kernel_monitor; + for (i = 0; i < dbg_breakpoint_num; i++) { + dbg_wb_write_reg(DBG_REG_BASE_BCR, i, + monitor->dbg_bcr[i]); + dbg_wb_write_reg(DBG_REG_BASE_BVR, i, + monitor->dbg_bvr[i]); + } + + for (i = 0; i < dbg_watchpoint_num; i++) { + dbg_wb_write_reg(DBG_REG_BASE_WCR, i, + monitor->dbg_wcr[i]); + dbg_wb_write_reg(DBG_REG_BASE_WVR, i, + monitor->dbg_wvr[i]); + } + mdscr = READ_SPECIALREG(mdscr_el1); if ((monitor->dbg_flags & DBGMON_ENABLED) == 0) { mdscr &= ~(MDSCR_MDE | MDSCR_KDE); } else { - for (i = 0; i < dbg_breakpoint_num; i++) { - dbg_wb_write_reg(DBG_REG_BASE_BCR, i, - monitor->dbg_bcr[i]); - dbg_wb_write_reg(DBG_REG_BASE_BVR, i, - monitor->dbg_bvr[i]); - } - - for (i = 0; i < dbg_watchpoint_num; i++) { - dbg_wb_write_reg(DBG_REG_BASE_WCR, i, - monitor->dbg_wcr[i]); - dbg_wb_write_reg(DBG_REG_BASE_WVR, i, - monitor->dbg_wvr[i]); - } mdscr |= MDSCR_MDE; if ((monitor->dbg_flags & DBGMON_KERNEL) == DBGMON_KERNEL) mdscr |= MDSCR_KDE; From nobody Mon Jul 15 12:38:03 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vH6sq7z5QrZ9; Mon, 15 Jul 2024 12:38:03 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vH5QDyz4H0x; Mon, 15 Jul 2024 12:38:03 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047083; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=/B70dsZUM6Rzcg3ZQsL7j5P6/zyvv8pDb3ZWvCnzVd4=; b=vOFiludNG4QmBekUxnmGnrpyGBI+wi7yqcfRDTAp4P3y6GWd8wQiMzo+I4LrqSnoa7b7Qb PYW1aZRkO/itHTyK2v3o7SfrgTgLAkIcZLW9B5YhEY2kgAXYxa/aayW41kfX0fBQz3VokI u0EWQ7CHx7vENgtmUulnzNTERcPLAZBEKuIE8PcwWvdw8K3aSXMdcyVwryLq/nyvYrNf0x sEY7h0IVAPFXaGsAj93NunbEX9DIV8EOziu0HW2y3LfSm7C7BoRB9xzuCWGGP2QWovv049 SzdON+1ETT5WXd3YA3QmXQJ83RUm4Us3DWjWFrUun7Nk4bCAF7MSpDCO5RJmMQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047083; a=rsa-sha256; cv=none; b=ULfJ5Sp3bkAIdPGtpOOgq1JNRg5lIoUQY3e6LwgSAcu8GfATbaU0zp/zg8gYrMzjbxkYts oU/roni+wT6XrTKqEPgYCx6Kn8zn8Vb8AXnzdOw0uZph78CjTwTu1o39KdGdkblmDBdAf6 iyV6T2lWsojpkHaaEZyDxUyuqtGdeekPdOnIChC3tzj49d9WrhSj1kxiCiksGyfijHWYD5 c+etfF7csS5/HnatOO3hSFlsZ9Mom4IA8DxF3oSFkFlPW8bs220qBsr2wIFU0kMl3NK2PF 9yhKzWFuoPEU5kgztGQK3STws9ddLGnvyGmynrvZvhEOVhSKklgTw1W0ocdENQ== 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=1721047083; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=/B70dsZUM6Rzcg3ZQsL7j5P6/zyvv8pDb3ZWvCnzVd4=; b=Or1/mKs3WdU3FicN0cCR+HHMqGXsGIYFhFU+5jAMI81kqUViV6fj37BDMx7z2IpXT1GdT/ txVfo1cm6gKozvEavhKa+gqqXRMQERHXf7ijbLI8sGGT1+ZgKsgyVgXTWo5sAzv8ACuBkM +vCG6THxpuHfoo3T9LeqS/kzFzkKxYe0DdGaKXTJnI8Qqt0fqnjud+tgIprtqsKcqY36Ck S1blx9vexUhooNDhHh41QhCQsxt3UttyvTGZVb6YQ+x6qwvloZlfNUNuP4y7stJeR2IsNf 3XOYQtNKdFxeBDFZuzK9cyY/0xaDn05KieYDpES+rtTsGwIi6N4Dizk5Q/fkwg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vH52sXzsLy; Mon, 15 Jul 2024 12:38:03 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCc3np059438; Mon, 15 Jul 2024 12:38:03 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCc3Nx059435; Mon, 15 Jul 2024 12:38:03 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:03 GMT Message-Id: <202407151238.46FCc3Nx059435@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 754e1308ce1d - stable/13 - arm64: Add a macro to find a VM fault address List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 754e1308ce1de66f3097cb7f38e81c62faa87804 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=754e1308ce1de66f3097cb7f38e81c62faa87804 commit 754e1308ce1de66f3097cb7f38e81c62faa87804 Author: Andrew Turner AuthorDate: 2024-02-21 18:17:47 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:28 +0000 arm64: Add a macro to find a VM fault address Add a macro to find which bits from far_el2 are needed to be copied to get the full intermediate physical address (IPA). The hpfar_el2 register only contains a 4k aligned fault address. We need to include the lower bits from far_el2 if we need the full faulting IPA. (cherry picked from commit b3bbec37ba039a46f7166f6fa3571f38da4253e9) --- sys/arm64/include/hypervisor.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sys/arm64/include/hypervisor.h b/sys/arm64/include/hypervisor.h index f3c871191688..ff6aff00e226 100644 --- a/sys/arm64/include/hypervisor.h +++ b/sys/arm64/include/hypervisor.h @@ -122,6 +122,8 @@ /* HPFAR_EL2_FIPA holds the 4k page address */ #define HPFAR_EL2_FIPA_ADDR(x) \ (HPFAR_EL2_FIPA_GET(x) << 12) +/* The bits from FAR_EL2 we need to add to HPFAR_EL2_FIPA_ADDR */ +#define FAR_EL2_HPFAR_PAGE_MASK (0xffful) /* ICC_SRE_EL2 */ #define ICC_SRE_EL2_SRE (1UL << 0) From nobody Mon Jul 15 12:38:04 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vK0TSPz5QrPS; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vJ6RMmz4H3R; Mon, 15 Jul 2024 12:38:04 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047084; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ayDZkwR8To3aw+Pigi6AQaCJrzshLVZXNBVaoF0yM78=; b=q5HZtfHXZd/P/M0c7yS8hi2hSbFoKEckb56zjj6mOmcp67YId7yiiEo8JuiCsmyjk91Chj GSdafJGVW60nvYOf/VYanAWqS64+bjtU5oZcE1Q4QSroGvmzRraavk88/CfqbW4F769okO Ie3tTylf3ir3rNajZgUMtX8/NWjoWvEdy36iD68ywtfDVgUKF8cHvdSRd+1dEGoPdYgfqe esAVb7F/dWwX8IGBXKXzhPhlb8GPvIjuX5vNGGczYGAY6Lp7gXKS2fTBHxzj4aV4HT4AIU tqdwgWP9bF5OM2Y5Sf9+Ho4wcPfYkk8NUreXkBpDAqk2VcfGN3r0cM1W/BFOwg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047084; a=rsa-sha256; cv=none; b=kH5JnjqcQqXpAot5hemLYWye6C8igLF/bh6ZZO2qsfafebna/V3CTfWdMEZI9upW3APynN g0s/POAmaXg/7VG4KqFELLTi659Ks9+V++lQ1RFyDeK2OAo5OBb7rYX1zQmLd4gZj68ihH S5+hcqCWdtqJQWPpfjWzvJsXV55O+liruZDoSpjlkOISz/6brLXI0Og75Omf+biofdynKU uqgu2Izqvoxet4qQmuqOqxFSs9aU8gJi2VEk9BsgdKo6n2u+u0vWu8jvyunqLL1TE9BbgU EHa3PvRLyP3L4QJAeKFF/aBq6gfqGtNQt44lLFRs4Sg9jnPvk49+a/HVo/5zhg== 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=1721047084; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ayDZkwR8To3aw+Pigi6AQaCJrzshLVZXNBVaoF0yM78=; b=YtibWh9kBM2gy3trB5OEuB/SxnGEmcJ5wUDb6pdY6t4CVoZnL3KH0LGQ+4sY5waDC65gws HqLFeaAGE8TBgK88e/27Noyf/TgjduhBRuvUjpTJSA6+5mHtMQ1y8cRT8hEDiQpqA6oTh9 5rYGe1Gg6LNTtfrZW+M4flAifkViHm3lj7G3l6pK56SXHEKaG4/8kYoov1UbXnWscATThX gGRSu1zyMnv9AHhuRRF5t0kQYZeBkm8Ac9b+rUdRcqUp/d/qa6tc4HnO2X068uIf3i/xCb olWxp0n216Cn0GgWv3l72gB6i8/Axo6fdnPc9HHoeoEzToX8e+h8QH2uJ7xMVw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vJ62LHzscg; Mon, 15 Jul 2024 12:38:04 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCc4xY059552; Mon, 15 Jul 2024 12:38:04 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCc47C059549; Mon, 15 Jul 2024 12:38:04 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:04 GMT Message-Id: <202407151238.46FCc47C059549@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: d253217f7198 - stable/13 - arm64: Add TF_LR, it will be used by bhyve asm List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: d253217f719872ee82125b51ee3d64f9413affbb Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=d253217f719872ee82125b51ee3d64f9413affbb commit d253217f719872ee82125b51ee3d64f9413affbb Author: Andrew Turner AuthorDate: 2024-02-21 18:24:04 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:28 +0000 arm64: Add TF_LR, it will be used by bhyve asm (cherry picked from commit 0f4071978e3dae6637d4988212661164115f6be8) --- sys/arm64/arm64/genassym.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sys/arm64/arm64/genassym.c b/sys/arm64/arm64/genassym.c index e423a000eed4..c8cda4c88aea 100644 --- a/sys/arm64/arm64/genassym.c +++ b/sys/arm64/arm64/genassym.c @@ -76,6 +76,7 @@ ASSYM(TD_MD_CANARY, offsetof(struct thread, td_md.md_canary)); ASSYM(TF_SIZE, sizeof(struct trapframe)); ASSYM(TF_SP, offsetof(struct trapframe, tf_sp)); +ASSYM(TF_LR, offsetof(struct trapframe, tf_lr)); ASSYM(TF_ELR, offsetof(struct trapframe, tf_elr)); ASSYM(TF_SPSR, offsetof(struct trapframe, tf_spsr)); ASSYM(TF_X, offsetof(struct trapframe, tf_x)); From nobody Mon Jul 15 12:38:04 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vJ5VT4z5QrX8; Mon, 15 Jul 2024 12:38:04 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vJ3jMXz4Gk1; Mon, 15 Jul 2024 12:38:04 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047084; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=2e1gVUf5v9b9YYAohfuRfbcP0wQViAc03KqFFhzNoWM=; b=xRVbb3Xg3duvI9KMZ5pahJ9XMcrB6sEx4Jj0MBg8ToPMjmAT3RhZdnwEWm4aMfvEclOF2E 6cBaKbyoRuegj5FYpurvaqvqgEZL1IWCROoJLxB5Sr1JzH2B0vCP+j09rqIBSsCXoYr8qk eyLWXJQ7cDeVdTXRjvAVILG074ShikJbNryge3Hx33dq1Fe4nDq91uTb3b9iJdBR4JT6KV SqM90huBsHqaZ+Ma5a0F/sVdvXdQ5/7EejuysQm+P9Gkj6BGAddWWkU8P69NyvT61hCIAT 7uZEe+UDJsAVRl0emZuIu5oUPgUXhd850vMKSF6Ay+VeKUtitBB4U3ba5f+MBA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047084; a=rsa-sha256; cv=none; b=qBdpdbw7f8DQLZRr2cE17MkdqBDtAlWk3RiLCJn23uh0myZbBMysbPg98Q4OOpL0Msx1ZF Ou+RPtGrZWWp97DaRpFd/jXVgG3bxUm8Y4mJ9Ly9mgr5+NWcJmoXKNgWi4Swy1Ady0Iklz ERndrRd8AulbuY394kHiV38LXxJ2UTvHfdtc+SjaQb9BiGgDxYwAyh4Jxo3pwFty/JSnSG i/tE0m4iJd+flzaOw/K9ybFne6YxZEhb74RJhEOdFPKVl5PSECPHRqEa2/RvB+Wlks/ZPB 0Gh+WVfH9j+DJvYjj7e1VGmaKawOhT0xsm3trQfiv5Gx6ric9SkKJfq4EHm9kg== 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=1721047084; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=2e1gVUf5v9b9YYAohfuRfbcP0wQViAc03KqFFhzNoWM=; b=sartAQ3z39g+GfXF9PEsy+yAwLKi9rCfjL6cHulpxXDQ0SiWkvydeRR0jKavKOdkwnMVr4 gpoQWSqD+z2Ct7DZXElPRsgk0BZTW8S9Il/PoWghNV1yMtFs2cgWf706xg6jWoffVCM/r6 rpcHWcKHkmRew/GbKT5Tdy0drQ0v62IvJNYS+lFXRyHyl+wih7kgfEkEH+EWK5OtrBvllU W1IjkDQ4VHS9OHwO2EMd1eBhxKwmZsTjRA/gyYPARL6wMDEat2mcGDZ8qRHjnhLYyU8lQb KIjQIRelb5GF+EcRwhN3oJETS+rZXB00ZY4kl+NVKPRjeakQJ58gLuukTeq7gw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vJ3KQVzsJH; Mon, 15 Jul 2024 12:38:04 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCc4sC059495; Mon, 15 Jul 2024 12:38:04 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCc4lS059492; Mon, 15 Jul 2024 12:38:04 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:04 GMT Message-Id: <202407151238.46FCc4lS059492@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: cf5be947352b - stable/14 - arm64: Use a switch to decide when to enable debug List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: cf5be947352bf5956ee98d4ef81050411bd05b08 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=cf5be947352bf5956ee98d4ef81050411bd05b08 commit cf5be947352bf5956ee98d4ef81050411bd05b08 Author: Andrew Turner AuthorDate: 2024-03-12 16:47:38 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:23:49 +0000 arm64: Use a switch to decide when to enable debug Use a switch statement to decide which exceptions we need to call dbg_enable for. This simplifies adding more esceptions to the list in the future. Reviewed by: jhb Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D44352 (cherry picked from commit d93b3a65f7697630ca1dd2635fc976f3ef36b602) --- sys/arm64/arm64/trap.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/sys/arm64/arm64/trap.c b/sys/arm64/arm64/trap.c index 6534fd2283a1..50f930b66664 100644 --- a/sys/arm64/arm64/trap.c +++ b/sys/arm64/arm64/trap.c @@ -496,9 +496,15 @@ do_el1h_sync(struct thread *td, struct trapframe *frame) * Enable debug exceptions if we aren't already handling one. They will * be masked again in the exception handler's epilogue. */ - if (exception != EXCP_BRK && exception != EXCP_WATCHPT_EL1 && - exception != EXCP_SOFTSTP_EL1) + switch (exception) { + case EXCP_BRK: + case EXCP_WATCHPT_EL1: + case EXCP_SOFTSTP_EL1: + break; + default: dbg_enable(); + break; + } switch (exception) { case EXCP_FP_SIMD: From nobody Mon Jul 15 12:38:05 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vK70Lqz5QrGX; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vK4jLvz4H7D; Mon, 15 Jul 2024 12:38:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047085; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=UCA5+8iMnK5cfrc1pmQvYaVgUzEG/3bsnTWtvdsMEh8=; b=gP2bvx3mTkgPeLIeT0UiGd/FgOzq8rPBWujTqzg1cuvtnglRZxVjKD6LISMb9/VGeinoBj 7gQFuNNwgv0/wj1c/6N8X/pYZ/0bJdjJI0byew87TlCQyZqrGkyzY6AUnvjwssTbMJZ1qs YFxl6Oa9FBRRBbFGoKJB20aqNNKbssyONmtDnEjdFOvCkty9nd4LNCb5+70AsScS+48BEU NDmeoENUKtfxqZHnxd6hqyMzKQ8cLfXm+Xw+6bitnz4kCOb+/D2BR7xfZ5ILd8jhvj5Tzt qN8mYoKP83bZhRFRIcAVfIiMs2DUPf63fn/+fNseVGqhG7XzUcfjGGMANOiSQw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047085; a=rsa-sha256; cv=none; b=IgdZ4vET+Ua4jJOsdIlF7UKBhVz2yM5uY0+62VfJMcvjDV/X99NTQTzsF6Sm7zQL031VmE KmxHhBhWyv2akf1mjhu65tc/lAtEHlMTNYMZWGuTX3h8HTuepA6hDmuLop72TqAKMpeMWG sWi4hwiAAl77Qm5i+yByXv+6/uF1fJ0wxE9AA+RJpCfxb/l5fPLUbRUrIR85NItXka5hj0 tJY99KnzytdITqskppLRoshJJfT/DTeYsprPmvllvcyaJjSvIeGHD17bQ8U1CT7vcC9p25 ChTNgq/snkMbF3PIz9zbeJDj/KlY2/qW+pQZS/16gzDaqqrH9Sc9oryZligyFw== 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=1721047085; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=UCA5+8iMnK5cfrc1pmQvYaVgUzEG/3bsnTWtvdsMEh8=; b=rONoecR2EVz7frDoM4G8lzqT4jHmAnbmqaOtebnOjJCCuzVha8a7QRuXf7nAckw0oLN/OD EQhsKU3/pbDe4GFjTvFtDqLlarfWI1dvTvybDyP+nV9Sq0/UuoFlRoSRENHWCqipf7S1Jz J4EgfTkEVizIquYvwU8PYLLQUFuqri+XK6N3DihCaA42r3LDKtUYpoWiftTKSM1i+UjxoP UTs6B59Fkikf5HJhvrlvtgwEEAxjn0K9aPgw2BPsdqrqJocTwj30/CMNQriIetmBuNNwM/ tllzo2L922DPZHild/nexbBUgBdNpHoR9xvQZTnMsTr4eJmt2gPgUz0jZGkhhQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vK4KzdzsJJ; Mon, 15 Jul 2024 12:38:05 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCc55C059597; Mon, 15 Jul 2024 12:38:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCc5rg059594; Mon, 15 Jul 2024 12:38:05 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:05 GMT Message-Id: <202407151238.46FCc5rg059594@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 27e9c833bb8f - stable/14 - arm64: Add EL1 hardware breakpoint exceptions List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 27e9c833bb8fdb87618649ae8193fe5485ccfdc3 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=27e9c833bb8fdb87618649ae8193fe5485ccfdc3 commit 27e9c833bb8fdb87618649ae8193fe5485ccfdc3 Author: Andrew Turner AuthorDate: 2024-03-12 16:50:04 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:23:58 +0000 arm64: Add EL1 hardware breakpoint exceptions Reviewed by: jhb Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D44353 (cherry picked from commit c802b486ddfd796ea35b770148af9a5b0cd0ee64) --- sys/arm64/arm64/gdb_machdep.c | 1 + sys/arm64/arm64/trap.c | 2 ++ sys/arm64/include/armreg.h | 1 + sys/arm64/include/db_machdep.h | 4 +++- 4 files changed, 7 insertions(+), 1 deletion(-) diff --git a/sys/arm64/arm64/gdb_machdep.c b/sys/arm64/arm64/gdb_machdep.c index dcfc91b33eb7..7b21675ea927 100644 --- a/sys/arm64/arm64/gdb_machdep.c +++ b/sys/arm64/arm64/gdb_machdep.c @@ -110,6 +110,7 @@ gdb_cpu_signal(int type, int code __unused) switch (type) { case EXCP_WATCHPT_EL1: case EXCP_SOFTSTP_EL1: + case EXCP_BRKPT_EL1: case EXCP_BRK: return (SIGTRAP); } diff --git a/sys/arm64/arm64/trap.c b/sys/arm64/arm64/trap.c index 50f930b66664..69c5cd73ade8 100644 --- a/sys/arm64/arm64/trap.c +++ b/sys/arm64/arm64/trap.c @@ -498,6 +498,7 @@ do_el1h_sync(struct thread *td, struct trapframe *frame) */ switch (exception) { case EXCP_BRK: + case EXCP_BRKPT_EL1: case EXCP_WATCHPT_EL1: case EXCP_SOFTSTP_EL1: break; @@ -549,6 +550,7 @@ do_el1h_sync(struct thread *td, struct trapframe *frame) panic("No debugger in kernel."); #endif break; + case EXCP_BRKPT_EL1: case EXCP_WATCHPT_EL1: case EXCP_SOFTSTP_EL1: #ifdef KDB diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index 6f9e109f4b70..b2dfd61c3083 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -439,6 +439,7 @@ #define EXCP_TRAP_FP 0x2c /* Trapped FP exception */ #define EXCP_SERROR 0x2f /* SError interrupt */ #define EXCP_BRKPT_EL0 0x30 /* Hardware breakpoint, from same EL */ +#define EXCP_BRKPT_EL1 0x31 /* Hardware breakpoint, from same EL */ #define EXCP_SOFTSTP_EL0 0x32 /* Software Step, from lower EL */ #define EXCP_SOFTSTP_EL1 0x33 /* Software Step, from same EL */ #define EXCP_WATCHPT_EL0 0x34 /* Watchpoint, from lower EL */ diff --git a/sys/arm64/include/db_machdep.h b/sys/arm64/include/db_machdep.h index f1f638a7882c..45b97443aec5 100644 --- a/sys/arm64/include/db_machdep.h +++ b/sys/arm64/include/db_machdep.h @@ -36,6 +36,7 @@ #include #define T_BREAKPOINT (EXCP_BRK) +#define T_HW_BREAKPOINT (EXCP_BRKPT_EL1) #define T_SINGLESTEP (EXCP_SOFTSTP_EL1) #define T_WATCHPOINT (EXCP_WATCHPT_EL1) @@ -56,7 +57,8 @@ typedef long db_expr_t; #define db_clear_single_step kdb_cpu_clear_singlestep #define db_set_single_step kdb_cpu_set_singlestep -#define IS_BREAKPOINT_TRAP(type, code) (type == T_BREAKPOINT) +#define IS_BREAKPOINT_TRAP(type, code) \ + (type == T_BREAKPOINT || type == T_HW_BREAKPOINT) #define IS_SSTEP_TRAP(type, code) (type == T_SINGLESTEP) #define IS_WATCHPOINT_TRAP(type, code) (type == T_WATCHPOINT) From nobody Mon Jul 15 12:38:05 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vL2Vdnz5QrVC; Mon, 15 Jul 2024 12:38:06 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vL06zSz4H9g; Mon, 15 Jul 2024 12:38:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047086; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=OAxYhEcCwDO+hj9A4MbWg/TWaksJS5tlQhj0+NVo1g8=; b=h4cqGXSILPeRkM8gbEZ6CSSDIes9SOinyPuZ0GN7OPlU4PA5PE5vARFt/e9UsGI/RiqbPM dp+dOO2CXECDJ2Z8DqiJIU3QbLAtGlZXAP8/wVv+9LcGnUvdregU/i2c5u0PFRkb4KaHSu gpYmXEzxpqOdzyDk7d5r11MOJr742xXDGHmMhGKc3OIXrPL2Q9M3MnJEf/yb9jShqSZE9y RYvoVz9iTAzY3ekKRF83EF4M0nwSyK2ns4mG5RVNM7WErfjy+9fbeLlK/k7VYotVyreP5R lDZRTCc6GlIyuVbOg3JsWjTHGcfvFPt7UDgr0Y7EWVDZ4g4uErmWWTbPUdDSVQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047086; a=rsa-sha256; cv=none; b=Xhz38HsV4DMXdiwWbIrruV9vvpGLUWbkWaYu1h1PCg3xb3U2woxfM2d5ftNnwKGqZTSwrQ 3Hqb7xCP50uglHWDjcJAAVSC4/BTn03dW4oWVGOKBumFySzDFUg5rvHcc+dw6r5o5NxlHV 8sXu/zezZAX4ecfh/VBxQpoUm8OAgwUQX0hDVPkA3c6PwXg6OELwaLIN6Qsd3Rg7eJA28q 3IydilKbQ4ULKgurYifb/xlI6douKPWlKW/KOS8zhpkVU9rIHdZ0huszWJr214buURynet VfWy0TvmY+SIQLnxv/ad+YTOQBjD/X5up4VhwHrVr65/HyH1yiNd1RPesyLxnQ== 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=1721047086; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=OAxYhEcCwDO+hj9A4MbWg/TWaksJS5tlQhj0+NVo1g8=; b=CDR+eSkFxawhFAroDFXcYD3w3nmx+tYtr2q8aDvn9jNKazWNZ6H9yUk4aPjQ2UkC3B0xDR z03kfa6xvZJc3M8h1xUy7FQQxULcV4XMfkwwLbF7xKNKsjOcKwmj1ub/fS+vf2NzU5Y3YZ aHfovg1DNZhzvHVK7kxc3SyxtLxW4vQQZgvn1u/ZLLFi5O0+aLg+EzMgH98d6g60r7bbH3 5oPdNHP8BOBMah5pRjSIs8c4JKnAl1VufXq0F7OlWYnYmsRMdVMAvWXoEDy1SamUQP3L6N dNyi38pmVexFpChF6faLJxMDSBYwoTKMWYOo/77AXKSX4S2N5Y1DcNvmEw006w== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vK6k16zsM0; Mon, 15 Jul 2024 12:38:05 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCc5Ee059639; Mon, 15 Jul 2024 12:38:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCc548059636; Mon, 15 Jul 2024 12:38:05 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:05 GMT Message-Id: <202407151238.46FCc548059636@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: cf99898c4e87 - stable/13 - arm64: Rename drop_to_el1 to enter_kernel_el List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: cf99898c4e8703174d6502b5690f5d68a8f37a5f Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=cf99898c4e8703174d6502b5690f5d68a8f37a5f commit cf99898c4e8703174d6502b5690f5d68a8f37a5f Author: Andrew Turner AuthorDate: 2024-02-15 14:48:54 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:28 +0000 arm64: Rename drop_to_el1 to enter_kernel_el In the future we may not drop to EL1, e.g. when we support FEAT_VHE where the kernel runs in EL2. Reviewed by: emaste, imp Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D43976 (cherry picked from commit 801160f4c0a3afbd136a1a6402c9ca233dfdc1eb) --- sys/arm64/arm64/locore.S | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/sys/arm64/arm64/locore.S b/sys/arm64/arm64/locore.S index a93c95b18f44..4bde1df945cb 100644 --- a/sys/arm64/arm64/locore.S +++ b/sys/arm64/arm64/locore.S @@ -49,8 +49,8 @@ */ ENTRY(_start) - /* Drop to EL1 */ - bl drop_to_el1 + /* Enter the kernel exception level */ + bl enter_kernel_el /* * Disable the MMU. We may have entered the kernel with it on and @@ -176,8 +176,8 @@ ENTRY(mpentry) /* Disable interrupts */ msr daifset, #DAIF_INTR - /* Drop to EL1 */ - bl drop_to_el1 + /* Enter the kernel exception level */ + bl enter_kernel_el /* Set the context id */ msr contextidr_el1, xzr @@ -232,7 +232,7 @@ END(mpentry) * If we are started in EL2, configure the required hypervisor * registers and drop to EL1. */ -LENTRY(drop_to_el1) +LENTRY(enter_kernel_el) mrs x23, CurrentEL lsr x23, x23, #2 cmp x23, #0x2 @@ -314,7 +314,7 @@ LENTRY(drop_to_el1) .align 3 .Lsctlr_res1: .quad SCTLR_RES1 -LEND(drop_to_el1) +LEND(enter_kernel_el) /* * Get the delta between the physical address we were loaded to and the From nobody Mon Jul 15 12:38:08 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vN43w7z5QrRR; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vN2D5Jz4H7t; Mon, 15 Jul 2024 12:38:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047088; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=CggST6yvJ6AKqyHXmJeO6VN1HQlHMtXkdl0VU5uHfVo=; b=W2/Eo6iytdj7b16bcDBONSByfEHZnY8T5btD/rvuiJR7Ep2Kw/ebBLspPHANoIJgD9pMS2 +sEXKI5N7kuny8M3dHDa+Z8pdHhM33BqXqpQZ6dxmt2TaTg07bdi/5Kz9tUwTq2F5XVnvR A07zYZZPUOKCtLJ9q/XP2jNG4G9X473ilivLPBSuq5CFzh1OFqOxPSKdIgk+vHf+xC4DIh wcPqBJP2dNMwYAEx1rvahtdoyDQ9+DsYJwfJvaD8CqL1iju8qMDCmK4Z2dWeurFhx2fV39 qWntip5tKscqZRB5Rfqw0KWGujUoB/RuT7EIHuOadElVAJ240KKzXWeeyiWIuw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047088; a=rsa-sha256; cv=none; b=u0NOVn9J3JpjKX8Ry1ktkHP8zt6bWkPUJkE/kehng/9R1+BvZnPV6t4R1EDogJZrKKpSj2 okTG6iHokSyD12GGwE5JQA400sZi7t5zrBhq3X2pkr5wuqS+7Jfh1h4RrxBwH7GNdrDM/S 2IOcedqMPoEnnS37lhOK+ZfdrPzZ034O7JKLWCf5mHmb+dZtln4r7rMDqIDTztgPP2CBVR xsK3g1HKDq8YpieA7bMpviiEFO9TXBfWEOUVMOS+Zvnf7jvlkKdCbRU8h+nQYOQy+MUVb0 Yrxle+QOaQ7ynB1MixiZtUjt+uN+Fcrl7vpz91hSRJq18CC4jnOhcFTOyo7K1w== 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=1721047088; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=CggST6yvJ6AKqyHXmJeO6VN1HQlHMtXkdl0VU5uHfVo=; b=oV3i1Mdww68sO5TYZsnML/cy4nIdKzSWviIs6dLmOg8mb5QGwjez9fj6iFaU/Uh7jljSeO 9mDEl5j1VVrjVyM5mIAESjlC6oL/o0jjqZ0CWPXrCHuWI3I19Ulh4o/p8gauw4xGoiBCrZ 5eDMs1AawjJRVt443ol/G8Attak5Bmq3KYOlht5vdcHgGftm3ZzvgbRJpm6pZ9z20Eqge/ sWtfaUO5v1EWlExZ0hMtwPaZ4g7zZo6pM2iYaMtUu3KCptVIKJG46EbL2f99f+8C2vgRI7 4KUP5ISFa4pxRFy4dIxtpFDWFgA39xA6KH9aR6qwo5JhJ08UZgRGxB4UNYt6HA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vN1qktzt3D; Mon, 15 Jul 2024 12:38:08 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCc8OP059832; Mon, 15 Jul 2024 12:38:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCc8J0059829; Mon, 15 Jul 2024 12:38:08 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:08 GMT Message-Id: <202407151238.46FCc8J0059829@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: d8db6b4f079e - stable/13 - arm64: Mask non-debug exceptions when single stepping List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: d8db6b4f079efc2de3195392a624ac2d47c3997f Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=d8db6b4f079efc2de3195392a624ac2d47c3997f commit d8db6b4f079efc2de3195392a624ac2d47c3997f Author: Andrew Turner AuthorDate: 2024-03-14 14:02:56 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:28 +0000 arm64: Mask non-debug exceptions when single stepping When an exception is pending when single stepping we may execute the handler for that exception rather than the single step handler. This could cause the scheduler to fire to run a new thread. This will mean we single step to a new thread causing unexpected results. Handle this by masking non-debug exceptions. This will cause issues when stepping over instructions that access the DAIF values so future work is needed to handle these cases, but for most code this now works as expected. Reviewed by: jhb Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D44350 (cherry picked from commit ed3c6cd76de8560c46607abe506a03568e9acab2) --- sys/arm64/arm64/debug_monitor.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/sys/arm64/arm64/debug_monitor.c b/sys/arm64/arm64/debug_monitor.c index 812f44398a67..6de148161a7f 100644 --- a/sys/arm64/arm64/debug_monitor.c +++ b/sys/arm64/arm64/debug_monitor.c @@ -188,6 +188,15 @@ kdb_cpu_set_singlestep(void) ("%s: debug exceptions are not masked", __func__)); kdb_frame->tf_spsr |= PSR_SS; + + /* + * TODO: Handle single stepping over instructions that access + * the DAIF values. On a read the value will be incorrect. + */ + kernel_monitor.dbg_flags &= ~PSR_DAIF; + kernel_monitor.dbg_flags |= kdb_frame->tf_spsr & PSR_DAIF; + kdb_frame->tf_spsr |= (PSR_A | PSR_I | PSR_F); + WRITE_SPECIALREG(mdscr_el1, READ_SPECIALREG(mdscr_el1) | MDSCR_SS | MDSCR_KDE); @@ -209,6 +218,9 @@ kdb_cpu_clear_singlestep(void) KASSERT((READ_SPECIALREG(daif) & PSR_D) == PSR_D, ("%s: debug exceptions are not masked", __func__)); + kdb_frame->tf_spsr &= ~PSR_DAIF; + kdb_frame->tf_spsr |= kernel_monitor.dbg_flags & PSR_DAIF; + WRITE_SPECIALREG(mdscr_el1, READ_SPECIALREG(mdscr_el1) & ~(MDSCR_SS | MDSCR_KDE)); From nobody Mon Jul 15 12:38:06 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vM54J7z5QrXB; Mon, 15 Jul 2024 12:38:07 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vM18cYz4H1j; Mon, 15 Jul 2024 12:38:07 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047087; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=nTPBygYzG5zGnfZWAJxVswtMkngyIpj1+VSxrKZ8s0Q=; b=RSH8RausJ96RmMihnQJVagjdC+0xN+weEK8DnG6faFeVAh2rhWJ4k+ef3QKLKorPzYfnEE 1jkCSnhJSqGUXPC1nMu/tAECmg3fAjuv8rQgXW7sYLPI/FgkygHjWCVsGyqZ9L2OpliawB ek2CnbKgBwWMTzT6/oAQZaF+vjhpGnaXzMl5z+HiP5YjzjjhlDpiN5x4sPFFc1oIaGXv5u 1IBAYWen9FM/cSYcdl1ZzTJd3ouOmjPQDnDn46QupNEJKvBf2FxIkQbLlQQeavTrW6uleb Tlb1PDEvAM13n3CfnL0o/a8+jZs/jK5D2ARGuPFLZ4QP91pLYtc1b0F9cV2KVA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047087; a=rsa-sha256; cv=none; b=OcnhPKfonhCOcx4qfosFIvTdzIJez4LaEsqoDqFsSmJvk2i3yefwi5DjnavuM5ELU1WqDa Fc0GmX9PqXqjgcv7HTN07Ojm9chQ4rabg1kKoJAIYhXNPtNGUSQCWWdFWCUW+JJXqhg68b +j+bW1S39etIHCd62R7hyCwe04146jcQ24mX19UN1YuyGF+2ieHBp5FHLcv2rSVaXIfrRm +i9DNeu1pAzp9wNFm5AqbrqweLmUCT7210zKruFoZ5M5SSF0qcZyMip7Vrf031xejjTo73 fkHncQ+9t5C7fr4BMhm6wWaLU37x6eE2lF6KyFzSiALx7v+WquJVZlhQpf8Vyg== 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=1721047087; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=nTPBygYzG5zGnfZWAJxVswtMkngyIpj1+VSxrKZ8s0Q=; b=hasPPO3E6GRpED6GjsHdmTL6TyI39MII47b+zWod3nxLuVLEliKCqURTGsFVjy99ZzMMxl hTGBYs7iX1KYNbtexSd/0gA4am+mWY8rYJ12Qw44XsU/2kTa1ofsdgw7NKVhWyuNpxJV0X GpFYQLcSdXX5cww6YmnGgsVt9YUXkogpEAeRbm/mmcbzgB5SdxuNeSKoGYtksIQmj3Z8Kp SIZfsUkh+dN2xyx94m0g2pV+BpnqdqrdSR3VN0hdrFwDsAsRXMY63WA8AAzeiPdM3VmIR3 0wqVBXSlg2wnfxhe9FWXJwmrrghaUgohFR/bd3VdmKvBG/W9163EsIe/nARadQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vM0jvdzsZC; Mon, 15 Jul 2024 12:38:07 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCc7PP059732; Mon, 15 Jul 2024 12:38:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCc6bf059729; Mon, 15 Jul 2024 12:38:06 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:06 GMT Message-Id: <202407151238.46FCc6bf059729@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: f236a9c8c437 - stable/13 - arm64: Return all registers to gdb when able List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: f236a9c8c437abaab9fceb6feecf56607801d48e Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=f236a9c8c437abaab9fceb6feecf56607801d48e commit f236a9c8c437abaab9fceb6feecf56607801d48e Author: Andrew Turner AuthorDate: 2024-03-14 17:31:39 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:28 +0000 arm64: Return all registers to gdb when able When the kdb thread is the current thread we read the registers from the trap frame. As this contains all general purpose registers we can use it to read these in the gdb stub. This allows us to include the non-callee saved registers, e.g. function arguments. Reviewed by: imp Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D44360 (cherry picked from commit 0a5f7918fc0e274a904b8fdd7c167bea7cdaf0f4) --- sys/arm64/arm64/gdb_machdep.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sys/arm64/arm64/gdb_machdep.c b/sys/arm64/arm64/gdb_machdep.c index 0673f591ef98..14af8b256e5d 100644 --- a/sys/arm64/arm64/gdb_machdep.c +++ b/sys/arm64/arm64/gdb_machdep.c @@ -55,6 +55,10 @@ gdb_cpu_getreg(int regnum, size_t *regsz) case GDB_REG_SP: return (&kdb_frame->tf_sp); case GDB_REG_PC: return (&kdb_frame->tf_elr); case GDB_REG_CSPR: return (&kdb_frame->tf_spsr); + default: + if (regnum >= GDB_REG_X0 && regnum <= GDB_REG_X29) + return (&kdb_frame->tf_x[regnum - GDB_REG_X0]); + break; } } switch (regnum) { From nobody Mon Jul 15 12:38:06 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vM0ZF0z5QrRM; Mon, 15 Jul 2024 12:38:07 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vL5qD8z4Gvl; Mon, 15 Jul 2024 12:38:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047086; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=btchcI4VQpWWtSn7vvxwOIpXa6rl+zSzWhxdDLXILLs=; b=t2HL/DPdK5420MdLsEqz93m4IPHIw5HsQT0K6M+YtNzwRt6mccvrtB24lg9bLHYOd124od lQj1CQeXq43oiPZbsTTKXW45BfWcFsEl8wsCKKrUh3PuouvfYsETbmvX57VJ/AriHo+AZo gaYr34iNQahBc1ROY3jLXIH1qGPsPzUadow+H/LVfnACuDbqq2+t/5xIZsTAiqtmeDhmAh 4VzsByX5DbeeMvutKtCao3ksRVMnRxdiECkGNQY+YRxk+QKFIF2CdbQGnXfGnUqAFPOurl ZBSldm2izk8U1sRN74aEoKPqwl0T8NM3BgwqqDFwAmXLtXfh9xaIc0r7rY+AIA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047086; a=rsa-sha256; cv=none; b=LhPAw2MbaORvffcViQb/isYTQjC4IxqAB2L6qBqm1gY7oeClEObgnoOT7z9VFWmOi0B/67 i/mLf4JkdKKcTPy9fJc52q5kl9TVhCKNRI1Rd5GOJtA/IqNupnZH7FnZhScF1r9OGOsGuU 4c+ZNRMcegPe6YqI6yPKGthT6E1Wr1+q1BeUhsu2zKvKF9+BS4BN4iGFcVnStUblhAivCX 0cu0cjzq1UCf85GKJY3Wa2szDskpwQZWlljURWeZhpcHDYx2c9imk2/OvjJR0+4HBkPXtI zwYM8itg6UYLCAeQ11wQTFKPb6QgoBOWmPqSNXHJDk1B3n3kgEy6lAILWa9lTQ== 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=1721047086; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=btchcI4VQpWWtSn7vvxwOIpXa6rl+zSzWhxdDLXILLs=; b=ZJx+DS9jT967zP9HBuo0o8a6Y9tIsSU9Z+603H75KOCMrkEc9KRR8ugwpvSUdz6Y7t9XdF ay2ihA8dcQsdcosqTLhGEBZoqSIgq5va3cAib5Ez1+dLEo4wNC0RnjKsKUzH2IzTw2hk1d luupqgZlMA6eKSFYlUwMozvzB2jNve3TQrW4ZdZGTuD+f8W9jmYXLcLw9Vvk9EVr0ZvEha JXIgdm2u7HEr0Qv11ns44W7Tb5GyWodHhRsUqNLaSTosJfWb7dKUmxVTGqMgh8fhN9L7A6 DlnVIUKJ3trXTkPlxqiwP66OEuHpZg2zqQf8fywxZrhyBg5F7NxGjAcF9wiSqw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vL5PBSzt1N; Mon, 15 Jul 2024 12:38:06 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCc6L1059681; Mon, 15 Jul 2024 12:38:06 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCc6lg059678; Mon, 15 Jul 2024 12:38:06 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:06 GMT Message-Id: <202407151238.46FCc6lg059678@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 276355b8fdd3 - stable/14 - elf_common.h: Add STO_AARCH64_VARIANT_PCS List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 276355b8fdd331cfa25837d7f2e217a149b8ac24 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=276355b8fdd331cfa25837d7f2e217a149b8ac24 commit 276355b8fdd331cfa25837d7f2e217a149b8ac24 Author: Andrew Turner AuthorDate: 2024-04-17 13:18:24 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:24:10 +0000 elf_common.h: Add STO_AARCH64_VARIANT_PCS This is used to mark symbols that use a variant procedure call with a different calling convention to the main ABI. Reviewed by: kib, imp Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D44868 (cherry picked from commit d7ac42676dc403cd31d4a6c9a91a2ed5680cca86) --- sys/sys/elf_common.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sys/sys/elf_common.h b/sys/sys/elf_common.h index 934f66fee953..b9e82cb8fa35 100644 --- a/sys/sys/elf_common.h +++ b/sys/sys/elf_common.h @@ -883,6 +883,9 @@ typedef struct { #define STV_SINGLETON 0x5 #define STV_ELIMINATE 0x6 +/* Architecture specific data - st_other */ +#define STO_AARCH64_VARIANT_PCS 0x80 + /* Special symbol table indexes. */ #define STN_UNDEF 0 /* Undefined symbol index. */ From nobody Mon Jul 15 12:38:07 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vN2L1Nz5QrM5; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vM6v6vz4H44; Mon, 15 Jul 2024 12:38:07 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047088; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=NsGZPPBPbSLJtlPtKFUbBlUIe7CX1/TsFgZck0zU4gI=; b=q8SEcxfblMtnH5GJHbaD6zxZTuK7BfMB8R40Dq8YIl0gvGmwKLDcbdj4LsihzWpxeDQODL 4hvkZLpGPLVRa2ZkETTffKZVskiG6sl8rQPVQW4hBq3cqFM4V2CiiXeseSTyi4LuFeDnic qw4zqfv9WDonxgDnEsnaI8TfSEKk771wKDjqfVJMU9YNcS0A5xilpCYJIVkxXLHkul/6jS i9LpbH/6YCSE/ca/0n2nGtjv5Jhe9pXS/NlEySE10l5yQC2tG3pPu6Ovgo52U5iiF81/t1 AXyfaWPjMH77Jw0iJxNUUuJVfYDsqMSpmMTmC8b2afZhtlc1rjXKeUp4ZlCrEg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047088; a=rsa-sha256; cv=none; b=lVMPbY9jRr3luL9A8S/7/PuCwiZCYmvCG0bqlnFNPGoHpU+kJvj6nxqeMBUOawY7za2VSP oysYM3lGOZQeGj4rYkhdbZN+JoLLqeO4rUFjcVYXfjcdy4ZvCObWCoCtC4OaLmdLf63r8s EFP3Zjp+hlYezd2qBnd1UeuXgHCX5BywZKHfXzESs76eyFiy98s7GmoOqT0m4y2UZEvErD v1SBkf54JamXqyuL/zCF/EidGVJOWYk0sgVwUVJrUQkau48fDdymNZ8sewigLbI0p62Xao Oz3gCdnQIXuF3P4hqRUrAXT+sXuHkdjAbKhROZ+4gx8Tp4JfbEbLyQNKblY6FQ== 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=1721047088; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=NsGZPPBPbSLJtlPtKFUbBlUIe7CX1/TsFgZck0zU4gI=; b=Ro2LVXmSSxicg9ll3TV0V/KsSM3Q2llk48GHs8FTUirEvUlIpzh/9VNbeVXtCqd3/GMY54 yfzweprU+/LdErcnsMtg+j/ql4Bd9L5k6F1TEEpfmUU4FKqqSi7f2neWsi2QTwCgCKMU4/ 2tUiH2jv5OvFlqfb9xIE3BlFQTmSqKXsXUxL2tbvetzLzgo4BQ8iSnMQ1bTmPz5YvF0vtp oOJe8NKORWCMIpjSv7up1GAigJC/CmgOJ/ZRZ3sIpL+8cjqRXUnzQPMN32DfAUBXgl66b0 SSJISddLBifPnVCaXIsyt093QpKWv/NW7ImCaT87FQLW5UnpOPC8UCuNHR7vdg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vM6W9pzsJK; Mon, 15 Jul 2024 12:38:07 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCc7Ok059784; Mon, 15 Jul 2024 12:38:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCc7pr059781; Mon, 15 Jul 2024 12:38:07 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:07 GMT Message-Id: <202407151238.46FCc7pr059781@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 5909ac43709a - stable/14 - am64: Allow cpu.h to be included from assembly List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 5909ac43709a83cac8b2d0a64b0dc2ecf4b9bb05 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=5909ac43709a83cac8b2d0a64b0dc2ecf4b9bb05 commit 5909ac43709a83cac8b2d0a64b0dc2ecf4b9bb05 Author: Andrew Turner AuthorDate: 2024-05-03 16:07:29 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:24:21 +0000 am64: Allow cpu.h to be included from assembly Reviewed by: jhibbits, kevans Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45081 (cherry picked from commit e353ac0cfd5d155c01253ee17c2bf23f888cb7de) --- sys/arm64/include/cpu.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sys/arm64/include/cpu.h b/sys/arm64/include/cpu.h index c84d48438964..0701a75d17f7 100644 --- a/sys/arm64/include/cpu.h +++ b/sys/arm64/include/cpu.h @@ -44,8 +44,10 @@ #ifndef _MACHINE_CPU_H_ #define _MACHINE_CPU_H_ +#if !defined(__ASSEMBLER__) #include #include +#endif #include #define TRAPF_PC(tfp) ((tfp)->tf_elr) @@ -200,6 +202,7 @@ #define CPU_MATCH_ERRATA_CAVIUM_THUNDERX_1_1 0 #endif +#if !defined(__ASSEMBLER__) extern char btext[]; extern char etext[]; @@ -267,6 +270,7 @@ ADDRESS_TRANSLATE_FUNC(s1e0w) ADDRESS_TRANSLATE_FUNC(s1e1r) ADDRESS_TRANSLATE_FUNC(s1e1w) +#endif /* !__ASSEMBLER__ */ #endif #endif /* !_MACHINE_CPU_H_ */ From nobody Mon Jul 15 12:38:09 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vP6rnGz5Qrfm; Mon, 15 Jul 2024 12:38:09 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vP3NtWz4GsR; Mon, 15 Jul 2024 12:38:09 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047089; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=U6e5YMU7NbAsCCgt6E04HoohoEVsX+J9l4BLgrywRH0=; b=n335euI0hq0kI/mAAivb5XK4X2PztDGu16nzJ5aVr+jN5MSvgUQR3dF8wdChJ6aTpNLi7C +feUt8L9533j6N80LVeoNCoomzhU8cEly9VfPbebwmVNXtDvPocVtKHF4JyQChsBl1HLYE IzQCaUwqLUMoSYKYSDvZvPVq9kWdfDYoEbfjSIEw+qwsQcaZ/+S1nQJoSMqOGKtb0Vwto3 yp9nVU2qnB7opOlXWka7RLQvhRmTuEwQluVrcTPu32YFxIUaH+zdpdq6XvQgfFNNUiAX6n vaNKtbZYpTNLE3AWmBTYdSnTOFIsUx38098sU9QBzbGqSEVY7vNfnm5KUqAYqQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047089; a=rsa-sha256; cv=none; b=V6Qe4Un67OrK7NcOvWMQ4uCpXiGHsA9Wx37QDCZ0rQUZDGu13sYFhev0azizfAC66S9GlX L7gEBP7c6pAU+RM4yrDZ/zNhPdrEU7zqJrrNmFrEWI1Lo/6lMco/usOWkSWQippGeRQ+jJ /xMNZdE6/C0/rwCTVwaqUFACDUoE6ASpulDGf7nPmLtclik4oFx38jDyBnm1PvO+kFw806 4fxDoixc+rxW1cnUyhB1JHB8gwwVZlGcNpFjSsxjo6WGD3fYcw/94xKB3R64r6LlXiD0gA qL89+y1k8PBBx9/LkqtE227xmRADlGd4kFQGb2tVb1WNH++YX8f2T/XtxsFSYQ== 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=1721047089; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=U6e5YMU7NbAsCCgt6E04HoohoEVsX+J9l4BLgrywRH0=; b=DgZVR1YPZJgEFQRXYHjAVWMKACUgCJx3HlI78JzLVbxD2OW80pI0MkU/e2Qw4F+1RvtdkI asIZoMgxkSBWaEt9Ua9u0kXjye8mzhEWA4Ud/2pbxfS0szQObUcikWbLjm9GJAPrYnQryS 14xhvMr5naWm3E8q3zkzX6eQIwu6APN9kh2i3EQhyMCZOGWNjmmHc29HceeTIUFf/IbvHY NNcPO135dQYrfwrZMZHUffb6AjFH2kaGboJawdsjbMa2sJqqAYMMf6IF449Qw6VOlMvT9X M0XyiNHLcpI1oA64a2kFZXHhPBo4eakI16cn4k/P8YV4fvBpOzVi1aOXnXBtBg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vP3147zsch; Mon, 15 Jul 2024 12:38:09 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCc9LX059931; Mon, 15 Jul 2024 12:38:09 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCc9xv059928; Mon, 15 Jul 2024 12:38:09 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:09 GMT Message-Id: <202407151238.46FCc9xv059928@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 531534bef90d - stable/13 - arm64: Always set the debug control and value regs List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 531534bef90d6df15d9a1efbd05d2255d9f11ed8 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=531534bef90d6df15d9a1efbd05d2255d9f11ed8 commit 531534bef90d6df15d9a1efbd05d2255d9f11ed8 Author: Andrew Turner AuthorDate: 2024-03-12 16:34:41 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:28 +0000 arm64: Always set the debug control and value regs When listing watchpoints we read the raw registers. To ensure we print an accurate list always set the watchpoint and breakpoint registers. Sponsored by: Arm Ltd Reviewed by: jhb Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D44351 (cherry picked from commit 2e2c983d5234cb5457548fc75608d93b2309b254) --- sys/arm64/arm64/debug_monitor.c | 27 ++++++++++++++------------- 1 file changed, 14 insertions(+), 13 deletions(-) diff --git a/sys/arm64/arm64/debug_monitor.c b/sys/arm64/arm64/debug_monitor.c index 6de148161a7f..7d3ca9db9134 100644 --- a/sys/arm64/arm64/debug_monitor.c +++ b/sys/arm64/arm64/debug_monitor.c @@ -490,23 +490,24 @@ dbg_register_sync(struct debug_monitor_state *monitor) if (monitor == NULL) monitor = &kernel_monitor; + for (i = 0; i < dbg_breakpoint_num; i++) { + dbg_wb_write_reg(DBG_REG_BASE_BCR, i, + monitor->dbg_bcr[i]); + dbg_wb_write_reg(DBG_REG_BASE_BVR, i, + monitor->dbg_bvr[i]); + } + + for (i = 0; i < dbg_watchpoint_num; i++) { + dbg_wb_write_reg(DBG_REG_BASE_WCR, i, + monitor->dbg_wcr[i]); + dbg_wb_write_reg(DBG_REG_BASE_WVR, i, + monitor->dbg_wvr[i]); + } + mdscr = READ_SPECIALREG(mdscr_el1); if ((monitor->dbg_flags & DBGMON_ENABLED) == 0) { mdscr &= ~(MDSCR_MDE | MDSCR_KDE); } else { - for (i = 0; i < dbg_breakpoint_num; i++) { - dbg_wb_write_reg(DBG_REG_BASE_BCR, i, - monitor->dbg_bcr[i]); - dbg_wb_write_reg(DBG_REG_BASE_BVR, i, - monitor->dbg_bvr[i]); - } - - for (i = 0; i < dbg_watchpoint_num; i++) { - dbg_wb_write_reg(DBG_REG_BASE_WCR, i, - monitor->dbg_wcr[i]); - dbg_wb_write_reg(DBG_REG_BASE_WVR, i, - monitor->dbg_wvr[i]); - } mdscr |= MDSCR_MDE; if ((monitor->dbg_flags & DBGMON_KERNEL) == DBGMON_KERNEL) mdscr |= MDSCR_KDE; From nobody Mon Jul 15 12:38:08 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vP2zk8z5QrXG; Mon, 15 Jul 2024 12:38:09 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vP0cd5z4HGm; Mon, 15 Jul 2024 12:38:09 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047089; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=AhLFzftEdp8YVmPUc3QASC213fmKiiYraU06segE+LQ=; b=ApjIKSO+qkfnuFjPy8VNFn+9yGCbEQkK1rNgBqofgKAJn6qNQ4BS1HbZHwX2Qq6w9Sps9W EFKkANLmPaFmRcK86pmvwgRc7bIpROfW69hmjWmhKvZdw2ZApFfGmj9V1hENCbH+BSQHPD QuuUU5rbHTKC2tTovPv3bpfGYgrQBN3QqZDDjdonQj/LoRfieEEmMnrwmOheEJgrbOxUuu MlInr42Q7c/yi0VU42PIS5JnFvBDmxKcYPL6VTknNBfzrhVNmrLiTBOuJLYiFqKNB9k66E kCi9+tfcqCJAvquCq5+1LYMpy8TdlteYnAhcY3w64kucfzYn/8TyUNomPVQ/5Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047089; a=rsa-sha256; cv=none; b=t61V2jO/TwZS4F2JMk7W+rNSvWxDTAJadOeaXGnFtzKtU65PJeEZ+NhxiLB7nUazzLgq1x eQILxXmir17lQGxzzyChzeiSFso8zz4/K2Vm97I0JZVdZ2J17DpmL1a52+Eojf9FPMmQjh vlH38tVA95rtYU2HvPf8MA4PTHJbiVahZa+Yu/Vp85LJkgq2bDjyBHDj0BGA/RmN8m4hS7 Q6ojWiSKJzRvT67/MI3BM0YfbOwwDsasRBVfNuCLpEFlaSJkYmLWIImSsBo8n/60uy1iQT CadVAOD78i3NEdCKh87ufwM4MT4jOHVzj3mX2ODqn+dOUSc0pDC7Lh2QVzCVZA== 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=1721047089; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=AhLFzftEdp8YVmPUc3QASC213fmKiiYraU06segE+LQ=; b=MBQnbwMxRuf4q42UrBcy7b9FrNFanuGBxcbiVB4vVGPdv3jUtp710J/ldvevw5N+uNhi/2 f4Y4aID5BumvoLbhVnUofUok11BV//Qvi8jLhQ9b99uLUDHb/PIqdsIy9tyEBf8bH+UKKi 2Q3K5XkLqqe0aJB5W9a2E5Lz04bBMqtqptDdPOZyZkAyjM6WEFrzJVQtTul2c7SNC1CE4S a3aD8Pr9kWR+ozAJxq1tl1gn4/9VGENkM8altn2POTtw79XhJLQsIsqh911IqrafLeJpR5 wfSmAwBcR+LvPkMcfO9vJePH3BBOzXSWBdl2fR1vZX/79lKiA1m8RZqZdwk9JQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vP0Bpfzsrp; Mon, 15 Jul 2024 12:38:09 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCc8GD059877; Mon, 15 Jul 2024 12:38:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCc8II059874; Mon, 15 Jul 2024 12:38:08 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:08 GMT Message-Id: <202407151238.46FCc8II059874@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: ab44e45862e0 - stable/14 - dev/psci: Check all compat strings List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: ab44e45862e099dac5f3bd5390c3233ad1073a56 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=ab44e45862e099dac5f3bd5390c3233ad1073a56 commit ab44e45862e099dac5f3bd5390c3233ad1073a56 Author: Andrew Turner AuthorDate: 2024-04-23 11:27:09 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:24:30 +0000 dev/psci: Check all compat strings When searching for the PSCI FDT node we only check a few compat strings. Use the existing compat_data array to check all strings the driver may attach to. Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D44913 (cherry picked from commit f91e9401c2098ba56f43093ef9747d0b1f60f8eb) --- sys/dev/psci/psci.c | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/sys/dev/psci/psci.c b/sys/dev/psci/psci.c index 4fd1cd62ed8c..bc35f818d844 100644 --- a/sys/dev/psci/psci.c +++ b/sys/dev/psci/psci.c @@ -378,12 +378,18 @@ psci_fdt_callfn(psci_callfn_t *callfn) { phandle_t node; - node = ofw_bus_find_compatible(OF_peer(0), "arm,psci-0.2"); - if (node == 0) { - node = ofw_bus_find_compatible(OF_peer(0), "arm,psci-1.0"); - if (node == 0) - return (PSCI_MISSING); + /* XXX: This is suboptimal, we should walk the tree & check each + * node against compat_data, but we only have a few entries so + * it's ok for now. + */ + for (int i = 0; compat_data[i].ocd_str != NULL; i++) { + node = ofw_bus_find_compatible(OF_peer(0), + compat_data[i].ocd_str); + if (node != 0) + break; } + if (node == 0) + return (PSCI_MISSING); *callfn = psci_fdt_get_callfn(node); return (0); From nobody Mon Jul 15 12:38:10 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vQ6TZfz5QrMP; Mon, 15 Jul 2024 12:38:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vQ4NLXz4HDm; Mon, 15 Jul 2024 12:38:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047090; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=kMjUobLczdtTP/wqjEO+oiuIXuGLaTGRcCAuI/Izusw=; b=UVV4lwGLfsw0r2IWiZ2kECYHdD0b9UGNLn9V1kDWFaYg68LmdWotNWTsELKcVMtKFwMr2g YpM6i27AeoitJjuyUdc+Zgad8j0nKVj/sBLcnUrs0Q2pTfSWK3ZoyYeQWup3k0sDK5xtmN MzTKyAzMcd36Rol2FfiP0wjuR3vydk1ws5NvMSLOvuXFdAszxh1iDIzDdboa6af3Oek/n2 q/NX6weEJy/zKphQAugesJCJNYGKdinx0E3rsuPKPLjsqAjGn6TIKVO8Pn6t7mpbZN4JdK Bdy1P7T2VJ1Yw0frhnFu+u2x6kTSiqezn9badbyjmkS+nYyjAcTG5qMWB6dg0g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047090; a=rsa-sha256; cv=none; b=eKA/5ebTyWXhZJQhjETigFViIFFcbVMQthhxmAabqDe5JevQFv+w4t6POy3u4tfMvJi9N6 5UpYMNlRWf2+c7FVSSTi0BVPCuQtgcbcoKfNiVzn3PoPI1y0k/DfjyHbbBc1e+uz8NFRet hO0yBDya1v9roVTHNwYJ5ufY/ko5mTAVk0CHd+4hk38THryx/1b7qP9IlQohqOfoZe4xXi Zb74Zs0rCe4ic12WLMGQ0uilBtDZC4z47WFNu1AAeDLMcNeLIxUBsqOM1zr9HhjspWfMUw xTqq92oyB9Wyo58K1RavIaQTm9M91a3ubMGU4NYJuEZglF/JqB3pRfT4NW9rCQ== 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=1721047090; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=kMjUobLczdtTP/wqjEO+oiuIXuGLaTGRcCAuI/Izusw=; b=lCGtVFwX36oevim5AW9Nfc3pFSFNVzL6ucbWkAGpeAk0YxA0ptZsL8Ouvst2CiEV0wRetX nqUidgqAa4FbjQoAJ8pUhcxmWWabKlz3xiGBrow/V2I4Yjl/ssgu2EkgvsJY6zl5WVNBx2 0fY4r+IDjsYvmG9t9CcgSAtErm7AR20v19KDZyqWchLHdlz7Fx98HGyvDvtxUAh19aTb/+ dMRg6m7zvfs8Cd2q5ytXRr6J5SX+SbbTxn9CzZM8iVRIQ/RZMDOjZIMgWnQDdidJXS1CNf p+kd+wFMy7BtR4NDgBBJCVZ0jHigOHoHnaRpQzNEncNZZlXl6WHjBtaozuHPKA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vQ40NmzsZD; Mon, 15 Jul 2024 12:38:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcAgn060036; Mon, 15 Jul 2024 12:38:10 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcAbc060033; Mon, 15 Jul 2024 12:38:10 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:10 GMT Message-Id: <202407151238.46FCcAbc060033@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 3ab140921420 - stable/13 - arm64: Use a switch to decide when to enable debug List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 3ab140921420046c3112769d7f00563f4d9b7f97 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=3ab140921420046c3112769d7f00563f4d9b7f97 commit 3ab140921420046c3112769d7f00563f4d9b7f97 Author: Andrew Turner AuthorDate: 2024-03-12 16:47:38 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:28 +0000 arm64: Use a switch to decide when to enable debug Use a switch statement to decide which exceptions we need to call dbg_enable for. This simplifies adding more esceptions to the list in the future. Reviewed by: jhb Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D44352 (cherry picked from commit d93b3a65f7697630ca1dd2635fc976f3ef36b602) --- sys/arm64/arm64/trap.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/sys/arm64/arm64/trap.c b/sys/arm64/arm64/trap.c index 74122cd508ab..4a659e9d5538 100644 --- a/sys/arm64/arm64/trap.c +++ b/sys/arm64/arm64/trap.c @@ -467,9 +467,15 @@ do_el1h_sync(struct thread *td, struct trapframe *frame) * Enable debug exceptions if we aren't already handling one. They will * be masked again in the exception handler's epilogue. */ - if (exception != EXCP_BRK && exception != EXCP_WATCHPT_EL1 && - exception != EXCP_SOFTSTP_EL1) + switch (exception) { + case EXCP_BRK: + case EXCP_WATCHPT_EL1: + case EXCP_SOFTSTP_EL1: + break; + default: dbg_enable(); + break; + } switch (exception) { case EXCP_FP_SIMD: From nobody Mon Jul 15 12:38:11 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vR4ghqz5QrXT; Mon, 15 Jul 2024 12:38:11 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vR2MQSz4HQc; Mon, 15 Jul 2024 12:38:11 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047091; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=HtFGe5TdKr/Zevg+WX9VYyeTjCiasMz2Ur3UhckqOeY=; b=I4FQK+08rrGBEW5bc6HizQ/CXSnNWWQQEG9cLFEuLpnb16TERKa7B8tMDtm6LnM0CUcdpN JMHH0ymda1mPj89EZkNLeRjCqiEg5NZ73Dh+BVspKAdUvMuARmYw+u9fVT8GvoFxagJua3 rC/RcMrpGQKJK0lVc66LIaO0hObCSgg54bxoToUXAk52fZKu0ZyFJq2FszNbZAvgzLQ4tX 2O6z6wLE6nDZjC6vql4A81PviX4q7x/aYn4Z1OLxBJQZlzo2jJN6h6Cz+2X+HHDF8Vj5/J CYIx++5eej/FsYCo4MvDl7L5ozbWkTlPzliOgCcw0lo716p3R9pzT0n+sSivkQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047091; a=rsa-sha256; cv=none; b=CECHcfbbZCGUZxtLu84jicXfofS/++5btqb1SQYgIxP5S6Fz6gAxob/9F//EgqwHJfeMm2 ocDGvqgvViePZcLRpvMPowQvMdW0ufWHRZW4LZz2SLnxMb+hja7n+TfOHilqxCApmtnrYk czIKlWJxqDRTQBgIxzWRscsPAdhHCyhGpZp4fa5bAX/g6/lJpXU+AxmfYyQxK2VVGSClKY AC+gxV+49chjXmDLQKhQWnaz5ekJo5QzT0S6hQN3plqyYgdy6xG0a0spyiNuXqgHPVGksr hVXSYWds/ssKeFeX4Mm8YfIfdxT0tuo/px1Sxad95p9w65oa/JCcgMDCHvgtEQ== 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=1721047091; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=HtFGe5TdKr/Zevg+WX9VYyeTjCiasMz2Ur3UhckqOeY=; b=kvm9tF2GWKo316KdyLMPV4/79B81MwqgQTXc+6jJ+gY698vzS46muX5uW7zZBbDsd3uY6M kCLU4h6N4tVLUeQG9GH5jJR2mfasW4vCuWfDnohzWuYfq5Ftrq6nNoao0x75O6FXlsiq2F 6hxBFf4lZV2ADXyexObxdlqMXonOgflmkhgiUNkJA0x6UkkDtKk6aG/XdqMqct3meyfT2z hjefB2+SAFi5IR9WDZwwJJ7iOrN6hanp9lh668gObFx3gJGrUYCdCEA39HtDWfzNpsKmHb T32Xi79p2sjJ4DVJiKWizBPRLomR+22FLDXq1DUOCyRVjQEsxiYLBwcxrvDZPg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vR1xsbzsrq; Mon, 15 Jul 2024 12:38:11 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcBQp060081; Mon, 15 Jul 2024 12:38:11 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcBBx060078; Mon, 15 Jul 2024 12:38:11 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:11 GMT Message-Id: <202407151238.46FCcBBx060078@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: c2e0dea93f71 - stable/14 - rtld: Add MD_OBJ_ENTRY to extend Struct_Obj_Entry List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: c2e0dea93f71c29c353875a865857d69ad26f8d7 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=c2e0dea93f71c29c353875a865857d69ad26f8d7 commit c2e0dea93f71c29c353875a865857d69ad26f8d7 Author: Andrew Turner AuthorDate: 2024-05-07 15:49:53 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:24:58 +0000 rtld: Add MD_OBJ_ENTRY to extend Struct_Obj_Entry Add a macro the architectures can use to add per-arch fields to Struct_Obj_Entry. Reviewed by: kib Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45116 (cherry picked from commit 06db20ffeca9898e5802d63f3b06caaa37c3a4ed) --- libexec/rtld-elf/aarch64/rtld_machdep.h | 2 ++ libexec/rtld-elf/amd64/rtld_machdep.h | 2 ++ libexec/rtld-elf/arm/rtld_machdep.h | 2 ++ libexec/rtld-elf/i386/rtld_machdep.h | 2 ++ libexec/rtld-elf/powerpc/rtld_machdep.h | 2 ++ libexec/rtld-elf/powerpc64/rtld_machdep.h | 2 ++ libexec/rtld-elf/riscv/rtld_machdep.h | 2 ++ libexec/rtld-elf/rtld.h | 2 ++ 8 files changed, 16 insertions(+) diff --git a/libexec/rtld-elf/aarch64/rtld_machdep.h b/libexec/rtld-elf/aarch64/rtld_machdep.h index b1c5e21cb505..7f7c3db865bb 100644 --- a/libexec/rtld-elf/aarch64/rtld_machdep.h +++ b/libexec/rtld-elf/aarch64/rtld_machdep.h @@ -37,6 +37,8 @@ struct Struct_Obj_Entry; +#define MD_OBJ_ENTRY + /* Return the address of the .dynamic section in the dynamic linker. */ #define rtld_dynamic(obj) \ ({ \ diff --git a/libexec/rtld-elf/amd64/rtld_machdep.h b/libexec/rtld-elf/amd64/rtld_machdep.h index 68e51c4894f4..dc8cd59d74c0 100644 --- a/libexec/rtld-elf/amd64/rtld_machdep.h +++ b/libexec/rtld-elf/amd64/rtld_machdep.h @@ -35,6 +35,8 @@ struct Struct_Obj_Entry; +#define MD_OBJ_ENTRY + /* Return the address of the .dynamic section in the dynamic linker. */ Elf_Dyn *rtld_dynamic_addr(void); #define rtld_dynamic(obj) rtld_dynamic_addr() diff --git a/libexec/rtld-elf/arm/rtld_machdep.h b/libexec/rtld-elf/arm/rtld_machdep.h index 6a08aa5eb02c..14d482c9591d 100644 --- a/libexec/rtld-elf/arm/rtld_machdep.h +++ b/libexec/rtld-elf/arm/rtld_machdep.h @@ -36,6 +36,8 @@ struct Struct_Obj_Entry; +#define MD_OBJ_ENTRY + /* Return the address of the .dynamic section in the dynamic linker. */ #define rtld_dynamic(obj) (&_DYNAMIC) diff --git a/libexec/rtld-elf/i386/rtld_machdep.h b/libexec/rtld-elf/i386/rtld_machdep.h index 6afb5e069cb5..15b23d187ed2 100644 --- a/libexec/rtld-elf/i386/rtld_machdep.h +++ b/libexec/rtld-elf/i386/rtld_machdep.h @@ -35,6 +35,8 @@ struct Struct_Obj_Entry; +#define MD_OBJ_ENTRY + /* Return the address of the .dynamic section in the dynamic linker. */ #define rtld_dynamic(obj) \ ((const Elf_Dyn *)((obj)->relocbase + (Elf_Addr)&_DYNAMIC)) diff --git a/libexec/rtld-elf/powerpc/rtld_machdep.h b/libexec/rtld-elf/powerpc/rtld_machdep.h index 7b106b7e38d7..8bdd2e0aaaeb 100644 --- a/libexec/rtld-elf/powerpc/rtld_machdep.h +++ b/libexec/rtld-elf/powerpc/rtld_machdep.h @@ -35,6 +35,8 @@ struct Struct_Obj_Entry; +#define MD_OBJ_ENTRY + /* Return the address of the .dynamic section in the dynamic linker. */ #define rtld_dynamic(obj) (&_DYNAMIC) diff --git a/libexec/rtld-elf/powerpc64/rtld_machdep.h b/libexec/rtld-elf/powerpc64/rtld_machdep.h index 7e6f13940daf..cb948b9cb689 100644 --- a/libexec/rtld-elf/powerpc64/rtld_machdep.h +++ b/libexec/rtld-elf/powerpc64/rtld_machdep.h @@ -35,6 +35,8 @@ struct Struct_Obj_Entry; +#define MD_OBJ_ENTRY + /* Return the address of the .dynamic section in the dynamic linker. */ #define rtld_dynamic(obj) (&_DYNAMIC) diff --git a/libexec/rtld-elf/riscv/rtld_machdep.h b/libexec/rtld-elf/riscv/rtld_machdep.h index 023245fbe6a4..381eba530c2d 100644 --- a/libexec/rtld-elf/riscv/rtld_machdep.h +++ b/libexec/rtld-elf/riscv/rtld_machdep.h @@ -42,6 +42,8 @@ struct Struct_Obj_Entry; +#define MD_OBJ_ENTRY + uint64_t set_gp(struct Struct_Obj_Entry *obj); /* Return the address of the .dynamic section in the dynamic linker. */ diff --git a/libexec/rtld-elf/rtld.h b/libexec/rtld-elf/rtld.h index 6311b3e6cc7f..a4f2c35cc03f 100644 --- a/libexec/rtld-elf/rtld.h +++ b/libexec/rtld-elf/rtld.h @@ -277,6 +277,8 @@ typedef struct Struct_Obj_Entry { bool unholdfree : 1; /* unmap upon last unhold */ bool doomed : 1; /* Object cannot be referenced */ + MD_OBJ_ENTRY; + struct link_map linkmap; /* For GDB and dlinfo() */ Objlist dldags; /* Object belongs to these dlopened DAGs (%) */ Objlist dagmembers; /* DAG has these members (%) */ From nobody Mon Jul 15 12:38:10 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vQ3Gvbz5QrZk; Mon, 15 Jul 2024 12:38:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vQ1xdNz4HHC; Mon, 15 Jul 2024 12:38:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047090; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=t/7pbkG9pBqfkwGWX3oj00elejXb3dsxvEsH2UxSYJc=; b=FScAUCMRpQTQhgPE62JR5jCyVco9pElxzvpIyZKFc3LYAe/rW20dZ1eandr4SwFmovGwtU h7q8qqPDp/SEemAVIgk1TYlWUTXwl3pLp2BUfLYC2L2KHEwnn/GzljP0++aKuHm7UpIL+j kPRHLfWo/adhIrjr3EZ/n5xXxSVYtSjEqBHXOFxLgjqcEz8QTMou64Ky1F/aRmD85gunjh oVptXW+wK9F5lMMhnrLNlXbTSL5uDMX3V2XLl08WOyuunHl3JYiHWcFfq9DMFukxBFRE5O GdWSHlH+yuxEftL9PS7RxmW3z7qMUzS8kdoiHtTbdPDib3+PgtTiVFItppBeHw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047090; a=rsa-sha256; cv=none; b=NSMTuDUrCUO9IOdUbeFsB9W8xXswysT6LOLNh1M6ZYkDKAc6SMpaCP/6dA21v4Cdlz2ltA uhnZrwlI+KA/003387EiPTVEDVxImUVNFf78u+RkFGnActAqpg76rTaVuxi4riKDAb7pGz M29tUiiZOhpY2cKuBycBo0s0GI2YcxOD61PAp5P6rGRoHGuM8K6DKXsDsxaDow53fViE7h NBZyN/DuaEszO9Yfhy+PGs0eFa42n7EApp73owRkglFijS0rT5B4XwZylWiXLCwyBcLKl/ 6TUuBY41y2zmAD9yLq4NxUxIbQtIzc6KsWaReWvmU9dAOvjTm5OirVWUqoZiww== 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=1721047090; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=t/7pbkG9pBqfkwGWX3oj00elejXb3dsxvEsH2UxSYJc=; b=SwILvglUZOxWk5tgc4ZyUZ8/6Ub9PMCmjQ4Wx5gmvsftO5poozxvx7wRU6mJZzXZsCI1py pQVHNcMlDtMeKGRdaxY6zjnSr2SBJXWUmJ/icY+BwKmCv3fcDsTpxuNTcyTvReKXHtWDzB XeqlfK9kLTwFHvGJzB1PaYTgWfbvW7YWAmPfKgXUUFrDIqExKXLhA8ioEhgFj92oC3Ct1D hmAu6QHveuoKJQil1M+9+0lwhaA2Tcmw1ay1I75x6U9orKSPVqC5zJNecWEpwuRMUVwxdK CkVIqcV8XiK8tfXc+R+SK0DPUKzBQOClxDjwaSsXYCz1t9L8Ml6qEMPxX5IFAw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vQ19pdzscj; Mon, 15 Jul 2024 12:38:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcAfs059979; Mon, 15 Jul 2024 12:38:10 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcADa059976; Mon, 15 Jul 2024 12:38:10 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:10 GMT Message-Id: <202407151238.46FCcADa059976@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 2f54bff74a4b - stable/14 - arm64/gicv3: Check if the hardware supports LPIs List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 2f54bff74a4b19108f39fc8791614a0dfa6e6b9c Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=2f54bff74a4b19108f39fc8791614a0dfa6e6b9c commit 2f54bff74a4b19108f39fc8791614a0dfa6e6b9c Author: Andrew Turner AuthorDate: 2024-04-23 11:28:23 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:24:40 +0000 arm64/gicv3: Check if the hardware supports LPIs Some simulators have the ITS in the DTB passed to the kernel, however it is a runtime configuration option to enable it. Check the GICD_TYPER register to see if LPIs are enabled before attaching the ITS driver. Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D44914 (cherry picked from commit 4ab0f5ab3fd6dcd7f76c1ed1c9dc0dcd152fb64f) --- sys/arm64/arm64/gic_v3.c | 4 ++++ sys/arm64/arm64/gic_v3_var.h | 2 ++ sys/arm64/arm64/gicv3_its.c | 6 ++++++ 3 files changed, 12 insertions(+) diff --git a/sys/arm64/arm64/gic_v3.c b/sys/arm64/arm64/gic_v3.c index 4e9080787149..9c77f6842aa4 100644 --- a/sys/arm64/arm64/gic_v3.c +++ b/sys/arm64/arm64/gic_v3.c @@ -495,6 +495,10 @@ gic_v3_read_ivar(device_t dev, device_t child, int which, uintptr_t *result) case GICV3_IVAR_REDIST: *result = (uintptr_t)&sc->gic_redists.pcpu[PCPU_GET(cpuid)]; return (0); + case GICV3_IVAR_SUPPORT_LPIS: + *result = + (gic_d_read(sc, 4, GICD_TYPER) & GICD_TYPER_LPIS) != 0; + return (0); case GIC_IVAR_HW_REV: KASSERT( GICR_PIDR2_ARCH(sc->gic_pidr2) == GICR_PIDR2_ARCH_GICv3 || diff --git a/sys/arm64/arm64/gic_v3_var.h b/sys/arm64/arm64/gic_v3_var.h index 81526e7cc15e..1c5d354ee217 100644 --- a/sys/arm64/arm64/gic_v3_var.h +++ b/sys/arm64/arm64/gic_v3_var.h @@ -102,9 +102,11 @@ MALLOC_DECLARE(M_GIC_V3); #define GICV3_IVAR_NIRQS 1000 /* 1001 was GICV3_IVAR_REDIST_VADDR */ #define GICV3_IVAR_REDIST 1002 +#define GICV3_IVAR_SUPPORT_LPIS 1003 __BUS_ACCESSOR(gicv3, nirqs, GICV3, NIRQS, u_int); __BUS_ACCESSOR(gicv3, redist, GICV3, REDIST, void *); +__BUS_ACCESSOR(gicv3, support_lpis, GICV3, SUPPORT_LPIS, bool); /* Device methods */ int gic_v3_attach(device_t dev); diff --git a/sys/arm64/arm64/gicv3_its.c b/sys/arm64/arm64/gicv3_its.c index 02c063fe57b5..8f3c30d772b6 100644 --- a/sys/arm64/arm64/gicv3_its.c +++ b/sys/arm64/arm64/gicv3_its.c @@ -2212,6 +2212,9 @@ gicv3_its_fdt_probe(device_t dev) if (!ofw_bus_is_compatible(dev, "arm,gic-v3-its")) return (ENXIO); + if (!gicv3_get_support_lpis(dev)) + return (ENXIO); + device_set_desc(dev, "ARM GIC Interrupt Translation Service"); return (BUS_PROBE_DEFAULT); } @@ -2281,6 +2284,9 @@ gicv3_its_acpi_probe(device_t dev) if (gic_get_hw_rev(dev) < 3) return (EINVAL); + if (!gicv3_get_support_lpis(dev)) + return (ENXIO); + device_set_desc(dev, "ARM GIC Interrupt Translation Service"); return (BUS_PROBE_DEFAULT); } From nobody Mon Jul 15 12:38:11 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vR6NPJz5QrMR; Mon, 15 Jul 2024 12:38:11 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vR5PdNz4HQl; Mon, 15 Jul 2024 12:38:11 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047091; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=+tZkwyENoozXfhGQAu11ydNEqix4MtuT4vDVyu4w1Vk=; b=fqcKfK6wsStrzhO8JaDKNG6dgpxbZtn+qOsyLo2pFQkfdOcy/A9Jg+LTz1FmtnnZ3PTdvL MovVFfyHdiHvxiyRbastinwiXzwbNQ+Xj6fzN5EgBmRt/Gd16g7UD7AZtluL9NqmNJuVn2 ygkeJNpE+9DoyvCeJtp/fyasNKKFvmv46O1P6YnRJJhVyURoLttjwBCk2x1tuPvRkjWNST WViMAqnIyOIyTvlhOC2sGaXFrrYkPpCNE39Ct5lMpC0bUimOMY/qpXhEIKLPTsl1QqOxhA zr5aCgw5bUDYnrizpX7kSRuTi65NU3tQ/hB6TMaLZsrQY223dz8ui6u116VB/A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047091; a=rsa-sha256; cv=none; b=nzDGAX5n2jHE1N0Y2mUGJghwlL2Ge4e5eKnd8mSfHhZxhPqp8r/gyC8sT0NQhKRSooxOlu yRnNgib9eU2dOC67wqmaJ53yZP9E2FgmvOIw0Y/o+fwxn1MdJkX7DIt0rpST3lHJzkn6rR GtJctsYAr0M+ePCj7wPBN6sz3CsbEUcSMNhanZzTRaYnRhNODPG3fNUaZNk+AzbgYP1fOP fyupNMxOopgwhTa6zwX+2XK5HCjD1HahGvoZsmZKiQVucZN6QPNW9FJdla1ce/ZctyLG6i ip0R37FHixneqdpHWkOBNAiKhTzyA2skWJQKIXFND4fqmM5sjznKC+Gg6ndEVQ== 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=1721047091; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=+tZkwyENoozXfhGQAu11ydNEqix4MtuT4vDVyu4w1Vk=; b=rLI3SJKVsnlYuNvCvJPnR93MkrzvhwxTc8BMCgHZJmHe+0zi+g+uhT1z3RPrTxA7yN/z0M pFiVCzBci1rkeSsofKSDwk+/s7BWKxujIQlyCVOQEvg2PnGhj2vikTBDBPTITyucqoxlG7 L4IKWb82a1dZqOkmmt285JpGsK9GpThk9oKSYMIYLG/yOmqS2yaADThqQURmnz0jkbwua+ /ltdjPpwu/BLgJJhMk9M/3XGRuukoZh1P08wlsPNSLvGSSTC7Ad2DWj162WQsy1q9PCA84 iw+EHsiNegBY9trSIipi5Niw+zLrrQXvUPHdpyycJY/RKVHYLxWUd1SdQ9zC1Q== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vR51b8zsrr; Mon, 15 Jul 2024 12:38:11 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcBsi060128; Mon, 15 Jul 2024 12:38:11 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcBos060125; Mon, 15 Jul 2024 12:38:11 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:11 GMT Message-Id: <202407151238.46FCcBos060125@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: d08d4bb18f6c - stable/13 - arm64: Add EL1 hardware breakpoint exceptions List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: d08d4bb18f6ce0476a48646e13b24b8f6b06044e Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=d08d4bb18f6ce0476a48646e13b24b8f6b06044e commit d08d4bb18f6ce0476a48646e13b24b8f6b06044e Author: Andrew Turner AuthorDate: 2024-03-12 16:50:04 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:28 +0000 arm64: Add EL1 hardware breakpoint exceptions Reviewed by: jhb Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D44353 (cherry picked from commit c802b486ddfd796ea35b770148af9a5b0cd0ee64) --- sys/arm64/arm64/gdb_machdep.c | 1 + sys/arm64/arm64/trap.c | 2 ++ sys/arm64/include/armreg.h | 1 + sys/arm64/include/db_machdep.h | 4 +++- 4 files changed, 7 insertions(+), 1 deletion(-) diff --git a/sys/arm64/arm64/gdb_machdep.c b/sys/arm64/arm64/gdb_machdep.c index 14af8b256e5d..8a29875caa4e 100644 --- a/sys/arm64/arm64/gdb_machdep.c +++ b/sys/arm64/arm64/gdb_machdep.c @@ -110,6 +110,7 @@ gdb_cpu_signal(int type, int code __unused) switch (type) { case EXCP_WATCHPT_EL1: case EXCP_SOFTSTP_EL1: + case EXCP_BRKPT_EL1: case EXCP_BRK: return (SIGTRAP); } diff --git a/sys/arm64/arm64/trap.c b/sys/arm64/arm64/trap.c index 4a659e9d5538..8d9e4abd8b3f 100644 --- a/sys/arm64/arm64/trap.c +++ b/sys/arm64/arm64/trap.c @@ -469,6 +469,7 @@ do_el1h_sync(struct thread *td, struct trapframe *frame) */ switch (exception) { case EXCP_BRK: + case EXCP_BRKPT_EL1: case EXCP_WATCHPT_EL1: case EXCP_SOFTSTP_EL1: break; @@ -521,6 +522,7 @@ do_el1h_sync(struct thread *td, struct trapframe *frame) panic("No debugger in kernel."); #endif break; + case EXCP_BRKPT_EL1: case EXCP_WATCHPT_EL1: case EXCP_SOFTSTP_EL1: #ifdef KDB diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index ffe19a5cc0ef..9add7515967a 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -442,6 +442,7 @@ #define EXCP_TRAP_FP 0x2c /* Trapped FP exception */ #define EXCP_SERROR 0x2f /* SError interrupt */ #define EXCP_BRKPT_EL0 0x30 /* Hardware breakpoint, from same EL */ +#define EXCP_BRKPT_EL1 0x31 /* Hardware breakpoint, from same EL */ #define EXCP_SOFTSTP_EL0 0x32 /* Software Step, from lower EL */ #define EXCP_SOFTSTP_EL1 0x33 /* Software Step, from same EL */ #define EXCP_WATCHPT_EL0 0x34 /* Watchpoint, from lower EL */ diff --git a/sys/arm64/include/db_machdep.h b/sys/arm64/include/db_machdep.h index 67747b8eba05..d88a0c908c86 100644 --- a/sys/arm64/include/db_machdep.h +++ b/sys/arm64/include/db_machdep.h @@ -36,6 +36,7 @@ #include #define T_BREAKPOINT (EXCP_BRK) +#define T_HW_BREAKPOINT (EXCP_BRKPT_EL1) #define T_SINGLESTEP (EXCP_SOFTSTP_EL1) #define T_WATCHPOINT (EXCP_WATCHPT_EL1) @@ -56,7 +57,8 @@ typedef long db_expr_t; #define db_clear_single_step kdb_cpu_clear_singlestep #define db_set_single_step kdb_cpu_set_singlestep -#define IS_BREAKPOINT_TRAP(type, code) (type == T_BREAKPOINT) +#define IS_BREAKPOINT_TRAP(type, code) \ + (type == T_BREAKPOINT || type == T_HW_BREAKPOINT) #define IS_SSTEP_TRAP(type, code) (type == T_SINGLESTEP) #define IS_WATCHPOINT_TRAP(type, code) (type == T_WATCHPOINT) From nobody Mon Jul 15 12:38:12 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vT0Qkyz5QrcM; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vS3GYPz4H63; Mon, 15 Jul 2024 12:38:12 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047092; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=8ehIffab/eLu0H0s69qhVQIjTU6A32tEyHGs9TRkJDY=; b=jaC9K+ImBtW4iTtOjON6o9SZcmHYNhKX18dTgKkqgD/LdoIKnFoJKFNr8FlZDSHBAWt4sc 33R+8AgTRD7am0iVjNniymybgWUZAGyaHb8W3CyFFkJSU2CVs2epw4ylH4XKQLGZFojlCl zwtHGa+TcGXsFaenoGl2uWtajJFd9ypuv1cvD3y+Twvt/prYPkjsRRz+qSpKJU0ks1ISIa rp5Bu0gIgAJzUe69AzqnlElVeuDAqJ2OTJOKCwbjnJD58ONuDBAgfdNCNPDKMQzljPYi2B Z/qqdDMIsqENI2SCCblio7tTeNSTG8ogBMTghnbvytxuEbIZFfZBIS+tpwpbjw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047092; a=rsa-sha256; cv=none; b=rKQPOHu5vimwfAXLFlxBuofOfaLj1xO14tNy8rA6qPY8Mi/6fqAQXPGu9JlOEyvq/Ez2Pr CbIBIPkOqo3XlxhqEq9N6k2tGOrjpKwCRCRwjTqWOfBTlqRyvswFHS3SQQnzl1F5XGYHaX RrwhwOzIkTx23BHq/JLh/BvVB5aAKOZZdDJiZriEBE6db+pXeD/BV1Sje2HCcq7bvRKeLA of0INRlXx1eeF7mfaWh6QpnShqvvzRmWN8SKWXQ5D6M0AWhLr/p1gs9R3dkwyiiE223uEb qzZijf55MPMdrDiHDJzogBOHG7/+owgpBHpwJDZQxkCyRIJVvg26JyhyA6/wwg== 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=1721047092; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=8ehIffab/eLu0H0s69qhVQIjTU6A32tEyHGs9TRkJDY=; b=KgsrKaUQUW4rHPuclnLXR/lXaQQun3ZyhJK7cyirl5jGbaQmqCQz1Ma1JcXXWfSCxTbBDG S5Y8XCdI3BjzPg8t9503DE3ubBfIR5oDChOeIegaLQYb8ZS8cKoKJS86Vhbu3QYOQiwW+z NJMVovvVx/fbIABlZk2OeMJnCTdYONTKTGt08t1ZWyuxt8w5y9NrNcI+cx3QtP9wyyPnUp 32524T7V69vgfbbMNGGV73GjhjDWWDU0fgEx/K12oL7i3Vpw4iqwmGOyM4rzM9jnoQVeG/ XLtOyzKd/ICnpiTiAv69tjRyaMFd+3aOGqeuhosX61+tIhLVCm+XTpumcG7ndg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vS2vJ8zsJL; Mon, 15 Jul 2024 12:38:12 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcC6q060177; Mon, 15 Jul 2024 12:38:12 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcCaU060174; Mon, 15 Jul 2024 12:38:12 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:12 GMT Message-Id: <202407151238.46FCcCaU060174@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 09a830be9485 - stable/14 - arm64: Add MRS_REG_ALT_NAME ID register macros List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 09a830be9485d363cb0a9780e8efbb7e17f7d3f7 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=09a830be9485d363cb0a9780e8efbb7e17f7d3f7 commit 09a830be9485d363cb0a9780e8efbb7e17f7d3f7 Author: Andrew Turner AuthorDate: 2024-05-13 13:58:45 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:25:09 +0000 arm64: Add MRS_REG_ALT_NAME ID register macros These can be used even when the compiler is too old for the register to be included. Reviewed by: Zachary Leaf Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45176 (cherry picked from commit d6d860c7ff5c4cbe9475d98000407d6f0ea84b47) --- sys/arm64/include/armreg.h | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index b2dfd61c3083..503a554df157 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -491,6 +491,7 @@ /* ID_AA64AFR0_EL1 */ #define ID_AA64AFR0_EL1 MRS_REG(ID_AA64AFR0_EL1) +#define ID_AA64AFR0_EL1_REG MRS_REG_ALT_NAME(ID_AA64AFR0_EL1) #define ID_AA64AFR0_EL1_op0 3 #define ID_AA64AFR0_EL1_op1 0 #define ID_AA64AFR0_EL1_CRn 0 @@ -499,6 +500,7 @@ /* ID_AA64AFR1_EL1 */ #define ID_AA64AFR1_EL1 MRS_REG(ID_AA64AFR1_EL1) +#define ID_AA64AFR1_EL1_REG MRS_REG_ALT_NAME(ID_AA64AFR1_EL1) #define ID_AA64AFR1_EL1_op0 3 #define ID_AA64AFR1_EL1_op1 0 #define ID_AA64AFR1_EL1_CRn 0 @@ -507,6 +509,7 @@ /* ID_AA64DFR0_EL1 */ #define ID_AA64DFR0_EL1 MRS_REG(ID_AA64DFR0_EL1) +#define ID_AA64DFR0_EL1_REG MRS_REG_ALT_NAME(ID_AA64DFR0_EL1) #define ID_AA64DFR0_EL1_op0 3 #define ID_AA64DFR0_EL1_op1 0 #define ID_AA64DFR0_EL1_CRn 0 @@ -596,6 +599,7 @@ /* ID_AA64DFR1_EL1 */ #define ID_AA64DFR1_EL1 MRS_REG(ID_AA64DFR1_EL1) +#define ID_AA64DFR1_EL1_REG MRS_REG_ALT_NAME(ID_AA64DFR1_EL1) #define ID_AA64DFR1_EL1_op0 3 #define ID_AA64DFR1_EL1_op1 0 #define ID_AA64DFR1_EL1_CRn 0 @@ -604,6 +608,7 @@ /* ID_AA64ISAR0_EL1 */ #define ID_AA64ISAR0_EL1 MRS_REG(ID_AA64ISAR0_EL1) +#define ID_AA64ISAR0_EL1_REG MRS_REG_ALT_NAME(ID_AA64ISAR0_EL1) #define ID_AA64ISAR0_EL1_op0 3 #define ID_AA64ISAR0_EL1_op1 0 #define ID_AA64ISAR0_EL1_CRn 0 @@ -690,6 +695,7 @@ /* ID_AA64ISAR1_EL1 */ #define ID_AA64ISAR1_EL1 MRS_REG(ID_AA64ISAR1_EL1) +#define ID_AA64ISAR1_EL1_REG MRS_REG_ALT_NAME(ID_AA64ISAR1_EL1) #define ID_AA64ISAR1_EL1_op0 3 #define ID_AA64ISAR1_EL1_op1 0 #define ID_AA64ISAR1_EL1_CRn 0 @@ -791,6 +797,7 @@ /* ID_AA64ISAR2_EL1 */ #define ID_AA64ISAR2_EL1 MRS_REG(ID_AA64ISAR2_EL1) +#define ID_AA64ISAR2_EL1_REG MRS_REG_ALT_NAME(ID_AA64ISAR2_EL1) #define ID_AA64ISAR2_EL1_op0 3 #define ID_AA64ISAR2_EL1_op1 0 #define ID_AA64ISAR2_EL1_CRn 0 @@ -838,6 +845,7 @@ /* ID_AA64MMFR0_EL1 */ #define ID_AA64MMFR0_EL1 MRS_REG(ID_AA64MMFR0_EL1) +#define ID_AA64MMFR0_EL1_REG MRS_REG_ALT_NAME(ID_AA64MMFR0_EL1) #define ID_AA64MMFR0_EL1_op0 3 #define ID_AA64MMFR0_EL1_op1 0 #define ID_AA64MMFR0_EL1_CRn 0 @@ -929,6 +937,7 @@ /* ID_AA64MMFR1_EL1 */ #define ID_AA64MMFR1_EL1 MRS_REG(ID_AA64MMFR1_EL1) +#define ID_AA64MMFR1_EL1_REG MRS_REG_ALT_NAME(ID_AA64MMFR1_EL1) #define ID_AA64MMFR1_EL1_op0 3 #define ID_AA64MMFR1_EL1_op1 0 #define ID_AA64MMFR1_EL1_CRn 0 @@ -1016,6 +1025,7 @@ /* ID_AA64MMFR2_EL1 */ #define ID_AA64MMFR2_EL1 MRS_REG(ID_AA64MMFR2_EL1) +#define ID_AA64MMFR2_EL1_REG MRS_REG_ALT_NAME(ID_AA64MMFR2_EL1) #define ID_AA64MMFR2_EL1_op0 3 #define ID_AA64MMFR2_EL1_op1 0 #define ID_AA64MMFR2_EL1_CRn 0 @@ -1102,6 +1112,7 @@ /* ID_AA64MMFR3_EL1 */ #define ID_AA64MMFR3_EL1 MRS_REG(ID_AA64MMFR3_EL1) +#define ID_AA64MMFR3_EL1_REG MRS_REG_ALT_NAME(ID_AA64MMFR3_EL1) #define ID_AA64MMFR3_EL1_op0 3 #define ID_AA64MMFR3_EL1_op1 0 #define ID_AA64MMFR3_EL1_CRn 0 @@ -1130,6 +1141,7 @@ /* ID_AA64MMFR4_EL1 */ #define ID_AA64MMFR4_EL1 MRS_REG(ID_AA64MMFR4_EL1) +#define ID_AA64MMFR4_EL1_REG MRS_REG_ALT_NAME(ID_AA64MMFR4_EL1) #define ID_AA64MMFR4_EL1_op0 3 #define ID_AA64MMFR4_EL1_op1 0 #define ID_AA64MMFR4_EL1_CRn 0 @@ -1138,6 +1150,7 @@ /* ID_AA64PFR0_EL1 */ #define ID_AA64PFR0_EL1 MRS_REG(ID_AA64PFR0_EL1) +#define ID_AA64PFR0_EL1_REG MRS_REG_ALT_NAME(ID_AA64PFR0_EL1) #define ID_AA64PFR0_EL1_op0 3 #define ID_AA64PFR0_EL1_op1 0 #define ID_AA64PFR0_EL1_CRn 0 @@ -1236,6 +1249,7 @@ /* ID_AA64PFR1_EL1 */ #define ID_AA64PFR1_EL1 MRS_REG(ID_AA64PFR1_EL1) +#define ID_AA64PFR1_EL1_REG MRS_REG_ALT_NAME(ID_AA64PFR1_EL1) #define ID_AA64PFR1_EL1_op0 3 #define ID_AA64PFR1_EL1_op1 0 #define ID_AA64PFR1_EL1_CRn 0 @@ -1294,6 +1308,7 @@ /* ID_AA64PFR2_EL1 */ #define ID_AA64PFR2_EL1 MRS_REG(ID_AA64PFR2_EL1) +#define ID_AA64PFR2_EL1_REG MRS_REG_ALT_NAME(ID_AA64PFR2_EL1) #define ID_AA64PFR2_EL1_op0 3 #define ID_AA64PFR2_EL1_op1 0 #define ID_AA64PFR2_EL1_CRn 0 From nobody Mon Jul 15 12:38:13 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vV0Kflz5Qrch; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vT4K8rz4HLR; Mon, 15 Jul 2024 12:38:13 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047093; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=3NnOGwEpyyOhPXXihi8xassNxUEbG+Sz08Z7ExRl+eA=; b=ntZQfwLjfAmRTv5u8fI89eFhz/vp5IFfg8hpAesnxqz4tD0N040R9uZBfBOSlWzyWmeIsq m7WGLZBnpQfwqApCVAgtkl/eDPLCq0CyFgnSasGe7bGyeTK2t8qJ9mEA1p9lrtVhAivG4M yAU5dAWT49BQeY5iibAGRggQMXIHA9rnykMduSH7akQWAhzP/Xj0T/MJOmF30j80OqCGPc 7GhuVvsU+6SR6MRDAEBRtB6Go8a/UI0hG4Nc0/EWyxGZsKtQM2fHoTvcacycTHOr4jdAHO Uz2qI6eYpzv9YtuMNF6rVOetRqojx493nRtoZSKwj0Fx2HmVeRnKckcFnXW/IQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047093; a=rsa-sha256; cv=none; b=EWU0vUAjVxaBTepJewE7oCo+waR5co7oKb87NbpK6sFVIqDmtYtOYrPxZmoAc0826NVyav SMmEIA50YQxa1FD2bY6vobUw0aafBgo1jo/XrqKeYvwF1cUukShyGjzShMzxld1I9sO8qI 5WjsZYidml6YJl0v2U4spEoAdnq2Swqzkq/5WYj2Bp7IWHcQJgLJAINk4Zm2jAf6s4Nl+c g7dVSSHhwikqcCUojRYAoJ+5mrsLFn3XQGfqDMrgfQTRo3L6yESYUB/Fn1EdlF8KRRiYB/ lNSJN21SeysGAxAcKc7+tuRyJcNGiF4ybfCasTkn+8r7u01PzaJMcIc9bjdEXg== 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=1721047093; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=3NnOGwEpyyOhPXXihi8xassNxUEbG+Sz08Z7ExRl+eA=; b=vDYg4ThFvhstbjO++zwLxZbziK/6kdp3sRZoQooOul/gNJTwnkCNIn6PRpF4OtLaUomEL2 Os71zXt/iQAukGNZUGWTHXvc2+mG0cMZ4PzDAUEVBpkzMVD/y1CnxhI0C6mBudwqksOzJf RZTGxLdBaDp2lzxVb48fAaIu7PENa4CEzEV5KN21Ie3JPrPthlflz7QUnmtPwlVgy1Rb6Y ZALgRHpkdPRNE8d++4pVg97+WpYFedwhbS+iXzgPCq6C8fPPHk3skZ7apr2ZRf2nUNomMm 6HPBvFS226c3PSZMhWAe5E+dK6U1yaESDGhvGF7PxMx3qorpvInfzplvPH/1jg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vT3tzdzsck; Mon, 15 Jul 2024 12:38:13 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcDHI060267; Mon, 15 Jul 2024 12:38:13 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcD3N060264; Mon, 15 Jul 2024 12:38:13 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:13 GMT Message-Id: <202407151238.46FCcD3N060264@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: dd701489c80c - stable/14 - arm64: Use the _REG macros to read ID registers List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: dd701489c80ce318bfc6076cf8fa0e774002e618 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=dd701489c80ce318bfc6076cf8fa0e774002e618 commit dd701489c80ce318bfc6076cf8fa0e774002e618 Author: Andrew Turner AuthorDate: 2024-05-13 14:48:25 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:25:20 +0000 arm64: Use the _REG macros to read ID registers To build with old toolchains use the *_REG macros to access the ID registers. These become a name in the form S?_?_C?_C?_? where the '?' values encode the op and CR values needed to access the register. For consistency use these macros for all ID registers, even if most toolchains understand them. Reviewed by: Zachary Leaf Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45177 (cherry picked from commit cd36810110017ad5882784a7842cfdf9c92ef098) --- sys/arm64/arm64/identcpu.c | 46 +++++++++++++--------------------------------- 1 file changed, 13 insertions(+), 33 deletions(-) diff --git a/sys/arm64/arm64/identcpu.c b/sys/arm64/arm64/identcpu.c index 8ecb4926c198..cc2c95d7cfb6 100644 --- a/sys/arm64/arm64/identcpu.c +++ b/sys/arm64/arm64/identcpu.c @@ -139,15 +139,11 @@ struct cpu_desc { uint64_t id_aa64mmfr0; uint64_t id_aa64mmfr1; uint64_t id_aa64mmfr2; -#ifdef NOTYET uint64_t id_aa64mmfr3; uint64_t id_aa64mmfr4; -#endif uint64_t id_aa64pfr0; uint64_t id_aa64pfr1; -#ifdef NOTYET uint64_t id_aa64pfr2; -#endif uint64_t id_aa64zfr0; uint64_t ctr; #ifdef COMPAT_FREEBSD32 @@ -1298,7 +1294,6 @@ static const struct mrs_field id_aa64mmfr2_fields[] = { }; -#ifdef NOTYET /* ID_AA64MMFR2_EL1 */ static const struct mrs_field_value id_aa64mmfr3_spec_fpacc[] = { MRS_FIELD_VALUE_NONE_IMPL(ID_AA64MMFR3, Spec_FPACC, NONE, IMPL), @@ -1334,7 +1329,6 @@ static const struct mrs_field id_aa64mmfr3_fields[] = { static const struct mrs_field id_aa64mmfr4_fields[] = { MRS_FIELD_END, }; -#endif /* ID_AA64PFR0_EL1 */ @@ -1575,12 +1569,10 @@ static const struct mrs_field id_aa64pfr1_fields[] = { }; -#ifdef NOTYET /* ID_AA64PFR2_EL1 */ static const struct mrs_field id_aa64pfr2_fields[] = { MRS_FIELD_END, }; -#endif /* ID_AA64ZFR0_EL1 */ @@ -1883,16 +1875,12 @@ static const struct mrs_user_reg user_regs[] = { USER_REG(ID_AA64MMFR0_EL1, id_aa64mmfr0, true), USER_REG(ID_AA64MMFR1_EL1, id_aa64mmfr1, true), USER_REG(ID_AA64MMFR2_EL1, id_aa64mmfr2, true), -#ifdef NOTYET USER_REG(ID_AA64MMFR3_EL1, id_aa64mmfr3, true), USER_REG(ID_AA64MMFR4_EL1, id_aa64mmfr4, true), -#endif USER_REG(ID_AA64PFR0_EL1, id_aa64pfr0, true), USER_REG(ID_AA64PFR1_EL1, id_aa64pfr1, true), -#ifdef NOTYET USER_REG(ID_AA64PFR2_EL1, id_aa64pfr2, true), -#endif USER_REG(ID_AA64ZFR0_EL1, id_aa64zfr0, true), @@ -2672,12 +2660,10 @@ print_cpu_features(u_int cpu, struct cpu_desc *desc, print_id_register(sb, "Processor Features 1", desc->id_aa64pfr1, id_aa64pfr1_fields); -#ifdef NOTYET /* AArch64 Processor Feature Register 2 */ if (SHOULD_PRINT_REG(id_aa64pfr2)) print_id_register(sb, "Processor Features 2", desc->id_aa64pfr2, id_aa64pfr2_fields); -#endif /* AArch64 Memory Model Feature Register 0 */ if (SHOULD_PRINT_REG(id_aa64mmfr0)) @@ -2694,7 +2680,6 @@ print_cpu_features(u_int cpu, struct cpu_desc *desc, print_id_register(sb, "Memory Model Features 2", desc->id_aa64mmfr2, id_aa64mmfr2_fields); -#ifdef NOTYET /* AArch64 Memory Model Feature Register 3 */ if (SHOULD_PRINT_REG(id_aa64mmfr3)) print_id_register(sb, "Memory Model Features 3", @@ -2704,7 +2689,6 @@ print_cpu_features(u_int cpu, struct cpu_desc *desc, if (SHOULD_PRINT_REG(id_aa64mmfr4)) print_id_register(sb, "Memory Model Features 4", desc->id_aa64mmfr4, id_aa64mmfr4_fields); -#endif /* AArch64 Debug Feature Register 0 */ if (SHOULD_PRINT_REG(id_aa64dfr0)) @@ -2812,23 +2796,19 @@ identify_cpu(u_int cpu) CPU_AFFINITY(cpu) = desc->mpidr & CPU_AFF_MASK; desc->ctr = READ_SPECIALREG(ctr_el0); - desc->id_aa64dfr0 = READ_SPECIALREG(id_aa64dfr0_el1); - desc->id_aa64dfr1 = READ_SPECIALREG(id_aa64dfr1_el1); - desc->id_aa64isar0 = READ_SPECIALREG(id_aa64isar0_el1); - desc->id_aa64isar1 = READ_SPECIALREG(id_aa64isar1_el1); - desc->id_aa64isar2 = READ_SPECIALREG(id_aa64isar2_el1); - desc->id_aa64mmfr0 = READ_SPECIALREG(id_aa64mmfr0_el1); - desc->id_aa64mmfr1 = READ_SPECIALREG(id_aa64mmfr1_el1); - desc->id_aa64mmfr2 = READ_SPECIALREG(id_aa64mmfr2_el1); -#ifdef NOTYET - desc->id_aa64mmfr3 = READ_SPECIALREG(id_aa64mmfr3_el1); - desc->id_aa64mmfr4 = READ_SPECIALREG(id_aa64mmfr4_el1); -#endif - desc->id_aa64pfr0 = READ_SPECIALREG(id_aa64pfr0_el1); - desc->id_aa64pfr1 = READ_SPECIALREG(id_aa64pfr1_el1); -#ifdef NOTYET - desc->id_aa64pfr2 = READ_SPECIALREG(id_aa64pfr2_el1); -#endif + desc->id_aa64dfr0 = READ_SPECIALREG(ID_AA64DFR0_EL1_REG); + desc->id_aa64dfr1 = READ_SPECIALREG(ID_AA64DFR1_EL1_REG); + desc->id_aa64isar0 = READ_SPECIALREG(ID_AA64ISAR0_EL1_REG); + desc->id_aa64isar1 = READ_SPECIALREG(ID_AA64ISAR1_EL1_REG); + desc->id_aa64isar2 = READ_SPECIALREG(ID_AA64ISAR2_EL1_REG); + desc->id_aa64mmfr0 = READ_SPECIALREG(ID_AA64MMFR0_EL1_REG); + desc->id_aa64mmfr1 = READ_SPECIALREG(ID_AA64MMFR1_EL1_REG); + desc->id_aa64mmfr2 = READ_SPECIALREG(ID_AA64MMFR2_EL1_REG); + desc->id_aa64mmfr3 = READ_SPECIALREG(ID_AA64MMFR3_EL1_REG); + desc->id_aa64mmfr4 = READ_SPECIALREG(ID_AA64MMFR4_EL1_REG); + desc->id_aa64pfr0 = READ_SPECIALREG(ID_AA64PFR0_EL1_REG); + desc->id_aa64pfr1 = READ_SPECIALREG(ID_AA64PFR1_EL1_REG); + desc->id_aa64pfr2 = READ_SPECIALREG(ID_AA64PFR2_EL1_REG); /* * ID_AA64ZFR0_EL1 is only valid when at least one of: From nobody Mon Jul 15 12:38:12 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vT2fMJz5QrVj; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vT07sgz4HNM; Mon, 15 Jul 2024 12:38:12 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047093; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=OABmotqt7gKPHXm92LTW+E39e+UOAZPLrJ8UY4em9oM=; b=RciT5pUbBemvUXgyOiirnOKWDPsddagrRcrCSeTVKF1mIrazp4rsHjww1eCT8SxH9Dp/Ya z84ZEFhwv2tXx/YZesNPvcGQOitRM9oN21h/V0bcTwv6NT+sDGgBHg0Ok2Q0OiADGi9TE7 5hvBOcubM4mFAZsCmS9ebV3lUye+t41oHs4JOnlOaSbeE22slNidsG72z2HHtCJiNhsGaK //FdaQ0wJ/l15+0JT6eqKI+wdHlrvw2q58z+6T1GCl0eFhlb8wD2aTw5ZiTHDUePag0rgI T1xV+uUUPldbm9W5MNWxjwH0y0AwsB6VqMW66sjMsjkSVgjX3aXiH/6gfprAJA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047093; a=rsa-sha256; cv=none; b=yFLl4iCObwtUGsVd6WUQ47pZU+y9wo4e8195laTP/cDfSQ8oPAwHSS+z/U/dfOwl1NOAsk M5PYxO4R9/j994WpZM3sIg6hEpUta7cqQzv34ZJon9AVcrfgiAVE1RV4iea26T/rKSjdhW 3/y6X5IZ6CraGgpD/GBMrhO+lBj2M5h5TwF7X03xa3F/yRdNWSx5AGRmerlvR9vufv9+RX EJ1X7J02pKnUFPYfW60BMnH/rfvJhhvFKvz4VmzDV2z2noFhRWTYki5nDc6V++LmTq7Vkm tOTpdlE+Xbgab2oxEHIL74GcHlfDulscault/YwWK0BGXhf3JzdHiA2dLHquDA== 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=1721047093; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=OABmotqt7gKPHXm92LTW+E39e+UOAZPLrJ8UY4em9oM=; b=SOzzcyaHxjHU9FU16ncSvAPKsqrO0Fvhsp0wbIbzS25eNCVXg44w738ufzeXwhEpq7lHR6 rt7PSoLDtIGbWDqeuTYH7R2yKl99EV2toQ5M/DX29rwdX0YIbOGhzYJGHUQy+Rg5bxWeqN lORA6BUoARC8sec3LVGy0jLQHjLi6nSsdJGXINzWbK14Tq1LvzRgbpyMfPiMzo2u1Nlwjw tOjsuXmL8L/PUbzWOF9XAMzhUyrFVDLWG7cj97aeDG2sQS2Htsl7FuSv1VLCjr1Ky6CN5F 1zdt/ZJgENdCAhl/+O9k1pK43d5c25Egk3/v9TneIPKSKnsqHftFH3x1/Ks8jQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vS5xTWzsJM; Mon, 15 Jul 2024 12:38:12 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcCXM060213; Mon, 15 Jul 2024 12:38:12 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcCoc060210; Mon, 15 Jul 2024 12:38:12 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:12 GMT Message-Id: <202407151238.46FCcCoc060210@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 449ba445507e - stable/13 - elf_common.h: Add STO_AARCH64_VARIANT_PCS List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 449ba445507ed45428a06f579de98e94f7257c23 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=449ba445507ed45428a06f579de98e94f7257c23 commit 449ba445507ed45428a06f579de98e94f7257c23 Author: Andrew Turner AuthorDate: 2024-04-17 13:18:24 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:28 +0000 elf_common.h: Add STO_AARCH64_VARIANT_PCS This is used to mark symbols that use a variant procedure call with a different calling convention to the main ABI. Reviewed by: kib, imp Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D44868 (cherry picked from commit d7ac42676dc403cd31d4a6c9a91a2ed5680cca86) --- sys/sys/elf_common.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sys/sys/elf_common.h b/sys/sys/elf_common.h index 4af241bb085c..fa85396b02df 100644 --- a/sys/sys/elf_common.h +++ b/sys/sys/elf_common.h @@ -881,6 +881,9 @@ typedef struct { #define STV_SINGLETON 0x5 #define STV_ELIMINATE 0x6 +/* Architecture specific data - st_other */ +#define STO_AARCH64_VARIANT_PCS 0x80 + /* Special symbol table indexes. */ #define STN_UNDEF 0 /* Undefined symbol index. */ From nobody Mon Jul 15 12:38:14 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vV6tGgz5QrXf; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vV4mLlz4HRL; Mon, 15 Jul 2024 12:38:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047094; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=5ILtkRyuSE0gJ7AdCI179sAHUbgSmtEeLXh9ilIj4uE=; b=kYAoPxctqhBFKsqTVp7QyHPVDak9yY94AxqcpVt4t4VTDZ/rg4gN9t0aL0h2KgVewKygCQ SF7fGr5WPuu5dVDWYim+TRJ7iLW2zsRcLDt1WbVy29LHRf8r5Q//G585zGMbDmsrKcri24 B30ygFeduiyrP5D0ZYSzLQN5hOC+7Sjiet8bOz9RUIkaDMF7x0+Zg2uUUCaoOh0bKwDO0g wiGtGLz0EnVXsQ2uUYQpzJZcAHnQ+D1WYaVIqhAu75ZUeXS1M/FZldGhQ9zPdFMnLnTkEX aOXyQBqUcgTVkA/z+RpdxUyOuwGSUdzU+KrYXQscbwPKaB+aw3plz8ZPFuVyRQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047094; a=rsa-sha256; cv=none; b=J0TNI6IGvHGq59Ej4NhG3vdvwm5c2w5QD45FM+hqt5i7vjf5TjIeZUm0AOZidLyg1aJ3/8 wI5jS1uPl2POOUcYkZuFjJL1uz5uHIepMV4843KDmplsvAnZAhs/g80K9/hLX99riXPxpQ R6lnHgU7ShD7lx3ex18sf5dY3JM7aglIXbezq7hMYUUWUIKGsHZuhKyRpAiT1EmEwnKfy1 QBGIrMQ854+2WxJgc7LUHl08tRwMRvZn/nOWPLdJOz9Moz6+4cTv76NhfvbhHrdfysjMPn srrYBn3psLzzhp+yLfu06s2RZxq+971lMa3Qyw6mKrCFqzfvrXg7vPR4Lvk4Mw== 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=1721047094; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=5ILtkRyuSE0gJ7AdCI179sAHUbgSmtEeLXh9ilIj4uE=; b=jfr+JPkJtHPNmR7Cq9Yzh7PxbvoV6DdTURkvQ1LziTe0kO307qlSHffSPANlL7YYrXSHsp g2l2e4FKrADRCQUXDpi+tTsRqXht8yIL+Y1Hyl0/+xuXStlQ6EflgKAifsJnFnBKoa3xRb 6M1WuYsWhXorx/kUGvVxMRp6pcCYYHGWuF9oqcaETcMv15s8BgMGoL0j+YnZzx7AYDxzyw maDLRsjb62LO5L49Njc1A1rfvjO1FvH1QnoMMW8ACNHX17pp7G51CUeAvAl77EuZsh9gdr Okfj4y5ErF61wRNzVmQThV0HoqqT0LZRhIDg8QnZDRjOK6I7ZCz+EV5lPk5pXg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vV4NhYzsM1; Mon, 15 Jul 2024 12:38:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcEBt060366; Mon, 15 Jul 2024 12:38:14 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcE4k060363; Mon, 15 Jul 2024 12:38:14 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:14 GMT Message-Id: <202407151238.46FCcE4k060363@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: d8a9e188f279 - stable/14 - arm64: make SPE regs use ALT_NAME macro List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: d8a9e188f2797c0cc4c20633d660aa613cb7c405 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=d8a9e188f2797c0cc4c20633d660aa613cb7c405 commit d8a9e188f2797c0cc4c20633d660aa613cb7c405 Author: Zachary Leaf AuthorDate: 2024-05-10 15:59:00 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:25:33 +0000 arm64: make SPE regs use ALT_NAME macro When the register is not defined in Armv8.0 i.e. added in a later extension, like SPE added in v8.2, the alternative name format of: S__C_C_ should be used; otherwise, calls to {READ,WRITE}_SPECIALREG() will fail. Use the MRS_REG_ALT_NAME() macro for SPE changing hex to decimal as required by the macro. Reviewed by: andrew Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45171 (cherry picked from commit f7bdaa103eb8906fc999c7fd5e8d6af440e26e6c) --- sys/arm64/include/armreg.h | 132 ++++++++++++++++++++++++--------------------- 1 file changed, 72 insertions(+), 60 deletions(-) diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index 503a554df157..ca281e800437 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -1636,11 +1636,12 @@ /* PMBIDR_EL1 */ #define PMBIDR_EL1 MRS_REG(PMBIDR_EL1) -#define PMBIDR_EL1_op0 0x3 -#define PMBIDR_EL1_op1 0x0 -#define PMBIDR_EL1_CRn 0x9 -#define PMBIDR_EL1_CRm 0xa -#define PMBIDR_EL1_op2 0x7 +#define PMBIDR_EL1_REG MRS_REG_ALT_NAME(PMBIDR_EL1) +#define PMBIDR_EL1_op0 3 +#define PMBIDR_EL1_op1 0 +#define PMBIDR_EL1_CRn 9 +#define PMBIDR_EL1_CRm 10 +#define PMBIDR_EL1_op2 7 #define PMBIDR_Align_SHIFT 0 #define PMBIDR_Align_MASK (UL(0xf) << PMBIDR_Align_SHIFT) #define PMBIDR_P_SHIFT 4 @@ -1650,11 +1651,12 @@ /* PMBLIMITR_EL1 */ #define PMBLIMITR_EL1 MRS_REG(PMBLIMITR_EL1) -#define PMBLIMITR_EL1_op0 0x3 -#define PMBLIMITR_EL1_op1 0x0 -#define PMBLIMITR_EL1_CRn 0x9 -#define PMBLIMITR_EL1_CRm 0xa -#define PMBLIMITR_EL1_op2 0x0 +#define PMBLIMITR_EL1_REG MRS_REG_ALT_NAME(PMBLIMITR_EL1) +#define PMBLIMITR_EL1_op0 3 +#define PMBLIMITR_EL1_op1 0 +#define PMBLIMITR_EL1_CRn 9 +#define PMBLIMITR_EL1_CRm 10 +#define PMBLIMITR_EL1_op2 0 #define PMBLIMITR_E_SHIFT 0 #define PMBLIMITR_E (UL(0x1) << PMBLIMITR_E_SHIFT) #define PMBLIMITR_FM_SHIFT 1 @@ -1667,22 +1669,24 @@ /* PMBPTR_EL1 */ #define PMBPTR_EL1 MRS_REG(PMBPTR_EL1) -#define PMBPTR_EL1_op0 0x3 -#define PMBPTR_EL1_op1 0x0 -#define PMBPTR_EL1_CRn 0x9 -#define PMBPTR_EL1_CRm 0xa -#define PMBPTR_EL1_op2 0x1 +#define PMBPTR_EL1_REG MRS_REG_ALT_NAME(PMBPTR_EL1) +#define PMBPTR_EL1_op0 3 +#define PMBPTR_EL1_op1 0 +#define PMBPTR_EL1_CRn 9 +#define PMBPTR_EL1_CRm 10 +#define PMBPTR_EL1_op2 1 #define PMBPTR_PTR_SHIFT 0 #define PMBPTR_PTR_MASK \ (UL(0xffffffffffffffff) << PMBPTR_PTR_SHIFT) /* PMBSR_EL1 */ #define PMBSR_EL1 MRS_REG(PMBSR_EL1) -#define PMBSR_EL1_op0 0x3 -#define PMBSR_EL1_op1 0x0 -#define PMBSR_EL1_CRn 0x9 -#define PMBSR_EL1_CRm 0xa -#define PMBSR_EL1_op2 0x3 +#define PMBSR_EL1_REG MRS_REG_ALT_NAME(PMBSR_EL1) +#define PMBSR_EL1_op0 3 +#define PMBSR_EL1_op1 0 +#define PMBSR_EL1_CRn 9 +#define PMBSR_EL1_CRm 10 +#define PMBSR_EL1_op2 3 #define PMBSR_MSS_SHIFT 0 #define PMBSR_MSS_MASK (UL(0xffff) << PMBSR_MSS_SHIFT) #define PMBSR_COLL_SHIFT 16 @@ -1848,11 +1852,12 @@ /* PMSCR_EL1 */ #define PMSCR_EL1 MRS_REG(PMSCR_EL1) -#define PMSCR_EL1_op0 0x3 -#define PMSCR_EL1_op1 0x0 -#define PMSCR_EL1_CRn 0x9 -#define PMSCR_EL1_CRm 0x9 -#define PMSCR_EL1_op2 0x0 +#define PMSCR_EL1_REG MRS_REG_ALT_NAME(PMSCR_EL1) +#define PMSCR_EL1_op0 3 +#define PMSCR_EL1_op1 0 +#define PMSCR_EL1_CRn 9 +#define PMSCR_EL1_CRm 9 +#define PMSCR_EL1_op2 0 #define PMSCR_E0SPE_SHIFT 0 #define PMSCR_E0SPE (UL(0x1) << PMSCR_E0SPE_SHIFT) #define PMSCR_E1SPE_SHIFT 1 @@ -1877,19 +1882,21 @@ /* PMSEVFR_EL1 */ #define PMSEVFR_EL1 MRS_REG(PMSEVFR_EL1) -#define PMSEVFR_EL1_op0 0x3 -#define PMSEVFR_EL1_op1 0x0 -#define PMSEVFR_EL1_CRn 0x9 -#define PMSEVFR_EL1_CRm 0x9 -#define PMSEVFR_EL1_op2 0x5 +#define PMSEVFR_EL1_REG MRS_REG_ALT_NAME(PMSEVFR_EL1) +#define PMSEVFR_EL1_op0 3 +#define PMSEVFR_EL1_op1 0 +#define PMSEVFR_EL1_CRn 9 +#define PMSEVFR_EL1_CRm 9 +#define PMSEVFR_EL1_op2 5 /* PMSFCR_EL1 */ #define PMSFCR_EL1 MRS_REG(PMSFCR_EL1) -#define PMSFCR_EL1_op0 0x3 -#define PMSFCR_EL1_op1 0x0 -#define PMSFCR_EL1_CRn 0x9 -#define PMSFCR_EL1_CRm 0x9 -#define PMSFCR_EL1_op2 0x4 +#define PMSFCR_EL1_REG MRS_REG_ALT_NAME(PMSFCR_EL1) +#define PMSFCR_EL1_op0 3 +#define PMSFCR_EL1_op1 0 +#define PMSFCR_EL1_CRn 9 +#define PMSFCR_EL1_CRm 9 +#define PMSFCR_EL1_op2 4 #define PMSFCR_FE_SHIFT 0 #define PMSFCR_FE (UL(0x1) << PMSFCR_FE_SHIFT) #define PMSFCR_FT_SHIFT 1 @@ -1907,11 +1914,12 @@ /* PMSICR_EL1 */ #define PMSICR_EL1 MRS_REG(PMSICR_EL1) -#define PMSICR_EL1_op0 0x3 -#define PMSICR_EL1_op1 0x0 -#define PMSICR_EL1_CRn 0x9 -#define PMSICR_EL1_CRm 0x9 -#define PMSICR_EL1_op2 0x2 +#define PMSICR_EL1_REG MRS_REG_ALT_NAME(PMSICR_EL1) +#define PMSICR_EL1_op0 3 +#define PMSICR_EL1_op1 0 +#define PMSICR_EL1_CRn 9 +#define PMSICR_EL1_CRm 9 +#define PMSICR_EL1_op2 2 #define PMSICR_COUNT_SHIFT 0 #define PMSICR_COUNT_MASK (UL(0xffffffff) << PMSICR_COUNT_SHIFT) #define PMSICR_ECOUNT_SHIFT 56 @@ -1919,11 +1927,12 @@ /* PMSIDR_EL1 */ #define PMSIDR_EL1 MRS_REG(PMSIDR_EL1) -#define PMSIDR_EL1_op0 0x3 -#define PMSIDR_EL1_op1 0x0 -#define PMSIDR_EL1_CRn 0x9 -#define PMSIDR_EL1_CRm 0x9 -#define PMSIDR_EL1_op2 0x7 +#define PMSIDR_EL1_REG MRS_REG_ALT_NAME(PMSIDR_EL1) +#define PMSIDR_EL1_op0 3 +#define PMSIDR_EL1_op1 0 +#define PMSIDR_EL1_CRn 9 +#define PMSIDR_EL1_CRm 9 +#define PMSIDR_EL1_op2 7 #define PMSIDR_FE_SHIFT 0 #define PMSIDR_FE (UL(0x1) << PMSIDR_FE_SHIFT) #define PMSIDR_FT_SHIFT 1 @@ -1951,11 +1960,12 @@ /* PMSIRR_EL1 */ #define PMSIRR_EL1 MRS_REG(PMSIRR_EL1) -#define PMSIRR_EL1_op0 0x3 -#define PMSIRR_EL1_op1 0x0 -#define PMSIRR_EL1_CRn 0x9 -#define PMSIRR_EL1_CRm 0x9 -#define PMSIRR_EL1_op2 0x3 +#define PMSIRR_EL1_REG MRS_REG_ALT_NAME(PMSIRR_EL1) +#define PMSIRR_EL1_op0 3 +#define PMSIRR_EL1_op1 0 +#define PMSIRR_EL1_CRn 9 +#define PMSIRR_EL1_CRm 9 +#define PMSIRR_EL1_op2 3 #define PMSIRR_RND_SHIFT 0 #define PMSIRR_RND (UL(0x1) << PMSIRR_RND_SHIFT) #define PMSIRR_INTERVAL_SHIFT 8 @@ -1963,21 +1973,23 @@ /* PMSLATFR_EL1 */ #define PMSLATFR_EL1 MRS_REG(PMSLATFR_EL1) -#define PMSLATFR_EL1_op0 0x3 -#define PMSLATFR_EL1_op1 0x0 -#define PMSLATFR_EL1_CRn 0x9 -#define PMSLATFR_EL1_CRm 0x9 -#define PMSLATFR_EL1_op2 0x6 +#define PMSLATFR_EL1_REG MRS_REG_ALT_NAME(PMSLATFR_EL1) +#define PMSLATFR_EL1_op0 3 +#define PMSLATFR_EL1_op1 0 +#define PMSLATFR_EL1_CRn 9 +#define PMSLATFR_EL1_CRm 9 +#define PMSLATFR_EL1_op2 6 #define PMSLATFR_MINLAT_SHIFT 0 #define PMSLATFR_MINLAT_MASK (UL(0xfff) << PMSLATFR_MINLAT_SHIFT) /* PMSNEVFR_EL1 */ #define PMSNEVFR_EL1 MRS_REG(PMSNEVFR_EL1) -#define PMSNEVFR_EL1_op0 0x3 -#define PMSNEVFR_EL1_op1 0x0 -#define PMSNEVFR_EL1_CRn 0x9 -#define PMSNEVFR_EL1_CRm 0x9 -#define PMSNEVFR_EL1_op2 0x1 +#define PMSNEVFR_EL1_REG MRS_REG_ALT_NAME(PMSNEVFR_EL1) +#define PMSNEVFR_EL1_op0 3 +#define PMSNEVFR_EL1_op1 0 +#define PMSNEVFR_EL1_CRn 9 +#define PMSNEVFR_EL1_CRm 9 +#define PMSNEVFR_EL1_op2 1 /* PMSWINC_EL0 */ #define PMSWINC_EL0 MRS_REG(PMSWINC_EL0) From nobody Mon Jul 15 12:38:15 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vW4Hvnz5QrXh; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vW19Bdz4H6Z; Mon, 15 Jul 2024 12:38:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047095; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=9OKXgLjwBEC+HuiB3qV8jrHct7S/qtePc2GLZTb278M=; b=XjStve0IQrQXtEdfj1KfZ8bv5ERj+eQG0AY5S4uREqU5Q0gnoRPctsC9PtgtY/cP1i00BO CkEywwY5Xi9ZEfHYTrxHyAzID9gMPrdXKF/mOEAcBQ9U3W3WMH+NB/MdrguPyq7A08lmOw HuC8Z3gox4QYv58PgOmrxNs29LMe6IO31KDJ2+aF6rIB81FZ96KJeN/1qF6C226LCrSyB/ hC8cF3ERODkIA5rBAbd1oE83rZBHD4LqLSZNsY2LH5ZyfyNpFg6wQMo5Y07kQqX0gh4sEP GDSqiP1pgnkrLv3RRQp2mqYgCJOEEN0Ul2Ci1c6+8KtdGZst0L1nYWJyN6/3Ag== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047095; a=rsa-sha256; cv=none; b=umbOj57ZuQAXCRZ0tb2qx8ykL9dRXav+GWya1t+/lezrMDr/KUv2KiMAAjK9uvXMU2NxyB ewDQtR9PxUSlLBh7mH2rj5EDUbtoUrsU6+Gj1bqcHDW1x8JBUVclcvjtTqsu5OpOKhJOu3 38joecUTXucoqh60ILSv8d9QcmclAXQogUlwID8sPw2lhfiNtitTSOUl4ZG+x86+y0Yl3g MhLg0nx+sgIzcr6LlTL2c3q/yvdRt4GS/7KZVNcBrvtK9Fnf8hOFhVTXvZZzr0JbfUd7cW XDVZHbp+ofX6YhqKymVmuTo9GwZwe+FLLAMxCZ5iAS+MdUzxtlLEOAo7GvkGpg== 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=1721047095; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=9OKXgLjwBEC+HuiB3qV8jrHct7S/qtePc2GLZTb278M=; b=Zr7p+YVEdgeAC498Jsb0zNuNYhuykLiGm9KI/3LiHWgj4zmKEopzexfXAwtvNQkurCFE+w ViJLiwVsBwh0C+yoXmn4DETPkrAtAtOCxGvHAuND3JC2551UILBllALfkDBLGUlKX6EKxq FkLBh95NUDUUlS21n5hhtx5ztAMtum2K2YSnbqT3zD+IFr9eBs09LKDGwqSc0V4cCEoPqX SfTIW42AeESXW1MHVtMeeRlIGux9EUd4tCGy+0Ct1Jh/kddiujywoAxIYENsKj83VjG1ja Rm3Pu59o2oWN4UE0ydLzTkOkQ8/ym8eRRcpsO/OYqfytOYKjCYQ0V8IYzXMLLw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vW0nmmzscl; Mon, 15 Jul 2024 12:38:15 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcFfl060408; Mon, 15 Jul 2024 12:38:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcFhp060405; Mon, 15 Jul 2024 12:38:15 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:15 GMT Message-Id: <202407151238.46FCcFhp060405@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 1320b22f49b2 - stable/13 - dev/psci: Check all compat strings List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 1320b22f49b2385dc12505a93c3e2e34071d4eae Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=1320b22f49b2385dc12505a93c3e2e34071d4eae commit 1320b22f49b2385dc12505a93c3e2e34071d4eae Author: Andrew Turner AuthorDate: 2024-04-23 11:27:09 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:29 +0000 dev/psci: Check all compat strings When searching for the PSCI FDT node we only check a few compat strings. Use the existing compat_data array to check all strings the driver may attach to. Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D44913 (cherry picked from commit f91e9401c2098ba56f43093ef9747d0b1f60f8eb) --- sys/dev/psci/psci.c | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/sys/dev/psci/psci.c b/sys/dev/psci/psci.c index a656a1365067..da0a5f2edb16 100644 --- a/sys/dev/psci/psci.c +++ b/sys/dev/psci/psci.c @@ -382,12 +382,18 @@ psci_fdt_callfn(psci_callfn_t *callfn) { phandle_t node; - node = ofw_bus_find_compatible(OF_peer(0), "arm,psci-0.2"); - if (node == 0) { - node = ofw_bus_find_compatible(OF_peer(0), "arm,psci-1.0"); - if (node == 0) - return (PSCI_MISSING); + /* XXX: This is suboptimal, we should walk the tree & check each + * node against compat_data, but we only have a few entries so + * it's ok for now. + */ + for (int i = 0; compat_data[i].ocd_str != NULL; i++) { + node = ofw_bus_find_compatible(OF_peer(0), + compat_data[i].ocd_str); + if (node != 0) + break; } + if (node == 0) + return (PSCI_MISSING); *callfn = psci_fdt_get_callfn(node); return (0); From nobody Mon Jul 15 12:38:13 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vV2FRxz5QrVt; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vV0Bpfz4H6R; Mon, 15 Jul 2024 12:38:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047094; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=tKJCwqE3QXSYPWXXivmEgsyfvBZNV2Mq5pTJPRWRtf4=; b=s0RjbuQAgGNJx/T9TSbxsiGFoQyQqE8Soep/00gm3omrzjSmGce2uzoDmcAlbwXCS+Ktqe B9bfuR2bHc8l/lGXYqdnJY54LADqwF6IffHTwzk6hBZgFLxwizqSup1znJR/Aq5JIFVF8c u4ER9w6m2e8FuQGCJ7SQIoaSR6MFfArhBJvx2piqlgtAcahtpAgkBoVdQ6DNJWd2O4Y9Su EfLnl/BT6/RaIPFj3DL53dMK2+QJRHFUd3CpPUL+GfRos7Vd5gFZb1FvoN3LmBKre/VVjq oZHNnoXKv42TfcV4TArZsmc4bxk6yKoPFoy7aV6+bpHbEuSRmczf3Yb0rHsE1Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047094; a=rsa-sha256; cv=none; b=OFKd3yHhH8umo5WfdNwOOtQAc9y7ZCW30yBuO30M/z6doism+KBOkBXv6Zs7M87bVDu8Bn isoTF6LHxYnhOk01HWQrx8Gh6rl8ciniG5XP/1AmBRGaqMrf59g/gCw/aZgpKOoX5HiRgz Yi33c8FhMP3fGeRODDNT3cSX5nD1TsQKRNEFQ+l9c8hQ2BxH8wgwgOMjtWAbHi9gFn93iH trGs6a59dxHRvin5z8DzmgNkzSNkJklgqb23cTYrUyizXYxRw5oqHki+yPzFcqkQF8LsFm F2SV0jbBJek4lbldZgpQ2glM1pnX75rYO1qoP3KUL+R8gFQSqpCMu+pneUji5g== 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=1721047094; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=tKJCwqE3QXSYPWXXivmEgsyfvBZNV2Mq5pTJPRWRtf4=; b=iwG+QwdRsuHvCQl7HmOItNPlh2YaokByYx51a0ENsGP74dC0FLzbzU6fI9TwkNrKiECv5l kX9PfYcg2uCB+oCTL4iFkD2XWbuJd+xmFXR11eEebtAEgSY79HEzy94XxC6OkFJdfQF8S4 vElriWQpvlH/EjmiQ6Oc7bqHnOQxK02RaU65SzguMCW21D/BDQP3qQNwjwqaefLE0TzEhu u39ApETEC1l7IElNfuiA5Fmf9pdkjPJZg2ruZ+PCqGNqKKdmg/JMvCkrw5eovb1DTAE8zt NiobAEhccOw2YiZigt0wlbG3A0DuSD1OPQUgkKXjT/vrz5N03pHrtVhkxtZ4Ew== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vT6wzczsp8; Mon, 15 Jul 2024 12:38:13 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcD3V060318; Mon, 15 Jul 2024 12:38:13 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcDsg060315; Mon, 15 Jul 2024 12:38:13 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:13 GMT Message-Id: <202407151238.46FCcDsg060315@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 23fd9f3e934b - stable/13 - am64: Allow cpu.h to be included from assembly List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 23fd9f3e934bc933e12eb7dcf01bb503be9ba0b8 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=23fd9f3e934bc933e12eb7dcf01bb503be9ba0b8 commit 23fd9f3e934bc933e12eb7dcf01bb503be9ba0b8 Author: Andrew Turner AuthorDate: 2024-05-03 16:07:29 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:28 +0000 am64: Allow cpu.h to be included from assembly Reviewed by: jhibbits, kevans Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45081 (cherry picked from commit e353ac0cfd5d155c01253ee17c2bf23f888cb7de) --- sys/arm64/include/cpu.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sys/arm64/include/cpu.h b/sys/arm64/include/cpu.h index ceccdf95ee8c..de6741fef1e0 100644 --- a/sys/arm64/include/cpu.h +++ b/sys/arm64/include/cpu.h @@ -40,8 +40,10 @@ #ifndef _MACHINE_CPU_H_ #define _MACHINE_CPU_H_ +#if !defined(__ASSEMBLER__) #include #include +#endif #include #define TRAPF_PC(tfp) ((tfp)->tf_elr) @@ -177,6 +179,7 @@ #define CPU_MATCH_ERRATA_CAVIUM_THUNDERX_1_1 0 #endif +#if !defined(__ASSEMBLER__) extern char btext[]; extern char etext[]; @@ -227,6 +230,7 @@ ADDRESS_TRANSLATE_FUNC(s1e0w) ADDRESS_TRANSLATE_FUNC(s1e1r) ADDRESS_TRANSLATE_FUNC(s1e1w) +#endif /* !__ASSEMBLER__ */ #endif #endif /* !_MACHINE_CPU_H_ */ From nobody Mon Jul 15 12:38:15 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vX15MDz5QrPw; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vW63Gyz4HFj; Mon, 15 Jul 2024 12:38:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047095; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=p7GUpU7RaJuWYWGMQ9VENA26cgbbg2hROU0T9YI2WnE=; b=p8NCZEyg7pbE48b73sn9cukpJ8S87Y8gNPWHxgWDwTZxwwZiHw+Mbfujg4ajUQeEiY3K4f 4J3BgLHgjfAkAH5lTp5WN/8ERzFaPOH/Ycriamnlmy3QJyamWl8gcuICUtAUJ9cPkXdAqs LHXUsZj8XKF1bEdMywmvKl2W8rP2kBnEHUVo9IlxwixFr3LrwEz2ajgk+rpsDbctBkYjP8 NXq1W/2Xp1Pxa2etAMAUtTXqGcqt+ML6OHQA9lmFOFn4ChwoiuDEByydaSZeUBop90DZLF 8SlcEddU5WHUgBVwYiFkM3CBxT6e5ZK95qNKZXVpoNNJw7mnh2IyCxm02llaig== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047095; a=rsa-sha256; cv=none; b=qSG3DUL7c5cdHmvfsT1uZS6poox8NgA/29G8/uHVd825/8vBzW+L9WjYl43QtBUKZbAjgt ugKB0Ml7QlKcd0R5sTeHSba0eXn2q7FdzbhZww7UgOv0DgaiP63IIdNrhQ6dUKyGjzZfHs 2HZR/VSAeYi9f1cuk5nwnAZADZhwbt2VE9JPcQBcGCugSaUuTP8Xg1vmpJnNX8QdYe0D5y qY4VDx4SkhCWPoev5B6XgsSxjhSYMFsYo4eHdB2SMFWPdM29AhIgP+Uwm1NXvuXa/Rwelh O/2rGQXaSCMsreuAiw7zh9t36Jei1j/9xmpA0rd7JL1P9wBoGnN/5YS3xgA0MA== 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=1721047095; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=p7GUpU7RaJuWYWGMQ9VENA26cgbbg2hROU0T9YI2WnE=; b=IuOfQuuOizMhY5k5l45jyuFgQJWR7/X3X3O7fd6dskOa4U4J+gmjKt+TcVdcf9jN0mvAzk hCjFjmmLDY444+UZY1Y+4Z5ELosHxMMtVjESYrS7CU79pEGWZrpYT16Ilc1Tr7DVnCJ8pg vlEBFg15Wsh6gA6/wLe0zA0t2lY9KeN6drs3VdTjlNTgnqvCIs8ZViDS3p6PCfYNTA47lL QrZTpY1zzvOFn8YtUH5QOw2ptDle+jTPs76GXP5LJi9PJPaCIdJf+JAsqvCmgnRxxX+xAw EUR85Pt2E75XSAyhNoNE6jsOUNLxrE1mLDrWSWzLUcrqK8fOMdhvhzjnO27nBg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vW5dRKzsp9; Mon, 15 Jul 2024 12:38:15 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcF0S060453; Mon, 15 Jul 2024 12:38:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcFSU060450; Mon, 15 Jul 2024 12:38:15 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:15 GMT Message-Id: <202407151238.46FCcFSU060450@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 2b2c134337ff - stable/14 - arm64: add PMBSR_MSS_{BSC,FSC} status code field List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 2b2c134337ff45b9ab3c409a5343f4fb04c4f4de Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=2b2c134337ff45b9ab3c409a5343f4fb04c4f4de commit 2b2c134337ff45b9ab3c409a5343f4fb04c4f4de Author: Zachary Leaf AuthorDate: 2023-09-20 09:51:22 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:25:40 +0000 arm64: add PMBSR_MSS_{BSC,FSC} status code field Bits [5:0] of PMBSR_MSS encodes either Buffer Status Code (BSC) or Fault Status Code (FSC) depending on PMBSR_EC value. Add PMBSR_MSS_{BSC,FSC} to cover this field. Reviewed by: andrew Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45172 (cherry picked from commit 10b3eac88db689d657c4d0d0716bcbdf240ff614) --- sys/arm64/include/armreg.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index ca281e800437..e90c6a57fd55 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -1689,6 +1689,8 @@ #define PMBSR_EL1_op2 3 #define PMBSR_MSS_SHIFT 0 #define PMBSR_MSS_MASK (UL(0xffff) << PMBSR_MSS_SHIFT) +#define PMBSR_MSS_BSC_MASK (UL(0x3f) << PMBSR_MSS_SHIFT) +#define PMBSR_MSS_FSC_MASK (UL(0x3f) << PMBSR_MSS_SHIFT) #define PMBSR_COLL_SHIFT 16 #define PMBSR_COLL (UL(0x1) << PMBSR_COLL_SHIFT) #define PMBSR_S_SHIFT 17 From nobody Mon Jul 15 12:38:16 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vX40Drz5QrS7; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vX1S28z4HCN; Mon, 15 Jul 2024 12:38:16 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047096; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=37k9JUvfH6CjW7t5/jxIQrwQgNZo/sRJafvrU0uOUmU=; b=v+lPxG+GtJh2PTvDpUcMLzReG1Q1eaODVG1+61B0BDPpaynpVg4sHNyyJolQy8H4d66zkV dBFyplQOQJS0WPkZrD2ExXnwx6C/csXn0tAMbc9YfNkrVBu0T/WxI71FvQjQ4Q2wSnJhwr YoDtR7Cm41Wn64gARW62tqGIwyoFKSSjFs6nu5LX3fjRuV7I7d1685A66aL0H+EyKcDf8L V6iPwwI9O6ZMIwUv08iqcS4tS6hBfiOe01C6bS9KdEfj1Q2bZpeUgNMv/tBkniQerXl19m znnvc8/JA9putAPc0VR5NmshexOeZJGbqlL75nPLzGHzm8opQ9QZlVkRkHpx5w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047096; a=rsa-sha256; cv=none; b=IC5Roc5kcHM6M2EUBG/GExAK3EHapn9T4SPduGoROpZ/HvBoXXZ+xX0o+qMnQqeOHhOEbP AGM3IB3lCwLi655UG8OPt0ctyxJ094tjBS3xBdN92LE4u5y7mTIltIf7lxtgDeXnhm7Rph m10/FLIELjPDPIFKhzp83tk4E56rVPhGToiZzmf/E9RYiFAP4lbgwxmhFMM3ofBMXtc5Cj xu3tvd+WEaJx/opvGJcu1+0ZhQTkNQSGV8C+kNRSyM86Ie8F5W9OcC1Tu5R1zIpY913nJw XMdtYguVUCcwTyCFIwFJrQ31dmL+Q1OYMw6V/7zJ+K7tZ8YfNIXVS3zAmTCCng== 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=1721047096; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=37k9JUvfH6CjW7t5/jxIQrwQgNZo/sRJafvrU0uOUmU=; b=wI/ma45JMMXD3k7C16D4Wta13uo2chUGWlmRa9XWWtq218DFkm8DF/IHfPY9jKK9XefV+s i2ekfaXvHOZ6cE6UwbHeS42Sgn38/hDar1FkQjryzcZolYoDNn5SX7toPkTx9uH1VUifzP WgDyjqEDdLbPNqaIO9JG8nSgkMfl9HASSIxN4ddmAR7Jvp3o+ODm4Iw7rgs1IPz32vC83J umZXUfiVUQSXgoXiGpskqcyt58qBgSbUxb3lKW4ccA5ShkWaxKRQ9q6Iz6SRedPcKySicF 19JNxBsyH3WzzgpmLzKCJx6K+QrhOm1hoG4k//6TNNP3BQGPI9GwvZbSIUQNEw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vX13c8zspB; Mon, 15 Jul 2024 12:38:16 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcG0x060501; Mon, 15 Jul 2024 12:38:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcGrJ060498; Mon, 15 Jul 2024 12:38:16 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:16 GMT Message-Id: <202407151238.46FCcGrJ060498@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: d7385a251abf - stable/13 - arm64/gicv3: Check if the hardware supports LPIs List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: d7385a251abffa8313f0c5c981d397bb64e1a683 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=d7385a251abffa8313f0c5c981d397bb64e1a683 commit d7385a251abffa8313f0c5c981d397bb64e1a683 Author: Andrew Turner AuthorDate: 2024-04-23 11:28:23 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:29 +0000 arm64/gicv3: Check if the hardware supports LPIs Some simulators have the ITS in the DTB passed to the kernel, however it is a runtime configuration option to enable it. Check the GICD_TYPER register to see if LPIs are enabled before attaching the ITS driver. Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D44914 (cherry picked from commit 4ab0f5ab3fd6dcd7f76c1ed1c9dc0dcd152fb64f) --- sys/arm64/arm64/gic_v3.c | 4 ++++ sys/arm64/arm64/gic_v3_var.h | 2 ++ sys/arm64/arm64/gicv3_its.c | 6 ++++++ 3 files changed, 12 insertions(+) diff --git a/sys/arm64/arm64/gic_v3.c b/sys/arm64/arm64/gic_v3.c index e37c68aa8a5d..c90edc3ba14c 100644 --- a/sys/arm64/arm64/gic_v3.c +++ b/sys/arm64/arm64/gic_v3.c @@ -443,6 +443,10 @@ gic_v3_read_ivar(device_t dev, device_t child, int which, uintptr_t *result) case GICV3_IVAR_REDIST: *result = (uintptr_t)sc->gic_redists.pcpu[PCPU_GET(cpuid)]; return (0); + case GICV3_IVAR_SUPPORT_LPIS: + *result = + (gic_d_read(sc, 4, GICD_TYPER) & GICD_TYPER_LPIS) != 0; + return (0); case GIC_IVAR_HW_REV: KASSERT( GICR_PIDR2_ARCH(sc->gic_pidr2) == GICR_PIDR2_ARCH_GICv3 || diff --git a/sys/arm64/arm64/gic_v3_var.h b/sys/arm64/arm64/gic_v3_var.h index d423e51453dc..1a4112a4b0ea 100644 --- a/sys/arm64/arm64/gic_v3_var.h +++ b/sys/arm64/arm64/gic_v3_var.h @@ -97,9 +97,11 @@ MALLOC_DECLARE(M_GIC_V3); #define GICV3_IVAR_NIRQS 1000 /* 1001 was GICV3_IVAR_REDIST_VADDR */ #define GICV3_IVAR_REDIST 1002 +#define GICV3_IVAR_SUPPORT_LPIS 1003 __BUS_ACCESSOR(gicv3, nirqs, GICV3, NIRQS, u_int); __BUS_ACCESSOR(gicv3, redist, GICV3, REDIST, void *); +__BUS_ACCESSOR(gicv3, support_lpis, GICV3, SUPPORT_LPIS, bool); /* Device methods */ int gic_v3_attach(device_t dev); diff --git a/sys/arm64/arm64/gicv3_its.c b/sys/arm64/arm64/gicv3_its.c index 852db0054aa7..3acc1558cf1a 100644 --- a/sys/arm64/arm64/gicv3_its.c +++ b/sys/arm64/arm64/gicv3_its.c @@ -2018,6 +2018,9 @@ gicv3_its_fdt_probe(device_t dev) if (!ofw_bus_is_compatible(dev, "arm,gic-v3-its")) return (ENXIO); + if (!gicv3_get_support_lpis(dev)) + return (ENXIO); + device_set_desc(dev, "ARM GIC Interrupt Translation Service"); return (BUS_PROBE_DEFAULT); } @@ -2088,6 +2091,9 @@ gicv3_its_acpi_probe(device_t dev) if (gic_get_hw_rev(dev) < 3) return (EINVAL); + if (!gicv3_get_support_lpis(dev)) + return (ENXIO); + device_set_desc(dev, "ARM GIC Interrupt Translation Service"); return (BUS_PROBE_DEFAULT); } From nobody Mon Jul 15 12:38:17 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vY4s71z5Qrn6; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vY2mhkz4HS2; Mon, 15 Jul 2024 12:38:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047097; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=oUtMdw4J3XrqGX7CxXYRPQIDJGXUzZtD1vKBM7C2+EY=; b=cvFPHhwVT3nne2DRcUvFMQN6PEKWjss6+MfKj3foMGdjJgFEHIL/H6aFQA05tdgQ/8MqPI 1/A8xI78lFOU+4YE+m/ZaZo1EVYXzCDkNzbcIR7h/0Ktp5KvrRTCCj6E2k1MY3H/S7treT HOSITsxLVr9Z5m3Lm7KufuXg83k62eM8crf4QxxAEi/xeOf+W8LaqKDXnr+1M/BwX1OAsV iJi47jpZaUzLTslI49kxkrixhg0W129BCswAhTc09tA1y8zbYTY4t0afeIngIVmv3TVydo O+ox9spRDtSSZ+M6+nYl9OmUOjhlYaimFQBuN3g7opw8f/Yr4VyNbaOeOuX+oQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047097; a=rsa-sha256; cv=none; b=gmnZSGxqjIR3OQHJR0DKI+1kvVdaL88RHCzJ7PKzswxiQcol5F7c+Yl0gdKKvQVTkH3zdp QeqSL/gem9d2iwG3FLiWSZP9TVk9Nqxj7rgwF9BZJleGJXgIPLLr0J6x9YXYPuPNi5QtlD BJ4C53ZrYWW4mBsYMnFGW2T1oWWsWTfKns8c23R8T7zX0mhuB0H6Wf2l3E8SZbTuxa3msz iBAEaxVliR2N9zwZPFqhJHHV0OHIr8e/16/D0WmX60no2qUZFGHkn/Y55zrxwXiQfz3SXT rEevpBHTePGoZ3zOp1HPvQCPPXdFe+Fk2+W9id+WXs5zquCxTbmpnfUPm3ohHw== 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=1721047097; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=oUtMdw4J3XrqGX7CxXYRPQIDJGXUzZtD1vKBM7C2+EY=; b=GF+P5jARqtjeT+JWVdhefaFIJFBLmpvQjgK/PpyAurWu0qQYLAvYXG8MQy/5EzuawLllIb 9viI395bROy69oLZhh8qy5QzbYl0Ov+QUO/G0eD2NPkfYMhCMsjcJYWZUmsQTgL5MtyzlC wDJMhyqejjW+P2ydoomOzqzQEAHWTFg3kzK28UonRJ6mmY0PojLhMCQVrsrJU3rQXn55lU Fii5UuzTvKdQwTAVieUPmR58/3HNO8qrVzvNI4fYfgE8wxe6dbi5aIdfSD47/2aGZ66kqL q4LDkrUVgXgGwTPby543BEuEQt5NLBbfvc00biJjmkra0vRXFi1DuyjlGkd0sQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vY2JzKzt3F; Mon, 15 Jul 2024 12:38:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcHmb060601; Mon, 15 Jul 2024 12:38:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcH3A060598; Mon, 15 Jul 2024 12:38:17 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:17 GMT Message-Id: <202407151238.46FCcH3A060598@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: f9210d37c5c6 - stable/13 - rtld: Add MD_OBJ_ENTRY to extend Struct_Obj_Entry List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: f9210d37c5c6ef427af619f2bf0ff7157415fa47 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=f9210d37c5c6ef427af619f2bf0ff7157415fa47 commit f9210d37c5c6ef427af619f2bf0ff7157415fa47 Author: Andrew Turner AuthorDate: 2024-05-07 15:49:53 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:29 +0000 rtld: Add MD_OBJ_ENTRY to extend Struct_Obj_Entry Add a macro the architectures can use to add per-arch fields to Struct_Obj_Entry. Reviewed by: kib Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45116 (cherry picked from commit 06db20ffeca9898e5802d63f3b06caaa37c3a4ed) --- libexec/rtld-elf/aarch64/rtld_machdep.h | 2 ++ libexec/rtld-elf/amd64/rtld_machdep.h | 2 ++ libexec/rtld-elf/arm/rtld_machdep.h | 2 ++ libexec/rtld-elf/i386/rtld_machdep.h | 2 ++ libexec/rtld-elf/powerpc/rtld_machdep.h | 2 ++ libexec/rtld-elf/powerpc64/rtld_machdep.h | 2 ++ libexec/rtld-elf/riscv/rtld_machdep.h | 2 ++ libexec/rtld-elf/rtld.h | 2 ++ 8 files changed, 16 insertions(+) diff --git a/libexec/rtld-elf/aarch64/rtld_machdep.h b/libexec/rtld-elf/aarch64/rtld_machdep.h index ffb340d17ffa..daa0f4fb28eb 100644 --- a/libexec/rtld-elf/aarch64/rtld_machdep.h +++ b/libexec/rtld-elf/aarch64/rtld_machdep.h @@ -37,6 +37,8 @@ struct Struct_Obj_Entry; +#define MD_OBJ_ENTRY + /* Return the address of the .dynamic section in the dynamic linker. */ #define rtld_dynamic(obj) \ ({ \ diff --git a/libexec/rtld-elf/amd64/rtld_machdep.h b/libexec/rtld-elf/amd64/rtld_machdep.h index 40d9e37263b6..037c7ed2bb7f 100644 --- a/libexec/rtld-elf/amd64/rtld_machdep.h +++ b/libexec/rtld-elf/amd64/rtld_machdep.h @@ -35,6 +35,8 @@ struct Struct_Obj_Entry; +#define MD_OBJ_ENTRY + /* Return the address of the .dynamic section in the dynamic linker. */ Elf_Dyn *rtld_dynamic_addr(void); #define rtld_dynamic(obj) rtld_dynamic_addr() diff --git a/libexec/rtld-elf/arm/rtld_machdep.h b/libexec/rtld-elf/arm/rtld_machdep.h index cbb0e4ac71c9..592176768afb 100644 --- a/libexec/rtld-elf/arm/rtld_machdep.h +++ b/libexec/rtld-elf/arm/rtld_machdep.h @@ -36,6 +36,8 @@ struct Struct_Obj_Entry; +#define MD_OBJ_ENTRY + /* Return the address of the .dynamic section in the dynamic linker. */ #define rtld_dynamic(obj) (&_DYNAMIC) diff --git a/libexec/rtld-elf/i386/rtld_machdep.h b/libexec/rtld-elf/i386/rtld_machdep.h index 8213597344f2..dce8d547cfd6 100644 --- a/libexec/rtld-elf/i386/rtld_machdep.h +++ b/libexec/rtld-elf/i386/rtld_machdep.h @@ -35,6 +35,8 @@ struct Struct_Obj_Entry; +#define MD_OBJ_ENTRY + /* Return the address of the .dynamic section in the dynamic linker. */ #define rtld_dynamic(obj) \ ((const Elf_Dyn *)((obj)->relocbase + (Elf_Addr)&_DYNAMIC)) diff --git a/libexec/rtld-elf/powerpc/rtld_machdep.h b/libexec/rtld-elf/powerpc/rtld_machdep.h index 107bde901c68..1601560437bd 100644 --- a/libexec/rtld-elf/powerpc/rtld_machdep.h +++ b/libexec/rtld-elf/powerpc/rtld_machdep.h @@ -35,6 +35,8 @@ struct Struct_Obj_Entry; +#define MD_OBJ_ENTRY + /* Return the address of the .dynamic section in the dynamic linker. */ #define rtld_dynamic(obj) (&_DYNAMIC) diff --git a/libexec/rtld-elf/powerpc64/rtld_machdep.h b/libexec/rtld-elf/powerpc64/rtld_machdep.h index e4f27f2fff61..ff4145b3fe9c 100644 --- a/libexec/rtld-elf/powerpc64/rtld_machdep.h +++ b/libexec/rtld-elf/powerpc64/rtld_machdep.h @@ -35,6 +35,8 @@ struct Struct_Obj_Entry; +#define MD_OBJ_ENTRY + /* Return the address of the .dynamic section in the dynamic linker. */ #define rtld_dynamic(obj) (&_DYNAMIC) diff --git a/libexec/rtld-elf/riscv/rtld_machdep.h b/libexec/rtld-elf/riscv/rtld_machdep.h index b4ae4cb5512f..6080f297be84 100644 --- a/libexec/rtld-elf/riscv/rtld_machdep.h +++ b/libexec/rtld-elf/riscv/rtld_machdep.h @@ -42,6 +42,8 @@ struct Struct_Obj_Entry; +#define MD_OBJ_ENTRY + uint64_t set_gp(struct Struct_Obj_Entry *obj); /* Return the address of the .dynamic section in the dynamic linker. */ diff --git a/libexec/rtld-elf/rtld.h b/libexec/rtld-elf/rtld.h index 1f9b82caef33..2673e62ddd65 100644 --- a/libexec/rtld-elf/rtld.h +++ b/libexec/rtld-elf/rtld.h @@ -283,6 +283,8 @@ typedef struct Struct_Obj_Entry { bool unholdfree : 1; /* unmap upon last unhold */ bool doomed : 1; /* Object cannot be referenced */ + MD_OBJ_ENTRY; + struct link_map linkmap; /* For GDB and dlinfo() */ Objlist dldags; /* Object belongs to these dlopened DAGs (%) */ Objlist dagmembers; /* DAG has these members (%) */ From nobody Mon Jul 15 12:38:16 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vY4qnKz5Qrn5; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vY0RG4z4HMK; Mon, 15 Jul 2024 12:38:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047097; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Fphdl749GX0ufJTUV55vgsf22x8tiuGF4dl8HjRbY/0=; b=lub9SDUVlYLah+Spu1LIiAfXbC/gph+pls8zI9O+H7v369PKDAZ/2QR89QxMIDfip8vw/l lFvD43VUgnOYe6+YfYLfWP23B1ZPRZkX+Bb8myJSUdClR2w8fW6uLq0jvyVejJihgdFgmm dVXyfXGvhHFG1advXMCYEr5WqXH19wPj2L8tYa3kfExo/suXiUGe7jiI68mWcSwopDvVO4 IK93tVQN4QJmiaqdp0FaIFeJt32nC3eZXSHOEGAsE+7LISMhczKynSbMo+rcNBz9kmt7UL yu0AK3ba88k8T3H4QtB1LyYDulqCoFj58bw0gXJG7yU5BezBSrKdxlpeAyVLyw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047097; a=rsa-sha256; cv=none; b=uC5ApkHwnHjzWQpBu2VCmtICBAzhT8Q+mzsTWGEM6PoY0Smv7YjxQU3jEXlmRzZv8pIU+J 6Egw/50ArddsgcVFHGDL2XQdeHJvjSRoAPgAfgbu/iJ5FrfYx9WaIwVAhAb50FW9QDgoX5 ZtitU8de9n3VQiIhvaAEQ6KyWEQaIeo43v6011TkLlfg0SjtX52NnqCHKC6gIzzkA7qdNp Coz/9hNz2eG6baKinYp3rGfo1mRBrgZGQePXdmzdcC6fFtcRf7XRxguRpkUU083ViA+mi+ sqvUEHntGf34TU2HYA9CDe0z59dhKThpP6LoiNEFEjpOFh1mN3BWp3DRO/l4Fw== 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=1721047097; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Fphdl749GX0ufJTUV55vgsf22x8tiuGF4dl8HjRbY/0=; b=vp6lai7xa234RML2AoL60qJdkg3qKclrkiZ2/yojtxVaBPVjiPfYpw+CS3F0IEbo5ZUH8Z E1Y44C3A/Fahnh2g3ZaKEokDeVnAvSpeERKsaGIaF3yn4489CXEFoSyfTg8GNONDVMrKl6 grj8VBsh2wOdcdflr2pqhg0qHB1ZbDFWfAbq6dMH+OTId86JvohfS2Ns3urpntxrynGxjG XDYbAW+gWRMPliMj3JEOYsQ3eHBjUQK58UBXBe5VN9vEfZezhKy1xHCZxJ/XX9LY/kKvaE ScRvxY9ZyaoMbJ+lYWSUyW/ZOhT96lYSjXe1z8LPoDTkmei6bDjpFs+a1AmbYA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vX6mQVzt5g; Mon, 15 Jul 2024 12:38:16 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcGsJ060555; Mon, 15 Jul 2024 12:38:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcGkI060552; Mon, 15 Jul 2024 12:38:16 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:16 GMT Message-Id: <202407151238.46FCcGkI060552@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 25eae8989139 - stable/14 - arm: Add a missing interrupt to the generic timer List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 25eae89891399e14f82de15e189d895521776b9a Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=25eae89891399e14f82de15e189d895521776b9a commit 25eae89891399e14f82de15e189d895521776b9a Author: Andrew Turner AuthorDate: 2024-01-11 17:07:59 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:25:51 +0000 arm: Add a missing interrupt to the generic timer The ACPI generic timer attachment added 3 interrupts, but missed the hypervisor physical interrupt. As the field is present in all versions of the GTDT ACPI table and isn't an optional interrupts we can add it to the interrupts provided to the driver. Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D43974 (cherry picked from commit f715e95461c9264913a65e2dc93c291b7e318d2e) --- sys/arm/arm/generic_timer.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sys/arm/arm/generic_timer.c b/sys/arm/arm/generic_timer.c index b9562620848f..0f20cdad90d6 100644 --- a/sys/arm/arm/generic_timer.c +++ b/sys/arm/arm/generic_timer.c @@ -564,6 +564,8 @@ arm_tmr_acpi_identify(driver_t *driver, device_t parent) gtdt->NonSecureEl1Interrupt); arm_tmr_acpi_add_irq(parent, dev, GT_VIRT, gtdt->VirtualTimerInterrupt); + arm_tmr_acpi_add_irq(parent, dev, GT_HYP_PHYS, + gtdt->NonSecureEl2Interrupt); out: acpi_unmap_table(gtdt); From nobody Mon Jul 15 12:38:19 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vb4H4Mz5QrY0; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vb2DJKz4HPd; Mon, 15 Jul 2024 12:38:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047099; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=JiXcZ8y1neOtZEfF2WT+7/jQY6XWXQ3vG5LTUywaMKg=; b=Nkyy4jdwKq8TtRyrK+M15id7veeswytblhQSpC5iA2+IiWiWqDi116uZb3b4XY938OqjD0 XK9adLLMQtGOAnvsIbdtvBrP3/FYC6LkTNzMATfTecGh/G0k5eUsf7H9FWERQtTYXLt89x wgvxUnh9vc3LRWzUn+CpAfIZOhh7kvJaCGHJOCWBBtjtDCuTF+Hz4vChsF4LRjfcQd4qHF ZBlBRr8N0klVvKPSTrxUp2z868NpxQoQFdwKhqySe+X1nbp94+CRWSb114LwqshMA/BdoN YNhKUdLCarcybsi9iHLRJxfDScHUAC5OLfWqoe11v74Sdt99nTk/lmg57PQznA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047099; a=rsa-sha256; cv=none; b=uXv9Z5avekpWqUUOdiulE7MEfpmv//CI3q4K2Vsgb9LTAPzMIMciEZPmMjEt1oaAp1pPza IUA+kHQstWgna3igyZn/KTTZ+8N+OCOk+bA4vPOKwxRtsr5BIOXD5+/PJP4xvCpxNW2gVs cCCyuD8aY9CXLxBT2RoQfOL7Eo53L8X9VMyfRvaIovtSxIqsnIDXE0GyHKvNVYRYcVQ0D6 w0OYFOTdQ5f3n7sEEuLWBzA9MenUBkNCiHSKQYlGkwraN+r37Dg7DPclitTHhj1nb1+zg5 AeHdVK/uuZ1a1VYs9Kq5glS/5LsHL2x51RoH1Qt31DSFpj7nzl5czX8h1dIR5A== 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=1721047099; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=JiXcZ8y1neOtZEfF2WT+7/jQY6XWXQ3vG5LTUywaMKg=; b=ozDz2TYDq+ILmQVhrVY4wc4QOGIfr69/bVAWMKCdvlQhxozJuzcJoYiQ9T56AyYSfDFDRG KFpZ8lD0WdnhMxWrKe2kNBwrBlJdVbwiaxiTwyaK23yhFXzW1GBIddhmBGTme+o7qlDY9d ECocUK19JypmhuMpZ5Ai4Mps6O7XqInymmKpctpiJHJzaBzaeHcG645HFiRDbqAeb9KCmw 3gFnmdiUk9pREYAlXyURpl1cvM8LMNWLfPIXD20Z8BKLUD8nQXMaJ+JS84Ji4dT+XE0YSF EtZIohTd0fKdJbX/P/ZZX2Kj5v3h5FurZeW1OVWhLLb8PRNBhA2CsUUJCHV9kA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vb1pRszspC; Mon, 15 Jul 2024 12:38:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcJDW060744; Mon, 15 Jul 2024 12:38:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcJAE060741; Mon, 15 Jul 2024 12:38:19 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:19 GMT Message-Id: <202407151238.46FCcJAE060741@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 21f3f3e87edd - stable/14 - stand/kboot: Fix the linker script OUTPUT_FORMAT List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 21f3f3e87edd710977df5a33955338a037d21262 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=21f3f3e87edd710977df5a33955338a037d21262 commit 21f3f3e87edd710977df5a33955338a037d21262 Author: Andrew Turner AuthorDate: 2024-05-22 08:17:52 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:26:11 +0000 stand/kboot: Fix the linker script OUTPUT_FORMAT ld.bfd doesn't understand elf64-aarch64 but does have elf64-littleaarch64. Switch to this so we can link kboot with it. While here switch to the single format version. We are unlikely to support booting from a big-endian Linux. Reviewed by: imp, emaste Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45258 (cherry picked from commit 8e82c5e28db6fb19f75d10fd2e7c3db784723f1f) --- stand/kboot/kboot/arch/aarch64/aarch64.ldscript | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stand/kboot/kboot/arch/aarch64/aarch64.ldscript b/stand/kboot/kboot/arch/aarch64/aarch64.ldscript index 9460be1874bf..dd551247125b 100644 --- a/stand/kboot/kboot/arch/aarch64/aarch64.ldscript +++ b/stand/kboot/kboot/arch/aarch64/aarch64.ldscript @@ -1,4 +1,4 @@ -OUTPUT_FORMAT("elf64-aarch64", "elf64-aarch64", "elf64-aarch64") +OUTPUT_FORMAT("elf64-littleaarch64") OUTPUT_ARCH(aarch64) ENTRY(_start) SECTIONS From nobody Mon Jul 15 12:38:17 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vZ6x6tz5QrSL; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vZ18swz4H75; Mon, 15 Jul 2024 12:38:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047098; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=m9SlxsJsnUA34ti8auOm15sVGWMSopQ5SueU4uDxpeo=; b=jnAxMfoU7RaGF49moWBKpnhy1GCzTtl3qrEzJ/+QsVkWPKyd6c5Ihq4C4LV6R1xacFXvRk pXlcmdf8qcZuEkk8RwTAalomLcGmvVtKZrZdKoq5J3Yzif8u+5tTQ9zIL8JOtHqbiCZcpL Fdau0pjA26NzuJjnKn8rtNj3Khsx9C1KN3bSblDFhVli7YvNVbA8iK8V2ImuKSmLB3+TcT P7DC4bqUuq8VUb1MZ6NvQDrUaFneTnfvz5RKvOpr7dYI/C2ZRQ9Ox8sQeajC6IvaEpmBRG 74+rdq9sdhhnNVnM8kjPti04Z7w1+tBSCMMRzM42m3NvzRsbfrbjBEgfIz9b5A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047098; a=rsa-sha256; cv=none; b=WxGJ1yu5sfLmttngx6cv2N6idfYbMERV4kwxiV4Df1oewc3jkOJuAp0pXDAz/b6vL0CSyl WTjNO0rv3bEKGmjn6ww9YGTKUtBLYMxRt4Jrc9g7+AWUy2RhygcdZbHggs1xW7zZkwcNq3 vxzXJALKpyMgXXZHA5Keut0sQOWfAXkQoRoV7E6a34cDlW81H3dKQgo4diN0rkttB99GhA zGrfoyXszDocG2rjFfFPAuypJb+sperQS+eaBrbUrbW/E0nnYTUPBUpUdt43kQx19XTWG2 7f75f4JTjq5CPydHYJEtEe8eTn06TAFngdvTqNos/Kj58dNwemLiv63GGo5iCw== 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=1721047098; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=m9SlxsJsnUA34ti8auOm15sVGWMSopQ5SueU4uDxpeo=; b=EfnBO2Tyz078VmrGu9d4WSxi4rC7A8/2H+s0zPM4+e514AoSOEiNX5tC0SCDkajkTIPXem HG0EIZyNHFrfgSVN6VMx9Oc9ae9tqaqEffoGcvJK/TV/VhC+ylIAeNYW7o5tJG4i9QtxPv 6gSM9MVrdEOid+DEY+WVU8p8PwIBjguutHas8QAk21YMGw7eVETpA7KHdOzpMT6ec+hwr7 fMjf1Xh/uh1NNSJskD9mALxHkxEG8Pdc99LVWztPfPgKZX3TlM3eiq4fezjcuFVPyVc3MA zpE7M6h5yUoRrzGxOQfs5yoMtlYIblU7RYxtgYQfCTCtYYixoQU25rpQwn8U8g== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vZ0hXDzsZF; Mon, 15 Jul 2024 12:38:18 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcHne060654; Mon, 15 Jul 2024 12:38:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcHiW060651; Mon, 15 Jul 2024 12:38:17 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:17 GMT Message-Id: <202407151238.46FCcHiW060651@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 2bd50014977a - stable/14 - stand/efi: Fix for binutils when targeting arm64 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 2bd50014977ae8428387c0e49e0ff484edd78c08 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=2bd50014977ae8428387c0e49e0ff484edd78c08 commit 2bd50014977ae8428387c0e49e0ff484edd78c08 Author: Andrew Turner AuthorDate: 2024-05-22 08:17:26 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:26:00 +0000 stand/efi: Fix for binutils when targeting arm64 When linking with ld.bfd it complain with the following: /usr/local/bin/aarch64-unknown-freebsd14.0-ld: start.o: relocation R_AARCH64_ABS32 against `__data_size' can not be used when making a shared object Fix this by marking the __data_size with ABSOLUTE. This returns a non-relocatable value which appears to be the same behaviour of lld. Reviewed by: imp Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45257 (cherry picked from commit 9f44638ef2c46861565b89bb01bbeeab17755649) --- stand/efi/loader/arch/arm64/arm64.ldscript | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stand/efi/loader/arch/arm64/arm64.ldscript b/stand/efi/loader/arch/arm64/arm64.ldscript index 18aead05cb49..889a1bafb9f7 100644 --- a/stand/efi/loader/arch/arm64/arm64.ldscript +++ b/stand/efi/loader/arch/arm64/arm64.ldscript @@ -68,7 +68,7 @@ SECTIONS . = ALIGN(16); .dynsym : { *(.dynsym) } _edata = .; - __data_size = . - __data_start; + __data_size = ABSOLUTE(. - __data_start); /* Unused sections */ .interp : { *(.interp) } From nobody Mon Jul 15 12:38:18 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vZ5VC2z5Qrpp; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vZ3Tjnz4HJq; Mon, 15 Jul 2024 12:38:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047098; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=htZsNAo+PRYrvv5RepfeRuH2aw13b4bOf51rKvujMyY=; b=rHRb0EsdZabP0XtnvFbD6WTdZmP/Jx4GZtGUx8INpyxJbMxCiuvc1T9tR4dziJMczRJaIm Ro5hehVchYLlx3izKh/e93EB7avy3CarA97OaOvalLXe20PNlmfDE+CYWiSQR0PjlFl7Sx OyyF/Lx2kLNrEAbNHVKvvt9jVgyeIu3gl6W0XqvsXLBagfNmY8RJrLTfWF3LRGpqgl8mT1 vOGvSL0CqTIT6RDTgYRU7ILiCYpLqkg1IWy5LQqgdcFQ6vkn3lf65pPK5gKt3fXT9xtU2I Tjy02Ryk1sNGHMxLGO2AgZN4J7TOmWaBk4g53ZngmA7BS7J8yjkhz2iDoOdGaQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047098; a=rsa-sha256; cv=none; b=ROO9AXwj4Btz0HMnjxJfuGAZzNF4fyyqVXTH4ELwaR00XAyOdETlOpeF3zqOD7uAwMLFPd keYMKEAIa6BArh+SgResAN7Ce6D/Q8Q/mOUnsqwHQbkE4uoH3s4PImsEt2+y/Apke5xoqG 5vcBVe07Af5HpQTmJaaY+bODYp1VTFyD4mE6TH3e1NbN6kEj0gaPF/zSa2GcseJSONE4m4 22qSUQwliw3x9Lu4AuG4EUH9PY5nF+S9+H4fvGMvReBqMYLjDJ0BdcrMsbUgW3jNmU/Z/2 dDxNAqsKf5evJjLy7kg4NISzZ76Gm/U5sYF1kamNzqAJ5s3UynLByx4JyhcBXQ== 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=1721047098; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=htZsNAo+PRYrvv5RepfeRuH2aw13b4bOf51rKvujMyY=; b=Qb7F9iwiWCa13JMUm9grkO1SUBN7Z/Fz3xMDOVOQQc3V3wkzlI1a1kZhnJM8fFt2DVlVlH 46S8yzIduFnDY17KKFEVzNeBNY9bsKiG3Q3FN66HDkA0pm6FgEIwhJT8DwJLxhPGxMt8Ig P6rEt8+pxq9Z3pwTTj+hF4UWOd4qfEG9o14gVvITqo7nADpul2urI0ZM2GNOh/fjcFRtZF j+6DMN3lHRc8qXT5pqTWY3KTjN8IJKk4DhvwfhnLyoC3B4imwrmInn1eF6HiHN/lFo4wCx SE/olF0Azg/ALjTQw8hWQtDNHYvjaa9AGIOhLb85TB2wWenWgqJ7WLhSQ7GGSw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vZ3649zt1P; Mon, 15 Jul 2024 12:38:18 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcI4P060699; Mon, 15 Jul 2024 12:38:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcIFm060696; Mon, 15 Jul 2024 12:38:18 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:18 GMT Message-Id: <202407151238.46FCcIFm060696@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 788cf499da8a - stable/13 - arm64: Add MRS_REG_ALT_NAME ID register macros List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 788cf499da8ab80570a868a3ad0ffc74595ac720 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=788cf499da8ab80570a868a3ad0ffc74595ac720 commit 788cf499da8ab80570a868a3ad0ffc74595ac720 Author: Andrew Turner AuthorDate: 2024-05-13 13:58:45 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:29 +0000 arm64: Add MRS_REG_ALT_NAME ID register macros These can be used even when the compiler is too old for the register to be included. Reviewed by: Zachary Leaf Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45176 (cherry picked from commit d6d860c7ff5c4cbe9475d98000407d6f0ea84b47) --- sys/arm64/include/armreg.h | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index 9add7515967a..92ad96550e56 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -494,6 +494,7 @@ /* ID_AA64AFR0_EL1 */ #define ID_AA64AFR0_EL1 MRS_REG(ID_AA64AFR0_EL1) +#define ID_AA64AFR0_EL1_REG MRS_REG_ALT_NAME(ID_AA64AFR0_EL1) #define ID_AA64AFR0_EL1_op0 3 #define ID_AA64AFR0_EL1_op1 0 #define ID_AA64AFR0_EL1_CRn 0 @@ -502,6 +503,7 @@ /* ID_AA64AFR1_EL1 */ #define ID_AA64AFR1_EL1 MRS_REG(ID_AA64AFR1_EL1) +#define ID_AA64AFR1_EL1_REG MRS_REG_ALT_NAME(ID_AA64AFR1_EL1) #define ID_AA64AFR1_EL1_op0 3 #define ID_AA64AFR1_EL1_op1 0 #define ID_AA64AFR1_EL1_CRn 0 @@ -510,6 +512,7 @@ /* ID_AA64DFR0_EL1 */ #define ID_AA64DFR0_EL1 MRS_REG(ID_AA64DFR0_EL1) +#define ID_AA64DFR0_EL1_REG MRS_REG_ALT_NAME(ID_AA64DFR0_EL1) #define ID_AA64DFR0_EL1_op0 3 #define ID_AA64DFR0_EL1_op1 0 #define ID_AA64DFR0_EL1_CRn 0 @@ -599,6 +602,7 @@ /* ID_AA64DFR1_EL1 */ #define ID_AA64DFR1_EL1 MRS_REG(ID_AA64DFR1_EL1) +#define ID_AA64DFR1_EL1_REG MRS_REG_ALT_NAME(ID_AA64DFR1_EL1) #define ID_AA64DFR1_EL1_op0 3 #define ID_AA64DFR1_EL1_op1 0 #define ID_AA64DFR1_EL1_CRn 0 @@ -607,6 +611,7 @@ /* ID_AA64ISAR0_EL1 */ #define ID_AA64ISAR0_EL1 MRS_REG(ID_AA64ISAR0_EL1) +#define ID_AA64ISAR0_EL1_REG MRS_REG_ALT_NAME(ID_AA64ISAR0_EL1) #define ID_AA64ISAR0_EL1_op0 3 #define ID_AA64ISAR0_EL1_op1 0 #define ID_AA64ISAR0_EL1_CRn 0 @@ -693,6 +698,7 @@ /* ID_AA64ISAR1_EL1 */ #define ID_AA64ISAR1_EL1 MRS_REG(ID_AA64ISAR1_EL1) +#define ID_AA64ISAR1_EL1_REG MRS_REG_ALT_NAME(ID_AA64ISAR1_EL1) #define ID_AA64ISAR1_EL1_op0 3 #define ID_AA64ISAR1_EL1_op1 0 #define ID_AA64ISAR1_EL1_CRn 0 @@ -794,6 +800,7 @@ /* ID_AA64ISAR2_EL1 */ #define ID_AA64ISAR2_EL1 MRS_REG(ID_AA64ISAR2_EL1) +#define ID_AA64ISAR2_EL1_REG MRS_REG_ALT_NAME(ID_AA64ISAR2_EL1) #define ID_AA64ISAR2_EL1_op0 3 #define ID_AA64ISAR2_EL1_op1 0 #define ID_AA64ISAR2_EL1_CRn 0 @@ -841,6 +848,7 @@ /* ID_AA64MMFR0_EL1 */ #define ID_AA64MMFR0_EL1 MRS_REG(ID_AA64MMFR0_EL1) +#define ID_AA64MMFR0_EL1_REG MRS_REG_ALT_NAME(ID_AA64MMFR0_EL1) #define ID_AA64MMFR0_EL1_op0 3 #define ID_AA64MMFR0_EL1_op1 0 #define ID_AA64MMFR0_EL1_CRn 0 @@ -932,6 +940,7 @@ /* ID_AA64MMFR1_EL1 */ #define ID_AA64MMFR1_EL1 MRS_REG(ID_AA64MMFR1_EL1) +#define ID_AA64MMFR1_EL1_REG MRS_REG_ALT_NAME(ID_AA64MMFR1_EL1) #define ID_AA64MMFR1_EL1_op0 3 #define ID_AA64MMFR1_EL1_op1 0 #define ID_AA64MMFR1_EL1_CRn 0 @@ -1019,6 +1028,7 @@ /* ID_AA64MMFR2_EL1 */ #define ID_AA64MMFR2_EL1 MRS_REG(ID_AA64MMFR2_EL1) +#define ID_AA64MMFR2_EL1_REG MRS_REG_ALT_NAME(ID_AA64MMFR2_EL1) #define ID_AA64MMFR2_EL1_op0 3 #define ID_AA64MMFR2_EL1_op1 0 #define ID_AA64MMFR2_EL1_CRn 0 @@ -1105,6 +1115,7 @@ /* ID_AA64MMFR3_EL1 */ #define ID_AA64MMFR3_EL1 MRS_REG(ID_AA64MMFR3_EL1) +#define ID_AA64MMFR3_EL1_REG MRS_REG_ALT_NAME(ID_AA64MMFR3_EL1) #define ID_AA64MMFR3_EL1_op0 3 #define ID_AA64MMFR3_EL1_op1 0 #define ID_AA64MMFR3_EL1_CRn 0 @@ -1133,6 +1144,7 @@ /* ID_AA64MMFR4_EL1 */ #define ID_AA64MMFR4_EL1 MRS_REG(ID_AA64MMFR4_EL1) +#define ID_AA64MMFR4_EL1_REG MRS_REG_ALT_NAME(ID_AA64MMFR4_EL1) #define ID_AA64MMFR4_EL1_op0 3 #define ID_AA64MMFR4_EL1_op1 0 #define ID_AA64MMFR4_EL1_CRn 0 @@ -1141,6 +1153,7 @@ /* ID_AA64PFR0_EL1 */ #define ID_AA64PFR0_EL1 MRS_REG(ID_AA64PFR0_EL1) +#define ID_AA64PFR0_EL1_REG MRS_REG_ALT_NAME(ID_AA64PFR0_EL1) #define ID_AA64PFR0_EL1_op0 3 #define ID_AA64PFR0_EL1_op1 0 #define ID_AA64PFR0_EL1_CRn 0 @@ -1239,6 +1252,7 @@ /* ID_AA64PFR1_EL1 */ #define ID_AA64PFR1_EL1 MRS_REG(ID_AA64PFR1_EL1) +#define ID_AA64PFR1_EL1_REG MRS_REG_ALT_NAME(ID_AA64PFR1_EL1) #define ID_AA64PFR1_EL1_op0 3 #define ID_AA64PFR1_EL1_op1 0 #define ID_AA64PFR1_EL1_CRn 0 @@ -1297,6 +1311,7 @@ /* ID_AA64PFR2_EL1 */ #define ID_AA64PFR2_EL1 MRS_REG(ID_AA64PFR2_EL1) +#define ID_AA64PFR2_EL1_REG MRS_REG_ALT_NAME(ID_AA64PFR2_EL1) #define ID_AA64PFR2_EL1_op0 3 #define ID_AA64PFR2_EL1_op1 0 #define ID_AA64PFR2_EL1_CRn 0 From nobody Mon Jul 15 12:38:20 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vd13Rqz5Qrq1; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vc6Q1sz4HGX; Mon, 15 Jul 2024 12:38:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047100; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=TPqtByXzy9GLuw8FVfl2xJMQ0lBkxtw+ygDND93jKX4=; b=n73bDgKrJMVGkm4IM2PUUZqI6Kw/9vmSzXiUZX21xJlupSPyq+Qv8VvIabFl8xNErpcKjv lcNQ50Jgpm600S6vG18gaJo5sZgFSiMGJLTPEKXfR2Tg0SxPq5Xjq0rMBX8LcDHVazI35R RS2aQZWKe+Iy0TgUcH6551qhvzOGxyHmbHDViluFdpdSHzJJ0WiQogdvd87Wx8rLItZa2P WAqmfvnn9x8e7qsMScUW1jCDMrXcX/Vv3VifKRhTAREFTLQSVTyT7sLJJvP+ZnyCy4maEk SE+qlKUjvYyO8iL4YwEKaNuUkBIjo/3zFEwiW5SVPWWyOulJsg70ElW10wlz7g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047100; a=rsa-sha256; cv=none; b=jyFFNYSml8mHQJVk/2SOHkpAnUIBo8YIpsjAEFKX9HV42+n1LadByl8j/fDw3eLuSnCdvm xzfny7Yv9sEp/6i7qV3VXm9UxW7aI0mqf2JzFLrHZdx+kLG/z4ujbKLvuqAZS5xkkFKo4+ MJByvcw7AkbDsKUb7WzJo+BMom8olnc/gEK/5PhELECUuWjaSQKJYamtZLnHFocw38ZWfy SnfOo8pTMbSpd8LY/wO90a1PwCwHufO3v90lDEXbhJshmmGnxozV6iWLFtRK9GIDql+Nbz nXZlGzcN2qEt9b1WzHEevZXqV5voyXO8oHaZd3AIb0gO/o46HlstzNmpJU0Xag== 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=1721047100; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=TPqtByXzy9GLuw8FVfl2xJMQ0lBkxtw+ygDND93jKX4=; b=MX0y3fykxF51SW+YAyZyK/CqzSTLj8SFt/t+RuY0fbfaRm3wZdKkv40PaifmAgTw24cacK LmgmP5syIX8qgehVz3lR0/gyqDITgkP7zTRDbfNdYmihqici3t+0+DFcp5J29vzQrFP+2T tRu67X0g2SFWKh2JszH1TAOyTFd6zTx3DL/iWXRmhw6ASBQFJk8mQeuwDILfj96RJoqlMz EqJhgMg/g86ubSU+JVtE7zGcVZrKx0MZI9CP3CyznG/asXG+LUM/8MhKLEjlH7l+SyxADc 2fZ/ajWDPzIpPII4Y1ZfcigMHew5J2tZuAt60tikVgGfiTdgL+NR8nR+7OSlEg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vc5bp3zsJN; Mon, 15 Jul 2024 12:38:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcKKT060888; Mon, 15 Jul 2024 12:38:20 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcKs9060885; Mon, 15 Jul 2024 12:38:20 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:20 GMT Message-Id: <202407151238.46FCcKs9060885@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 3414984c3aff - stable/13 - arm64: add PMBSR_MSS_{BSC,FSC} status code field List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 3414984c3aff2a87d884c4110b69d2a81d6c090f Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=3414984c3aff2a87d884c4110b69d2a81d6c090f commit 3414984c3aff2a87d884c4110b69d2a81d6c090f Author: Zachary Leaf AuthorDate: 2023-09-20 09:51:22 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:29 +0000 arm64: add PMBSR_MSS_{BSC,FSC} status code field Bits [5:0] of PMBSR_MSS encodes either Buffer Status Code (BSC) or Fault Status Code (FSC) depending on PMBSR_EC value. Add PMBSR_MSS_{BSC,FSC} to cover this field. Reviewed by: andrew Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45172 (cherry picked from commit 10b3eac88db689d657c4d0d0716bcbdf240ff614) --- sys/arm64/include/armreg.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index 1c9dfc1c19a7..eb62945acaff 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -1692,6 +1692,8 @@ #define PMBSR_EL1_op2 3 #define PMBSR_MSS_SHIFT 0 #define PMBSR_MSS_MASK (UL(0xffff) << PMBSR_MSS_SHIFT) +#define PMBSR_MSS_BSC_MASK (UL(0x3f) << PMBSR_MSS_SHIFT) +#define PMBSR_MSS_FSC_MASK (UL(0x3f) << PMBSR_MSS_SHIFT) #define PMBSR_COLL_SHIFT 16 #define PMBSR_COLL (UL(0x1) << PMBSR_COLL_SHIFT) #define PMBSR_S_SHIFT 17 From nobody Mon Jul 15 12:38:19 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vc0WqZz5QrSP; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vb4w4Tz4HPj; Mon, 15 Jul 2024 12:38:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047099; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=jKTok8AnG/8tAUzhVLSl0J8RKCVIohEWMOsvixxTLKk=; b=r88262k0vk2KWk4UFHphErAVPghgqR4trw6PKy3WIL/JsOp1/sE1uzqsyUA5jiRtS1rc4C EMMpe1n+gBdalmNI9uaHOxdqqu219beTXg2NOuGAX3Vvsbx+0d/G/W6NxVWRXv4AIGW1EZ 8WdzXA8bB5G84oZ88gurBwmlp4NNEhZBluKRMZfd/EV/VlW7Y3S6SW7KustfXmz4898lBv J15l7jg5x39cLAah77AqIY6rZDy0WD0Ez2tgJAQji0+InwtWr9ulcmOYWJXNktFrlPJQDn aRlDWFB0CX9V0sNb9ePe/5wcHlFQPm27qxy4EQKC2aB0hvW2NLWLgsLTy79wPw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047099; a=rsa-sha256; cv=none; b=JebIMeedgZkd/85+d/ORv5c4SmmILaH+pi+YhAO4ooVOTtwlLIMr9X+Y6dHMMaxQ555wUx 4Ht/9A1MrV7wD9udTUYa0ADNGYeFXEAPHmdWar66DqTIjv4c7jUIiM2ZWi1Vpf3RuAwSvV pfacwTW8s3oTawbiqP/gzKgC+x/W2qpN3hVAy14SO8XDG+B2v78rFNWP0dJkq0gQCuWhCw MwMFrCBt3lFTO+iVbab1+PwUz4FMBYLmYZWjRX7BASywlhYCS9uQv4cvCTOgdYFMBYHZtu Q0irS6ByTE9IzfIO37bYN9rQ6ZrXU8YhI+0QjafMkBXje/dE8T5Kv8LbuJwf2A== 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=1721047099; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=jKTok8AnG/8tAUzhVLSl0J8RKCVIohEWMOsvixxTLKk=; b=uID1Jw1R/2UlOkBX27wNK1jjqQK0CrY0fucKD98gtot0pi4jph36aY6pnGHJ5T7le0AzKW SknF8xTDckxvW5/fPB2yBuCw190aEmZz7nQ//I5wR2t6bEtSvydku0vbsGDVOX7b/8fqTV 3m19cXpahV1Jb3M9bmo11mtHC1Vdgc+kiH4tl0RqUJrLC+fbISjg1V0DXW/bfzqk+E31/I XixqAVb5tdVA3TlrnouKNjXFBQT6g06NTFnP6sDDjxLqrVI50w9e4SOmjRBYX3dlMx+LF3 lE6gshkDX39s3hX+1edEcgjNvTGWqP/sQ7dYfPwNpi6FbGilrrKIbiXrX9ZfKw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vb4VZBzsZG; Mon, 15 Jul 2024 12:38:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcJXZ060792; Mon, 15 Jul 2024 12:38:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcJXT060789; Mon, 15 Jul 2024 12:38:19 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:19 GMT Message-Id: <202407151238.46FCcJXT060789@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 750fbcc0603f - stable/13 - arm64: make SPE regs use ALT_NAME macro List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 750fbcc0603fb9e7d9e4ee143e793674bf7649d7 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=750fbcc0603fb9e7d9e4ee143e793674bf7649d7 commit 750fbcc0603fb9e7d9e4ee143e793674bf7649d7 Author: Zachary Leaf AuthorDate: 2024-05-10 15:59:00 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:29 +0000 arm64: make SPE regs use ALT_NAME macro When the register is not defined in Armv8.0 i.e. added in a later extension, like SPE added in v8.2, the alternative name format of: S__C_C_ should be used; otherwise, calls to {READ,WRITE}_SPECIALREG() will fail. Use the MRS_REG_ALT_NAME() macro for SPE changing hex to decimal as required by the macro. Reviewed by: andrew Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45171 (cherry picked from commit f7bdaa103eb8906fc999c7fd5e8d6af440e26e6c) --- sys/arm64/include/armreg.h | 132 ++++++++++++++++++++++++--------------------- 1 file changed, 72 insertions(+), 60 deletions(-) diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index 92ad96550e56..1c9dfc1c19a7 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -1639,11 +1639,12 @@ /* PMBIDR_EL1 */ #define PMBIDR_EL1 MRS_REG(PMBIDR_EL1) -#define PMBIDR_EL1_op0 0x3 -#define PMBIDR_EL1_op1 0x0 -#define PMBIDR_EL1_CRn 0x9 -#define PMBIDR_EL1_CRm 0xa -#define PMBIDR_EL1_op2 0x7 +#define PMBIDR_EL1_REG MRS_REG_ALT_NAME(PMBIDR_EL1) +#define PMBIDR_EL1_op0 3 +#define PMBIDR_EL1_op1 0 +#define PMBIDR_EL1_CRn 9 +#define PMBIDR_EL1_CRm 10 +#define PMBIDR_EL1_op2 7 #define PMBIDR_Align_SHIFT 0 #define PMBIDR_Align_MASK (UL(0xf) << PMBIDR_Align_SHIFT) #define PMBIDR_P_SHIFT 4 @@ -1653,11 +1654,12 @@ /* PMBLIMITR_EL1 */ #define PMBLIMITR_EL1 MRS_REG(PMBLIMITR_EL1) -#define PMBLIMITR_EL1_op0 0x3 -#define PMBLIMITR_EL1_op1 0x0 -#define PMBLIMITR_EL1_CRn 0x9 -#define PMBLIMITR_EL1_CRm 0xa -#define PMBLIMITR_EL1_op2 0x0 +#define PMBLIMITR_EL1_REG MRS_REG_ALT_NAME(PMBLIMITR_EL1) +#define PMBLIMITR_EL1_op0 3 +#define PMBLIMITR_EL1_op1 0 +#define PMBLIMITR_EL1_CRn 9 +#define PMBLIMITR_EL1_CRm 10 +#define PMBLIMITR_EL1_op2 0 #define PMBLIMITR_E_SHIFT 0 #define PMBLIMITR_E (UL(0x1) << PMBLIMITR_E_SHIFT) #define PMBLIMITR_FM_SHIFT 1 @@ -1670,22 +1672,24 @@ /* PMBPTR_EL1 */ #define PMBPTR_EL1 MRS_REG(PMBPTR_EL1) -#define PMBPTR_EL1_op0 0x3 -#define PMBPTR_EL1_op1 0x0 -#define PMBPTR_EL1_CRn 0x9 -#define PMBPTR_EL1_CRm 0xa -#define PMBPTR_EL1_op2 0x1 +#define PMBPTR_EL1_REG MRS_REG_ALT_NAME(PMBPTR_EL1) +#define PMBPTR_EL1_op0 3 +#define PMBPTR_EL1_op1 0 +#define PMBPTR_EL1_CRn 9 +#define PMBPTR_EL1_CRm 10 +#define PMBPTR_EL1_op2 1 #define PMBPTR_PTR_SHIFT 0 #define PMBPTR_PTR_MASK \ (UL(0xffffffffffffffff) << PMBPTR_PTR_SHIFT) /* PMBSR_EL1 */ #define PMBSR_EL1 MRS_REG(PMBSR_EL1) -#define PMBSR_EL1_op0 0x3 -#define PMBSR_EL1_op1 0x0 -#define PMBSR_EL1_CRn 0x9 -#define PMBSR_EL1_CRm 0xa -#define PMBSR_EL1_op2 0x3 +#define PMBSR_EL1_REG MRS_REG_ALT_NAME(PMBSR_EL1) +#define PMBSR_EL1_op0 3 +#define PMBSR_EL1_op1 0 +#define PMBSR_EL1_CRn 9 +#define PMBSR_EL1_CRm 10 +#define PMBSR_EL1_op2 3 #define PMBSR_MSS_SHIFT 0 #define PMBSR_MSS_MASK (UL(0xffff) << PMBSR_MSS_SHIFT) #define PMBSR_COLL_SHIFT 16 @@ -1851,11 +1855,12 @@ /* PMSCR_EL1 */ #define PMSCR_EL1 MRS_REG(PMSCR_EL1) -#define PMSCR_EL1_op0 0x3 -#define PMSCR_EL1_op1 0x0 -#define PMSCR_EL1_CRn 0x9 -#define PMSCR_EL1_CRm 0x9 -#define PMSCR_EL1_op2 0x0 +#define PMSCR_EL1_REG MRS_REG_ALT_NAME(PMSCR_EL1) +#define PMSCR_EL1_op0 3 +#define PMSCR_EL1_op1 0 +#define PMSCR_EL1_CRn 9 +#define PMSCR_EL1_CRm 9 +#define PMSCR_EL1_op2 0 #define PMSCR_E0SPE_SHIFT 0 #define PMSCR_E0SPE (UL(0x1) << PMSCR_E0SPE_SHIFT) #define PMSCR_E1SPE_SHIFT 1 @@ -1880,19 +1885,21 @@ /* PMSEVFR_EL1 */ #define PMSEVFR_EL1 MRS_REG(PMSEVFR_EL1) -#define PMSEVFR_EL1_op0 0x3 -#define PMSEVFR_EL1_op1 0x0 -#define PMSEVFR_EL1_CRn 0x9 -#define PMSEVFR_EL1_CRm 0x9 -#define PMSEVFR_EL1_op2 0x5 +#define PMSEVFR_EL1_REG MRS_REG_ALT_NAME(PMSEVFR_EL1) +#define PMSEVFR_EL1_op0 3 +#define PMSEVFR_EL1_op1 0 +#define PMSEVFR_EL1_CRn 9 +#define PMSEVFR_EL1_CRm 9 +#define PMSEVFR_EL1_op2 5 /* PMSFCR_EL1 */ #define PMSFCR_EL1 MRS_REG(PMSFCR_EL1) -#define PMSFCR_EL1_op0 0x3 -#define PMSFCR_EL1_op1 0x0 -#define PMSFCR_EL1_CRn 0x9 -#define PMSFCR_EL1_CRm 0x9 -#define PMSFCR_EL1_op2 0x4 +#define PMSFCR_EL1_REG MRS_REG_ALT_NAME(PMSFCR_EL1) +#define PMSFCR_EL1_op0 3 +#define PMSFCR_EL1_op1 0 +#define PMSFCR_EL1_CRn 9 +#define PMSFCR_EL1_CRm 9 +#define PMSFCR_EL1_op2 4 #define PMSFCR_FE_SHIFT 0 #define PMSFCR_FE (UL(0x1) << PMSFCR_FE_SHIFT) #define PMSFCR_FT_SHIFT 1 @@ -1910,11 +1917,12 @@ /* PMSICR_EL1 */ #define PMSICR_EL1 MRS_REG(PMSICR_EL1) -#define PMSICR_EL1_op0 0x3 -#define PMSICR_EL1_op1 0x0 -#define PMSICR_EL1_CRn 0x9 -#define PMSICR_EL1_CRm 0x9 -#define PMSICR_EL1_op2 0x2 +#define PMSICR_EL1_REG MRS_REG_ALT_NAME(PMSICR_EL1) +#define PMSICR_EL1_op0 3 +#define PMSICR_EL1_op1 0 +#define PMSICR_EL1_CRn 9 +#define PMSICR_EL1_CRm 9 +#define PMSICR_EL1_op2 2 #define PMSICR_COUNT_SHIFT 0 #define PMSICR_COUNT_MASK (UL(0xffffffff) << PMSICR_COUNT_SHIFT) #define PMSICR_ECOUNT_SHIFT 56 @@ -1922,11 +1930,12 @@ /* PMSIDR_EL1 */ #define PMSIDR_EL1 MRS_REG(PMSIDR_EL1) -#define PMSIDR_EL1_op0 0x3 -#define PMSIDR_EL1_op1 0x0 -#define PMSIDR_EL1_CRn 0x9 -#define PMSIDR_EL1_CRm 0x9 -#define PMSIDR_EL1_op2 0x7 +#define PMSIDR_EL1_REG MRS_REG_ALT_NAME(PMSIDR_EL1) +#define PMSIDR_EL1_op0 3 +#define PMSIDR_EL1_op1 0 +#define PMSIDR_EL1_CRn 9 +#define PMSIDR_EL1_CRm 9 +#define PMSIDR_EL1_op2 7 #define PMSIDR_FE_SHIFT 0 #define PMSIDR_FE (UL(0x1) << PMSIDR_FE_SHIFT) #define PMSIDR_FT_SHIFT 1 @@ -1954,11 +1963,12 @@ /* PMSIRR_EL1 */ #define PMSIRR_EL1 MRS_REG(PMSIRR_EL1) -#define PMSIRR_EL1_op0 0x3 -#define PMSIRR_EL1_op1 0x0 -#define PMSIRR_EL1_CRn 0x9 -#define PMSIRR_EL1_CRm 0x9 -#define PMSIRR_EL1_op2 0x3 +#define PMSIRR_EL1_REG MRS_REG_ALT_NAME(PMSIRR_EL1) +#define PMSIRR_EL1_op0 3 +#define PMSIRR_EL1_op1 0 +#define PMSIRR_EL1_CRn 9 +#define PMSIRR_EL1_CRm 9 +#define PMSIRR_EL1_op2 3 #define PMSIRR_RND_SHIFT 0 #define PMSIRR_RND (UL(0x1) << PMSIRR_RND_SHIFT) #define PMSIRR_INTERVAL_SHIFT 8 @@ -1966,21 +1976,23 @@ /* PMSLATFR_EL1 */ #define PMSLATFR_EL1 MRS_REG(PMSLATFR_EL1) -#define PMSLATFR_EL1_op0 0x3 -#define PMSLATFR_EL1_op1 0x0 -#define PMSLATFR_EL1_CRn 0x9 -#define PMSLATFR_EL1_CRm 0x9 -#define PMSLATFR_EL1_op2 0x6 +#define PMSLATFR_EL1_REG MRS_REG_ALT_NAME(PMSLATFR_EL1) +#define PMSLATFR_EL1_op0 3 +#define PMSLATFR_EL1_op1 0 +#define PMSLATFR_EL1_CRn 9 +#define PMSLATFR_EL1_CRm 9 +#define PMSLATFR_EL1_op2 6 #define PMSLATFR_MINLAT_SHIFT 0 #define PMSLATFR_MINLAT_MASK (UL(0xfff) << PMSLATFR_MINLAT_SHIFT) /* PMSNEVFR_EL1 */ #define PMSNEVFR_EL1 MRS_REG(PMSNEVFR_EL1) -#define PMSNEVFR_EL1_op0 0x3 -#define PMSNEVFR_EL1_op1 0x0 -#define PMSNEVFR_EL1_CRn 0x9 -#define PMSNEVFR_EL1_CRm 0x9 -#define PMSNEVFR_EL1_op2 0x1 +#define PMSNEVFR_EL1_REG MRS_REG_ALT_NAME(PMSNEVFR_EL1) +#define PMSNEVFR_EL1_op0 3 +#define PMSNEVFR_EL1_op1 0 +#define PMSNEVFR_EL1_CRn 9 +#define PMSNEVFR_EL1_CRm 9 +#define PMSNEVFR_EL1_op2 1 /* PMSWINC_EL0 */ #define PMSWINC_EL0 MRS_REG(PMSWINC_EL0) From nobody Mon Jul 15 12:38:20 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vc5yl7z5Qrh0; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vc3K0kz4HZ4; Mon, 15 Jul 2024 12:38:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047100; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=/pv1YCOxvhs1NnL/t05cKNMGn1PIGhsnYN38RtACeQI=; b=iyNqjSVdOJhs9seZRyG57nIC6Rfln3ZEd9kJV1aykHlCKgmRyrFow0AHfMebcjEiD4JBE7 76obTtRINDbxxzYzEPSCxI0lNnmAizAKoUzY9bivgrcMQ71XcPhJncLErlWoIRYERldbIu 7WJZyMPC+f16Gjv7PVtzZ10WyA4GfaTC+t7duBgbkbIsDiKIIcmmKSzCbjPmRkq4YkbrpG Cj9/nBT9uaH3/9oWYymmlo/MWR9P3w4DHAvOcEmUugjgNWdjLOin5hTG4qBw8exEP8gkZW SNj7bltFqbsO1bUmv2ootIWAXvCdAQ9oFDVFDvbQEAo3b2TxxYcqmBavSR1I3g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047100; a=rsa-sha256; cv=none; b=wVttVBkmn0nE4we5SnGXXjIG7V6RWUoHhvRkwxLakalntV94x1Uy+T4nMQrEZhamGaKH+L icfwr83ydHSnIfPa5mW65bL/kswizswmPoNRN9TwNv3kx1fP+dqAPT6XCFyHfIIkuMF6Df jEj2Ng10LrZHLC2Dl6e+TixiY93jwAIVKSeSM7XGqMjYvuPDpQTqX9GNO2rvhhrlVrC04H BB4g5qwHqIwi54SiXw76cK4dTFjaFp1daA1rAqo25XrQciUPszOxChxIwdR+Xp2OypCprD rz/ado0v5KD0ROtwYKC2K6DBiU/C9Z2kBqjj4/PCWnBh1k/UFL0yAfgYoNkk2Q== 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=1721047100; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=/pv1YCOxvhs1NnL/t05cKNMGn1PIGhsnYN38RtACeQI=; b=Ve1/rgXC3K2vvHCXDAnelHwNvj/fe6DiCxxKUElJTkxhY/ibc6+2BewUdyqBR/5xwKY+vR eqMHed3aelf8Lq4crcaTE6SsdB8ay4J6pcO23G0tQYou/AzwYNaWtDSCXvz2iy/Zc3gV8B z/AB1/lZB6MkQrlBpyUazMuBzgtRpyE4Nu0rqgBjTW5DX+SKKpRglNlINn1kM42K2Omn/O PoSdTB3prW8aq2HOdXqSsw0fhVMw7tDkBuJaGbZVrxplPtjtQI4KJAzTu17/182fSqfcdt 0vYSc0oYPt933vb9dLb6GOQCUwdOwTkXkYRpb0XYL7hpeJiIlVwhdMixpze6FQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vc2wqmzt5h; Mon, 15 Jul 2024 12:38:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcKdn060843; Mon, 15 Jul 2024 12:38:20 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcK0A060840; Mon, 15 Jul 2024 12:38:20 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:20 GMT Message-Id: <202407151238.46FCcK0A060840@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 71f04a360965 - stable/14 - csu: Find the main pointer through the GOT List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 71f04a3609655a1b9cfb28d45e2f5bf41dcb4e67 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=71f04a3609655a1b9cfb28d45e2f5bf41dcb4e67 commit 71f04a3609655a1b9cfb28d45e2f5bf41dcb4e67 Author: Andrew Turner AuthorDate: 2024-05-22 08:18:10 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:26:22 +0000 csu: Find the main pointer through the GOT Use the Global Offset Table to find the location of main in crt1. With lld the old code would point to main@plt, however ld.bfd fails to link when main is in a shared library. Fix this by using the GOT address to find main as it works with both lld and bfd. Reviewed by: jrtc27 Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45259 (cherry picked from commit 53120fbb68952b7d620c2c0e1cf05c5017fc1b27) --- lib/csu/aarch64/crt1_s.S | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/csu/aarch64/crt1_s.S b/lib/csu/aarch64/crt1_s.S index 981cf4653efd..1fb60f756a7a 100644 --- a/lib/csu/aarch64/crt1_s.S +++ b/lib/csu/aarch64/crt1_s.S @@ -44,8 +44,8 @@ ENTRY(_start) add x2, x1, x0, lsl #3 /* env is after argv */ add x2, x2, #8 /* argv is null terminated */ #ifdef PIC - adrp x4, main - add x4, x4, :lo12:main + adrp x4, :got:main + ldr x4, [x4, :got_lo12:main] #else ldr x4, =main #endif From nobody Mon Jul 15 12:38:21 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vd6KL7z5Qrq5; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vd4Qgwz4Hcx; Mon, 15 Jul 2024 12:38:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047101; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=1BtEsuq7zJ2g2u05lejAMZN4MCW3wCjMr6AArr2RhIg=; b=mwYpuafwKJWZJd1eO0sYURTytt3/zhbw+JDljq8jVY1rUlByNybHcPVKI9heMNHiDk9NxS Eo4Xrik7V0fN2phX8yMOmnHlOqowyylC8wqJSSFS+j+OekXn8/sM+XiqKYBz0YRQyrI6dC tarrXD9AlgJHfxiJbONfSjXTI0pGoBdzazYtnsG485hEFknPmPSLGNwSJ6mobXs3l9q8jN 09+Mj393RrG/R4aGx/XvN/oYxjRkbNUUB8YyE6CDhyMto1iEVt3onwJlrjMKHlZ3ReTJGN ehGykTZmWoiEl8YiKTyZSzqENaVM1vKQZjpYU+pzfJtPhIkTei2ptA5C67VyYw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047101; a=rsa-sha256; cv=none; b=E/x2rlPg8ERo+drFpswwh7T8a1sYUCgi2XQMt1AGEnmalXmBiyNZtx0wqO2DMhMA05CipY hQoG7pMNOSqiXfUQouBoK1EI0aZOIvtYNEXDVWgsURJMdSAVnync6PC4Rfcetxp0Ph0MUq PZAumlbNVWgjS2fpOxPtbaP4FVg1T6iDaQYKcgD85oqfXJlGdJkcc4g3B/jfExyGBYqJUa gT4DFzErhEg2MtjERpSND1F7yCnE8ohYP05ZNxT9NVJPLYcbc7bdSJ3Sm4SLQtccGbZdYx iq923Do1wru8/VI48lX020KSmDb7fiwRYb8rY51tio88sJjwkBPM8sVM3BZabw== 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=1721047101; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=1BtEsuq7zJ2g2u05lejAMZN4MCW3wCjMr6AArr2RhIg=; b=gEYTxRPw+TnfkIPefPer66Jc/43x3EXfUv5VsnFeuCklHhHVCZTua68970XkGmVaBOgpEk 4vy09AtPN+hsr8gQ8yJIONbMeJ1jt9oOrVrzW0mZoLVHdWxYqQu0oA6U4h+zDxqplzh2l+ APTxyqFW13hZv54KoNP9NO1Va+5Ngv4X4eWt3yez6zb8RQdSRDu8NfWX8D97FfY1qFxrs/ H5iROkj1fca4hy1salwP3+hEo3ve5UcQJ83tpzHtM+vY3ftxea3e9UZ6AESBvogD8jK+pn ZvywCWnvUzqcrOR6zN3H4W+6TVfWOV9IuUuJ4neUPA23puGxsxo1aSEzmJAZgg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vd41pJzt1Q; Mon, 15 Jul 2024 12:38:21 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcLNQ060927; Mon, 15 Jul 2024 12:38:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcLog060924; Mon, 15 Jul 2024 12:38:21 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:21 GMT Message-Id: <202407151238.46FCcLog060924@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: e63ac0eb580b - stable/14 - sys/sys: Fix __builtin_is_aligned fallback List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: e63ac0eb580b287201eb7a8aa3644d6c249a9cce Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=e63ac0eb580b287201eb7a8aa3644d6c249a9cce commit e63ac0eb580b287201eb7a8aa3644d6c249a9cce Author: Andrew Turner AuthorDate: 2024-05-22 08:18:26 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:26:34 +0000 sys/sys: Fix __builtin_is_aligned fallback When the compiler doesn't provide __builtin_is_aligned we use macro as a fallback. The macro was missing brackets around one argument. This could lead to incorrect results when the argument is more complex than a single stagement. Fix this by adding the needed brackets. Reviewed by: brooks, imp, jhb Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45260 (cherry picked from commit 940155d24afb5c80ce7fde59c856c5c0d5c6dbe1) --- sys/sys/cdefs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/sys/cdefs.h b/sys/sys/cdefs.h index 4893ae1662b8..84411e8e4b16 100644 --- a/sys/sys/cdefs.h +++ b/sys/sys/cdefs.h @@ -913,7 +913,7 @@ /* Provide fallback versions for other compilers (GCC/Clang < 10): */ #if !__has_builtin(__builtin_is_aligned) #define __builtin_is_aligned(x, align) \ - (((__uintptr_t)x & ((align) - 1)) == 0) + (((__uintptr_t)(x) & ((align) - 1)) == 0) #endif #if !__has_builtin(__builtin_align_up) #define __builtin_align_up(x, align) \ From nobody Mon Jul 15 12:38:21 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vf2zcZz5QrYJ; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vd6scKz4HSg; Mon, 15 Jul 2024 12:38:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047102; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ZDRjHIInX6MP7/2JJvXRiEPJWimLMzItArRKAZeUVEg=; b=CWNX+doRNWHUfmxq+6UvXcv82egon/ly40Dsi6fJnLmUMrYTfV4FelXXcKvFS+ZPTdWwld 2dbuhQ4OY02O9wk8LpRywiBWP1pOtMpDbi6uirCCJ6TNMhaOebDTLiiK23Jo0x6tP5cfBP hFWeke3EAdFmOltYfrR/8BqhZ/WCG+KSiPCST5ph+md7PSor8HaEJgoEyzqUGt9pcos+Ri zL4vO1whhLd//P4GJ2T/bdNuaBT0Z9FHjcehMFDJzkXdgg7/zWxCBzoXKOOj2yDHU9aKHM bCQcdiQilxG0IZLSOW2rEulQo1Ddn4QkmWiwvQQB9nA18uY7tAW/ZgWHf+JUdg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047102; a=rsa-sha256; cv=none; b=RsGdTlu8M+LkFqqn+NXVoxtAgfiaHArRwFG/8v4xKex32UY6GNsghA8N7xaNOhvkah9dVn wx/QW9ysQFoM58RzFP4rcGZbl6osVDxc6U6E4tfhZXOPqLTU8GsXKGgvLSGowqEdWlIPwK Tqc+jnBjPEBsIm89n7NYfpkiAFZ8844yBpVn7fr81KMz1ZoguwGI3dB5kn8slnDGy69qQN q5C9vs9ZU5GoIlIXk/Q/3Q9EycE/Nl/82GKUT0M7HktPxi17qFSS2Det/zRzcxZZ44ToAt yyoE0SpAB7aFnvWb6ajaZymVjxU0plylcU7puP62q4DVMQmrL0nd2Ca/jGFuJg== 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=1721047102; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ZDRjHIInX6MP7/2JJvXRiEPJWimLMzItArRKAZeUVEg=; b=getyvGopRhPzRyYd15CWmgA9Py3gLQBWt+QLmqlEfW2YG1B/Ko74VTw9wPQLkrjfofkmsG SjLSLoSk7HQfIal3uRFbChXIMJLXOOD0lvEJcXT0uvzlHwVOLd6eBihM4WAXUILyPzFS3e ViVHNJHi8sQFS/43R8PBGteh5kG7/Y8JIg+m/neLCbil37cq82NycuQg1Qru4DDWa58121 9QcHEOYBtK38zEct/eK2S7V4DH1sNgsT9L4qIO+zC0FBxEtLFkuiWUPXSf/FbnHT9MkWGK gLkI6BlwfujTP5TRlf2hGqAkJhNpB0g7hQjDzAyhTVsIYiFP1rAkOErmiUwaYw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vd6V8NzspD; Mon, 15 Jul 2024 12:38:21 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcLJr060981; Mon, 15 Jul 2024 12:38:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcLYq060978; Mon, 15 Jul 2024 12:38:21 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:21 GMT Message-Id: <202407151238.46FCcLYq060978@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 7f616da3cea0 - stable/13 - arm: Add a missing interrupt to the generic timer List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 7f616da3cea0e53399db7ad7ad7f6f391b17e364 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=7f616da3cea0e53399db7ad7ad7f6f391b17e364 commit 7f616da3cea0e53399db7ad7ad7f6f391b17e364 Author: Andrew Turner AuthorDate: 2024-01-11 17:07:59 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:29 +0000 arm: Add a missing interrupt to the generic timer The ACPI generic timer attachment added 3 interrupts, but missed the hypervisor physical interrupt. As the field is present in all versions of the GTDT ACPI table and isn't an optional interrupts we can add it to the interrupts provided to the driver. Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D43974 (cherry picked from commit f715e95461c9264913a65e2dc93c291b7e318d2e) --- sys/arm/arm/generic_timer.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sys/arm/arm/generic_timer.c b/sys/arm/arm/generic_timer.c index f08ddf830a77..40990d64cd5d 100644 --- a/sys/arm/arm/generic_timer.c +++ b/sys/arm/arm/generic_timer.c @@ -518,6 +518,8 @@ arm_tmr_acpi_identify(driver_t *driver, device_t parent) gtdt->NonSecureEl1Interrupt); arm_tmr_acpi_add_irq(parent, dev, GT_VIRT, gtdt->VirtualTimerInterrupt); + arm_tmr_acpi_add_irq(parent, dev, GT_HYP_PHYS, + gtdt->NonSecureEl2Interrupt); out: acpi_unmap_table(gtdt); From nobody Mon Jul 15 12:38:22 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vg2brRz5QrdK; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vf5Qnwz4Hm6; Mon, 15 Jul 2024 12:38:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047102; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=PxlsHCfHsP0PabowsO6GN7c+uzAgObhIbcwJQODl+6Q=; b=uieIZwmEUXBtSD6DUpAVZoln3gMyZgPt0fesbRi1oNrl1AobI1xgU9qM33nOaWhXk7Fh8M ORFxTWDQzjdOn1vcdp+WgF0Mxd/CgZOiphAn82Xr+2Ufn8COqmVLQ0PuvgMJS3WRFkrgJR Fo7XGUvHHtUyS2LQOdmnmmav5E5N8AOnOWtjufoHPJn+JeiPND+I5064Aj54AWnz1WhSQa kYneJCZOtSTg92jbdDzROMyjfk5ry+ssfb+Tk0Qd53m17T4FWIwyrnA+5DGlOxCj3NOtJC As6V+a4LZfpsS8wbxhBVywZ8WVfUsUcATzmEljkE8YT7UV33SQK3U9666p6P0g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047102; a=rsa-sha256; cv=none; b=aTjdp/OQt9c6LZ1iyIAFgIJLpWvNkiU+4dFyj155ZiESDwmHMkE1lBirIr9XMZDN5OhNjt MlN78Ul/cAz9K76Qc617nNLWmFgSKVc3HAN8uoUi38aiJ/32SLmMlru/X5AoPjBJok5gDZ Df/eT4VhkFsrZeuXuwHGKDgSt/40QkldLYwmYyFqgEyFn1zDqr0MZn+yBSflDWbKIepXAx dZM5pM8px7C81N+aVmOClKRtKM+2l0pyzi9YLoKJRarGJjlpZQkCRfW9KsNoeFuPjd27sK HEZBLt55n4QPXqyWJmUzymyd43tVNpEkOyWwzTankCbPAIk2McjO68TWfGoSFQ== 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=1721047102; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=PxlsHCfHsP0PabowsO6GN7c+uzAgObhIbcwJQODl+6Q=; b=kZwSaHmO/E3k83P8NpEtY7Ugq48Q6w8xnSpibDM/TswBAqLlLPKt3yL7mIPc/GKrhr02BB MIE6/NxgLm97seeWEKkTS/k6DxluTdjqTQZGcbPdxGNj5rl5gx1jbXnI7RgbxYonFJ2P61 AdXL+1KfPNCyp8/Xz7HMpUxi0nGwHXuWCqMShT1sYTuYJ+Qq+rDjtYBuN+hGxLmA2dZ/D+ TCUdf14Y/5Nbl1weZLW8dXltSW8ZqI7mS9n8SJy1pE0M+cFtlJmB15XN3hY9K5UHxH4Kgj 7TyqRRf3i8rgEAdGIs7IUX4ED0NPzQCAob6FboNXggyd2PCShgWAiMJMPpSFNQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vf52qRzt3G; Mon, 15 Jul 2024 12:38:22 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcM5t061032; Mon, 15 Jul 2024 12:38:22 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcMtJ061029; Mon, 15 Jul 2024 12:38:22 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:22 GMT Message-Id: <202407151238.46FCcMtJ061029@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 98740a0ef56f - stable/14 - arm64: Use the UL macro in TCR_EL1 defines List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 98740a0ef56f6b3c5cc9226728ccbe56c2bf07ed Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=98740a0ef56f6b3c5cc9226728ccbe56c2bf07ed commit 98740a0ef56f6b3c5cc9226728ccbe56c2bf07ed Author: Andrew Turner AuthorDate: 2024-05-22 08:18:39 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:26:46 +0000 arm64: Use the UL macro in TCR_EL1 defines While clang can handle numbers with a UL suffix in assembly files gcc/gas is unable to. Switch to use the UL macro for TCR_EL1 defines as some are used in locore.S Reviewed by: brooks, jhb Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45261 (cherry picked from commit 29c1cf9860e531146220d9dc3596e4c79f91cfcd) --- sys/arm64/include/armreg.h | 96 +++++++++++++++++++++++----------------------- 1 file changed, 48 insertions(+), 48 deletions(-) diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index e90c6a57fd55..243c9276cee0 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -2133,99 +2133,99 @@ /* TCR_EL1 - Translation Control Register */ /* Bits 63:59 are reserved */ #define TCR_TCMA1_SHIFT 58 -#define TCR_TCMA1 (1UL << TCR_TCMA1_SHIFT) +#define TCR_TCMA1 (UL(1) << TCR_TCMA1_SHIFT) #define TCR_TCMA0_SHIFT 57 -#define TCR_TCMA0 (1UL << TCR_TCMA0_SHIFT) +#define TCR_TCMA0 (UL(1) << TCR_TCMA0_SHIFT) #define TCR_E0PD1_SHIFT 56 -#define TCR_E0PD1 (1UL << TCR_E0PD1_SHIFT) +#define TCR_E0PD1 (UL(1) << TCR_E0PD1_SHIFT) #define TCR_E0PD0_SHIFT 55 -#define TCR_E0PD0 (1UL << TCR_E0PD0_SHIFT) +#define TCR_E0PD0 (UL(1) << TCR_E0PD0_SHIFT) #define TCR_NFD1_SHIFT 54 -#define TCR_NFD1 (1UL << TCR_NFD1_SHIFT) +#define TCR_NFD1 (UL(1) << TCR_NFD1_SHIFT) #define TCR_NFD0_SHIFT 53 -#define TCR_NFD0 (1UL << TCR_NFD0_SHIFT) +#define TCR_NFD0 (UL(1) << TCR_NFD0_SHIFT) #define TCR_TBID1_SHIFT 52 -#define TCR_TBID1 (1UL << TCR_TBID1_SHIFT) +#define TCR_TBID1 (UL(1) << TCR_TBID1_SHIFT) #define TCR_TBID0_SHIFT 51 -#define TCR_TBID0 (1UL << TCR_TBID0_SHIFT) +#define TCR_TBID0 (UL(1) << TCR_TBID0_SHIFT) #define TCR_HWU162_SHIFT 50 -#define TCR_HWU162 (1UL << TCR_HWU162_SHIFT) +#define TCR_HWU162 (UL(1) << TCR_HWU162_SHIFT) #define TCR_HWU161_SHIFT 49 -#define TCR_HWU161 (1UL << TCR_HWU161_SHIFT) +#define TCR_HWU161 (UL(1) << TCR_HWU161_SHIFT) #define TCR_HWU160_SHIFT 48 -#define TCR_HWU160 (1UL << TCR_HWU160_SHIFT) +#define TCR_HWU160 (UL(1) << TCR_HWU160_SHIFT) #define TCR_HWU159_SHIFT 47 -#define TCR_HWU159 (1UL << TCR_HWU159_SHIFT) +#define TCR_HWU159 (UL(1) << TCR_HWU159_SHIFT) #define TCR_HWU1 \ (TCR_HWU159 | TCR_HWU160 | TCR_HWU161 | TCR_HWU162) #define TCR_HWU062_SHIFT 46 -#define TCR_HWU062 (1UL << TCR_HWU062_SHIFT) +#define TCR_HWU062 (UL(1) << TCR_HWU062_SHIFT) #define TCR_HWU061_SHIFT 45 -#define TCR_HWU061 (1UL << TCR_HWU061_SHIFT) +#define TCR_HWU061 (UL(1) << TCR_HWU061_SHIFT) #define TCR_HWU060_SHIFT 44 -#define TCR_HWU060 (1UL << TCR_HWU060_SHIFT) +#define TCR_HWU060 (UL(1) << TCR_HWU060_SHIFT) #define TCR_HWU059_SHIFT 43 -#define TCR_HWU059 (1UL << TCR_HWU059_SHIFT) +#define TCR_HWU059 (UL(1) << TCR_HWU059_SHIFT) #define TCR_HWU0 \ (TCR_HWU059 | TCR_HWU060 | TCR_HWU061 | TCR_HWU062) #define TCR_HPD1_SHIFT 42 -#define TCR_HPD1 (1UL << TCR_HPD1_SHIFT) +#define TCR_HPD1 (UL(1) << TCR_HPD1_SHIFT) #define TCR_HPD0_SHIFT 41 -#define TCR_HPD0 (1UL << TCR_HPD0_SHIFT) +#define TCR_HPD0 (UL(1) << TCR_HPD0_SHIFT) #define TCR_HD_SHIFT 40 -#define TCR_HD (1UL << TCR_HD_SHIFT) +#define TCR_HD (UL(1) << TCR_HD_SHIFT) #define TCR_HA_SHIFT 39 -#define TCR_HA (1UL << TCR_HA_SHIFT) +#define TCR_HA (UL(1) << TCR_HA_SHIFT) #define TCR_TBI1_SHIFT 38 -#define TCR_TBI1 (1UL << TCR_TBI1_SHIFT) +#define TCR_TBI1 (UL(1) << TCR_TBI1_SHIFT) #define TCR_TBI0_SHIFT 37 -#define TCR_TBI0 (1UL << TCR_TBI0_SHIFT) +#define TCR_TBI0 (UL(1) << TCR_TBI0_SHIFT) #define TCR_ASID_SHIFT 36 #define TCR_ASID_WIDTH 1 -#define TCR_ASID_16 (1UL << TCR_ASID_SHIFT) +#define TCR_ASID_16 (UL(1) << TCR_ASID_SHIFT) /* Bit 35 is reserved */ #define TCR_IPS_SHIFT 32 #define TCR_IPS_WIDTH 3 -#define TCR_IPS_32BIT (0UL << TCR_IPS_SHIFT) -#define TCR_IPS_36BIT (1UL << TCR_IPS_SHIFT) -#define TCR_IPS_40BIT (2UL << TCR_IPS_SHIFT) -#define TCR_IPS_42BIT (3UL << TCR_IPS_SHIFT) -#define TCR_IPS_44BIT (4UL << TCR_IPS_SHIFT) -#define TCR_IPS_48BIT (5UL << TCR_IPS_SHIFT) +#define TCR_IPS_32BIT (UL(0) << TCR_IPS_SHIFT) +#define TCR_IPS_36BIT (UL(1) << TCR_IPS_SHIFT) +#define TCR_IPS_40BIT (UL(2) << TCR_IPS_SHIFT) +#define TCR_IPS_42BIT (UL(3) << TCR_IPS_SHIFT) +#define TCR_IPS_44BIT (UL(4) << TCR_IPS_SHIFT) +#define TCR_IPS_48BIT (UL(5) << TCR_IPS_SHIFT) #define TCR_TG1_SHIFT 30 -#define TCR_TG1_MASK (3UL << TCR_TG1_SHIFT) -#define TCR_TG1_16K (1UL << TCR_TG1_SHIFT) -#define TCR_TG1_4K (2UL << TCR_TG1_SHIFT) -#define TCR_TG1_64K (3UL << TCR_TG1_SHIFT) +#define TCR_TG1_MASK (UL(3) << TCR_TG1_SHIFT) +#define TCR_TG1_16K (UL(1) << TCR_TG1_SHIFT) +#define TCR_TG1_4K (UL(2) << TCR_TG1_SHIFT) +#define TCR_TG1_64K (UL(3) << TCR_TG1_SHIFT) #define TCR_SH1_SHIFT 28 -#define TCR_SH1_IS (3UL << TCR_SH1_SHIFT) +#define TCR_SH1_IS (UL(3) << TCR_SH1_SHIFT) #define TCR_ORGN1_SHIFT 26 -#define TCR_ORGN1_WBWA (1UL << TCR_ORGN1_SHIFT) +#define TCR_ORGN1_WBWA (UL(1) << TCR_ORGN1_SHIFT) #define TCR_IRGN1_SHIFT 24 -#define TCR_IRGN1_WBWA (1UL << TCR_IRGN1_SHIFT) +#define TCR_IRGN1_WBWA (UL(1) << TCR_IRGN1_SHIFT) #define TCR_EPD1_SHIFT 23 -#define TCR_EPD1 (1UL << TCR_EPD1_SHIFT) +#define TCR_EPD1 (UL(1) << TCR_EPD1_SHIFT) #define TCR_A1_SHIFT 22 -#define TCR_A1 (0x1UL << TCR_A1_SHIFT) +#define TCR_A1 (UL(1) << TCR_A1_SHIFT) #define TCR_T1SZ_SHIFT 16 -#define TCR_T1SZ_MASK (0x3fUL << TCR_T1SZ_SHIFT) +#define TCR_T1SZ_MASK (UL(0x3f) << TCR_T1SZ_SHIFT) #define TCR_T1SZ(x) ((x) << TCR_T1SZ_SHIFT) #define TCR_TG0_SHIFT 14 -#define TCR_TG0_MASK (3UL << TCR_TG0_SHIFT) -#define TCR_TG0_4K (0UL << TCR_TG0_SHIFT) -#define TCR_TG0_64K (1UL << TCR_TG0_SHIFT) -#define TCR_TG0_16K (2UL << TCR_TG0_SHIFT) +#define TCR_TG0_MASK (UL(3) << TCR_TG0_SHIFT) +#define TCR_TG0_4K (UL(0) << TCR_TG0_SHIFT) +#define TCR_TG0_64K (UL(1) << TCR_TG0_SHIFT) +#define TCR_TG0_16K (UL(2) << TCR_TG0_SHIFT) #define TCR_SH0_SHIFT 12 -#define TCR_SH0_IS (3UL << TCR_SH0_SHIFT) +#define TCR_SH0_IS (UL(3) << TCR_SH0_SHIFT) #define TCR_ORGN0_SHIFT 10 -#define TCR_ORGN0_WBWA (1UL << TCR_ORGN0_SHIFT) +#define TCR_ORGN0_WBWA (UL(1) << TCR_ORGN0_SHIFT) #define TCR_IRGN0_SHIFT 8 -#define TCR_IRGN0_WBWA (1UL << TCR_IRGN0_SHIFT) +#define TCR_IRGN0_WBWA (UL(1) << TCR_IRGN0_SHIFT) #define TCR_EPD0_SHIFT 7 -#define TCR_EPD0 (1UL << TCR_EPD0_SHIFT) +#define TCR_EPD0 (UL(1) << TCR_EPD0_SHIFT) /* Bit 6 is reserved */ #define TCR_T0SZ_SHIFT 0 -#define TCR_T0SZ_MASK (0x3fUL << TCR_T0SZ_SHIFT) +#define TCR_T0SZ_MASK (UL(0x3f) << TCR_T0SZ_SHIFT) #define TCR_T0SZ(x) ((x) << TCR_T0SZ_SHIFT) #define TCR_TxSZ(x) (TCR_T1SZ(x) | TCR_T0SZ(x)) From nobody Mon Jul 15 12:38:23 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vh0vSxz5QrnV; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vg6QZ7z4HZj; Mon, 15 Jul 2024 12:38:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047103; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=SWnhBBkPBnqJAYPEfhW0WcoPqLgK4AM0e3oplrBfnMQ=; b=O9a16iRzyWMYzwpRSajBChOtjfyRvtyLhiXyBe0aGmTrx2VoNQe04ExUk03DwGi5xpU/2l JQR3ym7rEJYcWcSZ3BD6hT5pkSYmXwQoxLDFnXUOSTldRawGvcCKBqc8/KwZFqGrbicepI XBlMvhIR76GHrbaiROFQ5z12tqOR4nDK1jvHzWJjLlUPyKWvlbEsX1oJeTriMpc5XyNC6r BFvllGKQNcLjj+gkQzgCm23Lr78Kh9B3T2AaKVh7PIVNfm+UH9Vcbh02cz+j7ZewMhILnM oNoLVVvD+XI5cCZVpCJ9xPsji4eYfzKqUqw/TATiV5B/bYVUpKLe8wOjUcV8Pw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047103; a=rsa-sha256; cv=none; b=GqYHSFekOUQepoI7MlOQ46kUHOOKbZ4QWW/qXjlHWqzF2xeP7AHj3aqf3rp0FqxqrPOtZ1 qI1BIEuKbVpPb4V3CzLUPPwMxO7Hd09/XYcgDobgN9An1LuFnHYzwwI5m2DzLM5bwjZFNY +U/ORsZfVtA14T4/ErHbjJ8LDg9T2oCZy0cwSQmBeq0l9CoiYPs+fl/LFb1dQ9fnMgxcoC Rl1t3djg5Vi1Oolx/0dzMkI+owXbVOZKIDAffAO1FenNE96E36uLf+aTed9LDA8P33GS4E Dv6jxtqJaW8KYpyxViLjw6Ss11Yk+OjLvwXO054XMr2RFpCuFF9ZvNwdO/IpXQ== 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=1721047103; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=SWnhBBkPBnqJAYPEfhW0WcoPqLgK4AM0e3oplrBfnMQ=; b=gMzhLw0smEGkJ2fk0nC9tFKFqX7jTVbQJCGOR1JFQhvrWNX5rhPbGqv7qN9wzzFAJng7Rb WLytFloJZtj3JoiUV/49WaEPUoRrUza0k68ZmqkUpSv14nCNCgrvRvvodZM7qYCwcM8uy5 H3FXyggq2AW/TxIDr2o7V73eagPuHSzzPUIm7m6lhAYZfAnmiv/hZDscMOzXaaO8kDN3kr aSgvoYrEjnPGt+79LE3x4RJR0wWX9f4wAP1B4TQ6zzrQs/OgCQu2cOmaWfiz+Ya8euzvyy 1R7M5kSJQd1LM1inusOQc5uFu4v+TwkMfKBozKRKu7AzHp9gqTjkiPCv50T6Lw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vg61rPzt3J; Mon, 15 Jul 2024 12:38:23 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcNYY061137; Mon, 15 Jul 2024 12:38:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcNic061134; Mon, 15 Jul 2024 12:38:23 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:23 GMT Message-Id: <202407151238.46FCcNic061134@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 2d72da2720db - stable/14 - arm64: Add the pointer auth registers to armreg.h List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 2d72da2720db37ad7f10da65419aa2b4922a41ce Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=2d72da2720db37ad7f10da65419aa2b4922a41ce commit 2d72da2720db37ad7f10da65419aa2b4922a41ce Author: Andrew Turner AuthorDate: 2024-05-22 08:18:54 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:26:58 +0000 arm64: Add the pointer auth registers to armreg.h Add the pointer authentication registers to armreg.h. These will be used to support pointer authentication in a kernel built with GCC. Reviewed by: jhb Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45262 (cherry picked from commit 57d714a23f5ce21e389d53636b8bc6c1b45d518e) --- sys/arm64/include/armreg.h | 80 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 80 insertions(+) diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index 243c9276cee0..fee36bc9dd4e 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -77,6 +77,86 @@ #define UL(x) UINT64_C(x) +/* APDAKeyHi_EL1 */ +#define APDAKeyHi_EL1_REG MRS_REG_ALT_NAME(APDAKeyHi_EL1) +#define APDAKeyHi_EL1_op0 3 +#define APDAKeyHi_EL1_op1 0 +#define APDAKeyHi_EL1_CRn 2 +#define APDAKeyHi_EL1_CRm 2 +#define APDAKeyHi_EL1_op2 1 + +/* APDAKeyLo_EL1 */ +#define APDAKeyLo_EL1_REG MRS_REG_ALT_NAME(APDAKeyLo_EL1) +#define APDAKeyLo_EL1_op0 3 +#define APDAKeyLo_EL1_op1 0 +#define APDAKeyLo_EL1_CRn 2 +#define APDAKeyLo_EL1_CRm 2 +#define APDAKeyLo_EL1_op2 0 + +/* APDBKeyHi_EL1 */ +#define APDBKeyHi_EL1_REG MRS_REG_ALT_NAME(APDBKeyHi_EL1) +#define APDBKeyHi_EL1_op0 3 +#define APDBKeyHi_EL1_op1 0 +#define APDBKeyHi_EL1_CRn 2 +#define APDBKeyHi_EL1_CRm 2 +#define APDBKeyHi_EL1_op2 3 + +/* APDBKeyLo_EL1 */ +#define APDBKeyLo_EL1_REG MRS_REG_ALT_NAME(APDBKeyLo_EL1) +#define APDBKeyLo_EL1_op0 3 +#define APDBKeyLo_EL1_op1 0 +#define APDBKeyLo_EL1_CRn 2 +#define APDBKeyLo_EL1_CRm 2 +#define APDBKeyLo_EL1_op2 2 + +/* APGAKeyHi_EL1 */ +#define APGAKeyHi_EL1_REG MRS_REG_ALT_NAME(APGAKeyHi_EL1) +#define APGAKeyHi_EL1_op0 3 +#define APGAKeyHi_EL1_op1 0 +#define APGAKeyHi_EL1_CRn 2 +#define APGAKeyHi_EL1_CRm 3 +#define APGAKeyHi_EL1_op2 1 + +/* APGAKeyLo_EL1 */ +#define APGAKeyLo_EL1_REG MRS_REG_ALT_NAME(APGAKeyLo_EL1) +#define APGAKeyLo_EL1_op0 3 +#define APGAKeyLo_EL1_op1 0 +#define APGAKeyLo_EL1_CRn 2 +#define APGAKeyLo_EL1_CRm 3 +#define APGAKeyLo_EL1_op2 0 + +/* APIAKeyHi_EL1 */ +#define APIAKeyHi_EL1_REG MRS_REG_ALT_NAME(APIAKeyHi_EL1) +#define APIAKeyHi_EL1_op0 3 +#define APIAKeyHi_EL1_op1 0 +#define APIAKeyHi_EL1_CRn 2 +#define APIAKeyHi_EL1_CRm 1 +#define APIAKeyHi_EL1_op2 1 + +/* APIAKeyLo_EL1 */ +#define APIAKeyLo_EL1_REG MRS_REG_ALT_NAME(APIAKeyLo_EL1) +#define APIAKeyLo_EL1_op0 3 +#define APIAKeyLo_EL1_op1 0 +#define APIAKeyLo_EL1_CRn 2 +#define APIAKeyLo_EL1_CRm 1 +#define APIAKeyLo_EL1_op2 0 + +/* APIBKeyHi_EL1 */ +#define APIBKeyHi_EL1_REG MRS_REG_ALT_NAME(APIBKeyHi_EL1) +#define APIBKeyHi_EL1_op0 3 +#define APIBKeyHi_EL1_op1 0 +#define APIBKeyHi_EL1_CRn 2 +#define APIBKeyHi_EL1_CRm 1 +#define APIBKeyHi_EL1_op2 3 + +/* APIBKeyLo_EL1 */ +#define APIBKeyLo_EL1_REG MRS_REG_ALT_NAME(APIBKeyLo_EL1) +#define APIBKeyLo_EL1_op0 3 +#define APIBKeyLo_EL1_op1 0 +#define APIBKeyLo_EL1_CRn 2 +#define APIBKeyLo_EL1_CRm 1 +#define APIBKeyLo_EL1_op2 2 + /* CCSIDR_EL1 - Cache Size ID Register */ #define CCSIDR_NumSets_MASK 0x0FFFE000 #define CCSIDR_NumSets64_MASK 0x00FFFFFF00000000 From nobody Mon Jul 15 12:38:22 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vg5r3rz5QrSb; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vg0TCbz4HXG; Mon, 15 Jul 2024 12:38:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047103; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=S13OeLFB1bziFVupo7VSLK0q1+7tT0J4t7fuGUN5zEI=; b=yQJm50SIz+rQM1/YJiqaNdcugbOSscCJi0tZ1Q/K7eUjAV9CmlMn+j4BFqvQaNuf/ohN+4 IZSzJHFLeOelWl6lTElblXImxWFGYDzHUysJ9oVXqI7riQt0VGJB6QFLWomUSu/Kkgiab7 9ZuC3ivFkmBk2WAEG+oRyk9JTsOPaU+X+cJ2I5td5BSGmIYbmZ7oJUFhaIetM9sFpFJ6ft Hb2dCywyCLID9/PJaF07cICjy+bKxsdY4HfCvmGMQO/2vZ6B8Zsqfpg80j8Z0xSswbkBvm N0fJU/+APz3FKGUW6g35C8m84YoFD+CoS8c1NgSskL+ScdLCidV2uZI3gwvDPA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047103; a=rsa-sha256; cv=none; b=oqwAXjg9jTZU25t/YJKRBS0SnL9XON/83X+ROkzwq5jjDerLNV2XKKirWy9xgtQFdmSO/D 7jlVzp4Uv0OAm2Bd2aP6HNlv7hc4BSnbvejjDOqG0d9CN1R5xau2Xk3r7EAjBnSSfSEr2D 0MZWx2hyFQ81pFmZ3C12gKCdXagZOpD2M0MyJ1spTH7oH1hFo9kysN6cRXFGI0TcO5bfPH KgbIYxPybwQoJvIRTlXpA7RivA6YMRUIXPxRlhntz846joHciyXZOxc6ITcPjZ3sNK8Dzz RHnq4T80oHC2QjcXIwSTSNKJsZxCUW64T1Qoy9L6USOLX4ICM+Ax0RBcs3xbWg== 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=1721047103; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=S13OeLFB1bziFVupo7VSLK0q1+7tT0J4t7fuGUN5zEI=; b=iEZ7QjCrIMYJf3ygeyO1QIbgwd3rSt6uYmAE5CsJsDPu4H/IOxCR4B//8g8HB99KNPn69e SrWi3TjIRDi4LnKC4O0W89TXADre/edg9oatGMBElEj3z0Piu2/Y3Sme6TMUIHR9oTiv6v GYSgXYBVfk/v5IOBJ5RzvmCUeh4JPL+0iSYUjwMBuunTja9g7dOSieGyiYEZdcPN0MVgsW 8OG5A1BIc5pUwhY398oEFzM99BNO510d2ICfca3hP7oYOTrBRcIXv5uarDXKs2D6r04lw7 pL6MJwDOzodv2DkVV2Hkth1M0LVb7K+oA2t1yrkAdlG2Bt8q7gta+CReHOwQvw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vg05WSzt3H; Mon, 15 Jul 2024 12:38:23 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcMEU061081; Mon, 15 Jul 2024 12:38:22 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcMwk061077; Mon, 15 Jul 2024 12:38:22 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:22 GMT Message-Id: <202407151238.46FCcMwk061077@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 7d8cb4115996 - stable/13 - stand/efi: Fix for binutils when targeting arm64 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 7d8cb4115996cc46907f49c637a6599e0f14a2ed Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=7d8cb4115996cc46907f49c637a6599e0f14a2ed commit 7d8cb4115996cc46907f49c637a6599e0f14a2ed Author: Andrew Turner AuthorDate: 2024-05-22 08:17:26 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:29 +0000 stand/efi: Fix for binutils when targeting arm64 When linking with ld.bfd it complain with the following: /usr/local/bin/aarch64-unknown-freebsd14.0-ld: start.o: relocation R_AARCH64_ABS32 against `__data_size' can not be used when making a shared object Fix this by marking the __data_size with ABSOLUTE. This returns a non-relocatable value which appears to be the same behaviour of lld. Reviewed by: imp Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45257 (cherry picked from commit 9f44638ef2c46861565b89bb01bbeeab17755649) --- stand/efi/loader/arch/arm64/ldscript.arm64 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stand/efi/loader/arch/arm64/ldscript.arm64 b/stand/efi/loader/arch/arm64/ldscript.arm64 index bacb81b5032f..c6af9f48bd12 100644 --- a/stand/efi/loader/arch/arm64/ldscript.arm64 +++ b/stand/efi/loader/arch/arm64/ldscript.arm64 @@ -79,7 +79,7 @@ SECTIONS . = ALIGN(16); .dynsym : { *(.dynsym) } _edata = .; - __data_size = . - __data_start; + __data_size = ABSOLUTE(. - __data_start); /* Unused sections */ .interp : { *(.interp) } From nobody Mon Jul 15 12:38:24 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vj1yLtz5Qrnc; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vj0LC2z4Hpd; Mon, 15 Jul 2024 12:38:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047105; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=+9ewlpC9HgAm8eUKgy12+8gtMbehKT0lgH+fMe6L2yg=; b=fgYxPXPNH62b+NNsoA1y04Dov58jq4RvLSOseIr1thbcvgcFLsDTXokSfcIHZJm2AqJ3Ig M7gk+ea8FbaTv0LjlcwNcxhl8F21ZwCEAJXCn5K9XLv47jz4rcBFoi9AWhq34UtM6Of9Vo plaVhW+dSMsQDe2N/b9SmlnLuaWDuSDJ8hEYAC4rQ20+6NsZrzwa84TK5lfFv2u+Q64qkM LeV2q2pQQ4NKbTkan034HijVKn/AXtHBtZAPbjDoM1XpNrKb4DjRPuFXlr2XUpufUrY9/E jNaRF8BqOisDUGsfwgKGTomuLRyxBrqlPoHjTHg6aA6eQo2CFpR1gm7Zsm+urA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047105; a=rsa-sha256; cv=none; b=Be0m93CylmpDz//gsE5FtXU6xfqRPsuPo6+H/cpmSGRrf6K6F8LoO+QJGuQ23u0+hes/Gr Pyj6WRRJdh+ozToN9srPzIR11B30cm44hFS16aDq0jzBnKO7w/lREdAi6qqgWNgRp6gkvZ kr4lUBQa6z4ztc+1KeVp5r4FOhcATaScIDCsjNnOpMOwMMBkWr+g8vnqZYYe3L/0J6Q4YY saAQ6ArftWz4jbt1MM3RNipchW2lkl6vA1vjmmvYTtPjEnO0PNX4A4wCXOott+kyQoMjOV yLd9g4zKubr0uBVGoQ6ADSN/ERiQEDAenK0eDkGXIU4XDhXCZtCcq8yr3nYzyQ== 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=1721047105; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=+9ewlpC9HgAm8eUKgy12+8gtMbehKT0lgH+fMe6L2yg=; b=s6wsfIkCTTSaBZAffNcv6WSB8MshB6H2dQejkLySa78Hdkl8uZb3vcaRrK0xxBrpQqNwOc do/bzKeRxni32a4Rq03vPRvUka+O9l9xiS3tF9+raub+wtlA40xWTCXxxXsZ0dtdAVbmcJ oLaHJZUrOCoSW6guh7g0qoyrjqsVvJsrUVmZyiRAo0FRV8l1TsY1tb0hSarxN7V2PXRJ1b 62yxq2pwWw9Jm4FE72mWpGXbkV/9RFjedJZ35Q8TH4zy4Ym5OES9CulowabX86yhVBMDAa XjCmYrudAdnfYANs1qPC1MqR7UlDnTqaNZibR9Ah2wshzdRSk+lrkEWPkC3ecg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vh74RPzt5j; Mon, 15 Jul 2024 12:38:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcOPl061230; Mon, 15 Jul 2024 12:38:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcOhv061227; Mon, 15 Jul 2024 12:38:24 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:24 GMT Message-Id: <202407151238.46FCcOhv061227@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 81e973eaf95e - stable/14 - arm64: Use the pointer auth register defines List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 81e973eaf95ee62d83129eea83f610ba829229f8 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=81e973eaf95ee62d83129eea83f610ba829229f8 commit 81e973eaf95ee62d83129eea83f610ba829229f8 Author: Andrew Turner AuthorDate: 2024-05-22 08:19:06 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:27:23 +0000 arm64: Use the pointer auth register defines When building with gcc it complains the pointer authentication registers aren't valid with the architecture level we are targeting. Fix this by using the alternative spelling of these registers accesses through MRS_REG_ALT_NAME. Reviewed by: jhb Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45263 (cherry picked from commit 73c200447361a649e00cdb1693a0ae7f3291914e) --- sys/arm64/arm64/ptrauth.c | 32 +++++++++++++++----------------- 1 file changed, 15 insertions(+), 17 deletions(-) diff --git a/sys/arm64/arm64/ptrauth.c b/sys/arm64/arm64/ptrauth.c index 03610e9313f5..c7cf47f8a6cd 100644 --- a/sys/arm64/arm64/ptrauth.c +++ b/sys/arm64/arm64/ptrauth.c @@ -170,13 +170,11 @@ ptrauth_thread_alloc(struct thread *td) * Load the userspace keys. We can't use WRITE_SPECIALREG as we need * to set the architecture extension. */ -#define LOAD_KEY(space, name) \ -__asm __volatile( \ - ".arch_extension pauth \n" \ - "msr "#name"keylo_el1, %0 \n" \ - "msr "#name"keyhi_el1, %1 \n" \ - ".arch_extension nopauth \n" \ - :: "r"(td->td_md.md_ptrauth_##space.name.pa_key_lo), \ +#define LOAD_KEY(space, name, reg) \ +__asm __volatile( \ + "msr "__XSTRING(MRS_REG_ALT_NAME(reg ## KeyLo_EL1))", %0 \n" \ + "msr "__XSTRING(MRS_REG_ALT_NAME(reg ## KeyHi_EL1))", %1 \n" \ + :: "r"(td->td_md.md_ptrauth_##space.name.pa_key_lo), \ "r"(td->td_md.md_ptrauth_##space.name.pa_key_hi)) void @@ -188,7 +186,7 @@ ptrauth_thread0(struct thread *td) /* TODO: Generate a random number here */ memset(&td->td_md.md_ptrauth_kern, 0, sizeof(td->td_md.md_ptrauth_kern)); - LOAD_KEY(kern, apia); + LOAD_KEY(kern, apia, APIA); /* * No isb as this is called before ptrauth_start so can rely on * the instruction barrier there. @@ -241,8 +239,8 @@ ptrauth_mp_start(uint64_t cpu) __asm __volatile( ".arch_extension pauth \n" - "msr apiakeylo_el1, %0 \n" - "msr apiakeyhi_el1, %1 \n" + "msr "__XSTRING(APIAKeyLo_EL1_REG)", %0 \n" + "msr "__XSTRING(APIAKeyHi_EL1_REG)", %1 \n" ".arch_extension nopauth \n" :: "r"(start_key.pa_key_lo), "r"(start_key.pa_key_hi)); @@ -258,7 +256,7 @@ struct thread * ptrauth_switch(struct thread *td) { if (enable_ptrauth) { - LOAD_KEY(kern, apia); + LOAD_KEY(kern, apia, APIA); isb(); } @@ -272,7 +270,7 @@ ptrauth_exit_el0(struct thread *td) if (!enable_ptrauth) return; - LOAD_KEY(kern, apia); + LOAD_KEY(kern, apia, APIA); isb(); } @@ -283,11 +281,11 @@ ptrauth_enter_el0(struct thread *td) if (!enable_ptrauth) return; - LOAD_KEY(user, apia); - LOAD_KEY(user, apib); - LOAD_KEY(user, apda); - LOAD_KEY(user, apdb); - LOAD_KEY(user, apga); + LOAD_KEY(user, apia, APIA); + LOAD_KEY(user, apib, APIB); + LOAD_KEY(user, apda, APDA); + LOAD_KEY(user, apdb, APDB); + LOAD_KEY(user, apga, APGA); /* * No isb as this is called from the exception handler so can rely * on the eret instruction to be the needed context synchronizing event. From nobody Mon Jul 15 12:38:24 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vh2dzSz5Qrh5; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vh1jx4z4HXj; Mon, 15 Jul 2024 12:38:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047104; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=+s1agdcM/G/uR0LIjbwTBJkTvqcte5HqNfJKREhx2sE=; b=Q4Tsviitky87WXsMG56EFh2n04ex8yuYpWZMWwGRtfiwS75nR2dpX1iZiqV6a2khJD9pnF QBh0kPfX6v0KdXxAHuvH5Rgr9PcdUwmLg2w6Fou/m3DQwRF4NT2pBk2VR1r5DOy6EuSwkf gVrfbsof/ZczOLhw0XK7MMDLzuTU2v+AFhYjpVFl2fG8GN7gKsoWolkjxhC13xTfg3MA5a 2JmWDEqF4j/bo3SRniJU9tGVtSgzIdV+FFoRiWCF1LVJoLdaUNYT/o40zWtjdNdQPzZa8h /4vsjTuAluyN8EO+pCH675l1U6QWWjBPJMVO3VewKgyR1fQ0tNG8Q78En8i5xw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047104; a=rsa-sha256; cv=none; b=fq8x+q2ls9gRZt0A5/N9A0OvoMd4nI45sBCDAPDx6/ExE7xCJJj17u1w9+cBeW9gWGzx0r wfQewZwkWL9+yS5EMQvm9OkwRdu4iqyWFZlSX2ckfFzDi7PiEehll+oK4F4JJKpfNS5goN KwJM6psdPPjMrzovT2OexdSbQUvq5XQi77yBwrFGPUBJgWHwbUTP9QboBj5nx7GmvIlYO6 DHl/v5dYAkOCsC6X1K3GeqiMI9/Hh58g38J7AdwOJEtBQKYeGD2cFSKcp2p3/MYzMKSdyo a7mAPwDCqnogl49yABGmKLtdOEBw4r+bvVSTOPHqud7EQ66OSrV2EkGsyFtSZA== 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=1721047104; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=+s1agdcM/G/uR0LIjbwTBJkTvqcte5HqNfJKREhx2sE=; b=IM0niJxoxFm0OmELopxYZa2Un8Eoj5XdmZJgdAWEji1uQEZZPv5f+26637YV9+70V0rKhz jJc/vxFkShLDUYKeBzpHenvWkaP39pdyXDwFgPjSPpAKiRKbf7sKip2ddvPgCppJYQZAwX +DldTAtEChjd2NVH5cjd9qWu3FLpENwoInTDuCqcWSLZZy5DxsKXHhVvdxbyx0eyT6mKdD hHKJMJgu/zOW56bL7fDrT8fz4L1weXFIy6LBZlIgQIJN0I7BclbcSsAsNhZECYIEX3MBaE 6WPTzePc+3Ow4eelplBWZt9BRfA3YZgi1FIynj6fcAFsIGttXnyLXiUGVl36xg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vh1LRVzspF; Mon, 15 Jul 2024 12:38:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcOQu061182; Mon, 15 Jul 2024 12:38:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcO2p061179; Mon, 15 Jul 2024 12:38:24 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:24 GMT Message-Id: <202407151238.46FCcO2p061179@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: f94f593ca78b - stable/13 - stand/kboot: Fix the linker script OUTPUT_FORMAT List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: f94f593ca78b77ca2ea2c4e7a983a8de0d9709f3 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=f94f593ca78b77ca2ea2c4e7a983a8de0d9709f3 commit f94f593ca78b77ca2ea2c4e7a983a8de0d9709f3 Author: Andrew Turner AuthorDate: 2024-05-22 08:17:52 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:29 +0000 stand/kboot: Fix the linker script OUTPUT_FORMAT ld.bfd doesn't understand elf64-aarch64 but does have elf64-littleaarch64. Switch to this so we can link kboot with it. While here switch to the single format version. We are unlikely to support booting from a big-endian Linux. Reviewed by: imp, emaste Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45258 (cherry picked from commit 8e82c5e28db6fb19f75d10fd2e7c3db784723f1f) --- stand/kboot/arch/aarch64/ldscript.aarch64 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stand/kboot/arch/aarch64/ldscript.aarch64 b/stand/kboot/arch/aarch64/ldscript.aarch64 index 62b7d2b6be01..efe787164c20 100644 --- a/stand/kboot/arch/aarch64/ldscript.aarch64 +++ b/stand/kboot/arch/aarch64/ldscript.aarch64 @@ -1,4 +1,4 @@ -OUTPUT_FORMAT("elf64-aarch64", "elf64-aarch64", "elf64-aarch64") +OUTPUT_FORMAT("elf64-littleaarch64") OUTPUT_ARCH(aarch64) ENTRY(_start) SECTIONS From nobody Mon Jul 15 12:38:26 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vk4lbRz5QrSg; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vk3fhlz4HkG; Mon, 15 Jul 2024 12:38:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047106; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=OmRY+vq2wYK1XvzHUpPb+UlkzgZ3mD1YHWPK+idQx3Q=; b=O3pI9xr1Y4d1OE4vLPH+aR/ugjjADVm5AblI0cVjgpC/f7FwP1/Lqoo69jn8SjnB7Me+DI icS/jJv/ZffRD/vuyTOjtpN33zDUl+kqp0dhdVTJWxH2gnObVT1KMfGJ6PqgkNgWa23DxO 0a+81FUTApwgp3GH6Xdy40ImeBw1dKjfKWvvOAygie8Z6mcV93JDo/K9SZn8XWKX7fNkja Yrg8pqpJ9h8J/0MH1cAoS907t9uoaBL2f9VRQA9MRgGSXKSWxSPiGnzBTqCPrES/jON9X+ arv7nD9BV+ZKbvR6JhYIWwEKWgRXeuaJv5bwPsyofYpx4GpIanIpPCOZnhF76A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047106; a=rsa-sha256; cv=none; b=oiuocTKcXT6Ns/B4xfQU3p9+seDbPLa4kWqEbB/f6i3Yh+Gvv9gqBn8rijY4G/gN9JPCU/ EnuT+cxOvQ2WvkoW7OtDbotUBN3V+X3/d9UeS1DbKLGhNK3v5lpNdLFkSv6qRkEbqlytU+ J6XaVCeNvH4tL7B4jcuahAuMNhgkOuR0gxWGqRRN+7K4SbELqnx8i02xmiNa/D3qMxtIaM 4TTEg/5DoWASQS4CPl4l5M3HIciMJcMsM/4G2jD3PtWCqnyJIMM4F3Ou6aOhqPflnTUa9n tnm83xe6gQSG0MhJNzSFz7sjKk+Rve6dUTxlkQ6K5yPXCQF2MTqi9KgBmIuwaQ== 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=1721047106; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=OmRY+vq2wYK1XvzHUpPb+UlkzgZ3mD1YHWPK+idQx3Q=; b=HZZWKwv64R56+ZA68i1En28Cxu1YMvl4i1389VU8+0VwF/UOZQ2QHmzhHp1l7wQoEYuYrF jFZNqrBLQr9Jb/+w9oeTgh30VojxLhmdVUkIdTHPcGb0arkyVNqEzFnibnVpqcClw3PK8V mfVi+OoHBP32HWsv5kNLlHqOaZs1twO/t5aG5sp850D8JdOwUDC8+ANuwH4WpTwi4mbcbi Q7qlbpdmOdt/tMmE6pK2xOLxGLmemLxs2OXcpmVIjbSNr9Eq2ZHBY12ZVRMPFgCGKyjr3W xOq0Dk9TL6lGz3+AqYr6CKk8OGqVDgui/Eynn+wFqLAjPXgt2/GoVU5gUHJJlg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vk3D20zt5m; Mon, 15 Jul 2024 12:38:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcQg1061366; Mon, 15 Jul 2024 12:38:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcQR7061363; Mon, 15 Jul 2024 12:38:26 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:26 GMT Message-Id: <202407151238.46FCcQR7061363@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: bd1252482bf6 - stable/13 - arm64: Use the UL macro in TCR_EL1 defines List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: bd1252482bf67949f6f9564804c7381f7e66eb7f Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=bd1252482bf67949f6f9564804c7381f7e66eb7f commit bd1252482bf67949f6f9564804c7381f7e66eb7f Author: Andrew Turner AuthorDate: 2024-05-22 08:18:39 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:29 +0000 arm64: Use the UL macro in TCR_EL1 defines While clang can handle numbers with a UL suffix in assembly files gcc/gas is unable to. Switch to use the UL macro for TCR_EL1 defines as some are used in locore.S Reviewed by: brooks, jhb Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45261 (cherry picked from commit 29c1cf9860e531146220d9dc3596e4c79f91cfcd) --- sys/arm64/include/armreg.h | 96 +++++++++++++++++++++++----------------------- 1 file changed, 48 insertions(+), 48 deletions(-) diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index eb62945acaff..2f8da2ad7e0b 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -2136,99 +2136,99 @@ /* TCR_EL1 - Translation Control Register */ /* Bits 63:59 are reserved */ #define TCR_TCMA1_SHIFT 58 -#define TCR_TCMA1 (1UL << TCR_TCMA1_SHIFT) +#define TCR_TCMA1 (UL(1) << TCR_TCMA1_SHIFT) #define TCR_TCMA0_SHIFT 57 -#define TCR_TCMA0 (1UL << TCR_TCMA0_SHIFT) +#define TCR_TCMA0 (UL(1) << TCR_TCMA0_SHIFT) #define TCR_E0PD1_SHIFT 56 -#define TCR_E0PD1 (1UL << TCR_E0PD1_SHIFT) +#define TCR_E0PD1 (UL(1) << TCR_E0PD1_SHIFT) #define TCR_E0PD0_SHIFT 55 -#define TCR_E0PD0 (1UL << TCR_E0PD0_SHIFT) +#define TCR_E0PD0 (UL(1) << TCR_E0PD0_SHIFT) #define TCR_NFD1_SHIFT 54 -#define TCR_NFD1 (1UL << TCR_NFD1_SHIFT) +#define TCR_NFD1 (UL(1) << TCR_NFD1_SHIFT) #define TCR_NFD0_SHIFT 53 -#define TCR_NFD0 (1UL << TCR_NFD0_SHIFT) +#define TCR_NFD0 (UL(1) << TCR_NFD0_SHIFT) #define TCR_TBID1_SHIFT 52 -#define TCR_TBID1 (1UL << TCR_TBID1_SHIFT) +#define TCR_TBID1 (UL(1) << TCR_TBID1_SHIFT) #define TCR_TBID0_SHIFT 51 -#define TCR_TBID0 (1UL << TCR_TBID0_SHIFT) +#define TCR_TBID0 (UL(1) << TCR_TBID0_SHIFT) #define TCR_HWU162_SHIFT 50 -#define TCR_HWU162 (1UL << TCR_HWU162_SHIFT) +#define TCR_HWU162 (UL(1) << TCR_HWU162_SHIFT) #define TCR_HWU161_SHIFT 49 -#define TCR_HWU161 (1UL << TCR_HWU161_SHIFT) +#define TCR_HWU161 (UL(1) << TCR_HWU161_SHIFT) #define TCR_HWU160_SHIFT 48 -#define TCR_HWU160 (1UL << TCR_HWU160_SHIFT) +#define TCR_HWU160 (UL(1) << TCR_HWU160_SHIFT) #define TCR_HWU159_SHIFT 47 -#define TCR_HWU159 (1UL << TCR_HWU159_SHIFT) +#define TCR_HWU159 (UL(1) << TCR_HWU159_SHIFT) #define TCR_HWU1 \ (TCR_HWU159 | TCR_HWU160 | TCR_HWU161 | TCR_HWU162) #define TCR_HWU062_SHIFT 46 -#define TCR_HWU062 (1UL << TCR_HWU062_SHIFT) +#define TCR_HWU062 (UL(1) << TCR_HWU062_SHIFT) #define TCR_HWU061_SHIFT 45 -#define TCR_HWU061 (1UL << TCR_HWU061_SHIFT) +#define TCR_HWU061 (UL(1) << TCR_HWU061_SHIFT) #define TCR_HWU060_SHIFT 44 -#define TCR_HWU060 (1UL << TCR_HWU060_SHIFT) +#define TCR_HWU060 (UL(1) << TCR_HWU060_SHIFT) #define TCR_HWU059_SHIFT 43 -#define TCR_HWU059 (1UL << TCR_HWU059_SHIFT) +#define TCR_HWU059 (UL(1) << TCR_HWU059_SHIFT) #define TCR_HWU0 \ (TCR_HWU059 | TCR_HWU060 | TCR_HWU061 | TCR_HWU062) #define TCR_HPD1_SHIFT 42 -#define TCR_HPD1 (1UL << TCR_HPD1_SHIFT) +#define TCR_HPD1 (UL(1) << TCR_HPD1_SHIFT) #define TCR_HPD0_SHIFT 41 -#define TCR_HPD0 (1UL << TCR_HPD0_SHIFT) +#define TCR_HPD0 (UL(1) << TCR_HPD0_SHIFT) #define TCR_HD_SHIFT 40 -#define TCR_HD (1UL << TCR_HD_SHIFT) +#define TCR_HD (UL(1) << TCR_HD_SHIFT) #define TCR_HA_SHIFT 39 -#define TCR_HA (1UL << TCR_HA_SHIFT) +#define TCR_HA (UL(1) << TCR_HA_SHIFT) #define TCR_TBI1_SHIFT 38 -#define TCR_TBI1 (1UL << TCR_TBI1_SHIFT) +#define TCR_TBI1 (UL(1) << TCR_TBI1_SHIFT) #define TCR_TBI0_SHIFT 37 -#define TCR_TBI0 (1UL << TCR_TBI0_SHIFT) +#define TCR_TBI0 (UL(1) << TCR_TBI0_SHIFT) #define TCR_ASID_SHIFT 36 #define TCR_ASID_WIDTH 1 -#define TCR_ASID_16 (1UL << TCR_ASID_SHIFT) +#define TCR_ASID_16 (UL(1) << TCR_ASID_SHIFT) /* Bit 35 is reserved */ #define TCR_IPS_SHIFT 32 #define TCR_IPS_WIDTH 3 -#define TCR_IPS_32BIT (0UL << TCR_IPS_SHIFT) -#define TCR_IPS_36BIT (1UL << TCR_IPS_SHIFT) -#define TCR_IPS_40BIT (2UL << TCR_IPS_SHIFT) -#define TCR_IPS_42BIT (3UL << TCR_IPS_SHIFT) -#define TCR_IPS_44BIT (4UL << TCR_IPS_SHIFT) -#define TCR_IPS_48BIT (5UL << TCR_IPS_SHIFT) +#define TCR_IPS_32BIT (UL(0) << TCR_IPS_SHIFT) +#define TCR_IPS_36BIT (UL(1) << TCR_IPS_SHIFT) +#define TCR_IPS_40BIT (UL(2) << TCR_IPS_SHIFT) +#define TCR_IPS_42BIT (UL(3) << TCR_IPS_SHIFT) +#define TCR_IPS_44BIT (UL(4) << TCR_IPS_SHIFT) +#define TCR_IPS_48BIT (UL(5) << TCR_IPS_SHIFT) #define TCR_TG1_SHIFT 30 -#define TCR_TG1_MASK (3UL << TCR_TG1_SHIFT) -#define TCR_TG1_16K (1UL << TCR_TG1_SHIFT) -#define TCR_TG1_4K (2UL << TCR_TG1_SHIFT) -#define TCR_TG1_64K (3UL << TCR_TG1_SHIFT) +#define TCR_TG1_MASK (UL(3) << TCR_TG1_SHIFT) +#define TCR_TG1_16K (UL(1) << TCR_TG1_SHIFT) +#define TCR_TG1_4K (UL(2) << TCR_TG1_SHIFT) +#define TCR_TG1_64K (UL(3) << TCR_TG1_SHIFT) #define TCR_SH1_SHIFT 28 -#define TCR_SH1_IS (3UL << TCR_SH1_SHIFT) +#define TCR_SH1_IS (UL(3) << TCR_SH1_SHIFT) #define TCR_ORGN1_SHIFT 26 -#define TCR_ORGN1_WBWA (1UL << TCR_ORGN1_SHIFT) +#define TCR_ORGN1_WBWA (UL(1) << TCR_ORGN1_SHIFT) #define TCR_IRGN1_SHIFT 24 -#define TCR_IRGN1_WBWA (1UL << TCR_IRGN1_SHIFT) +#define TCR_IRGN1_WBWA (UL(1) << TCR_IRGN1_SHIFT) #define TCR_EPD1_SHIFT 23 -#define TCR_EPD1 (1UL << TCR_EPD1_SHIFT) +#define TCR_EPD1 (UL(1) << TCR_EPD1_SHIFT) #define TCR_A1_SHIFT 22 -#define TCR_A1 (0x1UL << TCR_A1_SHIFT) +#define TCR_A1 (UL(1) << TCR_A1_SHIFT) #define TCR_T1SZ_SHIFT 16 -#define TCR_T1SZ_MASK (0x3fUL << TCR_T1SZ_SHIFT) +#define TCR_T1SZ_MASK (UL(0x3f) << TCR_T1SZ_SHIFT) #define TCR_T1SZ(x) ((x) << TCR_T1SZ_SHIFT) #define TCR_TG0_SHIFT 14 -#define TCR_TG0_MASK (3UL << TCR_TG0_SHIFT) -#define TCR_TG0_4K (0UL << TCR_TG0_SHIFT) -#define TCR_TG0_64K (1UL << TCR_TG0_SHIFT) -#define TCR_TG0_16K (2UL << TCR_TG0_SHIFT) +#define TCR_TG0_MASK (UL(3) << TCR_TG0_SHIFT) +#define TCR_TG0_4K (UL(0) << TCR_TG0_SHIFT) +#define TCR_TG0_64K (UL(1) << TCR_TG0_SHIFT) +#define TCR_TG0_16K (UL(2) << TCR_TG0_SHIFT) #define TCR_SH0_SHIFT 12 -#define TCR_SH0_IS (3UL << TCR_SH0_SHIFT) +#define TCR_SH0_IS (UL(3) << TCR_SH0_SHIFT) #define TCR_ORGN0_SHIFT 10 -#define TCR_ORGN0_WBWA (1UL << TCR_ORGN0_SHIFT) +#define TCR_ORGN0_WBWA (UL(1) << TCR_ORGN0_SHIFT) #define TCR_IRGN0_SHIFT 8 -#define TCR_IRGN0_WBWA (1UL << TCR_IRGN0_SHIFT) +#define TCR_IRGN0_WBWA (UL(1) << TCR_IRGN0_SHIFT) #define TCR_EPD0_SHIFT 7 -#define TCR_EPD0 (1UL << TCR_EPD0_SHIFT) +#define TCR_EPD0 (UL(1) << TCR_EPD0_SHIFT) /* Bit 6 is reserved */ #define TCR_T0SZ_SHIFT 0 -#define TCR_T0SZ_MASK (0x3fUL << TCR_T0SZ_SHIFT) +#define TCR_T0SZ_MASK (UL(0x3f) << TCR_T0SZ_SHIFT) #define TCR_T0SZ(x) ((x) << TCR_T0SZ_SHIFT) #define TCR_TxSZ(x) (TCR_T1SZ(x) | TCR_T0SZ(x)) From nobody Mon Jul 15 12:38:25 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vj5yT7z5Qrqv; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vj2nCdz4Hk8; Mon, 15 Jul 2024 12:38:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047105; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=kh7KDABb6x/N90A5iEmFzErgvfvxrwfSGPicZ27dYDE=; b=rXLiciCbGeZr71Y6SAFpKXGyT+F4geecsR0y7QumaVrQiASBRiWZsvbWl6uazFZrTPFBsf nE0z0xCCRERaBu7cmlQvlDBcTUyF+PkjjDj4ugvTw5nFRuZ2ekuAiyQ6PXTqfl+se3ePm7 oNUhPwlLHIDW3o/IY0G1oxmJ5h876U6Uxi9/OYmYerK1A6On0mINK63KNxc5yUVU7KQHEE r/p3TmXH2vt++D2a/tMKF8h5jndfNrQPYS7ruHzS1aRZVNVp5yCUBdJweMgs79WWrLED0V Owmu0ztf+QNZoYhBLxG6ablTnI8yOaXGLND6DAp69g9TMhHZdVhm0WbJfO8YJg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047105; a=rsa-sha256; cv=none; b=Jn4XFp1JrqVkQFHVi5NFjXvgZudBND5nWh2cqjVzitq3NRGetG5edb6w0DCvZzMN59haJ5 LbHxQINjM8J/5fbTJM1yZspSfklEmEHET5z8aet/VuS8fenQg8/r6QOvVNB/6rUhWUoVIT +EJXEUtwgyrFv7qbmzyVXQAczgmOFdCeRyQjmj/o4c+ysgIz2H1zf0UNE0PrPiFU4SZgJ3 MNVRI9g5StB2ym/aARk97s7Wsn0sCQjdRXWxlUSfPkjg6cobXO9o/EQr2TYND7b94UCMB3 6PgvL703vdTJkzCwkIUHowuKdgsYyfWum22Z9Os9kyVig6gMdPfawZXgLnWVuA== 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=1721047105; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=kh7KDABb6x/N90A5iEmFzErgvfvxrwfSGPicZ27dYDE=; b=W+RqtCwV+plVV9z5J8Po5Ipzp4uN9r6pqGz0CafNWWGXZYDMTkx0+Y3zrEcurX8RnlpL/Z ELIuC6P5uktYny70E2qOKx7OWtd897vfSetpApTZw7Yku9tLNDrlpe4CYXpuZYx1D0Tp4s xlwaBrD7kh1GCxwEvu0niSIZBDZdp6gsHkUwvMlTzuctqLMQ44sMoEF7x+QUngcEJppyvX AeDX0IdL/gxlkoCyj4lWcuEyB76NsRb6Vel77SSXvuExkwYfPk0GDr8jI+nO8+NHx13g5Y NYG5r3ROcfAEDzVq39dYK3vbXLl74M3niiGttiP4Z8O11OnId7y7fwIggVZcQA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vj2KsTzt5k; Mon, 15 Jul 2024 12:38:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcPxK061269; Mon, 15 Jul 2024 12:38:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcPo4061266; Mon, 15 Jul 2024 12:38:25 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:25 GMT Message-Id: <202407151238.46FCcPo4061266@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: f028010f4eac - stable/13 - sys/sys: Fix __builtin_is_aligned fallback List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: f028010f4eac429f94ba15a7490ce28d5e8c80ff Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=f028010f4eac429f94ba15a7490ce28d5e8c80ff commit f028010f4eac429f94ba15a7490ce28d5e8c80ff Author: Andrew Turner AuthorDate: 2024-05-22 08:18:26 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:29 +0000 sys/sys: Fix __builtin_is_aligned fallback When the compiler doesn't provide __builtin_is_aligned we use macro as a fallback. The macro was missing brackets around one argument. This could lead to incorrect results when the argument is more complex than a single stagement. Fix this by adding the needed brackets. Reviewed by: brooks, imp, jhb Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45260 (cherry picked from commit 940155d24afb5c80ce7fde59c856c5c0d5c6dbe1) --- sys/sys/cdefs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/sys/cdefs.h b/sys/sys/cdefs.h index 080fcf27dba4..df15a3c04193 100644 --- a/sys/sys/cdefs.h +++ b/sys/sys/cdefs.h @@ -896,7 +896,7 @@ /* Provide fallback versions for other compilers (GCC/Clang < 10): */ #if !__has_builtin(__builtin_is_aligned) #define __builtin_is_aligned(x, align) \ - (((__uintptr_t)x & ((align) - 1)) == 0) + (((__uintptr_t)(x) & ((align) - 1)) == 0) #endif #if !__has_builtin(__builtin_align_up) #define __builtin_align_up(x, align) \ From nobody Mon Jul 15 12:38:26 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vk4jmpz5QrsD; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vk1N6vz4HVT; Mon, 15 Jul 2024 12:38:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047106; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=mGLVq9Eu8qrVWRh/Z5mzobTVNOdGi/eNmELLwPLL2r8=; b=TCIb7Wqb37dXINNhqHBFQp0q69/OpF6M9yul8jPFrZq971LJg8Flcc/HkVRUY80iOd9zyB ON0bakS4muzBTjYUOPnzgy0lMUoVYJoeCCUWAa3IB0nFfGRWN74VAjjcBN1x/mi03BW8/d 5/4lxm/5GwERO4mbt0wBDVFI+XIqsxqswX+0k/0ZNT8PJlWejXHjf0mRc70cVKfLIRF05z SzzMXy7SqLZCF39MhOCJMZHxF4Xu7sXYe8xamhaaExc7GtkZudyJG0zRUjtFWhP5zcE/Z5 ymebpQIJNDdSAsFgmX7SIkClh5Iw9Bj9kpb+OSpfO9BdFAcIEq9gOClzZ+0BpA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047106; a=rsa-sha256; cv=none; b=RtRHCqdnVoSBAGdd4J/Pg8wi/WxoZX0GbVcLqB3FsjZEDqesCPOaydsxPf5LJAPdIr88JX eskm/bXrRGrMHWQpN/JmboxCrc4W/WGER0KW8QpVb2wv8NPYVr2UhjOco7aEq/iKdkBMs0 W6434/UdiJdnw1ABd406ylNQDcDCnQfPYBuf2hxUllE2HT+XvUp/Pwp1x1Ci+6zmseXioE 18GtwJw/GMLecvgfDIGoDdhP68wEIoGxaTMrP2UCHEfdZlkILNnOhy21scTixSYJjCdfdg jgKeHW8+AxN722y8arLgJB8KbxPQFakP3hbn5aReK6DKmPyTw5yBggHITaY+og== 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=1721047106; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=mGLVq9Eu8qrVWRh/Z5mzobTVNOdGi/eNmELLwPLL2r8=; b=oh0BfC89nrR9odQR0SWZ1l00KsjhasnhOyCZud3X4yO6L2gsGQabdErE0xCuVGlReKU9c+ i2MaqKyhnPE/OTtcczco6xH2bhxWB/35Bo4lKjC2XqK0SjyG1KTDHkKBTb3H43cu93TUU7 S0/WhSRlTYs+NyMaGc0/3Kc15q8BbEHv6EgpcJjEaBdihzSuW281tcFn8tiBcJr6uEk3Vd loVpD4MKfS9eL53lcHcsiwj9CBnEVaoY5Ly5emgji0AU3HyFeJSp6Pxj1PF4wo1DuJIVse 8B1I1T+qcTrHd7bA38cWfnGXm7XnR3XPMgOaHv+AnbxJaclO+IpwfTXnBzJPPg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vk0zXfzt5l; Mon, 15 Jul 2024 12:38:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcQbE061315; Mon, 15 Jul 2024 12:38:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcQ29061312; Mon, 15 Jul 2024 12:38:26 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:26 GMT Message-Id: <202407151238.46FCcQ29061312@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 0fdc0f361482 - stable/14 - arm64/rockchip: Fix the build with GCC List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 0fdc0f361482267646f033a9daa6fd564be3a209 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=0fdc0f361482267646f033a9daa6fd564be3a209 commit 0fdc0f361482267646f033a9daa6fd564be3a209 Author: Andrew Turner AuthorDate: 2024-05-22 08:19:19 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:27:30 +0000 arm64/rockchip: Fix the build with GCC We were missing brackets in GPIO_FLAGS_PINCTRL. Without them GCC complains a use is ambiguous. Fix by adding the needed brackets. Reviewed by: manu, brooks, imp, jhb, emaste Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45264 (cherry picked from commit 4f012d7a7a473d2486f01ce355fd2c79c3d43db6) --- sys/arm64/rockchip/rk_gpio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/arm64/rockchip/rk_gpio.c b/sys/arm64/rockchip/rk_gpio.c index c0d35fae3b7b..b1175963a5e4 100644 --- a/sys/arm64/rockchip/rk_gpio.c +++ b/sys/arm64/rockchip/rk_gpio.c @@ -77,7 +77,7 @@ enum gpio_regs { GPIO_INTR_EDGE_RISING | GPIO_INTR_EDGE_FALLING | \ GPIO_INTR_LEVEL_HIGH | GPIO_INTR_LEVEL_LOW) -#define GPIO_FLAGS_PINCTRL GPIO_PIN_PULLUP | GPIO_PIN_PULLDOWN +#define GPIO_FLAGS_PINCTRL (GPIO_PIN_PULLUP | GPIO_PIN_PULLDOWN) #define RK_GPIO_MAX_PINS 32 struct pin_cached { From nobody Mon Jul 15 12:38:27 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vl6GmRz5Qrk4; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vl4bmpz4Hf9; Mon, 15 Jul 2024 12:38:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047107; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=seO+WiqnqX0Udd+T+gb3qTGiWr07VcTYcFSAZCq2rjE=; b=TTpS2Ekf+xmOBG5jbIYzeWkbKB1Rd7GBT/QEM1r5RHiDqGahHTr77Bd5KqKK56gakdel1V c/mSux5ZGblMEb1Ei8aDbKjdpO+zXJUqnEb9QoB3UxbH7cxXIfw5gHK1lN2wKK9N6zLhBu jKZK8IszGYhWr0zQAIuffbstwGolozUsKumUyj960pBhhnC22JlraR0ZMLMMjBl8ELtvK0 VzWfxelyoA3zidTqIcnCGvakAragZIDJ8S29OdbB0WGp8eC1wTq13+gV/yCbP1G+yesLi/ YAUfnVinBPlq8/AyV8oQYznvbK+ldicTvea+9Fwu6rbfM2t9NNDmngWKk/uhsg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047107; a=rsa-sha256; cv=none; b=CtzQIJKrk3xUB0AXIGTuNaVCG0OPiBBLpkCufZfXGXrQJIv23FenTDGaEDWcb6XXtE2dwn QNwIZANVsqYt1nVEfwaVeOzfWWSwI4D92Xh4NcL24+AUlev65jEXifD2+GHMz4FJNF/K5G lPzt0gtqf3Z4LcjuMd0LT3ouDuY6IVQcKm+wVlMpMMxZ+Mz1qtDObvjFw4rRsp5023BhuO 0RI/CVLYBh2ICADzq/Z5Ahs/IP0dx+nvfmfPJCm/6Mj6QUkhX4sPBUOwzh0Nr5OUgya9Ih qZpgibG/61EPoLG3kdrcdDcxWfp40MrXEuqvQJ84BtkrdJzAhJbPEI7rPQbrAw== 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=1721047107; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=seO+WiqnqX0Udd+T+gb3qTGiWr07VcTYcFSAZCq2rjE=; b=Kf1wAsHbzPx99EKjKm8385pakhv1SvDuCs+ZWIP9SFvEvFYOOSoxXcYAjfb/51KFA0juTQ VkdNibWILhpbDNrq5w2FGbBOuO//5D3yGSBP4XhOwDiuwEVNj4Xaf+L8qE/UQLhgEUO36X k5LaASPxSRnskDjMeRjw/wAkY0tyjuhB1Zk8TVxXkbUfDTqW93MYcO3M29cOpVNo9CptlN axiHKByJgZ0x3Xx400EdY4YmHfRncqGYx4zKzaJol20Pjrgip5VaKKkr8YHa4qqUb+wrxO RZ53BLUziRJvKL05KYYL7+Hj856KYddzoyYd0WYetbQXXokyAdx578VMh9z6Tg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vl4CKSzscm; Mon, 15 Jul 2024 12:38:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcR50061459; Mon, 15 Jul 2024 12:38:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcRja061456; Mon, 15 Jul 2024 12:38:27 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:27 GMT Message-Id: <202407151238.46FCcRja061456@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 5ad0db240e03 - stable/13 - arm64: Add the pointer auth registers to armreg.h List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 5ad0db240e0302e2bcf251214714c77c8b404d63 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=5ad0db240e0302e2bcf251214714c77c8b404d63 commit 5ad0db240e0302e2bcf251214714c77c8b404d63 Author: Andrew Turner AuthorDate: 2024-05-22 08:18:54 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:29 +0000 arm64: Add the pointer auth registers to armreg.h Add the pointer authentication registers to armreg.h. These will be used to support pointer authentication in a kernel built with GCC. Reviewed by: jhb Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45262 (cherry picked from commit 57d714a23f5ce21e389d53636b8bc6c1b45d518e) --- sys/arm64/include/armreg.h | 80 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 80 insertions(+) diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index 2f8da2ad7e0b..053f7a6d0afc 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -73,6 +73,86 @@ #define UL(x) UINT64_C(x) +/* APDAKeyHi_EL1 */ +#define APDAKeyHi_EL1_REG MRS_REG_ALT_NAME(APDAKeyHi_EL1) +#define APDAKeyHi_EL1_op0 3 +#define APDAKeyHi_EL1_op1 0 +#define APDAKeyHi_EL1_CRn 2 +#define APDAKeyHi_EL1_CRm 2 +#define APDAKeyHi_EL1_op2 1 + +/* APDAKeyLo_EL1 */ +#define APDAKeyLo_EL1_REG MRS_REG_ALT_NAME(APDAKeyLo_EL1) +#define APDAKeyLo_EL1_op0 3 +#define APDAKeyLo_EL1_op1 0 +#define APDAKeyLo_EL1_CRn 2 +#define APDAKeyLo_EL1_CRm 2 +#define APDAKeyLo_EL1_op2 0 + +/* APDBKeyHi_EL1 */ +#define APDBKeyHi_EL1_REG MRS_REG_ALT_NAME(APDBKeyHi_EL1) +#define APDBKeyHi_EL1_op0 3 +#define APDBKeyHi_EL1_op1 0 +#define APDBKeyHi_EL1_CRn 2 +#define APDBKeyHi_EL1_CRm 2 +#define APDBKeyHi_EL1_op2 3 + +/* APDBKeyLo_EL1 */ +#define APDBKeyLo_EL1_REG MRS_REG_ALT_NAME(APDBKeyLo_EL1) +#define APDBKeyLo_EL1_op0 3 +#define APDBKeyLo_EL1_op1 0 +#define APDBKeyLo_EL1_CRn 2 +#define APDBKeyLo_EL1_CRm 2 +#define APDBKeyLo_EL1_op2 2 + +/* APGAKeyHi_EL1 */ +#define APGAKeyHi_EL1_REG MRS_REG_ALT_NAME(APGAKeyHi_EL1) +#define APGAKeyHi_EL1_op0 3 +#define APGAKeyHi_EL1_op1 0 +#define APGAKeyHi_EL1_CRn 2 +#define APGAKeyHi_EL1_CRm 3 +#define APGAKeyHi_EL1_op2 1 + +/* APGAKeyLo_EL1 */ +#define APGAKeyLo_EL1_REG MRS_REG_ALT_NAME(APGAKeyLo_EL1) +#define APGAKeyLo_EL1_op0 3 +#define APGAKeyLo_EL1_op1 0 +#define APGAKeyLo_EL1_CRn 2 +#define APGAKeyLo_EL1_CRm 3 +#define APGAKeyLo_EL1_op2 0 + +/* APIAKeyHi_EL1 */ +#define APIAKeyHi_EL1_REG MRS_REG_ALT_NAME(APIAKeyHi_EL1) +#define APIAKeyHi_EL1_op0 3 +#define APIAKeyHi_EL1_op1 0 +#define APIAKeyHi_EL1_CRn 2 +#define APIAKeyHi_EL1_CRm 1 +#define APIAKeyHi_EL1_op2 1 + +/* APIAKeyLo_EL1 */ +#define APIAKeyLo_EL1_REG MRS_REG_ALT_NAME(APIAKeyLo_EL1) +#define APIAKeyLo_EL1_op0 3 +#define APIAKeyLo_EL1_op1 0 +#define APIAKeyLo_EL1_CRn 2 +#define APIAKeyLo_EL1_CRm 1 +#define APIAKeyLo_EL1_op2 0 + +/* APIBKeyHi_EL1 */ +#define APIBKeyHi_EL1_REG MRS_REG_ALT_NAME(APIBKeyHi_EL1) +#define APIBKeyHi_EL1_op0 3 +#define APIBKeyHi_EL1_op1 0 +#define APIBKeyHi_EL1_CRn 2 +#define APIBKeyHi_EL1_CRm 1 +#define APIBKeyHi_EL1_op2 3 + +/* APIBKeyLo_EL1 */ +#define APIBKeyLo_EL1_REG MRS_REG_ALT_NAME(APIBKeyLo_EL1) +#define APIBKeyLo_EL1_op0 3 +#define APIBKeyLo_EL1_op1 0 +#define APIBKeyLo_EL1_CRn 2 +#define APIBKeyLo_EL1_CRm 1 +#define APIBKeyLo_EL1_op2 2 + /* CCSIDR_EL1 - Cache Size ID Register */ #define CCSIDR_NumSets_MASK 0x0FFFE000 #define CCSIDR_NumSets64_MASK 0x00FFFFFF00000000 From nobody Mon Jul 15 12:38:27 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vl52Hgz5Qrr0; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vl22wvz4HVg; Mon, 15 Jul 2024 12:38:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047107; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=tTMRqkHPuCTkNpZG7izBL2Ub8KryCVRGy4qgAQaHJAg=; b=FN1qsRvKR6sNBVdHIXiz/mz0R11xKN+aDwULBSO0XurfK2EHSSET2e7LQqpBZfpkOlWQ7J CKiskdIN5TXHv0gI3QRKVFuQC9MXAacz0x4IlR7ppYmWFhufUvKk0alFEv/EwOrNdowc5P UlWksSsGKiDZgJRb3f1V5CEyEa/omOps+LZt9/zK67t/RlZNqSm+RIFga5DdDRl0Vtuw7Z vkfTJqdXKsXhnS1TrIrLajg73ffbTWE1O5mfjddV3OBjvPAiPcEuwjcJRdgODYA1UogiKL whV/N9ZiKOH65eWEWH4hnXjLgp2zphSu68MXIo6Lzm34IzktvKGmBXe/jBgZmw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047107; a=rsa-sha256; cv=none; b=O3LGS6drsBY/U47p3E5jczix+U6ADifNlX/VfdDsHevLg6J/wN2iF6FSVXtBWjWwcqM6IE 3Uy8Ma2ZmPKG07MKeTmz0LZTKIWyOnwNh5RvElmNP+y/CF86VdfdyWTmBG2CSw/kHbj4wW uH1Eo5Cjk+D/z0/IMnEX+qgFMFtjexu8MofZrQY5cQGaFH7fPx7X+cVueP59+UaTFAcpCo 2eonoMOSCN+oOxGN1Rk2LXIFFK+MslBpSoFRNr65zXn5LSfsc1G/mWcQ0Pauu5SaBdkLCG XpA+hYNVModk8fCAFYBxU6tKMAPzn9Dk4729vMp4IQj0SHra3QARQw9V7w4AXg== 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=1721047107; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=tTMRqkHPuCTkNpZG7izBL2Ub8KryCVRGy4qgAQaHJAg=; b=JAUE6bmwjaMEoVSGy9ZbFARiSzU3o9lO7t1JOK2i0prTyvbhMbJDszlheyslxiOWUTTb6+ 6gJoUzoVOQQaq4BZSgAd5al+jDbRWGJcUx5IbFW0WxxN8e4KnZwRGFQ0ac8OQvTIky2DE1 QxVTYgEaDRn/k9Lkka5cWQuTcpYDBPZ7yTszNP5MXmdTXqU5Pu0hFIWOWzx4P+HjaUVmLT garSKFmyiCsR6caB/LAUvTgvTBH5D0BiI5q6tix/O6bAQWbHKoTKMCqbBZrwL/Gr8fV00f BNcpoPtT0bnAXtPoeHLyi273JJFR1148rWPCh6eGuAj3tiWenKlWhqqg6DmbkA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vl1dhkzsJP; Mon, 15 Jul 2024 12:38:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcR6j061408; Mon, 15 Jul 2024 12:38:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcRSW061405; Mon, 15 Jul 2024 12:38:27 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:27 GMT Message-Id: <202407151238.46FCcRSW061405@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 0496539fe32d - stable/14 - pci: Fix pci_host_generic_acpi with gcc List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 0496539fe32d87b33baccee97ca2bf774f6bb56f Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=0496539fe32d87b33baccee97ca2bf774f6bb56f commit 0496539fe32d87b33baccee97ca2bf774f6bb56f Author: Andrew Turner AuthorDate: 2024-05-22 08:19:38 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:27:37 +0000 pci: Fix pci_host_generic_acpi with gcc In pci_host_generic_acpi.c we loop over pci_acpi_quirks to check if we need to handle any quirks. GCC doesn't like the terminatin as it sets a fixed width string to 0. As this the array is only ever used in this file change to use nitems to find when to stop the loop. Reviewed by: brooks, imp, jhb, emaste Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45265 (cherry picked from commit f55e866488ba2d8bb5b79659ee84bec1fe7808fb) --- sys/dev/pci/pci_host_generic_acpi.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/sys/dev/pci/pci_host_generic_acpi.c b/sys/dev/pci/pci_host_generic_acpi.c index 2191ec4d655a..0cd17d5f5555 100644 --- a/sys/dev/pci/pci_host_generic_acpi.c +++ b/sys/dev/pci/pci_host_generic_acpi.c @@ -99,7 +99,6 @@ static struct { { "MVEBU ", "CN9130 ", PCIE_ECAM_DESIGNWARE_QUIRK }, { "MVEBU ", "CN9131 ", PCIE_ECAM_DESIGNWARE_QUIRK }, { "MVEBU ", "CN9132 ", PCIE_ECAM_DESIGNWARE_QUIRK }, - { 0 }, }; /* Forward prototypes */ @@ -202,9 +201,9 @@ static void pci_host_acpi_get_oem_quirks(struct generic_pcie_acpi_softc *sc, ACPI_TABLE_HEADER *hdr) { - int i; + size_t i; - for (i = 0; pci_acpi_quirks[i].quirks; i++) { + for (i = 0; i < nitems(pci_acpi_quirks); i++) { if (memcmp(hdr->OemId, pci_acpi_quirks[i].oem_id, ACPI_OEM_ID_SIZE) != 0) continue; From nobody Mon Jul 15 12:38:28 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vm56BMz5Qrny; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vm3MNTz4Hq9; Mon, 15 Jul 2024 12:38:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047108; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=vo+JSC1qJoNIuX8hZtG7grfiDY3l/V6Q3Psmb5PQNQE=; b=MbrEIO/Xzunjab6M+BHW6Wi2+nxrmFCQYu5arR42KvEaB/a9XFJR/pVSAwWFUFuoST5TeQ kwAiT/o8wXVH235uAjZib4ZSf8nutBCxAgDp3sSW0Ye9zrrpbzH4mvxIrQRaVzOX6hkakC pwBJgM4DucPx0avL1KfXdA512EF/Z4gbakn51Ut6AU/5Awj8mJXbe6HKBWe6jp/qvYRfOA eU5ca3hYexB44NFQs0qrLCRWxGg2u5O06gROHH41jb78Q8eNN5QDjpJZQtngo+fZP+BFfL xLCaN0F7BBE/hCpU8W2xqhQVi4wQ5z92cMwNLUXWAltJ/0j48SnIFnZSjI/7ZQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047108; a=rsa-sha256; cv=none; b=xhK7UJdI4dgJk+StRQUj7H0qOwBaxPzQ8vbQ+ornz2ve4o89bhpAewrgaB23yIaKaILZmP ynrk+QJTl4sX9vZXozWV9rglXYi5os92cn3LeLj6kZQU59bLDq8vk4m4eebIvjwQbfQp2B cl5DXPpR4EGfOPjLIsND/Py7DywSig5+Rws+k8Q7LPUKdGsY0I3NnqfVKr0Yp4xVTNHv0X MHaf484PDWBZczR8VrQyS/F+T6fNGOu+9vqI4SmFRh6MNOaI+yUtRfL8Qda1pyBHqS+7RX ZPttVSn1L+bFaFjvXn2SSsoytoVtjcWI7JhOyrcOvSbC59JzMgi2eqT8GfKoIg== 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=1721047108; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=vo+JSC1qJoNIuX8hZtG7grfiDY3l/V6Q3Psmb5PQNQE=; b=gC/ofO06bNMyGgF6rc6Tktd/ahkSg87mqJUyoqNlpTRJGBVJmkNfQZdOTDa3ipvPmkCkdh DSjsybwM4MgIc34q2TpLfiD2e4l8U/jzdt26wTsymhL7Gw6RcM1zm0qzSqsb+O2u9xd0cw WED6icxC1yVmYi2xadUp9q/etO14vMkXCcPPK4wVkn3aCfCf8PDEIxIErFb+VfLFlIAQmB EP9DLjWL0x029hkbgRYf67I9q+7HG3a8HCP8NOcbafD+//fLPHnzjMps4HH2/Vm0ZGQHMu W30C3k1J3mBILhFPNlTPgSf9hN25n2EgSG/KqMixhBKygNBizbfSS73Rfxz5Zg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vm2zsgzt5n; Mon, 15 Jul 2024 12:38:28 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcSAg061504; Mon, 15 Jul 2024 12:38:28 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcSZW061501; Mon, 15 Jul 2024 12:38:28 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:28 GMT Message-Id: <202407151238.46FCcSZW061501@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: dfd26e29dd43 - stable/14 - dev/hwpmc: Fix the dmc620 MD4 macro List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: dfd26e29dd43e4370ba31159c57fa474ef6e995b Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=dfd26e29dd43e4370ba31159c57fa474ef6e995b commit dfd26e29dd43e4370ba31159c57fa474ef6e995b Author: Andrew Turner AuthorDate: 2024-05-22 08:19:49 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:27:45 +0000 dev/hwpmc: Fix the dmc620 MD4 macro Add braces to the dmc620 MD4 macro to fix the GCC build. Reviewed by: brooks, imp, jhb Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45266 (cherry picked from commit 131c1718c6331e87f139b42b4ad0e57b6a71ea44) --- sys/dev/hwpmc/pmu_dmc620.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/hwpmc/pmu_dmc620.c b/sys/dev/hwpmc/pmu_dmc620.c index 42e5dfdbf154..c33e5264f7de 100644 --- a/sys/dev/hwpmc/pmu_dmc620.c +++ b/sys/dev/hwpmc/pmu_dmc620.c @@ -68,7 +68,7 @@ struct pmu_dmc620_softc { #define RD4(sc, r) bus_read_4((sc)->sc_res[0], (r)) #define WR4(sc, r, v) bus_write_4((sc)->sc_res[0], (r), (v)) -#define MD4(sc, r, c, s) WR4((sc), (r), RD4((sc), (r)) & ~(c) | (s)) +#define MD4(sc, r, c, s) WR4((sc), (r), (RD4((sc), (r)) & ~(c)) | (s)) #define CD2MD4(sc, u, r, c, s) MD4((sc), DMC620_CLKDIV2_REG((u), (r)), (c), (s)) #define CMD4(sc, u, r, c, s) MD4((sc), DMC620_CLK_REG((u), (r)), (c), (s)) From nobody Mon Jul 15 12:38:28 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vn1Wh3z5QrhW; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vm5Yk0z4HfP; Mon, 15 Jul 2024 12:38:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047108; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=8yl/Qm5Lr/hugRgr7x3z/4SFKDNmeWXkjZjt7Yq68GQ=; b=rZOgVGgVclRujJAztIVDN14u55Lf3wpjxFSlGDP7u8U4HQBxSupdo+PBNjPYSrFfI8ufP7 GG2HPfY3CTxznBpqkG+iyJf4Tcn0oEbH6NkLivWTLXqTUChNlC7gnmGYr1MWZy2OMnu7tS 3e0gvSY9VDroyFDRz/jtxdU6BMn+7HaJH8/DRvHFOxl1FwfNJy04Y45RuPshFsf3ODi45x LuUBfHh8+WAfbizHJMZQSsSVe5vUhZDEph+r5lyTnF9KqjHp4TCQN1BxMMx9QlJhURz8pn al5yc+6xTrX01YYJvM+8B4aWp9Q4GXVsg5FSseESaMAcPIk6zMC8Z2frgXJ7FQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047108; a=rsa-sha256; cv=none; b=E1FQsodryKKRDo0llHUEAmq9D5Ezk9xlVK4xzkZlF5c7hl3ZNxVRILGq2gc/CdvZZ5ZneC 2C/DO/1hXMUYsOHhP5jcC5asRM646k2KyXx3WjVm1ws+hShgWTICmymjVBoWFfUdxUjViw lhNRXkc1BVVdtkksW7WJxPQVyCbsb/SifUuDZJA1XlcvlfS1n9peWK/PTCwTEwP5kroA46 PwMh8PkER8HozIIlmjurLClB9xMQPpy5OBtxBXYbDnb2z3EWBowNxMiJZ9dB4bw1DFbgq6 SOlmuVdcG0WN00piMWJhqVHL50PS+Y3FwjBh+rlrzm/jDkAcbi3NCbbVVzqNmA== 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=1721047108; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=8yl/Qm5Lr/hugRgr7x3z/4SFKDNmeWXkjZjt7Yq68GQ=; b=xoxWRwASsrte5umvdGUh8hiiHpALONpx+ZWMues+mwfSJRJ5rUYM9QSubE5jex6ZtQ5Uv8 MJJQjD7wLmycEaLB7I8lZe9KA13QmorpKHucECePgjs7xg59/51a3UKNQCaXn2Jeisww6U EG+E58AUiIw96+Udw7FhuOvvuRfvi3/+u3Cbx0A5ws82ybI91dGINpW90O1MgA1fpLcwGs +emPdYeeOWnFudmFGcfKJdhE6anJqRSJ27TDwG5O9KaL6vwqJdlLqJZYiNWdX3s60zOlIm SWvghts/n36663tZ+oUB+ULrkgKg1SiRb/wgwZgJVfrvuKT5caYCPE4X8eJPTQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vm5BG7zt1R; Mon, 15 Jul 2024 12:38:28 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcSXb061550; Mon, 15 Jul 2024 12:38:28 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcS8p061547; Mon, 15 Jul 2024 12:38:28 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:28 GMT Message-Id: <202407151238.46FCcS8p061547@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 29f8816b668b - stable/13 - arm64/rockchip: Fix the build with GCC List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 29f8816b668bfe7765b819eea32a97091d41b5f8 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=29f8816b668bfe7765b819eea32a97091d41b5f8 commit 29f8816b668bfe7765b819eea32a97091d41b5f8 Author: Andrew Turner AuthorDate: 2024-05-22 08:19:19 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:29 +0000 arm64/rockchip: Fix the build with GCC We were missing brackets in GPIO_FLAGS_PINCTRL. Without them GCC complains a use is ambiguous. Fix by adding the needed brackets. Reviewed by: manu, brooks, imp, jhb, emaste Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45264 (cherry picked from commit 4f012d7a7a473d2486f01ce355fd2c79c3d43db6) --- sys/arm64/rockchip/rk_gpio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/arm64/rockchip/rk_gpio.c b/sys/arm64/rockchip/rk_gpio.c index 765e03666eeb..4796743bea6e 100644 --- a/sys/arm64/rockchip/rk_gpio.c +++ b/sys/arm64/rockchip/rk_gpio.c @@ -71,7 +71,7 @@ #define RK_GPIO_DEFAULT_CAPS (GPIO_PIN_INPUT | GPIO_PIN_OUTPUT | \ GPIO_PIN_PULLUP | GPIO_PIN_PULLDOWN) -#define GPIO_FLAGS_PINCTRL GPIO_PIN_PULLUP | GPIO_PIN_PULLDOWN +#define GPIO_FLAGS_PINCTRL (GPIO_PIN_PULLUP | GPIO_PIN_PULLDOWN) #define RK_GPIO_MAX_PINS 32 struct pin_cached { From nobody Mon Jul 15 12:38:29 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vp36g6z5Qrvg; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vn6D2hz4HsG; Mon, 15 Jul 2024 12:38:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047109; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=A2x8sF3NUvLrmLvOwa0zKhP9XRsXiTlyW1tKTiV429c=; b=UPVTEP/GJ9bdOBk5kOHRcbR9XaE3V6EwglEtGnHuVEpoDvGZwMe6+R6Pn7CtPXEcxctzmn dOiXiR3fxSzmvDplIx1SoHYerxDAJm1Nemu447xQgnXjn/UKLxrd20TEc7tPCqFu1DD8Oe Tezs0jzyIl6+DI16uIa8gfPfL5lHF55CLw/xyUrbScMZ82xH9378VlsOUQPQgzDRwp/dtR zpm28LeFa4gN0lpC8U3i41/xCGsXhGqPYCn2hr9REqBdJr14iXutSrUWTgJDVgmAbYkddz fUBK8KVYh9w50vJOEX9i18U53Aahc9tVCArb+Yk8NOidw1kneJtgGg+eKIhUIA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047109; a=rsa-sha256; cv=none; b=oivdQ4SP1s/c33IuzjaUUcUQiFhqMLH8wY3CHwR5arPb8entMfsE+6hFMHwYMaoSYmVh+Z cQJHu1wheEHffRiX8Gg/5HK7lkWWYW3FJR4zz/wHOnW0yIGfk7yMBgBve8ADeFufSnx+O2 tiYUaGjlYxcF8I1i+U7JYAwEswH0Jt7j807UKgsuSgg1l2PygrGp7Ki+dvdTV1ogYQDSTr V5kNKnV0nWzfCR3jhCg2zqW4yosL/HL529UxKDgc3sohwrmrlbDnCSfFOdIUlkcBzfJrKz DpyZ5xlnsyS8Bo7wQu6lq599kYIt1mBuvE6lUSWYbm9vnp1KfwzXiw+X2f4IZw== 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=1721047109; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=A2x8sF3NUvLrmLvOwa0zKhP9XRsXiTlyW1tKTiV429c=; b=UqlT0hwVbDIWM0f1Y/x9lcWBZPg1XTWMG26GfKIi1vLahBfRHbeCmAMEoOkEryCFt4Fmnf CqdXrHUvCEIz7CHszrjY0jM6Jj4bl3mHN3uz7nSxYgs76qOz8WWUehGxZ0SDVeY6W9Q/c6 NudfzAnl0Mv3h8hJhK/7t+lDHnbIsVKLst70QHKvd0Z59UwuFAKmHoGM/Zz0lgv89/bKGi HA8S/dib4kAuspjRQ7XrOci+8bQHj1X3herf7Vy8xgw7+plIsmbaU0oy0/Dv/RzGNJfgZh aGtrIfktvfPqFDqKd3hqsrkVtX8zQHJMJyG29HhYd53ZHFjD7k/R/teOPiSXdg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vn5rg8zsJQ; Mon, 15 Jul 2024 12:38:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcTHY061647; Mon, 15 Jul 2024 12:38:29 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcT3N061644; Mon, 15 Jul 2024 12:38:29 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:29 GMT Message-Id: <202407151238.46FCcT3N061644@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: aedbe2058290 - stable/13 - pci: Fix pci_host_generic_acpi with gcc List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: aedbe205829059cb1a2245d68d63398855cbab5d Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=aedbe205829059cb1a2245d68d63398855cbab5d commit aedbe205829059cb1a2245d68d63398855cbab5d Author: Andrew Turner AuthorDate: 2024-05-22 08:19:38 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:29 +0000 pci: Fix pci_host_generic_acpi with gcc In pci_host_generic_acpi.c we loop over pci_acpi_quirks to check if we need to handle any quirks. GCC doesn't like the terminatin as it sets a fixed width string to 0. As this the array is only ever used in this file change to use nitems to find when to stop the loop. Reviewed by: brooks, imp, jhb, emaste Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45265 (cherry picked from commit f55e866488ba2d8bb5b79659ee84bec1fe7808fb) --- sys/dev/pci/pci_host_generic_acpi.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/sys/dev/pci/pci_host_generic_acpi.c b/sys/dev/pci/pci_host_generic_acpi.c index 25a4197a2bdc..ca9845fff7c2 100644 --- a/sys/dev/pci/pci_host_generic_acpi.c +++ b/sys/dev/pci/pci_host_generic_acpi.c @@ -99,7 +99,6 @@ static struct { { "MVEBU ", "CN9130 ", PCIE_ECAM_DESIGNWARE_QUIRK }, { "MVEBU ", "CN9131 ", PCIE_ECAM_DESIGNWARE_QUIRK }, { "MVEBU ", "CN9132 ", PCIE_ECAM_DESIGNWARE_QUIRK }, - { 0 }, }; /* Forward prototypes */ @@ -204,9 +203,9 @@ static void pci_host_acpi_get_oem_quirks(struct generic_pcie_acpi_softc *sc, ACPI_TABLE_HEADER *hdr) { - int i; + size_t i; - for (i = 0; pci_acpi_quirks[i].quirks; i++) { + for (i = 0; i < nitems(pci_acpi_quirks); i++) { if (memcmp(hdr->OemId, pci_acpi_quirks[i].oem_id, ACPI_OEM_ID_SIZE) != 0) continue; From nobody Mon Jul 15 12:38:29 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vp0BFlz5Qrr8; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vn3yFXz4Hnc; Mon, 15 Jul 2024 12:38:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047109; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=vVlNA3+4YF752rju26zpwVlJPwlq0lW3SMVkhjNsV7c=; b=BzzWVTKxzTvGyKpAVwt/EWBvSf7bQPlb3/hvxg+qvoURqq1Hjceq/DcaePIyXmAVMHMIBe V1JavmMYIFaK0wT75fWEAOC85h6krtnmxliHteMSB2ZBd7cskVq0bVJcxfqN34QE8wZdRs fIwMFV2m1IoXc1RCEoU4oTk5ONhh/JEMJQnhtz00MW6PXuGh7/KjFU5VcFMYJQxuYpGBCB soEMJAK2rLT+9N7iFMcHeE1PkfGiAwY9WNJX26W0GgtwaKPssVP5rABXG8hxcte7itHxx7 z8I6+iib7BbpTUSVgFcKTYnMdKGPQws1KW/53Agnze6j3UxIUtewdlh8SnZR+g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047109; a=rsa-sha256; cv=none; b=mQDT4FF6EZ/mvhECW6krUHZwLTFtqFc/2asQkCxIkMCdjliJmHWCtA0oFLZ1YmmxjXqDCf fdSUYDYDvGkWMFtodDGk8abyZcpGyNenvVVOib9tqLAMk8pEL0ae3f60BOqWm6819+K2Ec oVpdaQEWg77VCszReJFqLNH9v6TbY9/cUNzvjqrfbtGKeQCAhzaZBXdaYdVuWSxSxNTy+V U+fTWsV0MediEvyIyRH/kEW+kZnMDO+2iL4VShBPHS/RQ6Ye/6ZXOp8LKffq3MtuDwu5gy Vc2Yb57waSZyC7TOB7N7+2Y9Y1vV1c/Gls+lNLyr39yuQ67ea/Kr4lsmyTDPXg== 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=1721047109; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=vVlNA3+4YF752rju26zpwVlJPwlq0lW3SMVkhjNsV7c=; b=YuARxcrI+kMbKMV6B+fj9cxLPiize4cewPVnNUJ0E16y72EQGabobW3yAv2fm/cyq92p/y 9v2huKyy2r15/oWmMB7Z28taK3IoxAo+ZwKZ/XM/gsslmSJ9NkbZDuSXhVRHaUr9VE9SNr 8IdoBEhcctkldWkevnQ0tfMOMWHqHZL8JRsMoOJcZfYxozD0cxrx106EPLFIc/1mhAZSKg QKCSm1XgeP6O0TXjZZ0RMBNRJ8PC2jUQA4cuYjoOXpOs6XpZjIB0Vgesd5k4Z35NpyyP+F hwvWr/uD0WcVAMuGRjwHOIJMvTTdsTpaxA0gQ6oVz2/UquVODiXsKvY4U54txw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vn3SClzt3K; Mon, 15 Jul 2024 12:38:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcTja061604; Mon, 15 Jul 2024 12:38:29 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcTsC061601; Mon, 15 Jul 2024 12:38:29 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:29 GMT Message-Id: <202407151238.46FCcTsC061601@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 8ecef12113ad - stable/14 - sys: Build arm64 per-thread SSP with GCC List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 8ecef12113ad61e25a7c56e8c77cb6754fa1060c Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=8ecef12113ad61e25a7c56e8c77cb6754fa1060c commit 8ecef12113ad61e25a7c56e8c77cb6754fa1060c Author: Andrew Turner AuthorDate: 2024-05-22 08:20:01 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:27:54 +0000 sys: Build arm64 per-thread SSP with GCC It has been supported since GCC 9. It is unlikely anything older than that will build the kernel so mark it as supported by GCC. Reviewed by: brooks, jhb Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45267 (cherry picked from commit c2628accc029a07eb8ff73b6df7f7d6af194ca2d) --- sys/conf/Makefile.arm64 | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sys/conf/Makefile.arm64 b/sys/conf/Makefile.arm64 index 77c36fa6ce6c..5e706549486a 100644 --- a/sys/conf/Makefile.arm64 +++ b/sys/conf/Makefile.arm64 @@ -31,7 +31,8 @@ CFLAGS += -DLINUX_DTS_VERSION=\"${LINUX_DTS_VERSION}\" PERTHREAD_SSP_ENABLED!= grep PERTHREAD_SSP opt_global.h || true ; echo .if !empty(PERTHREAD_SSP_ENABLED) -. if ${COMPILER_TYPE} == "clang" && ${COMPILER_VERSION} >= 130000 +. if (${COMPILER_TYPE} == "clang" && ${COMPILER_VERSION} >= 130000) || \ + ${COMPILER_TYPE} == "gcc" ARM64_SSP_CFLAGS = -mstack-protector-guard=sysreg ARM64_SSP_CFLAGS += -mstack-protector-guard-reg=sp_el0 ARM64_SSP_CFLAGS += -mstack-protector-guard-offset=0 From nobody Mon Jul 15 12:38:30 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vq0PBtz5QrsM; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vp56lMz4Hj3; Mon, 15 Jul 2024 12:38:30 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047110; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=07qMHOXLX1wCKO1sWiW2LlO4eGNvBX8ucnL+uR6M148=; b=O+/8t2MI1SVnAQlfCt/wizeCu8whMulo2M39sL6e/Amm3Ckl3d06eWTGBufZzdWWwkZZaj 6bpn2hfiaj1xB07QWXfNLQDgJOIziFs4peIULM+19Ebc71DJ7j0EG9GXQdRtG5m1VU8/TH 2bl29zY1siayU6Mj0yqGggymnAFV0WBQjyR5EhJ++345sPPo7ILLCBYJn2TykR71R4E8aD //tqL6yiOu56ccojNCd5SOa3sLbTNZ4PEvvtDSUwrCXRfurhVR/nVF1kTNvvvVFD7BQDHU X0+0rpGeOuhBImPv3l0Hk+PrPg2fv3w4IqyM2jiY87E8klaHbbboXvshKU1/Yw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047110; a=rsa-sha256; cv=none; b=L7WDILyTp5/J7mTRsAizLWZjpZlK++zPh2raI41IIuIXW0zVE3g91E9reqHU58Lm0Ey6jC pmXLVCVxigN3hURb+gekNewzDmeIV47s1mMEf/sDG2i8piQ5c6QenresaE/KRvxDDEMmZ/ MHiKXuBmAHDlww6N5sacuX+pbIne5jQ8ITS8qsaohcjH7uBZE63gI1H0gRz2BITPumCOVM BjXhKPAJklvywoUfsY4wgOVVIh+eHZVAOLdm1d092/OUuTyE7W4u6gxR6r8pUUanNgNQsG nC+H8QhJ0F5tVyBtliTnEDzQloeRab0QGkjHlY0kJQWxfMbtY/7MALSYZrZTTg== 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=1721047110; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=07qMHOXLX1wCKO1sWiW2LlO4eGNvBX8ucnL+uR6M148=; b=i0sOUkKJFXci+u0pn751FMMjtoBC1mp1YTZc8RfkH5Gzyi+GUgfQ1nZd5yAzoCvrTbpwN+ H77Eq9DOYEPhE8hWRGTo15yeb+sg/B0sZqmGUvEZS2pfr46uEdi4in6DbM7kvFBiJ5BTAg oL5Lb/xAXaKAoVFbWmm1cw9KNFJunedXHhFdAv/7+Kl8nWK00IbsGb5Eqq3BQoNe2dLOBh D+d0TAmympCAYl9+EXpelOo3iqmjaS1g4kw0t5r9yyd8KZBCmAb+VIaauCNLz+Yhw3Gv47 AKL2xr/qgjQtoEITtf4KiCxrKPJnnUrrBDUWFEpsf5eBoltk5SN08DwoY+NyCw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vp4lQCzt5p; Mon, 15 Jul 2024 12:38:30 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcUqp061692; Mon, 15 Jul 2024 12:38:30 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcUhw061689; Mon, 15 Jul 2024 12:38:30 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:30 GMT Message-Id: <202407151238.46FCcUhw061689@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 8971fe25a80b - stable/14 - stats: Fix the build under gcc List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 8971fe25a80b8cdb5547beb48c72d923ade5875c Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=8971fe25a80b8cdb5547beb48c72d923ade5875c commit 8971fe25a80b8cdb5547beb48c72d923ade5875c Author: Andrew Turner AuthorDate: 2024-06-04 12:46:33 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:28:28 +0000 stats: Fix the build under gcc Reviewed by: brooks, imp Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45302 (cherry picked from commit a5affc0c4cabb59cceca98c4099fc9acc6a05dda) --- sys/kern/subr_stats.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/kern/subr_stats.c b/sys/kern/subr_stats.c index 6a9dff2b9126..6d04b9ae1588 100644 --- a/sys/kern/subr_stats.c +++ b/sys/kern/subr_stats.c @@ -296,7 +296,7 @@ static const bool vsd_compoundtype[VSD_NUM_DTYPES] = { const struct voistatdata_numeric numeric_limits[2][VSD_DTYPE_Q_U64 + 1] = { [LIM_MIN] = { - [VSD_DTYPE_VOISTATE] = {0}, + [VSD_DTYPE_VOISTATE] = {}, [VSD_DTYPE_INT_S32] = {.int32 = {.s32 = INT32_MIN}}, [VSD_DTYPE_INT_U32] = {.int32 = {.u32 = 0}}, [VSD_DTYPE_INT_S64] = {.int64 = {.s64 = INT64_MIN}}, @@ -309,7 +309,7 @@ const struct voistatdata_numeric numeric_limits[2][VSD_DTYPE_Q_U64 + 1] = { [VSD_DTYPE_Q_U64] = {.q64 = {.uq64 = 0}}, }, [LIM_MAX] = { - [VSD_DTYPE_VOISTATE] = {0}, + [VSD_DTYPE_VOISTATE] = {}, [VSD_DTYPE_INT_S32] = {.int32 = {.s32 = INT32_MAX}}, [VSD_DTYPE_INT_U32] = {.int32 = {.u32 = UINT32_MAX}}, [VSD_DTYPE_INT_S64] = {.int64 = {.s64 = INT64_MAX}}, From nobody Mon Jul 15 12:38:31 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vr48mpz5QrkH; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vr12Qsz4J1S; Mon, 15 Jul 2024 12:38:32 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047112; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=qEQ0Xqc6XXy+RLgw3NMXAL4pwXjoYZqIYuVlesdmcuY=; b=WhYNPmKoiqOLuUllhn8ny4PRtbO34MsL/kUndKb0gQcxl4lDCvcvdezcXBzq6PnkM1/VGZ yScNl+GPJA7VP5nKoLlfTwA94b9IENx8JoeHp1iuwhh+deO0PPQNBWhBrxk5MGEqDPX26w Arpr/OXeTdViYALezxpOAl/EW5AYu7IjR17DvHhgaqvSsNd2O0LU12paDbYvnet/CoCAIP CIxpUcLMKqsO4/hiDETyKWITKHTHZQhjWl09i8gEtvdEcotuBHMgPt6m1DiyjZRVAiei+e h2Q/Cq+bnge8GjIrB02jIgDse4KuxekVhwsnB7z/VccoSUAxGDd2QKUnLJPOLA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047112; a=rsa-sha256; cv=none; b=n1ZPtk6wN+7Ex5C/msCWI1JIscfbNDce+KDGCr+ms6ZEAcvjum3+ovx1nOLaZ5aM4uZVzM nuWekfVcKstpOsKJiMjhdexkxan+VqEDlp8GwwhNk5CBcREj+TRH4uQtQzrv3SHER3ub+X a4IZ61aCphsZs9Qc0/UVlSi0rj+Ych0INdSgGlA0zRb8g6sy1bGguN206y2J1rIO6tWsuH 9d3gxGMylISchUL+YA6vlEHpyJKYna2rU5iq3k7enwW9niqufYPlE+6mAkr2+jH8SUpW18 J0XOer8sLWlGKBaVQklsXEKT57b2k2AYIJb5120BMykwAiulP6TF50Ky/jVmmg== 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=1721047112; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=qEQ0Xqc6XXy+RLgw3NMXAL4pwXjoYZqIYuVlesdmcuY=; b=kZ/jDDDo8zMmBAEEqV7nfPN4aEED5DfrIIY8MQIIAaYKb5BeOU37r4vwSqATd1SBm3B2kG 0GZexzl21QS0o/yjuqsIzKe3xcbfN0NMXe8xP365KkaIqwTxM1a0HjlySnYSH81WO6QevA dVpLTSrbPlIQ5z6PfrydYDugQSBHbP7F45kO5SRt/b/1CmEmdzbQDSWE8xFPPHl4/hVPf/ XTzNQVMgRIwxipXpsRkprcKcVQuArqKrghNaikunkrvy0Dkg7gFqhiurLWmccR+90uxsr6 N/x5kQMSI/FW7d0ortKgp1KriXOgoHpAVfLn4Thb++dEF/rnJpaW5CTzAOnVyg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vr0fcGzspG; Mon, 15 Jul 2024 12:38:32 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcV4k061824; Mon, 15 Jul 2024 12:38:31 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcVuZ061821; Mon, 15 Jul 2024 12:38:31 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:31 GMT Message-Id: <202407151238.46FCcVuZ061821@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 41c730459831 - stable/13 - arm64: Disable outling atomics List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 41c730459831e31e0233097bab8ae68580a68f3e Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=41c730459831e31e0233097bab8ae68580a68f3e commit 41c730459831e31e0233097bab8ae68580a68f3e Author: Andrew Turner AuthorDate: 2024-06-04 12:45:00 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:54 +0000 arm64: Disable outling atomics We don't have the symbols for this. The virtio randon number driver uses a C11 atomic operation. With inline atomics this is translated to an Armv8.0 atomic operation, with outling atomics this becomes a function call to a handler. As we don't have the needed function the kernel fails to link. Fix by disabling outline atomics for now. Reviewed by: brooks, imp Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45301 (cherry picked from commit 361da40536d7f6fc6c06d54b261c299d170ccf2f) --- sys/conf/kern.mk | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sys/conf/kern.mk b/sys/conf/kern.mk index b4ae8b17e90e..7a2cc4bfa7ff 100644 --- a/sys/conf/kern.mk +++ b/sys/conf/kern.mk @@ -152,6 +152,8 @@ INLINE_LIMIT?= 8000 CFLAGS += -mgeneral-regs-only # Reserve x18 for pcpu data CFLAGS += -ffixed-x18 +# TODO: support outline atomics +CFLAGS += -mno-outline-atomics INLINE_LIMIT?= 8000 .endif From nobody Mon Jul 15 12:38:30 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vq4TDvz5QrrG; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vq0SVWz4Hvl; Mon, 15 Jul 2024 12:38:31 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047111; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=JJTPav2e9/WJP9GjKgGfpXUXliyUU78KAbjmvIiBhVc=; b=cY0VtvdhX3Uu19nyp08JrId6LYLfwKjh48g/AYlVxwZihb+0Vnp3hpplwjXKE2lb+ZNI6f CA06A/hVM4PbjG+ODvrfckb2NjQxmyb2q//ROEfM4F/hl86/jhy8vtYEC2OpxcGEdXWeuE PdmomrtMlslBQRhjrw7AgvOAzSHojTXeUSmktKvR8AJzBNqtphhcFjSH6igz6JaoXACBRm Snbveae5jgglhBK/yW+qVzZ+HZLXmHxqL/WBkRHZYNVsvPZxS7mmGaChf/k8yfjPuhp4mi 6yX0aSk7LRHKFKwVQCVEkbgfauyHh7BuBfNbH39CMtGyzf7fz1n+U23PWgUBIA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047111; a=rsa-sha256; cv=none; b=q7jecoJmpbW0c5IQXcZ7PHj4y5x2emGTgeQ/3yIxPSAUdKBRnoLEUtsPVWu2YfE8MmDkfv MUbNymBvf/BjSYCYTVzcVKJ1XnNZEqIWayGQauPzpzJXQc+HP6YWERelF3wn9jdFY/xOhf BULg3+dQccvrBy7nX2Xt428HYW49sJbk76DNUlkSDHRauMpji4w975fMdMlVUWM+gHrRgR rTxHPasdB4TLH18WTVsTLjnMg3mAM9B+PJU4KuTNhqXKBe3i+1nrEOIq1RWEOsyqpzXqET 16TE4T8q+hwx2JKDKnBTthJAQ76Inc2t2GDHyITBdZmIy1aH5n/svacxtP70Ug== 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=1721047111; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=JJTPav2e9/WJP9GjKgGfpXUXliyUU78KAbjmvIiBhVc=; b=kWkJNa09a9nid4w0K1i4Xg+CyocmwnbkQVwXGBiCf6mZUtPw9m7p870vxyu3vl3bli8nw6 i4JvHyWUfJoq7Rc55eBr3xQdy9Otv8vTnR29mMMniUqkzxaoAJJjTv67ysZIoPkO8BmJsa XMtwvaPisxHqQWI93y/bChYctSQ05bebjhD7jQKqn849+9sLqzHWHMv9swVeyjmgyZMJFp zn779QpMHUKy0a+Uv6ChCSG3mmu5LqO6nPDTr8QatPd3Mg0bVXVLlspzkh+qX516ywqkys P9jyTVBeN3JViegGEOI2Beblq5qHAdSizZUm6snV92UuKm9lFzS9ddIkQCyVKw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vq02Ckzscn; Mon, 15 Jul 2024 12:38:31 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcU2s061740; Mon, 15 Jul 2024 12:38:30 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcUbV061737; Mon, 15 Jul 2024 12:38:30 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:30 GMT Message-Id: <202407151238.46FCcUbV061737@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: fa84eb9cfb7e - stable/13 - sys: Build arm64 per-thread SSP with GCC List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: fa84eb9cfb7e3745d09e6745bfe15f54f2f36b0b Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=fa84eb9cfb7e3745d09e6745bfe15f54f2f36b0b commit fa84eb9cfb7e3745d09e6745bfe15f54f2f36b0b Author: Andrew Turner AuthorDate: 2024-05-22 08:20:01 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:34:29 +0000 sys: Build arm64 per-thread SSP with GCC It has been supported since GCC 9. It is unlikely anything older than that will build the kernel so mark it as supported by GCC. Reviewed by: brooks, jhb Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45267 (cherry picked from commit c2628accc029a07eb8ff73b6df7f7d6af194ca2d) --- sys/conf/Makefile.arm64 | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sys/conf/Makefile.arm64 b/sys/conf/Makefile.arm64 index 3a2f2ba6362d..9ec7d7983480 100644 --- a/sys/conf/Makefile.arm64 +++ b/sys/conf/Makefile.arm64 @@ -31,7 +31,8 @@ CFLAGS += -DLINUX_DTS_VERSION=\"${LINUX_DTS_VERSION}\" PERTHREAD_SSP_ENABLED!= grep PERTHREAD_SSP opt_global.h || true ; echo .if !empty(PERTHREAD_SSP_ENABLED) -. if ${COMPILER_TYPE} == "clang" && ${COMPILER_VERSION} >= 130000 +. if (${COMPILER_TYPE} == "clang" && ${COMPILER_VERSION} >= 130000) || \ + ${COMPILER_TYPE} == "gcc" ARM64_SSP_CFLAGS = -mstack-protector-guard=sysreg ARM64_SSP_CFLAGS += -mstack-protector-guard-reg=sp_el0 ARM64_SSP_CFLAGS += -mstack-protector-guard-offset=0 From nobody Mon Jul 15 12:38:31 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vr1xdzz5Qrvl; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vq65nrz4Hsk; Mon, 15 Jul 2024 12:38:31 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047111; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=LBtQSKHtUXBrCWETnzCPyR/VEyaF+ERaV90XHdX8MG8=; b=yet9MTIsm86lgFAVg57UFw4/TtX2cqO8MYS5XdL3VxQzPgxB8KWJN88vPZK/4jyfWi0pTX /PDRH3nQ4bdP2alEgkG7MbkZ/6idToRl29E2dSfo+Xh/sUOTjXihGWkMj/C7ebPkfm4DQR cLKH4QTZGtHqP17weSEALutBXz50fbsjiR4Wb4qBc6H613U/zPkPG0vPtmR9RFvW+6AsQ4 mDg6jkf/ylaRy/iGTlEgRqmoR0/7dK4Vz8sQ9vsjaUaSlz0oO6DIuIZEQRexhujD0byzMC dn9kNB5FleTe/82jxJKsBoHRDqUrPpCbvnJiHkwvNknTEYCuf9eY/BxZkco+Zw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047111; a=rsa-sha256; cv=none; b=AWSIzG2mgqycAJpAG8YI0I7PeifNO6hu0Fq5Qv+MTrkvPisdcfSzSqFK2IJerNlZGbMO9I Hu8SHmrSmbS66EukSLQztGHGr5wzycpag3L/OAZbEDO2vErYXRtiZEsbzYrf2cwkFPGmsi ZAMJa3Q29pykiGNjd4UJtR3Fp/OFRE7Vspe5a2dZceHLCBXWbNZtkUlPgTtFWzkn2Pq3Lk sNwT80rkI6y8zWefe6QIjMjRoeFoNkN/nxeAPG34LmEs+9nrHxETjJtzsVVJBFR/KO2W3F Qw7u/f0zOzYrjRQ2jrZ/9nRXri2G3dr8/5jJbBKN9ajjIzvqw7bMNVPlXz/f0Q== 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=1721047111; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=LBtQSKHtUXBrCWETnzCPyR/VEyaF+ERaV90XHdX8MG8=; b=xVxAa4f0m1AlMPeBcUaIurEoJobKiDcs+F5FBO6/gLaO4z26QikKqgwkcUKTLcRwO5kSvh N3XFPak2RRwq1SZgiN6ZDlOXCwskVDi98RPIPHft9shuU0r7o0f6QPHIUiUeMrwmS+oywv 2J2UVFToxEtF7HDqk8xH2IcfTsGd5u+eZWz7cIYwZexaAVhSWn2pDk5RPNnalB5mj1lNz2 4X9mRL/Cwl/tQilGmv+a/2FVkt3JHx50R8xu1tN9VdJwxfXCJNBUWI7UkjbV03rFr+nFAW vpmIbWi2m4FvUrqFURFE5T0ylZNyREdoVylOZ+QmwejQW4nm0h43PsNMahInuw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vq5k1czt3L; Mon, 15 Jul 2024 12:38:31 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcV6v061785; Mon, 15 Jul 2024 12:38:31 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcVFq061782; Mon, 15 Jul 2024 12:38:31 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:31 GMT Message-Id: <202407151238.46FCcVFq061782@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 258672fe62af - stable/14 - arm64: Fix indentation to be consistent List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 258672fe62af8e59cb1e8fdb07f539561cc1a262 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=258672fe62af8e59cb1e8fdb07f539561cc1a262 commit 258672fe62af8e59cb1e8fdb07f539561cc1a262 Author: Andrew Turner AuthorDate: 2024-06-10 14:58:22 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:28:37 +0000 arm64: Fix indentation to be consistent Adjust the mair_el1 macro indentation to be consistent with the surrounding macros. Reviewed by: emaste Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45524 (cherry picked from commit 86bafddd61aba115bc46bcf1d7e0afb125850b5f) --- sys/arm64/include/armreg.h | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index fee36bc9dd4e..b96d2223eb0b 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -1496,13 +1496,13 @@ #define ID_ISAR5_VCMA_IMPL (UL(0x1) << ID_ISAR5_VCMA_SHIFT) /* MAIR_EL1 - Memory Attribute Indirection Register */ -#define MAIR_ATTR_MASK(idx) (UL(0xff) << ((n)* 8)) -#define MAIR_ATTR(attr, idx) ((attr) << ((idx) * 8)) -#define MAIR_DEVICE_nGnRnE UL(0x00) -#define MAIR_DEVICE_nGnRE UL(0x04) -#define MAIR_NORMAL_NC UL(0x44) -#define MAIR_NORMAL_WT UL(0xbb) -#define MAIR_NORMAL_WB UL(0xff) +#define MAIR_ATTR_MASK(idx) (UL(0xff) << ((n)* 8)) +#define MAIR_ATTR(attr, idx) ((attr) << ((idx) * 8)) +#define MAIR_DEVICE_nGnRnE UL(0x00) +#define MAIR_DEVICE_nGnRE UL(0x04) +#define MAIR_NORMAL_NC UL(0x44) +#define MAIR_NORMAL_WT UL(0xbb) +#define MAIR_NORMAL_WB UL(0xff) /* MDCCINT_EL1 */ #define MDCCINT_EL1 MRS_REG(MDCCINT_EL1) From nobody Mon Jul 15 12:38:32 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vs46vZz5Qrhf; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vr6X7Xz4J1h; Mon, 15 Jul 2024 12:38:32 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047112; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=5bplBUzSyPOsFzM0n5BPU3rvII1U5X9JvN975aJGUwc=; b=W2BIM8nUjmUKTq38aD2nHUP4dWzpqUupyC/dyAQiLOHgjfyufbmmrhPnN3eIlgakrcX5iN ofiwbivCueOdGFmfCRei35mt6q1VlRh2JYCi/ZmN8ks+2Jj1cxUTVWYkt8jTD/wqYXLLKe BC3JFsSGwAQT/j2dBrUEG9NyRxpGiHgx6+59Co9GQucwZmcf+NkDWJ95FVObzSbydpWNiE GhriV4H/qMhL7ufhAqGNctgH2RNuxVBJBKf/CbxdKLk788tF8/3tkgwVCV4wVbZqgQWzyw SNhBlExXJKJ0Q7m1qqZevvNj0HWsPXbvMhSmysMgiZbivC+jiD0jmCBg5I7tzA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047112; a=rsa-sha256; cv=none; b=u61RvXDp/ucEHaXiq6FE7ptMGX+lLhMlYFW5rhWdlBEh423rYBc1W3NB+bQ/Qb+bKYoFhA WoV7TkcZW+IK5IZWQECVXo5KN7HNpDwpJUidETwHzIRmb10ZNCt3KhaWFBM2Z7s6IgZG0n np4updWSgFsFF6cc1tqw1knQoESMimtkRK0qbXKYhZspVEs35qkDHAWdObTMiwHU0gTqp4 hb6a51EafsCw5xqvoAbPqtXjIWt2SfQH//fKcNP9BIQIb4XJVV/fMuxnCku1gUl9dH+8Pb fYcyPzg0p3fGRV+Acw6W7WDi0X4XA/2puQc6fLDEEojnKLT4ZpMzJIDnpO3d5A== 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=1721047112; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=5bplBUzSyPOsFzM0n5BPU3rvII1U5X9JvN975aJGUwc=; b=xkgt+yhDJH7m6P80Xz2FH6e+wUpRJ49JdAwEZY1+tGi5j7YqsIfQdUkMjnZC4Pz/lvdZWC pLp1tGy1xkhd+ZaD9QPDaQPNy2/i9JXJXCHjEysiaeFqAqgyl5SKCZLRPvWQFYBMJj7M8l 6rnMNZ4FNz7QK9MQIeOJ43Q2BzfoatClLyLF/tPJmTGrLK3tMmkVYdmhLD8LFvr/jhQkK5 nClXhJD+RWL7vzC7LwjNnL7jgSwbVCbBy0VUesgVE3niyBlwiMJb7sNen75qbCJwLBGIXo as/28LRUkj7lW/+4WMNNJ0S7NS1WPwTWpvGF6g2pPOPPhdAGsfo8LxVtKRRCrA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vr68YHzspH; Mon, 15 Jul 2024 12:38:32 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcWUX061875; Mon, 15 Jul 2024 12:38:32 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcWAw061872; Mon, 15 Jul 2024 12:38:32 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:32 GMT Message-Id: <202407151238.46FCcWAw061872@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 833ccd66dac6 - stable/14 - cdefs: Add __writeonly to mark write only vars List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 833ccd66dac6d9888d542fa0cc52cfa482e314ba Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=833ccd66dac6d9888d542fa0cc52cfa482e314ba commit 833ccd66dac6d9888d542fa0cc52cfa482e314ba Author: Andrew Turner AuthorDate: 2024-06-12 13:04:13 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:28:45 +0000 cdefs: Add __writeonly to mark write only vars When a variable in write only and can't be removed, e.g. for API reasons, it is useful to document this fact similar to __diagused and __witness_used. Add __writeonly to tell the compiler and anyone looking at the code that this variable is expected to only be written to, and to not raise and error. Reviewed by: imp, kib Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45561 (cherry picked from commit a7ae78caaa17ff840da844c1dcaa780d194c9e20) --- sys/sys/cdefs.h | 1 + 1 file changed, 1 insertion(+) diff --git a/sys/sys/cdefs.h b/sys/sys/cdefs.h index 84411e8e4b16..19b7d8fe427d 100644 --- a/sys/sys/cdefs.h +++ b/sys/sys/cdefs.h @@ -218,6 +218,7 @@ #define __aligned(x) __attribute__((__aligned__(x))) #define __section(x) __attribute__((__section__(x))) #endif +#define __writeonly __unused #if __GNUC_PREREQ__(4, 3) || __has_attribute(__alloc_size__) #define __alloc_size(x) __attribute__((__alloc_size__(x))) #define __alloc_size2(n, x) __attribute__((__alloc_size__(n, x))) From nobody Mon Jul 15 12:38:33 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vt2PMCz5Qrf7; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vt0j3Fz4J8x; Mon, 15 Jul 2024 12:38:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047114; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=O//O6kGNo3mvuIu+L4a210tvfPvVvkEumtTVoi57Qg4=; b=Goa1i5WKde7bkMyd/BIVRvFaAAoDoOCAe9ndyCwydl/ZP0gwKp6POfpnEyN+PhVHYxggYn 0pFlgjPdml+BZvkH4Iwe5LILu0jUPJT39i7vF5YdFjX32zoM+g1U6m8HR9guF8W4JGBBHC cji3LQuuL5tgYcIFwHnH5F3ZsZTZZfDnvziBIbxOZbIEeKE7kzPblaeTL6Q7DQPOcXFiYh LYOxCuwN7yeRevA3ZyaY2a7hdl0WXtKN5F/bijNFIyLG03rjTlQB7hsjU2QhRBY7kqSEKD sMiULxBHyQ8hm0UQA/61u5tSYQSUEi0qk3e4Jqxxdp4R/HYOd9rg83qp9wxDRA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047114; a=rsa-sha256; cv=none; b=NIrO/zoe1eDcWha9q74Ss8MLQb2cdI1QGrE/XnIR3nl+ACHAkJDrs46cQ6bT5/85K0qNJ0 xPOsIPYDi3Ai3zIg5P9Cr58dmA28cHqtxXbikDsUf7lsyzaJf/L0WbGcIitPJiEIkBAwr6 cHipaG//tt+XDvRH60z/wqwV+ETcDrnY8vQfxd2AqbcANtziSN2YoDl3RV7DkEwCbrHetW 43vk3X7Go0pfUo7dobRCl3o8W4k0fPdTN3V2pOOmf9gRZbc25FF4qJJFIzqxKw/ZqqFJvG E/Kha9ADvkgBXhZ/kiWIvxI33iA+nOhoQ3mkttqcLMF9DSnJH7wqtGX46uGntQ== 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=1721047114; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=O//O6kGNo3mvuIu+L4a210tvfPvVvkEumtTVoi57Qg4=; b=skjxLNWBDzSEbuyrpoujRd8NPgifEuzFioaN7qFJ1TUGOsK+lTQh5qVEmRRrXDuOLNkmTW 3i65MZYW6/Su96iwAAj6OQHKwl0QSEXjxtGKGUBqHj5JcqEslm+lB2FP6WUPeNnYEEiINg 7uP5CGPxCJm4BlBT7xm4WNzQKiCs9tKR89nqXHcOLRthqlY78WCm4T9QyBXKoEcVAF7a32 s9Z18aOT9DhD4DgMun/ZLLlp106+e1YGwJpXNAxdIm1uPUdI4aSAZFVAdN7ekesrg8u+2A Wf0zHj3xs0XEMYP+ULjwv4jCL0pwal+v2YYzDb8WO2C6D4mBWsfog/y0P8R38w== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vt0KLpzsJR; Mon, 15 Jul 2024 12:38:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcX5j061959; Mon, 15 Jul 2024 12:38:33 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcXmr061956; Mon, 15 Jul 2024 12:38:33 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:33 GMT Message-Id: <202407151238.46FCcXmr061956@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 77d05874de8e - stable/14 - ibcore: Mark write-only variables List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 77d05874de8eaa05725b414b7217becdb85ed037 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=77d05874de8eaa05725b414b7217becdb85ed037 commit 77d05874de8eaa05725b414b7217becdb85ed037 Author: Andrew Turner AuthorDate: 2024-06-12 13:04:45 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:28:53 +0000 ibcore: Mark write-only variables Some LinuxKPI lock macros pass need a flags field passed in. This is written to but never read from so gcc complains. Fix this by marking the flags variables as unused to quieten the compiler. Reviewed by: brooks (earlier version), kib Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45303 (cherry picked from commit 19782e5bef3403a6ed65d46653f2e70f81dced37) --- sys/ofed/drivers/infiniband/core/ib_cache.c | 16 ++++++++-------- sys/ofed/drivers/infiniband/core/ib_cm.c | 4 ++-- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/sys/ofed/drivers/infiniband/core/ib_cache.c b/sys/ofed/drivers/infiniband/core/ib_cache.c index b170f2b637f9..d2cc680796ef 100644 --- a/sys/ofed/drivers/infiniband/core/ib_cache.c +++ b/sys/ofed/drivers/infiniband/core/ib_cache.c @@ -465,7 +465,7 @@ static int _ib_cache_gid_table_find(struct ib_device *ib_dev, struct ib_gid_table *table; u8 p; int local_index; - unsigned long flags; + unsigned long flags __writeonly; for (p = 0; p < ib_dev->phys_port_cnt; p++) { table = ports_table[p]; @@ -514,7 +514,7 @@ int ib_find_cached_gid_by_port(struct ib_device *ib_dev, unsigned long mask = GID_ATTR_FIND_MASK_GID | GID_ATTR_FIND_MASK_GID_TYPE; struct ib_gid_attr val = {.ndev = ndev, .gid_type = gid_type}; - unsigned long flags; + unsigned long flags __writeonly; if (!rdma_is_port_valid(ib_dev, port)) return -ENOENT; @@ -570,7 +570,7 @@ static int ib_cache_gid_find_by_filter(struct ib_device *ib_dev, struct ib_gid_table **ports_table = ib_dev->cache.gid_cache; struct ib_gid_table *table; unsigned int i; - unsigned long flags; + unsigned long flags __writeonly; bool found = false; if (!ports_table) @@ -879,7 +879,7 @@ int ib_get_cached_gid(struct ib_device *device, struct ib_gid_attr *gid_attr) { int res; - unsigned long flags; + unsigned long flags __writeonly; struct ib_gid_table **ports_table = device->cache.gid_cache; struct ib_gid_table *table = ports_table[port_num - rdma_start_port(device)]; @@ -929,7 +929,7 @@ int ib_get_cached_pkey(struct ib_device *device, u16 *pkey) { struct ib_pkey_cache *cache; - unsigned long flags; + unsigned long flags __writeonly; int ret = 0; if (!rdma_is_port_valid(device, port_num)) @@ -956,7 +956,7 @@ int ib_find_cached_pkey(struct ib_device *device, u16 *index) { struct ib_pkey_cache *cache; - unsigned long flags; + unsigned long flags __writeonly; int i; int ret = -ENOENT; int partial_ix = -1; @@ -997,7 +997,7 @@ int ib_find_exact_cached_pkey(struct ib_device *device, u16 *index) { struct ib_pkey_cache *cache; - unsigned long flags; + unsigned long flags __writeonly; int i; int ret = -ENOENT; @@ -1027,7 +1027,7 @@ int ib_get_cached_lmc(struct ib_device *device, u8 port_num, u8 *lmc) { - unsigned long flags; + unsigned long flags __writeonly; int ret = 0; if (!rdma_is_port_valid(device, port_num)) diff --git a/sys/ofed/drivers/infiniband/core/ib_cm.c b/sys/ofed/drivers/infiniband/core/ib_cm.c index 3ee17a847720..7ace287b1c88 100644 --- a/sys/ofed/drivers/infiniband/core/ib_cm.c +++ b/sys/ofed/drivers/infiniband/core/ib_cm.c @@ -4057,7 +4057,7 @@ static void cm_add_one(struct ib_device *ib_device) struct ib_port_modify port_modify = { .set_port_cap_mask = IB_PORT_CM_SUP }; - unsigned long flags; + unsigned long flags __writeonly; int ret; int count = 0; u8 i; @@ -4150,7 +4150,7 @@ static void cm_remove_one(struct ib_device *ib_device, void *client_data) struct ib_port_modify port_modify = { .clr_port_cap_mask = IB_PORT_CM_SUP }; - unsigned long flags; + unsigned long flags __writeonly; int i; if (!cm_dev) From nobody Mon Jul 15 12:38:35 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vv3W3Qz5QrkW; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vv1gt4z4J28; Mon, 15 Jul 2024 12:38:35 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047115; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=PDr6I3KQFQ6rOwXL5dGJ8TsMToier8XVzhj7764N1YY=; b=PgVCU1tT0QkIToXB2suZx/ryIMxYt69aPPuW3MDgM9ItQmBAcfwXTZbO6aX894eVyLCEu4 wxJbxBtAVG725W8dGOxP2jVmzW0dvdLFDDSjQ0WrDvhNAe6r5f1EJRAsIm/ld6nf0h6bqq xyLx/Kt1bGGTYBRTBVHvBkBgfqD+mytQvY3+HRmNtLQ2ya52sMPbMFXhrebDI2eSzrlAaR x98HEhqdEE6SEH0YJ/UjoQUSRsmdbHIYPeXGS9bEMeMXpi37cq+h8CbaUXQC0j+fxOS+jE AxlBUKlwm/ev2YZaNxpYWhGcI4AWyWFZI7kiTBQ6W7N6Ai+FRELkEKdWwDqP3Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047115; a=rsa-sha256; cv=none; b=okdSp2NmKuKftusGvulzoMEAieS+w1ITU6F2Oaf2Ehe5ph3itQ3c5fKalMRw7hhTTbVc3K fMahIXQPRFnHnGmiu21NWbts5iSIZRRfR8B8tJC4DM20FTob2r+n6KMqhjXZapwEsjv/Ld BrnLKmfWNczAKjsKl46KoHT7taN+KN/61RQNd+oK7Zhl5HbGzlbsgOAwIezzR9MPbJndaw Iu7iwMuUwSn4khrVhDbuuJHzo57zTwGLLDRsi4pFbQc1yaffA5BJB5/zPWNVTTZMMXDp2U TzinBIcrYnglrp1QXcUUbePXEFJc0hfmgBug5xKodO6cY3y7bVLL8fhdmE6QnQ== 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=1721047115; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=PDr6I3KQFQ6rOwXL5dGJ8TsMToier8XVzhj7764N1YY=; b=i1CzOm2niKcMfxPHialhEr75q75PGCbveM78Rfr4zS6+J+DbAg1ufxfjyxZ5C2myrqxhRi JAtJR3hZ2uD8YMwBWOOv3sBiFG4hqUd2jLFYE+DN2/8XQnOjJPpBHs/y+ZphK62He1v/cb i+y/E8rpsEYiD8lM19EIryfscDITupVwJZ9B9RC9wehAicfTOpxM007WorNKrO8iz5isak DLUoTXAKw99uhIlvq5eVLyNNcPINnpeW/qL1Iatzq79Wr+dCUTmxWHM5QWR+YbKutZE0b/ QwQi/u+B7p0Mkl+/cjvq6g9tapByREHy05dTVzMni3peiW8QUkKoHwpwrTCVwg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vv1F8LzsZH; Mon, 15 Jul 2024 12:38:35 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcZft062057; Mon, 15 Jul 2024 12:38:35 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcZMe062054; Mon, 15 Jul 2024 12:38:35 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:35 GMT Message-Id: <202407151238.46FCcZMe062054@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 19349d339406 - stable/14 - binmiscctl.8: Change the example to armv7 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 19349d3394062a8d92c3544c05947c74d7a0e2b9 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=19349d3394062a8d92c3544c05947c74d7a0e2b9 commit 19349d3394062a8d92c3544c05947c74d7a0e2b9 Author: Andrew Turner AuthorDate: 2024-06-20 09:26:18 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:29:01 +0000 binmiscctl.8: Change the example to armv7 armv6 is in the process of being removed. Reviewed by: manu, imp, emaste Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45641 (cherry picked from commit 68f044de29b3867c2e0d282b86395f777f95b034) --- usr.sbin/binmiscctl/binmiscctl.8 | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/usr.sbin/binmiscctl/binmiscctl.8 b/usr.sbin/binmiscctl/binmiscctl.8 index 178389920448..4a4890146b57 100644 --- a/usr.sbin/binmiscctl/binmiscctl.8 +++ b/usr.sbin/binmiscctl/binmiscctl.8 @@ -288,15 +288,15 @@ Add QEMU bsd-user program as an image activator for 64-bit RISC-V binaries: \exff\exff\exff\exff\exff\exff\exfe\exff\exff\exff" \e --size 20 --set-enabled .Ed -.Ss "Create and use an ARMv6 chroot on an AMD64 host" +.Ss "Create and use an ARMv7 chroot on an AMD64 host" Use an existing source tree to build a chroot host with architecture overrides: .Bd -literal -offset ident D=/path/to/chroot cd /usr/src mkdir -p $D -make world TARGET=arm TARGET_ARCH=armv6 DESTDIR=$D -make distribution TARGET=arm TARGET_ARCH=armv6 DESTDIR=$D +make world TARGET=arm TARGET_ARCH=armv7 DESTDIR=$D +make distribution TARGET=arm TARGET_ARCH=armv7 DESTDIR=$D .Ed .Pp With From nobody Mon Jul 15 12:38:34 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vv0btdz5QrrX; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vt3FPNz4Hrf; Mon, 15 Jul 2024 12:38:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047114; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=1Lz3Tyav7MrguEZ1lIVWixbjrcDTu1i+O94OdJMI8vI=; b=q8C/TnrTylYnV/CMou/1wuWG5fsR3k7dxeBdVIZkWSvl/maBfdvKW85Yk0IdOleXEaqY5Z sNZ3r9CAQo+xCl5FdZgJC7pxttOqF5AbhULL0t11WLaeWU3XIIxSzHhjvUE8+eLXlcod/O JWD1Fvdc46tfKljs94Uu/sFThHZ/jlBjFtOmN4Ewzc4nhTXl0FYDIOU1PEXBJnPKVasYJ2 bA9joInpDbs4GxzvHXCm9Wp171hlUPYrMQ+wYhHnwSuX5iO9jm6GEgphAM/rrcERSOP5ZC XDzcmA/vskAuRXO29HAp7CJfDIkxHJr0LzyHx7D+P199mpqKxcnlPFEWzHLF6g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047114; a=rsa-sha256; cv=none; b=YYDsdCpDaJq49ckfiS9K/OthVEGci6GwNJaGnQ0SrnYScAJjIAStmev28sufLwc7e0gu6c /NOEZGg1yKsO/aFjg1QLjqGQPDAjZIAsXpoJG/aNkXll0uIPR8DmUM9Wvdgwg8QvnHsgcG KfocDpU0B+DKtpQr0MiadPeUe7ddtpAbqTb6jOUwNVGY/SOeQIlrbeIcMHvv7fpwdNwHhj Rr8mpTkuqWe3AnK3EhgjEBGeDJXO04A31mf3EiumDxrEpq8zFU0rZDIEFHWDi9UOXGHn8z ADHFq7IfUcKDSkL1mhwz0wnzouocsF7alIIv1FDNIeO7AQHezNKsL3xk4NVCxg== 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=1721047114; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=1Lz3Tyav7MrguEZ1lIVWixbjrcDTu1i+O94OdJMI8vI=; b=WMg9jq4JjEAwg3JEeSNfsmyjXvmSkv7AEv9hWImsYzctTlSz6w4nEaxHPLWcA29HzXBKZn s5vjcdJslPujmJRQSySxqvovB7eJ0QZ5L7oHn0JRqG7FqV6d1bXL9v9f3HGNjs73mZuzDr bTvI9yFWrOwcya4IFbnHANSILb2u1X9P4Ld0N05y82Wf/wc4jXrFvYCH7HiIORTGBVGvGQ jYwNw0uKjBntYqQ6/uMdstDQR7NbwOlNPOnQ8f1lW76me4zVzHTl3qup+PZyvROqV9iC3q IkndXxpIxdp56+2yRTvtq7jDIJiKGNgBcLd3UhANQ+vYtSy7XR1pPy/ZTZBCjw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vt2pb8zsrs; Mon, 15 Jul 2024 12:38:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcYOq062004; Mon, 15 Jul 2024 12:38:34 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcYIF062001; Mon, 15 Jul 2024 12:38:34 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:34 GMT Message-Id: <202407151238.46FCcYIF062001@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: c73d1e81b68e - stable/13 - arm64: Fix indentation to be consistent List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: c73d1e81b68e04bd3b5967e616439992c644e842 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=c73d1e81b68e04bd3b5967e616439992c644e842 commit c73d1e81b68e04bd3b5967e616439992c644e842 Author: Andrew Turner AuthorDate: 2024-06-10 14:58:22 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:35:21 +0000 arm64: Fix indentation to be consistent Adjust the mair_el1 macro indentation to be consistent with the surrounding macros. Reviewed by: emaste Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45524 (cherry picked from commit 86bafddd61aba115bc46bcf1d7e0afb125850b5f) --- sys/arm64/include/armreg.h | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/sys/arm64/include/armreg.h b/sys/arm64/include/armreg.h index 053f7a6d0afc..1a194075990d 100644 --- a/sys/arm64/include/armreg.h +++ b/sys/arm64/include/armreg.h @@ -1499,13 +1499,13 @@ #define ID_ISAR5_VCMA_IMPL (UL(0x1) << ID_ISAR5_VCMA_SHIFT) /* MAIR_EL1 - Memory Attribute Indirection Register */ -#define MAIR_ATTR_MASK(idx) (UL(0xff) << ((n)* 8)) -#define MAIR_ATTR(attr, idx) ((attr) << ((idx) * 8)) -#define MAIR_DEVICE_nGnRnE UL(0x00) -#define MAIR_DEVICE_nGnRE UL(0x04) -#define MAIR_NORMAL_NC UL(0x44) -#define MAIR_NORMAL_WT UL(0xbb) -#define MAIR_NORMAL_WB UL(0xff) +#define MAIR_ATTR_MASK(idx) (UL(0xff) << ((n)* 8)) +#define MAIR_ATTR(attr, idx) ((attr) << ((idx) * 8)) +#define MAIR_DEVICE_nGnRnE UL(0x00) +#define MAIR_DEVICE_nGnRE UL(0x04) +#define MAIR_NORMAL_NC UL(0x44) +#define MAIR_NORMAL_WT UL(0xbb) +#define MAIR_NORMAL_WB UL(0xff) /* MDCCINT_EL1 */ #define MDCCINT_EL1 MRS_REG(MDCCINT_EL1) From nobody Mon Jul 15 12:38:35 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vv6Qccz5QrrY; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vv46kfz4J2K; Mon, 15 Jul 2024 12:38:35 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047115; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=gV1CsYI7/oGsL0y8v/QYDvkjLc44xZNHwV7XETC6DRw=; b=Etz/YgaeR3w4j3lqbMfnGlxME1Zvf4o5XcNytLXbUla5udCT9ZEl2F6lFaFQ7PUqtz/Fhp NMXxYg3b237Xs2MUZdKiBmT3hoSbDXEo69W5oQg3gj5hKgtDvDzgo94Spr4Ii9ekCuU0Mz 6t0r96zrab7G6tRxZO3ADTjWYRi2EwwUjb+dC7/A53GXTi+pxayCJdz7i0xIsiWJFRXWdr wWdQmj/PI4hjNGm2imTkwi05C56He+IfpL317a/aL5M3Wbf+CoBk70EIc2LIFnY0tCHPtP nXU3x1cSuCH/hr1pqHimNawR15hOg5IUzGFzwcDHtCEYHSoynis29+efA7zfVQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047115; a=rsa-sha256; cv=none; b=jhuLcDF3gHnOqEN49eWFvw3gEBOjs34hnp+5YUp/ZisAiu6yhmyPdH/+FRDvJv2jRlXbXd WnPOP0DglcsyiV7RSPenLIxymXgCpozTeMIe/9h5SOuu0X9Tn1Eb8qU+MUY0cMM12S5nKQ mum+nob4m1kTjvKUu9orU1zxDBY5iHERM8sA4jwQQhfZGCI1txzStdTGrWwYFkTpSqr87a lIKFEH2vikICmiF8GxV06Ld+Y1MBvAQ2/Osv7b18tyxmiiuLbaaWYK4+ydA0ZmzjIQzbkf GEkC4frf0fXc7DghoqB3goK8a54io3dkopp6URLObAJuH/ynRnCyNo+fOr8NHg== 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=1721047115; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=gV1CsYI7/oGsL0y8v/QYDvkjLc44xZNHwV7XETC6DRw=; b=QnvjSJ/FvrtwGq67tXJuG/QsR5KsjiLEaDRnN3l49QRM4tEH10sJQG+KhnogUe+Alv50WZ JeEjCiPsS1r3IFem52XxGUF7SUN+DGHBUfarYE/aFX4r2SWam4jLdrwi7bzqAdDRYHVMdL Y3yOmJqatlBCDJ2Bv9wZ0CE7tRpt4hnvMrbwDmxuNWDkf4mkpl30vP54XqPbHT3QByjhZY SNWV38xpbT4PK1wsGzpm3RUpKtN07V4XTWKqZ2Bi7iR1gPGmgLkAiF4vP33Pdo14Bp01/m wmPH1vAr/wArxNGrlD5ij+Y6wxuTKARA4gqVpkowIr4MmZgxZSBBhODRUyOtIQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vv3j5xzspJ; Mon, 15 Jul 2024 12:38:35 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcZtP062108; Mon, 15 Jul 2024 12:38:35 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcZcB062105; Mon, 15 Jul 2024 12:38:35 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:35 GMT Message-Id: <202407151238.46FCcZcB062105@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 066069197864 - stable/13 - cdefs: Add __writeonly to mark write only vars List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 06606919786416d9854a16ad856ed89582856f16 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=06606919786416d9854a16ad856ed89582856f16 commit 06606919786416d9854a16ad856ed89582856f16 Author: Andrew Turner AuthorDate: 2024-06-12 13:04:13 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:35:21 +0000 cdefs: Add __writeonly to mark write only vars When a variable in write only and can't be removed, e.g. for API reasons, it is useful to document this fact similar to __diagused and __witness_used. Add __writeonly to tell the compiler and anyone looking at the code that this variable is expected to only be written to, and to not raise and error. Reviewed by: imp, kib Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45561 (cherry picked from commit a7ae78caaa17ff840da844c1dcaa780d194c9e20) --- sys/sys/cdefs.h | 1 + 1 file changed, 1 insertion(+) diff --git a/sys/sys/cdefs.h b/sys/sys/cdefs.h index df15a3c04193..d9e1c476f1ef 100644 --- a/sys/sys/cdefs.h +++ b/sys/sys/cdefs.h @@ -219,6 +219,7 @@ #define __aligned(x) __attribute__((__aligned__(x))) #define __section(x) __attribute__((__section__(x))) #endif +#define __writeonly __unused #if __GNUC_PREREQ__(4, 3) || __has_attribute(__alloc_size__) #define __alloc_size(x) __attribute__((__alloc_size__(x))) #define __alloc_size2(n, x) __attribute__((__alloc_size__(n, x))) From nobody Mon Jul 15 12:38:36 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vw60pGz5Qrrg; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vw2QXgz4J78; Mon, 15 Jul 2024 12:38:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047116; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=u8BCf2pLLAm/2Vp+6/7ZQNgP2+EmPJWXJfcwcVD9qnA=; b=dPlnOhByGqf/xTgBEmjJsxnd6SRlt7G4U3E+OOWAGvoGrv5+uTEsy5dKnVnS8QHDZQ+Jze bWixq01XIAk4NtKg966v2y62QV7qZfkw7oR546RNk5qpK2+2cfQ79bQWQBFPaJNYTpJF7t xmbJ81Qxy8K9185bHJ7tS+5vKbsjLjdSKBM/8VAGC7EclySI4BSfmauUDu6cohGpjyVehG QhnGNxRrRz3zLFnMi3I0m4H7vx5OynUTUfXxqctsc0hFWnyup1Fc6lStWd6jottjMXZ+Bk UqCQGnYkCnA8jSKPgZvROfkbShKKri9BuLSqdssxXIX/o0enX3ZtKxqxsl3kkg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047116; a=rsa-sha256; cv=none; b=cT7q3Ja417A2YHHElrFOwNiq162BLjmPm5hpy3Ljj+pxfk8WJ1tX1iIiUOyhsUutlBrkXi AWtj6sAf78YDnoY1IcaNNaW+wt8i5XIwiFJOqvp1x04+omxDqHU0ndJ6LaGMmyYN9eEenL r5llTES3xzvUQOP/ERrTCPfjS0GTocjxCk3RIOH3oOwxsfNo91PkYxkhtGFlyyvcFpYUXN p4VbfAYVsNu8Q1WqjpGDDBXuhareUCicea+gVhLhSxBtQUTiBm+ljuaQcsGYqUwtm7Ztyo awDLVO5fmPypArFIMeNs6nRmDytHUFcRrE6nFl7drqIgXhvQEu+SkTeEdyeFOQ== 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=1721047116; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=u8BCf2pLLAm/2Vp+6/7ZQNgP2+EmPJWXJfcwcVD9qnA=; b=FPFqMfugbisFUaINw7NMiYJpIrVKwYqx+JJgsayBUS71B+YBhvkQLjJdXH1JiyPA7Vosqe X8YDLwiYlVJ18TPfMLmjpHxGi/iCK70jyaJgTKYgo96fW3MAgAQNsgRrD3BZdF+mikvyRz 68ZmJUhTVB9uqIDaNnLQ1Og77rjANjZ7kKZteLxmuEjI+g2LwJbY8oulSBEs8YQZWUtRrw MczXk6/o6JvuxhIozf+pCo8tJWCRnRErtuvxy45GnJSqaAVUKg3SEqmbJsUuaW+pZA6frK dJ7AjMzPIIYmJ3A00nrWbpEAXXp8wG9ArGHUK0PAyENqrzT5bosP/EEcP2RAtA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vw22xnzsZJ; Mon, 15 Jul 2024 12:38:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcaF9062150; Mon, 15 Jul 2024 12:38:36 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcak6062147; Mon, 15 Jul 2024 12:38:36 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:36 GMT Message-Id: <202407151238.46FCcak6062147@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 5b1f4e679dea - stable/14 - arm64: Disable outling atomics List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 5b1f4e679dea004ad4a47b408b7b7d27575da90e Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=5b1f4e679dea004ad4a47b408b7b7d27575da90e commit 5b1f4e679dea004ad4a47b408b7b7d27575da90e Author: Andrew Turner AuthorDate: 2024-06-04 12:45:00 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:30:02 +0000 arm64: Disable outling atomics We don't have the symbols for this. The virtio randon number driver uses a C11 atomic operation. With inline atomics this is translated to an Armv8.0 atomic operation, with outling atomics this becomes a function call to a handler. As we don't have the needed function the kernel fails to link. Fix by disabling outline atomics for now. Reviewed by: brooks, imp Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45301 (cherry picked from commit 361da40536d7f6fc6c06d54b261c299d170ccf2f) --- sys/conf/kern.mk | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sys/conf/kern.mk b/sys/conf/kern.mk index 6cc22a44f51e..38d0664538ea 100644 --- a/sys/conf/kern.mk +++ b/sys/conf/kern.mk @@ -141,6 +141,8 @@ INLINE_LIMIT?= 8000 CFLAGS += -mgeneral-regs-only # Reserve x18 for pcpu data CFLAGS += -ffixed-x18 +# TODO: support outline atomics +CFLAGS += -mno-outline-atomics INLINE_LIMIT?= 8000 .endif From nobody Mon Jul 15 12:38:37 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vy2qMfz5Qrsr; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vx5dRLz4JD2; Mon, 15 Jul 2024 12:38:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047117; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=++sRPDfsQmAx6fTWTu4587Vu5JoFg4OpkehjsgSdceg=; b=xg6a8jgTk9kWzKTgEkcRbM7/ogW/1Nv4RL5fMG+Ntxwhe1iS2HX/dOwUgx7IJLyj9bZPIo jMGf2jUPu6Mky5annW+qDdCehj0ibxnjCYB9yETcaGVuWRO97FpBCHTrz6qL6dBNCvfy7j MSz1c1udOHbxtuvyBUusH7ZYa/fsIRUQAwPTd/IcGI2WUBRA1b8Pk82k7PZDUbaKhep8k9 SB+lvLEhga9Uo2+Tk7TRB7U7X8pXKTif7EIAz+blkNAs/I2zYfUtBVPeJMtIbTV3WsmwTb /pbZd9lq+Xqb8mVnCOJpHETsjUyawshgFU35JsWG5Vptsr0VQYEmpQEDmun/yw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047117; a=rsa-sha256; cv=none; b=fPGDRvpvBv3HpxgQPzyyKRxKOF4ZJPHHaVMJIiAraufrcaF/cSnw2QKKLPbj8Htq9hvMIc HdaGHpRhJXPNwlBUBLCcT+6yV3IiEBrJAI119RSwzK6yvl/PPGnbSGKFJEw6ZOfbZxt4At jEJu+QRHu2uABzspGTTwVBUn7R6QK8WvVRBjWFkuiBeBI6fvr4zgG3scyhmhc8h0njQWaH e8XuWkGMEaw388jQhiOY1chmClrh1xgnPOWjsAsxcfpGhF03QEbzjT3VaMoiZJy+6kfUNe sbJT9Pk7MCnJF0mfIk/HI7ZqEo0EiOwL7oGGW/aSSerH/iueNlOKiCsmQdDVhg== 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=1721047117; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=++sRPDfsQmAx6fTWTu4587Vu5JoFg4OpkehjsgSdceg=; b=lXaeyjfV4oahRfl/3iw8+2uwBDAOpNIohYk0pTwJM4tKW2BZw5O4/Rt58oRhUc4tnVNoGR BWuW7c7cZhrB6E4l0Yxw4pifaNXjBrygnFZV1QcbCS13ZlziPFXZTwaG58Hmk6hz9QhYQr kN2sLPB+APItUW/6ufhQKlZFtogHq8Yde+HUIdcUQ1y5UzNdvSEPPHG92qlJKrJYr+HL3A FV/rWAv0yEzpgq0Iff96NwkheKYC5EFbqJ84VXiXRnY12bznVFgmilRsUC3AqGXk10PUzY 5aP+cuiBEDy/lyvRe+pTIS2o1OchacwhjaZmov+Ox+Xvbe5SYR6Pj+95EgUNUQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vx5FfCzt3M; Mon, 15 Jul 2024 12:38:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcbT0062463; Mon, 15 Jul 2024 12:38:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcbYk062460; Mon, 15 Jul 2024 12:38:37 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:37 GMT Message-Id: <202407151238.46FCcbYk062460@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 64542285a832 - stable/13 - binmiscctl.8: Change the example to armv7 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 64542285a83209746679ce6e9335d5d2f3abef47 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=64542285a83209746679ce6e9335d5d2f3abef47 commit 64542285a83209746679ce6e9335d5d2f3abef47 Author: Andrew Turner AuthorDate: 2024-06-20 09:26:18 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:35:21 +0000 binmiscctl.8: Change the example to armv7 armv6 is in the process of being removed. Reviewed by: manu, imp, emaste Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45641 (cherry picked from commit 68f044de29b3867c2e0d282b86395f777f95b034) --- usr.sbin/binmiscctl/binmiscctl.8 | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/usr.sbin/binmiscctl/binmiscctl.8 b/usr.sbin/binmiscctl/binmiscctl.8 index 178389920448..4a4890146b57 100644 --- a/usr.sbin/binmiscctl/binmiscctl.8 +++ b/usr.sbin/binmiscctl/binmiscctl.8 @@ -288,15 +288,15 @@ Add QEMU bsd-user program as an image activator for 64-bit RISC-V binaries: \exff\exff\exff\exff\exff\exff\exfe\exff\exff\exff" \e --size 20 --set-enabled .Ed -.Ss "Create and use an ARMv6 chroot on an AMD64 host" +.Ss "Create and use an ARMv7 chroot on an AMD64 host" Use an existing source tree to build a chroot host with architecture overrides: .Bd -literal -offset ident D=/path/to/chroot cd /usr/src mkdir -p $D -make world TARGET=arm TARGET_ARCH=armv6 DESTDIR=$D -make distribution TARGET=arm TARGET_ARCH=armv6 DESTDIR=$D +make world TARGET=arm TARGET_ARCH=armv7 DESTDIR=$D +make distribution TARGET=arm TARGET_ARCH=armv7 DESTDIR=$D .Ed .Pp With From nobody Mon Jul 15 12:38:36 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN1vx0L04z5Qry7; Mon, 15 Jul 2024 12:38: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN1vw5p0wz4J07; Mon, 15 Jul 2024 12:38:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721047116; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=kSw48Tu+kgLSzAcjo6KypmYl9tb54m8tuNW5hpuUqr4=; b=JEYfgf0jp9dSqnfOF7w13pWKC3EfSqtJGpObrBc7bvbpVrS+3VghFYDxDp5Col3bI1zuWg VYwLSg/2aIuubiAdSA6bC0o7SVhRw8zTqximN4oeWR8ZzmB+yHKKOKiN5g4hYg/E7VMHsS gfSLz8rNiYqizIsS61tGrLLY17ttUidTzouU92GQdhu3MjXKI2mTIy4IUQVSuOsFs+VzXj E8bcfLi+miG/VsicAX8RXaq30o2/JBGqJNJBoo8m6sps5/Y8kuG9GRteNCHEm+B6sbfA07 EFj2f9eVWJ4RnajTe7dqnzGFgxFx185HDqCPZGF9/41unu85ZAId6kURqOOvDA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721047116; a=rsa-sha256; cv=none; b=Z4G3H41ohzknnrbxXY8HTmKc78BjbVQJ46JfwvHV/DIvBref26sv6cleHKHxv/C8Zd/LZI 13/m2cbVdrwfhTouI3Roc2Io+SKk9e/zDQ8aTDtdFZMorpcAafiJWG7/qbaee0pVI1xbeO 9D3UtsV7VCg6U2sReGs0VFgXQjd0chmeH3iCgyrMwYXILzo5WOs8lozhByJUhmoqO3wUHu C1GRl8ic5GMKCfsaXqcjZhj/wfVXOBcrbCZEy3ebi+2hizx4gX0b1q+iqnjw+tmcJdZCFZ NX1fAjPEKldJMgJvnFZhmqkcTkmWTpWES2l6XxVwiHv8QM8nyOgPrNrqI9NmiQ== 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=1721047116; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=kSw48Tu+kgLSzAcjo6KypmYl9tb54m8tuNW5hpuUqr4=; b=aJNC9s1rqs8efHx1mwJ+YVI7cxaSgpKYBh2xB2DFhfySSntUk/DYDYTJYPcGe0T3a/x5Si HhpuQyjHNgLLdThI9+PDF7csB7YXGgJXDmhxxJwap17/laMvgSIyRuf2hBFdg/BwTzmgDR uWwsoLgR7DNPP/driaavJOGQF/8BoMrgdZHC4I2pCdySFUrbrkzvuBS3neV+0BEleQYmgg hYLWQGMRG+wglDHzAq1ZlvBOai08nTw60AlAJA/C+q38VlHPsor6XAuvX1HtkyZir/Uhay qH7HRdUd97H1FdgkhjktqHeDNXCLYuATydNrnoKSCF6mVUlzc6Lo8gI8AnGn0w== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN1vw4hJWzspK; Mon, 15 Jul 2024 12:38:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCcatR062189; Mon, 15 Jul 2024 12:38:36 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCcapO062186; Mon, 15 Jul 2024 12:38:36 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:38:36 GMT Message-Id: <202407151238.46FCcapO062186@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: 4de39679dc35 - stable/13 - ibcore: Mark write-only variables List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 4de39679dc35cc9a7b02de0ed8584db3656ca288 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=4de39679dc35cc9a7b02de0ed8584db3656ca288 commit 4de39679dc35cc9a7b02de0ed8584db3656ca288 Author: Andrew Turner AuthorDate: 2024-06-12 13:04:45 +0000 Commit: Andrew Turner CommitDate: 2024-07-15 12:35:21 +0000 ibcore: Mark write-only variables Some LinuxKPI lock macros pass need a flags field passed in. This is written to but never read from so gcc complains. Fix this by marking the flags variables as unused to quieten the compiler. Reviewed by: brooks (earlier version), kib Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45303 (cherry picked from commit 19782e5bef3403a6ed65d46653f2e70f81dced37) --- sys/ofed/drivers/infiniband/core/ib_cache.c | 16 ++++++++-------- sys/ofed/drivers/infiniband/core/ib_cm.c | 4 ++-- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/sys/ofed/drivers/infiniband/core/ib_cache.c b/sys/ofed/drivers/infiniband/core/ib_cache.c index 0c6eef74594b..647a5fede9af 100644 --- a/sys/ofed/drivers/infiniband/core/ib_cache.c +++ b/sys/ofed/drivers/infiniband/core/ib_cache.c @@ -465,7 +465,7 @@ static int _ib_cache_gid_table_find(struct ib_device *ib_dev, struct ib_gid_table *table; u8 p; int local_index; - unsigned long flags; + unsigned long flags __writeonly; for (p = 0; p < ib_dev->phys_port_cnt; p++) { table = ports_table[p]; @@ -514,7 +514,7 @@ int ib_find_cached_gid_by_port(struct ib_device *ib_dev, unsigned long mask = GID_ATTR_FIND_MASK_GID | GID_ATTR_FIND_MASK_GID_TYPE; struct ib_gid_attr val = {.ndev = ndev, .gid_type = gid_type}; - unsigned long flags; + unsigned long flags __writeonly; if (!rdma_is_port_valid(ib_dev, port)) return -ENOENT; @@ -570,7 +570,7 @@ static int ib_cache_gid_find_by_filter(struct ib_device *ib_dev, struct ib_gid_table **ports_table = ib_dev->cache.gid_cache; struct ib_gid_table *table; unsigned int i; - unsigned long flags; + unsigned long flags __writeonly; bool found = false; if (!ports_table) @@ -879,7 +879,7 @@ int ib_get_cached_gid(struct ib_device *device, struct ib_gid_attr *gid_attr) { int res; - unsigned long flags; + unsigned long flags __writeonly; struct ib_gid_table **ports_table = device->cache.gid_cache; struct ib_gid_table *table = ports_table[port_num - rdma_start_port(device)]; @@ -929,7 +929,7 @@ int ib_get_cached_pkey(struct ib_device *device, u16 *pkey) { struct ib_pkey_cache *cache; - unsigned long flags; + unsigned long flags __writeonly; int ret = 0; if (!rdma_is_port_valid(device, port_num)) @@ -956,7 +956,7 @@ int ib_find_cached_pkey(struct ib_device *device, u16 *index) { struct ib_pkey_cache *cache; - unsigned long flags; + unsigned long flags __writeonly; int i; int ret = -ENOENT; int partial_ix = -1; @@ -997,7 +997,7 @@ int ib_find_exact_cached_pkey(struct ib_device *device, u16 *index) { struct ib_pkey_cache *cache; - unsigned long flags; + unsigned long flags __writeonly; int i; int ret = -ENOENT; @@ -1027,7 +1027,7 @@ int ib_get_cached_lmc(struct ib_device *device, u8 port_num, u8 *lmc) { - unsigned long flags; + unsigned long flags __writeonly; int ret = 0; if (!rdma_is_port_valid(device, port_num)) diff --git a/sys/ofed/drivers/infiniband/core/ib_cm.c b/sys/ofed/drivers/infiniband/core/ib_cm.c index 51b16cb84c1d..363b6abc79fe 100644 --- a/sys/ofed/drivers/infiniband/core/ib_cm.c +++ b/sys/ofed/drivers/infiniband/core/ib_cm.c @@ -4057,7 +4057,7 @@ static void cm_add_one(struct ib_device *ib_device) struct ib_port_modify port_modify = { .set_port_cap_mask = IB_PORT_CM_SUP }; - unsigned long flags; + unsigned long flags __writeonly; int ret; int count = 0; u8 i; @@ -4150,7 +4150,7 @@ static void cm_remove_one(struct ib_device *ib_device, void *client_data) struct ib_port_modify port_modify = { .clr_port_cap_mask = IB_PORT_CM_SUP }; - unsigned long flags; + unsigned long flags __writeonly; int i; if (!cm_dev) From nobody Mon Jul 15 12:55:33 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN2HV04H7z5Qtht; Mon, 15 Jul 2024 12: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN2HT6RSjz4hK8; Mon, 15 Jul 2024 12:55:33 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721048133; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=JxnXQ6GhtTr4Aj5Fsz0UeRJyGod4H3OWsJyeFjfb50c=; b=UUw5Rmc6MwNWk6fqlnk9mBussGpNLEdrLBy4BjKl1ja31h2Ef52gQVeojio7/JKzEFvnSk YUsx3wK5RBPHr/cUXC0p1bNlfNPBRZ6v9WXsFc8srN2iRFkn1bWdT1/pWH9TfNvwV82bQf D0bJcKq1W+3wkWuoSX47AE06ce+YQidsc3MeLwvc6NotbKPH4q6/sP6wzF5QpaK8bJOV+9 b7GIOZuCpl/sbaKhoLe/vgRJZx6v476DlwMHQax3bRl9OOEx08piXS9eNND0VnbzmKmPzW UC8fbO6iVl0ixCuo5iBGIDJCIM2lWwPS9Q+eHPw0FS4hwaadRG+kw0tg4ZV4pQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721048133; a=rsa-sha256; cv=none; b=QOm8tE4KCPg2YOq/YwdEGRNVVYPR9fHtzJxqiYcGtVHUx13jpKy5vBKBtpwTwnbKOCu0Tc wbLNjUpdd8wti6hXwk3Yv11m1mChPlhlQNrlVi3FCw8eoHXvmD1ONefSFQoECrBc7eGYZs Y2LTKYrD3f0VRij3oeSfLdREAHSUDpBmV2DJ057A2ktkeuRWah4EzrKCW2lCkrDaAmVa2f rrbgJi2SkzbE4SGnhE9gYELLYfP1tkOTKbVasgxpxH1GMhVWDZ0mpAVe9ThkAl5I8JvVov CU5H9P+T7NM1IHaLntgQyNq3J3MAp5V9fnHXK3qTr6EzsivVsw+r8KesvJaG9w== 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=1721048133; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=JxnXQ6GhtTr4Aj5Fsz0UeRJyGod4H3OWsJyeFjfb50c=; b=xwHsHPmNiEKLTVXmrukyPPuvA4rfXF2SfeiFECNwUmxLRRs+eoy84o03gd43Vsu1WuAseI Dh+LLM84X2RuJ6ol+J3GMiFprllwTue+dRXhbkuOO+uC0OqJZ+edKWDOBPjI+SXNipNgai bBN42Zs3HGzsWm2G4aXVeXqWoHG00f+K96Qyp9kdpbVxNuNUwN14yqMtMNTfi4ihjrL3zW ZcZkA667xR4a4SDJsOuKh5L2V4xdRCXOggNKTapT3nH805sYiiGdHh9ewVXa0crUY+KGbX 2ri9V/q6ESWZG1vyAeDWf6Ns9z+SSQq4dy0cEmf4kw/SuFe4NXNj5ll+LS7X5Q== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN2HT63NzztXN; Mon, 15 Jul 2024 12:55:33 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FCtX0i095271; Mon, 15 Jul 2024 12:55:33 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FCtXpl095268; Mon, 15 Jul 2024 12:55:33 GMT (envelope-from git) Date: Mon, 15 Jul 2024 12:55:33 GMT Message-Id: <202407151255.46FCtXpl095268@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: 004d5af853bf - main - splash(4): fix markup around cross-references List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: emaste X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 004d5af853bfef1eb66394a15ac9e94e6dcebc0a Auto-Submitted: auto-generated The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=004d5af853bfef1eb66394a15ac9e94e6dcebc0a commit 004d5af853bfef1eb66394a15ac9e94e6dcebc0a Author: Ed Maste AuthorDate: 2024-07-15 12:53:52 +0000 Commit: Ed Maste CommitDate: 2024-07-15 12:53:52 +0000 splash(4): fix markup around cross-references Fixes: 7504e0e3e517 ("splash(4): Document how to use splash screen ...") Sponsored by: The FreeBSD Foundation --- share/man/man4/splash.4 | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/share/man/man4/splash.4 b/share/man/man4/splash.4 index 736703317a7f..af2ae2e4369a 100644 --- a/share/man/man4/splash.4 +++ b/share/man/man4/splash.4 @@ -204,8 +204,8 @@ have the following line in the kernel configuration file. .Dl device splash .Pp Next for -.Xr syscons 4 -, edit +.Xr syscons 4 , +edit .Pa /boot/loader.conf (see .Xr loader.conf 5 ) @@ -244,8 +244,8 @@ bitmap_name="/boot/splash.bin" .Ed .Pp For -.Xr vt 4 -, edit +.Xr vt 4 , +edit .Pa /boot/loader.conf (see .Xr loader.conf 5 ) From nobody Mon Jul 15 13:03:16 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN2Sh6Rrmz5QvPc; Mon, 15 Jul 2024 13:03:32 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: from mail-io1-f51.google.com (mail-io1-f51.google.com [209.85.166.51]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "WR4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN2Sh0QnFz4hy6; Mon, 15 Jul 2024 13:03:32 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=fail reason="SPF not aligned (relaxed), No valid DKIM" header.from=freebsd.org (policy=none); spf=pass (mx1.freebsd.org: domain of carpeddiem@gmail.com designates 209.85.166.51 as permitted sender) smtp.mailfrom=carpeddiem@gmail.com Received: by mail-io1-f51.google.com with SMTP id ca18e2360f4ac-7fe8d029fbeso144824239f.3; Mon, 15 Jul 2024 06:03:32 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721048608; x=1721653408; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=0g8apwROfei5LIpxKtqt4xFCY8Lo/cw/NPquv9tU1vQ=; b=JdJ3HMI2lT9OumrbhdPAsAB9hQVSHqgFBszWeYWNZOu+4fHN16k6aeql+CzXfsahRG U93a3iZlDB/qP/+kNFAXaJATZaD4DT1HNablA4ogasbJFyTcdI+RSotpSUVP6YF6FBis u0NXtEjiU41v6u32G97c19c4FCrNS4dUO1zHZ6m/EfiWmMPPKyJkwiau7O7ptgXklc6K NJhnHb758tDws7/tzpVko3TwIY0dupARKZ9pzggfMcObQXEgic6KVXyKaGcpANbTsimA u7Y/tXvfe0m4U2/Bn/trEFHWzXEvXj17y0ZJOFImIFBlnX7EyC7jRkfET/iTto3VlNIE ue1w== X-Forwarded-Encrypted: i=1; AJvYcCVxwJ4VWrzBJWe0R20Oq++BUUSEoZS2Euz/RBaYSB11aOtxtXmvXC/f2OtQAnm8YspeRwwUPPYNadAMnM4kTjjbnJ69xD34oSYtoZmZ6zULpmbGZUpW+dCheQIos2SVwZlrSTgWJUq5+thXPZ/IhqC+0g== X-Gm-Message-State: AOJu0YxhLZJCNSSkHTq7GfDNyH8nE1GeFkCDtbHkeHBn/gYBPhFs4MNi /Yhe5LT7y24H3gOKSSvv9FYkjXJuD9bWwb7s4bC2dbeATQdsD7SDI7r0p7aV8guXluKZs3EZjKh LUgZEfvq0ZNljJSHSxfyv2vaJekzvJA== X-Google-Smtp-Source: AGHT+IGJF+DFse6wyrwPgiydo5mLSXBF9nPc832ussTh83nimuONiRuHoyN+molou25tgC/80J5hP5N8Q+wxEf7oId8= X-Received: by 2002:a05:6602:4fd6:b0:7f9:b435:4f5 with SMTP id ca18e2360f4ac-80000ea0ad0mr1986027939f.11.1721048608439; Mon, 15 Jul 2024 06:03:28 -0700 (PDT) List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 References: <202407140600.46E60JKl047510@gitrepo.freebsd.org> In-Reply-To: <202407140600.46E60JKl047510@gitrepo.freebsd.org> From: Ed Maste Date: Mon, 15 Jul 2024 09:03:16 -0400 Message-ID: Subject: Re: git: 60f098f84119 - main - arch: Update to remove armv6 To: Warner Losh Cc: src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Content-Type: text/plain; charset="UTF-8" X-Spamd-Bar: - X-Spamd-Result: default: False [-1.75 / 15.00]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_SHORT(-0.48)[-0.476]; NEURAL_HAM_MEDIUM(-0.37)[-0.370]; FORGED_SENDER(0.30)[emaste@freebsd.org,carpeddiem@gmail.com]; R_SPF_ALLOW(-0.20)[+ip4:209.85.128.0/17:c]; DMARC_POLICY_SOFTFAIL(0.10)[freebsd.org : SPF not aligned (relaxed), No valid DKIM,none]; MIME_GOOD(-0.10)[text/plain]; ARC_NA(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; RCPT_COUNT_THREE(0.00)[4]; RCVD_TLS_LAST(0.00)[]; TO_DN_SOME(0.00)[]; MIME_TRACE(0.00)[0:+]; FROM_HAS_DN(0.00)[]; RCVD_COUNT_ONE(0.00)[1]; FREEMAIL_ENVFROM(0.00)[gmail.com]; MLMMJ_DEST(0.00)[dev-commits-src-all@freebsd.org,dev-commits-src-main@freebsd.org]; FROM_NEQ_ENVFROM(0.00)[emaste@freebsd.org,carpeddiem@gmail.com]; MISSING_XM_UA(0.00)[]; R_DKIM_NA(0.00)[]; ASN(0.00)[asn:15169, ipnet:209.85.128.0/17, country:US]; RWL_MAILSPIKE_POSSIBLE(0.00)[209.85.166.51:from]; FREEFALL_USER(0.00)[carpeddiem]; RCVD_IN_DNSWL_NONE(0.00)[209.85.166.51:from] X-Rspamd-Queue-Id: 4WN2Sh0QnFz4hy6 On Sun, 14 Jul 2024 at 02:00, Warner Losh wrote: > > .Dv aarch64 > will support execution of > -.Dv armv6 > -or > .Dv armv7 > binaries if the CPU implements > .Dv AArch32 > -execution state, however older arm binaries aren't supported. > +execution state, however older arm binaries are not supported by > +.Fx . Do older 32-bit Arm userland binaries actually not work? Would "support execution of 32-bit Arm binaries if the CPU implements the AArch32 execution state" be accurate? From nobody Mon Jul 15 13:31:33 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN3515XtZz5QxhP; Mon, 15 Jul 2024 13:31: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN35152k4z4mmV; Mon, 15 Jul 2024 13:31:33 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721050293; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6fTKnjDdPa7c/8+YrIr4m7ZT2z38/MctvXAHaQ5CS7o=; b=Li3c/OURh9ANkkYB9+vamHY/Xkk2U4lGCLkvSUuzTb+MaS0OFHiPk7cZ6ShXkFx3ntTPlq KKGQGD1hbW2vYhabB/OFqlCPWMvXX1a+EgRhXet8DTCXcltN3tKwNDi4+P4uew4XMttsGT dPI9VW6l72PbsxD8S8zDtkKT/eBIoM5PBa7KuYFRI2kAd8CZYCef3vOhxgCkn9xvre2tjg SwhVjVsRa/zOuFbOAXuHEteV4/h2gIHoH+FNpjdtiEtHxS8lOspCh+gzKqti1ao8PdHcp3 ioab3C4Zq7AfqFsWvHlEwQKI+yLkVrfZ8Qf3an4j4+43odz9Ntdg0eMCcUOgpg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721050293; a=rsa-sha256; cv=none; b=oqgKr2syNLKP0WoFrlkc5SwGU7QOSL2dziLa34h/B4AhibqBB6iQAo6jR+Tk6gKEy31Pe7 7wlPGbE5ITYEuIFF/Y8yfeiQESU9DwVRab78eRA9Bu4FnYvHLovjb7cySP5SW84tsG9HXN z6kW18TFouz1QEHP8qtt+/ZDswIZjgLB9BuoCsCHAN6NJ6AyFXa90CU3zuk/OPTJiw4sqH luifSx1jRqv+8r8smJK10R/Tlifxop4mob8X8ovDPzJPok9sVAYuwjpXTilLsSuGEW638h vGTm1hHRJh4kK1WZvKLcgJZTZWLJF8zze7ncxeKx9h0tVl439z2B93AJzr78sw== 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=1721050293; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6fTKnjDdPa7c/8+YrIr4m7ZT2z38/MctvXAHaQ5CS7o=; b=tFSQMK7OOoR3G7HivM4iU1oz/U6KaiBfw7CKERJzWWeowFLzCtmo+D/4CUH5RnJRRZGyLU ZK/32+vK5lFK32Dre2BcPQ6pOj0v3fDW6XECRDFs18z7CVHE6QrOl29W0MgmVYu6UYQL9p VnoQ7UHYnTPisviOeY52x2G2cjm5643cvNvGq8YF8VwxsRfmeNCFONANzIfcKjUH5vtyR2 bkqQg+xxujY2qmpmNJh1rG5ODwwfz1NVilbkNFzOK17MB6ZbeYBC5Ceg/8n5EVHgSgSbi3 oX7APK7MUBSay/D9QnTLG1iiPGcBIzVvAmlF5S/MNtoh+AjYH6zOMLQZaV1bUQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN3514f39ztmn; Mon, 15 Jul 2024 13:31:33 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FDVX6M061376; Mon, 15 Jul 2024 13:31:33 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FDVXkW061373; Mon, 15 Jul 2024 13:31:33 GMT (envelope-from git) Date: Mon, 15 Jul 2024 13:31:33 GMT Message-Id: <202407151331.46FDVXkW061373@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: 001606523a48 - main - libm: add parens to clarify expressions in fma, fmal List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: emaste X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 001606523a48ca2aa440c985db47327a00671358 Auto-Submitted: auto-generated The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=001606523a48ca2aa440c985db47327a00671358 commit 001606523a48ca2aa440c985db47327a00671358 Author: Ed Maste AuthorDate: 2024-06-18 01:30:44 +0000 Commit: Ed Maste CommitDate: 2024-07-15 13:30:02 +0000 libm: add parens to clarify expressions in fma, fmal Obtained from: NetBSD --- lib/msun/src/s_fma.c | 6 +++--- lib/msun/src/s_fmal.c | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/lib/msun/src/s_fma.c b/lib/msun/src/s_fma.c index 16902d321290..6c889a6a46ca 100644 --- a/lib/msun/src/s_fma.c +++ b/lib/msun/src/s_fma.c @@ -222,17 +222,17 @@ fma(double x, double y, double z) case FE_TONEAREST: return (z); case FE_TOWARDZERO: - if (x > 0.0 ^ y < 0.0 ^ z < 0.0) + if ((x > 0.0) ^ (y < 0.0) ^ (z < 0.0)) return (z); else return (nextafter(z, 0)); case FE_DOWNWARD: - if (x > 0.0 ^ y < 0.0) + if ((x > 0.0) ^ (y < 0.0)) return (z); else return (nextafter(z, -INFINITY)); default: /* FE_UPWARD */ - if (x > 0.0 ^ y < 0.0) + if ((x > 0.0) ^ (y < 0.0)) return (nextafter(z, INFINITY)); else return (z); diff --git a/lib/msun/src/s_fmal.c b/lib/msun/src/s_fmal.c index 9d08bc72e12e..80c835d09c2b 100644 --- a/lib/msun/src/s_fmal.c +++ b/lib/msun/src/s_fmal.c @@ -203,17 +203,17 @@ fmal(long double x, long double y, long double z) case FE_TONEAREST: return (z); case FE_TOWARDZERO: - if (x > 0.0 ^ y < 0.0 ^ z < 0.0) + if ((x > 0.0) ^ (y < 0.0) ^ (z < 0.0)) return (z); else return (nextafterl(z, 0)); case FE_DOWNWARD: - if (x > 0.0 ^ y < 0.0) + if ((x > 0.0) ^ (y < 0.0)) return (z); else return (nextafterl(z, -INFINITY)); default: /* FE_UPWARD */ - if (x > 0.0 ^ y < 0.0) + if ((x > 0.0) ^ (y < 0.0)) return (nextafterl(z, INFINITY)); else return (z); From nobody Mon Jul 15 13:39:16 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN3Fw6Jfsz5QyF9; Mon, 15 Jul 2024 13:39: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN3Fw5hNMz4nq7; Mon, 15 Jul 2024 13:39:16 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721050756; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=g4j0m2mY4O+EHGPVa0Sbkw6FkxczZkSaq4yjtByB4zs=; b=XcvQv99LHmg8KqZSaEQyFYiZzRKzrUOjY1Cuq1aaNdv+o5ICeA0mgUoSNN6WBL0F+SlfET RoNTdPtx5dFO87RHtqE9ox0al5Xiqw1z1SXfvv4K4+wuQyLUPi4x9Zddr4AczZKcT9h4O3 hNfQWSxOntN5FNd7vvPbd4o4p0X7R8tOQqbmZ4P+87kGYAOgYK7FSdq34CX28GyAiCqDg/ EXQ9dwgZSZixUbzZnkVT0T9U+HJfBfQbJUYnoBg7tKBr3CQyX4BPhKj7pDAkYhBPxqiF+z V0dSwgIWc5bt2E8xSnExCTAg1UFhIKKuaRWf0gOdEwQWMRfXbmhkecIgep3wtw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721050756; a=rsa-sha256; cv=none; b=lwwUohRwMb2jS1/5rPx5BzXiK0/YFv+dGW8aH3tVwoFoj7w8FIfc59ATe7bVOQl04zkvA+ njM3PZ89WfFeLQyOnymZyz07OZzuntGOzvwEZCpiCH1RIx1zP5VhrQyEFRm2hgJQmoIgPk DezqXFARHpLYACEMmCeac+grN1m7ZQlMpoCbuFqFPKhgrj+ApOx/mrk/hBM2EVZ9vLok5b k+w5vvHsoh+zD2VHGvOl446yp6/4FWBx9dH6VFgeDWtVFu/FsadM71yXOTLqAKsSTHoHIw rArg0Qxb+ItBJOp0+18CZ5e16Qnj7fSDe4HuVsefG0jD+rrzDVMr0vksKeznTA== 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=1721050756; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=g4j0m2mY4O+EHGPVa0Sbkw6FkxczZkSaq4yjtByB4zs=; b=NfR0WNW/GBeACd5xEpnSutmKGo9I3oEa9/TrT5tfrcjTtHiz1CoH+l3FVQwHdPOdu0r4k/ vtsaDeWv863IY9eddqwVA4S9/3foTqxTjWgTGmx/3cvFg9kbeTE4Qe190q2ZXDYec7/vvS g31agFo8kB5b8HqfYs9HOLDD8zAW5gEhOR9X6km/sOOflgDqiYKiDlMCE6GNKiWrvgg2UR 3ucw8gsjB8YWiybx4plCXKPWAEFCmHRMvzvjWv0/GLCAGyhkXbAwOM68gVZj1BGkY7Z/pH 03ZfeH4Ja8AlTCMxf2G18MDcIkvTH/qI1Gt9QCE0CIVZuPqRr1xMWz3xgpQ6VQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN3Fw5B9czvWc; Mon, 15 Jul 2024 13:39:16 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FDdGhc063471; Mon, 15 Jul 2024 13:39:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FDdGNu063468; Mon, 15 Jul 2024 13:39:16 GMT (envelope-from git) Date: Mon, 15 Jul 2024 13:39:16 GMT Message-Id: <202407151339.46FDdGNu063468@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: 7e32f871b7dd - stable/14 - taskqueue: Move the timeout_task definition to _task.h List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 7e32f871b7dd522c2b1d649e8b9e4e7be9032b4a Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=7e32f871b7dd522c2b1d649e8b9e4e7be9032b4a commit 7e32f871b7dd522c2b1d649e8b9e4e7be9032b4a Author: Mark Johnston AuthorDate: 2024-07-08 16:26:35 +0000 Commit: Mark Johnston CommitDate: 2024-07-15 13:39:06 +0000 taskqueue: Move the timeout_task definition to _task.h So that timeout_task may be embedded into structures without pulling in too many other definitions. No functional change intended. MFC after: 1 week Sponsored by: Klara, Inc. Sponsored by: Stormshield (cherry picked from commit bea256f3c5b9d9608278377576047bf0e591a4e7) --- sys/sys/_task.h | 10 ++++++++++ sys/sys/taskqueue.h | 8 -------- 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/sys/sys/_task.h b/sys/sys/_task.h index 0e6f212990ec..86c68da8bab0 100644 --- a/sys/sys/_task.h +++ b/sys/sys/_task.h @@ -29,6 +29,7 @@ #ifndef _SYS__TASK_H_ #define _SYS__TASK_H_ +#include #include /* @@ -58,6 +59,15 @@ struct task { #define TASK_IS_NET(ta) ((ta)->ta_flags & TASK_NETWORK) +struct taskqueue; + +struct timeout_task { + struct taskqueue *q; + struct task t; + struct callout c; + int f; +}; + #ifdef _KERNEL typedef void gtask_fn_t(void *context); diff --git a/sys/sys/taskqueue.h b/sys/sys/taskqueue.h index 34d64a5042a6..9757e1fce575 100644 --- a/sys/sys/taskqueue.h +++ b/sys/sys/taskqueue.h @@ -35,7 +35,6 @@ #include #include -#include #include struct taskqueue; @@ -43,13 +42,6 @@ struct taskqgroup; struct proc; struct thread; -struct timeout_task { - struct taskqueue *q; - struct task t; - struct callout c; - int f; -}; - enum taskqueue_callback_type { TASKQUEUE_CALLBACK_TYPE_INIT, TASKQUEUE_CALLBACK_TYPE_SHUTDOWN, From nobody Mon Jul 15 13:39:17 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN3Fx6xTzz5Qy6t; Mon, 15 Jul 2024 13:39: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN3Fx6HNBz4nvL; Mon, 15 Jul 2024 13:39:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721050757; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=12Zcvoh/up4iVQHZz9g0RvEWz7IkaXs7hI7LdOr26Mo=; b=r+vRq2Grl9CwmKEzBFoC8nzcLBKulTkdas8OWr/WC9zQx93rQ6/ex3/pbVu3VjNpKwW1d2 TJFdTxLnRfjCRkHAsSriAH+EOwJGj5PD3ddtW7xt3M/zOkeTMpbOAcn2OPWsCDtvGSHogH MNKVe3if8QjRciIbZ5Xq5MZQXfaCXBLs/zqhsUkBZbFbD/EKY8u8ZFQdO7TVbqFFEychIq 5XZciVRjKyOUVa8Mv4QlS1eCa6lt1b2Zbrf9jNgmRuEmb6ptbx4F2j+JU5dw0x/kaCkqO0 y+dXNZxr8DuZ4j9EY5VV62AggYpuCw2WSy381kwpEhblI9uZ5sIVQP/8egBrbg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721050757; a=rsa-sha256; cv=none; b=KMhkSSwmlfSAxh3Dniyfw1lAj5fd/RBPZVK0wSl6Jc3ANap/jmGzQf5Epu3ae6bluVspNh zD8Knq3aF0UK7EOPSrojkaNBBB/DhMgc/nTXAw8bQUVMzamGt/nfxphysUXWXy2hw+xCq1 ddUrqnpbreYoOpvNROXt3TONDa98ZNLQl6W71P9NU55jOxc4opLPl/FQLrMyAdYZF4Ky3L zjN0hXH6pBPC7Uxl1w7qjCsV7l63e5IRmPu4cGS0bBkYGZKYsxKWhCURajhndhsuiPiyxt 8CyBxC5zFlakmjt25D1kAmTCC9hv+fEDqBarJoUNszRJSYj4PW6e9je9E+fjQQ== 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=1721050757; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=12Zcvoh/up4iVQHZz9g0RvEWz7IkaXs7hI7LdOr26Mo=; b=x/aLfp0WE64y+V2HoHhJkqmGnPYm0+7JNB55NWifOyxyOh2z7h7iyQyc+bCgi8TolG7Kif 4KbOIq2y8zFYYWcIpQLPou9NnDtwJIun7C9M7EoxNcp6nDPdoAs9RsVrKtO9fw2QkcPG6p pLS8se1ETLvPEWYvFzXz/a66gZHgrH8/6vwGsqlDfNqmQcelvWPeXJacJR1ElwM/rRg+5k EFxo+5m7BGTROqTOlrOX9b5r1NxlQQtSKn98/mxpvbQmgEANwXKprgR4Aamp3fGmt+0jRg OzOFdkKK1dxP30Ocz9Z73RGj28sMk+g3va7i2aV5xwu6xY8wu3BR8ilcrdt6/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 4WN3Fx5tVxztsn; Mon, 15 Jul 2024 13:39:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FDdHWL063518; Mon, 15 Jul 2024 13:39:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FDdHrW063515; Mon, 15 Jul 2024 13:39:17 GMT (envelope-from git) Date: Mon, 15 Jul 2024 13:39:17 GMT Message-Id: <202407151339.46FDdHrW063515@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: 355a797dfaee - stable/14 - man9: Add an MLINK for taskqueue_enqueue_timeout_sbt.9 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 355a797dfaeebbab65d2dde03d179cf7796a38cc Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=355a797dfaeebbab65d2dde03d179cf7796a38cc commit 355a797dfaeebbab65d2dde03d179cf7796a38cc Author: Mark Johnston AuthorDate: 2024-07-08 16:20:06 +0000 Commit: Mark Johnston CommitDate: 2024-07-15 13:39:08 +0000 man9: Add an MLINK for taskqueue_enqueue_timeout_sbt.9 MFC after: 1 week Sponsored by: Klara, Inc. Sponsored by: Stormshield (cherry picked from commit 713c77b927f2feb7d51a96f4bc9184cf8dce61b4) --- share/man/man9/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/share/man/man9/Makefile b/share/man/man9/Makefile index 55427c5b0eca..eff555170276 100644 --- a/share/man/man9/Makefile +++ b/share/man/man9/Makefile @@ -2241,6 +2241,7 @@ MLINKS+=taskqueue.9 TASK_INIT.9 \ taskqueue.9 taskqueue_drain_timeout.9 \ taskqueue.9 taskqueue_enqueue.9 \ taskqueue.9 taskqueue_enqueue_timeout.9 \ + taskqueue.9 taskqueue_enqueue_timeout_sbt.9 \ taskqueue.9 TASKQUEUE_FAST_DEFINE.9 \ taskqueue.9 TASKQUEUE_FAST_DEFINE_THREAD.9 \ taskqueue.9 taskqueue_free.9 \ From nobody Mon Jul 15 13:51:39 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN3XC31psz5R08K; Mon, 15 Jul 2024 13:51: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN3XC2cLjz4qKP; Mon, 15 Jul 2024 13:51:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721051499; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=XAMbQtIHfWqglUEdANrlbL9gDXhkKsJuedgSObZmWJ4=; b=ddi3grJ2Vi04fSGr5tANssnOcAKewlDxGOWKATZtTYPzZHVeMp4pFU0NQQo1audTvPrmrG otIX0QN3TRWlq8xboInWAPVoqKhhePM1ht3Ozx9BrjZ+RnchNbpnIwiG3Jftz+RVqKw+3p YU3/GQAADce/IMJNo2qreflPkmGngz6XytiNpaDeLu8MhflGA15ENGNEJHJXPjlBEF4XK/ kbzgg2oeprMbXws4yhxXteBjcb6jynwDj9zSIvypDHFR3h/9FAfZHgw8QomJa5Gdr5IlzW grUFhUrlb0IaEWmBdWLZOfxHr0Wct84KFem2LWW4DSznH8ahauoV8624tWt75A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721051499; a=rsa-sha256; cv=none; b=aJJKjoV1qVv3KnXjl5N6PdIvUodIuxItDgQJVM+qY/R5mjkmPPEqy7upkM1R+afnI5eKJ7 Zj57YLakkAe+nGTgzo44oLZaQIk/lv5QyRxHwm/3N3Jmyx2NHTYWcyCiqXKSML8comcOkh VPR0ZUaHvLKPaefSST+7/7EXaPoiTE8d8pQSqbe3HNuLMLULOtAv9O7BdxuQEV7Qx5SxDQ I9w5kXIX0U7o0YpWX66az+9rgsJh3MK1lBA8oK8x0LO+oBIqFKHc07ptsuiMTu+3MHNMJq O94A/GMGdpiSox5vKazALDmwMUnHAMKhqv0mXcizgqvm9TMRngHKh3zxaOzZ4w== 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=1721051499; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=XAMbQtIHfWqglUEdANrlbL9gDXhkKsJuedgSObZmWJ4=; b=JhA69Ev4CWDBE7UB7C5eibCNXepu5z46Z4zgf01NunimGUzBgLXTkMXVtLfPMWilnNZyO9 ta/Fhs3oFFNGC/02JvuWm6TPZ9u7SuueLkK0rQY7AGUkK9b+UEYHez7OQASd5tPGia/NJH Y5hSxzLbuCGW5SfwOqHfmLIWeBOexU9bQHkjb2wi2dVCSjyEC0uzmpbTN40DC/wFh8NBwx w6Q/EjOfafwxoQHmr27UWpfoOj1pfqcXrut26Mw/vfjkerCPy+i+dcdVvrB1QCbThkr1dc y1RA0MiBTmGAl3zciGx8FFT/rbGEJorU7e+3b63udY1GsIAu/OXqdiFhQoXXHg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN3XC2Cv2zvXC; Mon, 15 Jul 2024 13:51:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FDpdYF092824; Mon, 15 Jul 2024 13:51:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FDpdWE092821; Mon, 15 Jul 2024 13:51:39 GMT (envelope-from git) Date: Mon, 15 Jul 2024 13:51:39 GMT Message-Id: <202407151351.46FDpdWE092821@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: 867873b3980c - main - Revert "Makefile.inc1: show time for `make installworld'" List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: emaste X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 867873b3980c42c379f1f0e6ac88d92337ddf5dd Auto-Submitted: auto-generated The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=867873b3980c42c379f1f0e6ac88d92337ddf5dd commit 867873b3980c42c379f1f0e6ac88d92337ddf5dd Author: Ed Maste AuthorDate: 2024-07-15 13:49:26 +0000 Commit: Ed Maste CommitDate: 2024-07-15 13:50:04 +0000 Revert "Makefile.inc1: show time for `make installworld'" It broke `make packages`, so revert until that can be fixed. This reverts commit e5a0202f96948a95bf1b879727e155a4f1d1da93. Reported by: bapt, theraven --- Makefile.inc1 | 22 +++------------------- 1 file changed, 3 insertions(+), 19 deletions(-) diff --git a/Makefile.inc1 b/Makefile.inc1 index 7ff961e22e7a..19ed923702b1 100644 --- a/Makefile.inc1 +++ b/Makefile.inc1 @@ -1241,19 +1241,11 @@ WMAKE_TGTS+= build${libcompat} .endif WMAKE_TGTS+= everything -# record buildworld / install time in seconds +# record buildworld time in seconds .if make(buildworld) _BUILDWORLD_START!= date '+%s' .export _BUILDWORLD_START .endif -.if make(installworld) -_INSTALLWORLD_START!= date '+%s' -.export _INSTALLWORLD_START -.endif -.if make(installkernel) -_INSTALLKERNEL_START!= date '+%s' -.export _INSTALLKERNEL_START -.endif buildworld: buildworld_prologue ${WMAKE_TGTS} buildworld_epilogue .PHONY .ORDER: buildworld_prologue ${WMAKE_TGTS} buildworld_epilogue @@ -1321,11 +1313,11 @@ kernel-toolchain: ${KERNEL_TOOLCHAIN_TGTS} .PHONY installcheck: _installcheck_world _installcheck_kernel .PHONY _installcheck_world: .PHONY @echo "--------------------------------------------------------------" - @echo ">>> Install check world started on `LC_ALL=C date`" + @echo ">>> Install check world" @echo "--------------------------------------------------------------" _installcheck_kernel: .PHONY @echo "--------------------------------------------------------------" - @echo ">>> Install check kernel started on `LC_ALL=C date`" + @echo ">>> Install check kernel" @echo "--------------------------------------------------------------" # @@ -1649,8 +1641,6 @@ restage reinstall: .MAKE .PHONY .endfor @echo "--------------------------------------------------------------" @echo ">>> Installing everything completed on `LC_ALL=C date`" - @seconds=$$(($$(date '+%s') - ${_INSTALLWORLD_START})); \ - echo ">>> Install world completed in $$seconds seconds, ncpu: $$(${_ncpu_cmd})${.MAKE.JOBS:S/^/, make -j/}" @echo "--------------------------------------------------------------" redistribute: .MAKE .PHONY @@ -1883,9 +1873,6 @@ reinstallkernel reinstallkernel.debug: _installcheck_kernel .PHONY @echo "--------------------------------------------------------------" @echo ">>> Installing kernel ${INSTALLKERNEL} completed on $$(LC_ALL=C date)" @echo "--------------------------------------------------------------" - @seconds=$$(($$(date '+%s') - ${_INSTALLKERNEL_START})); \ - echo ">>> Install kernel(s) ${INSTALLKERNEL} completed in $$seconds seconds, ncpu: $$(${_ncpu_cmd})${.MAKE.JOBS:S/^/, make -j/}" - @echo "--------------------------------------------------------------" .endif .if ${BUILDKERNELS:[#]} > 1 && ${NO_INSTALLEXTRAKERNELS} != "yes" .for _kernel in ${BUILDKERNELS:[2..-1]} @@ -1900,9 +1887,6 @@ reinstallkernel reinstallkernel.debug: _installcheck_kernel .PHONY @echo ">>> Installing kernel ${_kernel} completed on $$(LC_ALL=C date)" @echo "--------------------------------------------------------------" .endfor - @seconds=$$(($$(date '+%s') - ${_INSTALLKERNEL_START})); \ - echo ">>> Install kernel(s) ${BUILDKERNELS} completed in $$seconds seconds, ncpu: $$(${_ncpu_cmd})${.MAKE.JOBS:S/^/, make -j/}" - @echo "--------------------------------------------------------------" .endif distributekernel distributekernel.debug: .PHONY From nobody Mon Jul 15 14:14:26 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN42V4XnLz5R1qC; Mon, 15 Jul 2024 14:14: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN42V3ZVqz4stS; Mon, 15 Jul 2024 14:14:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721052866; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Y/9q84YBF97EVqmRaWaXXlrPUOtWuDv5e1d2Ax5zJ4w=; b=yC6vXGrv1+km2cRshTufT8sjenepm9ze3aXiYSMUD4SsZLwY8GqS//c2ygWHWOpsEmhOeU UCYIoWNz5jK0xfgyNzbQpi9rgKornsaWSYSyR8aeiltS/TpJrJ66jiryHMgzkX5SetFulI wi2bLT00lsHMKhqOZ6tcNvm/0eAF7jKFCIf9VV8wCNVuAC02fvbpCl93hzeah84OmByC18 KQnw6P+RDIflPQOINdziWBCGEUaFJrk97GSBguvy9WaJqmUTqfJ7s1MNrBudI77ChaHhot CoD4hq3tboC4mQuCftTZZp9SoKJt5QD7++pY22bJ4BdQPei/N5DEJ46h0QOEYw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721052866; a=rsa-sha256; cv=none; b=q9nPdXcn1BDTv0IgzZNRq9htRvuuIcLgTsyjMQVO+Pv8gte50gpRegGGHBwJmG8HVkcsOy ziW7uFl1SOvPedRvf5RioKu7aIGV4KWNp6pe4WonS0PIIqEfyZrRcOqdCRpo2MX05AALNu VERfdp0uO1L75qG3Y6vfjw4OFx2nzuJY5kbxzoFusbnRlveSh7lpySeDZezX0NtPF4nXHy c/KDiVqXgTV2k7dBDuWFognlm7FQ25N50tsECl6yJW1hcxPaR1nEMreQ8yiB+hYXSLcVdg yNVooErEkMhgHnAFU33bZfXCS+3phllIUXoxZ0gMoPIsFA9dysLyLLDF/SytBQ== 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=1721052866; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Y/9q84YBF97EVqmRaWaXXlrPUOtWuDv5e1d2Ax5zJ4w=; b=AHHhPNvrrr6XIHgR0CgIfH7tWxgx7lfWDYFs23Inxqb9h7Jo6ku2mxH++DVqeraDgdT2bb xDtUiFkQ+kz2claO5JpC4MaQ8bRG3UxcXmxbxNWw7BMIGx8FWQWwtCUX9jBeoUHNgzSpRY CdN2xEF+pLMnCuBlF5UNubdZC0+5VlzbLX/4qXP4UpMc9B+pP5ftKTUlXeIFw4juMVk95C ryj+mJGhbwmEQSfl720p5cSNUlcB5kFxuiqUQZtBVQs1ZEacQ8qTrmHT2EnjgiAsYLFG9/ ifm6mQxmlcHd1PV1nZaGUFDljK+2QyVgmoOSse6uOY3FeBOSL3RvE+5Ihmiz6w== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN42V2ntczw3h; Mon, 15 Jul 2024 14:14:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FEEQrZ031515; Mon, 15 Jul 2024 14:14:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FEEQM0031512; Mon, 15 Jul 2024 14:14:26 GMT (envelope-from git) Date: Mon, 15 Jul 2024 14:14:26 GMT Message-Id: <202407151414.46FEEQM0031512@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: e5a18aa2373b - main - splash(4): Subject/verb agreement List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e5a18aa2373b9446fd93622acf6a8a7ba10e2589 Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=e5a18aa2373b9446fd93622acf6a8a7ba10e2589 commit e5a18aa2373b9446fd93622acf6a8a7ba10e2589 Author: John Baldwin AuthorDate: 2024-07-15 13:59:57 +0000 Commit: John Baldwin CommitDate: 2024-07-15 13:59:57 +0000 splash(4): Subject/verb agreement --- share/man/man4/splash.4 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/man/man4/splash.4 b/share/man/man4/splash.4 index af2ae2e4369a..b001663c4fa5 100644 --- a/share/man/man4/splash.4 +++ b/share/man/man4/splash.4 @@ -304,7 +304,7 @@ and modules were written by .An Dag-Erling Sm\(/orgrav Aq Mt des@FreeBSD.org . .Sh CAVEATS -The screen saver work with +The screen saver works with .Xr syscons 4 only. .Sh BUGS From nobody Mon Jul 15 14:17:04 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN45X4dz6z5R2Wn; Mon, 15 Jul 2024 14:17: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN45X47jyz4tgF; Mon, 15 Jul 2024 14:17:04 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721053024; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=E6hyfblkeISuomKjGAjGVSATaxveL75XubxU6h/HMf8=; b=XUHrz425w181E1e7uIG8jkaRHfV6fQVxJDM2v6ueDK5KaVggqg5sXpZ7LbmFDyJagc/Kew yjLfnr2ns4KfbKX0bPI/NMEsa21ojNL3NCRn/16ADzCxjyx3qxQ/RllcYYkcuGGLu68QFJ nrAm+ixn9DOPDyZ7Cjh6kTrXLeIMpF0Rjly8EbzGdDAl4kQhpvw2ameIrJcG/rzdbpkL1G uc2CoGkT7yjGCWU1UkYGKbZqKZUihxmDWYZDEOMWUnNN1WMa9mMn95tTorvY4UZ9ywyU5/ TWr+Cze3W7Ca6SQbn2lmn+IrXJ1SLaqbnoET4Y0m9XqWMNa/T2MhhpWKKibksw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721053024; a=rsa-sha256; cv=none; b=xncdEQ1eBfsdGwsosp84m+1Yc7SrSmumc6stY/B9iWXq2PUetGOAg++/MSPzfaDHItGr0l KVDyy+nDkLWCeuCU5LLoDD+LcHgj7Oioa5Hgtp3rMG8fZAMWw1Ct78sPb7rvRymmI2VPnE 5VKfFl4n87K1N65RkC6QVsv/9AnQNO3HxHPg84K8jSi0QJ3DXUWN25N4c2mKUCMnHAwryZ qodF2sJxgFIlDoduxz8K3oCwPEaEI9HzHO4jENqGnJRBqVTKYtFF9htK8/n9jKp0WAC+my jajG/f9pywd0JVcaf0Ej3GiFCeo9bB5F5WH1/vZFs1k1h8XrccZXU0uHB4f7Jg== 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=1721053024; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=E6hyfblkeISuomKjGAjGVSATaxveL75XubxU6h/HMf8=; b=caNpbLzx2XgJ4y1fi/ljRp1KSsSki93qIxWSCKSh89LlVIKfZJy617jnc1TssrsBFt3+8I x/ar8jKVtNeq8PTHHJPtnfIGPs+1ODHcTje9+dk4dlGPvNYi0WsZwLHHxFgQ+qo34qa6YE xLDMIiNwoXbzka2CSXJQ3HxIywdQSfm3OYjiEehYhExPGgErMthXS1iLVbcVq39Guwj3+r efOElaMBdXoQgCmdiUYLvluWLce0zhNQdzUY/F1CM61gm+dATT5UQMeXpFumNeFnF7B/Cg 12n591EXU47Svx+8d8QLVQeQMTj8N4FXjsG/PhN+kt/RssGeAE2QRzDXAgPi1w== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN45X3lGyzwF9; Mon, 15 Jul 2024 14:17:04 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FEH4Wa032033; Mon, 15 Jul 2024 14:17:04 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FEH4Bi032030; Mon, 15 Jul 2024 14:17:04 GMT (envelope-from git) Date: Mon, 15 Jul 2024 14:17:04 GMT Message-Id: <202407151417.46FEH4Bi032030@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 480cc750a2a8 - main - amd64 GENERIC: Drop hints for fdc0 and ppc0 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 480cc750a2a8f92d078803f15eecb1f8a084a1ea Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=480cc750a2a8f92d078803f15eecb1f8a084a1ea commit 480cc750a2a8f92d078803f15eecb1f8a084a1ea Author: John Baldwin AuthorDate: 2024-07-15 14:16:39 +0000 Commit: John Baldwin CommitDate: 2024-07-15 14:16:48 +0000 amd64 GENERIC: Drop hints for fdc0 and ppc0 Modern x86 systems do not ship with ISA floppy disk controllers or LPT ports. Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D45946 --- sys/amd64/conf/GENERIC.hints | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/sys/amd64/conf/GENERIC.hints b/sys/amd64/conf/GENERIC.hints index be3f59cd1950..7c2a3f28b9ce 100644 --- a/sys/amd64/conf/GENERIC.hints +++ b/sys/amd64/conf/GENERIC.hints @@ -1,11 +1,3 @@ -hint.fdc.0.at="isa" -hint.fdc.0.port="0x3F0" -hint.fdc.0.irq="6" -hint.fdc.0.drq="2" -hint.fd.0.at="fdc0" -hint.fd.0.drive="0" -hint.fd.1.at="fdc0" -hint.fd.1.drive="1" hint.atkbdc.0.at="isa" hint.atkbdc.0.port="0x060" hint.atkbd.0.at="atkbdc" @@ -21,8 +13,6 @@ hint.uart.0.irq="4" hint.uart.1.at="isa" hint.uart.1.port="0x2F8" hint.uart.1.irq="3" -hint.ppc.0.at="isa" -hint.ppc.0.irq="7" hint.atrtc.0.at="isa" hint.atrtc.0.port="0x70" hint.atrtc.0.irq="8" From nobody Mon Jul 15 15:23:51 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN5Zc0xdQz5R7ng; Mon, 15 Jul 2024 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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN5Zc0ktrz43W2; Mon, 15 Jul 2024 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=1721057032; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=EOBwQaFI+U5FsB8MalndvAy5MW5nWLNlZjVnqMLYkyI=; b=Rcdw7fNcHEvK6sn7XmX8sEsbHARUSqapyA+zrt+fj6ZTB5Nye4YIA1rtQGDshzz4jLef2k wsI1U3wn66QkEgKbtvAvxhr9SVMmiQ28HnJrd6h8x8fMmqLkAhXsTaGUqo0D3F8OwIYefe BBogEjefbgodlIYSP8R4Yiqq5i3VJJINNZN3GNNjudOoZDVUOuiI06g5RIXBpX99ksvlz1 iw0aDGHjhVSgNCYxD7hKKA4ucQ5E3fAst9FMYjmh7l8gYP3K6tEbcm+5tO/DrYAGL06U1v oRbwjotdnJPfgQhdCHm5sBPzzrJnyNVuNDp3/qCkj9os7Mf5vzIfoTcTaUpFqg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721057032; a=rsa-sha256; cv=none; b=uFTCWF1k1e9AfNpNvs2K32SJRaFLH+UsBximapFtQrXw3Bo9B1F8h6eapUN1zu5X5I+1NG IJhl5cprKOhLIzAnHvdWk2ZhebF3TS+BvHASw5JadYrcK+MKEPL4iOQ6IeKQRaxt7kKsWf n+a0HfziCfG2yOx2mMaV5cxHkb3NM2LvBYUh7TMw4fA1DKNzGo6/6Wbolu8vBaNi8iQdlT mtMlZIngPNuOQS6F2f8snqa0pL8JK/DMTg90D3IRauoxfDvXr0pkGvjTMkGz9QA/uxOxCm dXW8+1YkzvG3dFfe6OKYAnyrBt3jR0Xl1Mwc4si3s0mxRh7kCI6rUSxMDnZC5A== 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=1721057032; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=EOBwQaFI+U5FsB8MalndvAy5MW5nWLNlZjVnqMLYkyI=; b=DoWAOP9IaSlvakQ4mNbE//yyLkId8BMiffPPOIc4IOyBtzXiXWYDLo5z1mKDyuRPK6gjbW KW5wzqFN+3icXRKoHV1R00Lk80cIdk5BjbbXq2JRCKtFiBIHFHa4xV8lmPhPGzKth9d0b1 SgGiYPwXjxShdvvKxpcp2xwNpR5KilB8NvZruYUARtBHfWmlPynlwhu3bFmVauytVrf72T AefPglrsCz+mOCVoCbOekYSK+xfpHHAP9ZPEhJI4B7k5PGoCsI2ZHytf+GuVmlWqTbmraE y+sEigk45gwWSoT28GnxEtw2ABHEDGnfJsfDFYHuaU0Qy6FaLh6hHLMFtDkaQg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN5Zc0KmNzyB4; Mon, 15 Jul 2024 15:23:52 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FFNpZ0049014; Mon, 15 Jul 2024 15:23:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FFNpxb049011; Mon, 15 Jul 2024 15:23:51 GMT (envelope-from git) Date: Mon, 15 Jul 2024 15:23:51 GMT Message-Id: <202407151523.46FFNpxb049011@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Cy Schubert Subject: git: 51c8a9c1be57 - main - unbound: Remove backup file List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cy X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 51c8a9c1be57b6750e7c64e1379e8c33bd0f02c1 Auto-Submitted: auto-generated The branch main has been updated by cy: URL: https://cgit.FreeBSD.org/src/commit/?id=51c8a9c1be57b6750e7c64e1379e8c33bd0f02c1 commit 51c8a9c1be57b6750e7c64e1379e8c33bd0f02c1 Author: Cy Schubert AuthorDate: 2024-07-15 15:15:27 +0000 Commit: Cy Schubert CommitDate: 2024-07-15 15:15:27 +0000 unbound: Remove backup file Upstream unbound includes a backup configure file which is distributed in the upstream tarball. It must be created by their release process and not deleted prior to packaging the tarball. I've received two emails so far asking about it. Let's remove it so nobody else asks about it. MFC: 1 week --- contrib/unbound/configure~ | 26616 ------------------------------------------- 1 file changed, 26616 deletions(-) diff --git a/contrib/unbound/configure~ b/contrib/unbound/configure~ deleted file mode 100755 index d4a394eb9540..000000000000 --- a/contrib/unbound/configure~ +++ /dev/null @@ -1,26616 +0,0 @@ -#! /bin/sh -# Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.71 for unbound 1.20.0. -# -# Report bugs to . -# -# -# Copyright (C) 1992-1996, 1998-2017, 2020-2021 Free Software Foundation, -# Inc. -# -# -# This configure script is free software; the Free Software Foundation -# gives unlimited permission to copy, distribute and modify it. -## -------------------- ## -## M4sh Initialization. ## -## -------------------- ## - -# Be more Bourne compatible -DUALCASE=1; export DUALCASE # for MKS sh -as_nop=: -if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1 -then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else $as_nop - case `(set -o) 2>/dev/null` in #( - *posix*) : - set -o posix ;; #( - *) : - ;; -esac -fi - - - -# Reset variables that may have inherited troublesome values from -# the environment. - -# IFS needs to be set, to space, tab, and newline, in precisely that order. -# (If _AS_PATH_WALK were called with IFS unset, it would have the -# side effect of setting IFS to empty, thus disabling word splitting.) -# Quoting is to prevent editors from complaining about space-tab. -as_nl=' -' -export as_nl -IFS=" "" $as_nl" - -PS1='$ ' -PS2='> ' -PS4='+ ' - -# Ensure predictable behavior from utilities with locale-dependent output. -LC_ALL=C -export LC_ALL -LANGUAGE=C -export LANGUAGE - -# We cannot yet rely on "unset" to work, but we need these variables -# to be unset--not just set to an empty or harmless value--now, to -# avoid bugs in old shells (e.g. pre-3.0 UWIN ksh). This construct -# also avoids known problems related to "unset" and subshell syntax -# in other old shells (e.g. bash 2.01 and pdksh 5.2.14). -for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH -do eval test \${$as_var+y} \ - && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : -done - -# Ensure that fds 0, 1, and 2 are open. -if (exec 3>&0) 2>/dev/null; then :; else exec 0&1) 2>/dev/null; then :; else exec 1>/dev/null; fi -if (exec 3>&2) ; then :; else exec 2>/dev/null; fi - -# The user is always right. -if ${PATH_SEPARATOR+false} :; then - PATH_SEPARATOR=: - (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { - (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || - PATH_SEPARATOR=';' - } -fi - - -# Find who we are. Look in the path if we contain no directory separator. -as_myself= -case $0 in #(( - *[\\/]* ) as_myself=$0 ;; - *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - test -r "$as_dir$0" && as_myself=$as_dir$0 && break - done -IFS=$as_save_IFS - - ;; -esac -# We did not find ourselves, most probably we were run as `sh COMMAND' -# in which case we are not to be found in the path. -if test "x$as_myself" = x; then - as_myself=$0 -fi -if test ! -f "$as_myself"; then - printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 - exit 1 -fi - - -# Use a proper internal environment variable to ensure we don't fall - # into an infinite loop, continuously re-executing ourselves. - if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then - _as_can_reexec=no; export _as_can_reexec; - # We cannot yet assume a decent shell, so we have to provide a -# neutralization value for shells without unset; and this also -# works around shells that cannot unset nonexistent variables. -# Preserve -v and -x to the replacement shell. -BASH_ENV=/dev/null -ENV=/dev/null -(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV -case $- in # (((( - *v*x* | *x*v* ) as_opts=-vx ;; - *v* ) as_opts=-v ;; - *x* ) as_opts=-x ;; - * ) as_opts= ;; -esac -exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} -# Admittedly, this is quite paranoid, since all the known shells bail -# out after a failed `exec'. -printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2 -exit 255 - fi - # We don't want this to propagate to other subprocesses. - { _as_can_reexec=; unset _as_can_reexec;} -if test "x$CONFIG_SHELL" = x; then - as_bourne_compatible="as_nop=: -if test \${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1 -then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which - # is contrary to our usage. Disable this feature. - alias -g '\${1+\"\$@\"}'='\"\$@\"' - setopt NO_GLOB_SUBST -else \$as_nop - case \`(set -o) 2>/dev/null\` in #( - *posix*) : - set -o posix ;; #( - *) : - ;; -esac -fi -" - as_required="as_fn_return () { (exit \$1); } -as_fn_success () { as_fn_return 0; } -as_fn_failure () { as_fn_return 1; } -as_fn_ret_success () { return 0; } -as_fn_ret_failure () { return 1; } - -exitcode=0 -as_fn_success || { exitcode=1; echo as_fn_success failed.; } -as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } -as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } -as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } -if ( set x; as_fn_ret_success y && test x = \"\$1\" ) -then : - -else \$as_nop - exitcode=1; echo positional parameters were not saved. -fi -test x\$exitcode = x0 || exit 1 -blah=\$(echo \$(echo blah)) -test x\"\$blah\" = xblah || exit 1 -test -x / || exit 1" - as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO - as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO - eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && - test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 -test \$(( 1 + 1 )) = 2 || exit 1 - - test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || ( - ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' - ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO - ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO - PATH=/empty FPATH=/empty; export PATH FPATH - test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\ - || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1" - if (eval "$as_required") 2>/dev/null -then : - as_have_required=yes -else $as_nop - as_have_required=no -fi - if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null -then : - -else $as_nop - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -as_found=false -for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - as_found=: - case $as_dir in #( - /*) - for as_base in sh bash ksh sh5; do - # Try only shells that exist, to save several forks. - as_shell=$as_dir$as_base - if { test -f "$as_shell" || test -f "$as_shell.exe"; } && - as_run=a "$as_shell" -c "$as_bourne_compatible""$as_required" 2>/dev/null -then : - CONFIG_SHELL=$as_shell as_have_required=yes - if as_run=a "$as_shell" -c "$as_bourne_compatible""$as_suggested" 2>/dev/null -then : - break 2 -fi -fi - done;; - esac - as_found=false -done -IFS=$as_save_IFS -if $as_found -then : - -else $as_nop - if { test -f "$SHELL" || test -f "$SHELL.exe"; } && - as_run=a "$SHELL" -c "$as_bourne_compatible""$as_required" 2>/dev/null -then : - CONFIG_SHELL=$SHELL as_have_required=yes -fi -fi - - - if test "x$CONFIG_SHELL" != x -then : - export CONFIG_SHELL - # We cannot yet assume a decent shell, so we have to provide a -# neutralization value for shells without unset; and this also -# works around shells that cannot unset nonexistent variables. -# Preserve -v and -x to the replacement shell. -BASH_ENV=/dev/null -ENV=/dev/null -(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV -case $- in # (((( - *v*x* | *x*v* ) as_opts=-vx ;; - *v* ) as_opts=-v ;; - *x* ) as_opts=-x ;; - * ) as_opts= ;; -esac -exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} -# Admittedly, this is quite paranoid, since all the known shells bail -# out after a failed `exec'. -printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2 -exit 255 -fi - - if test x$as_have_required = xno -then : - printf "%s\n" "$0: This script requires a shell more modern than all" - printf "%s\n" "$0: the shells that I found on your system." - if test ${ZSH_VERSION+y} ; then - printf "%s\n" "$0: In particular, zsh $ZSH_VERSION has bugs and should" - printf "%s\n" "$0: be upgraded to zsh 4.3.4 or later." - else - printf "%s\n" "$0: Please tell bug-autoconf@gnu.org and -$0: unbound-bugs@nlnetlabs.nl or -$0: https://github.com/NLnetLabs/unbound/issues about your -$0: system, including any error possibly output before this -$0: message. Then install a modern shell, or manually run -$0: the script under such a shell if you do have one." - fi - exit 1 -fi -fi -fi -SHELL=${CONFIG_SHELL-/bin/sh} -export SHELL -# Unset more variables known to interfere with behavior of common tools. -CLICOLOR_FORCE= GREP_OPTIONS= -unset CLICOLOR_FORCE GREP_OPTIONS - -## --------------------- ## -## M4sh Shell Functions. ## -## --------------------- ## -# as_fn_unset VAR -# --------------- -# Portably unset VAR. -as_fn_unset () -{ - { eval $1=; unset $1;} -} -as_unset=as_fn_unset - - -# as_fn_set_status STATUS -# ----------------------- -# Set $? to STATUS, without forking. -as_fn_set_status () -{ - return $1 -} # as_fn_set_status - -# as_fn_exit STATUS -# ----------------- -# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. -as_fn_exit () -{ - set +e - as_fn_set_status $1 - exit $1 -} # as_fn_exit -# as_fn_nop -# --------- -# Do nothing but, unlike ":", preserve the value of $?. -as_fn_nop () -{ - return $? -} -as_nop=as_fn_nop - -# as_fn_mkdir_p -# ------------- -# Create "$as_dir" as a directory, including parents if necessary. -as_fn_mkdir_p () -{ - - case $as_dir in #( - -*) as_dir=./$as_dir;; - esac - test -d "$as_dir" || eval $as_mkdir_p || { - as_dirs= - while :; do - case $as_dir in #( - *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( - *) as_qdir=$as_dir;; - esac - as_dirs="'$as_qdir' $as_dirs" - as_dir=`$as_dirname -- "$as_dir" || -$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_dir" : 'X\(//\)[^/]' \| \ - X"$as_dir" : 'X\(//\)$' \| \ - X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || -printf "%s\n" X"$as_dir" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - test -d "$as_dir" && break - done - test -z "$as_dirs" || eval "mkdir $as_dirs" - } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" - - -} # as_fn_mkdir_p - -# as_fn_executable_p FILE -# ----------------------- -# Test if FILE is an executable regular file. -as_fn_executable_p () -{ - test -f "$1" && test -x "$1" -} # as_fn_executable_p -# as_fn_append VAR VALUE -# ---------------------- -# Append the text in VALUE to the end of the definition contained in VAR. Take -# advantage of any shell optimizations that allow amortized linear growth over -# repeated appends, instead of the typical quadratic growth present in naive -# implementations. -if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null -then : - eval 'as_fn_append () - { - eval $1+=\$2 - }' -else $as_nop - as_fn_append () - { - eval $1=\$$1\$2 - } -fi # as_fn_append - -# as_fn_arith ARG... -# ------------------ -# Perform arithmetic evaluation on the ARGs, and store the result in the -# global $as_val. Take advantage of shells that can avoid forks. The arguments -# must be portable across $(()) and expr. -if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null -then : - eval 'as_fn_arith () - { - as_val=$(( $* )) - }' -else $as_nop - as_fn_arith () - { - as_val=`expr "$@" || test $? -eq 1` - } -fi # as_fn_arith - -# as_fn_nop -# --------- -# Do nothing but, unlike ":", preserve the value of $?. -as_fn_nop () -{ - return $? -} -as_nop=as_fn_nop - -# as_fn_error STATUS ERROR [LINENO LOG_FD] -# ---------------------------------------- -# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are -# provided, also output the error to LOG_FD, referencing LINENO. Then exit the -# script with STATUS, using 1 if that was 0. -as_fn_error () -{ - as_status=$1; test $as_status -eq 0 && as_status=1 - if test "$4"; then - as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 - fi - printf "%s\n" "$as_me: error: $2" >&2 - as_fn_exit $as_status -} # as_fn_error - -if expr a : '\(a\)' >/dev/null 2>&1 && - test "X`expr 00001 : '.*\(...\)'`" = X001; then - as_expr=expr -else - as_expr=false -fi - -if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then - as_basename=basename -else - as_basename=false -fi - -if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then - as_dirname=dirname -else - as_dirname=false -fi - -as_me=`$as_basename -- "$0" || -$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ - X"$0" : 'X\(//\)$' \| \ - X"$0" : 'X\(/\)' \| . 2>/dev/null || -printf "%s\n" X/"$0" | - sed '/^.*\/\([^/][^/]*\)\/*$/{ - s//\1/ - q - } - /^X\/\(\/\/\)$/{ - s//\1/ - q - } - /^X\/\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - -# Avoid depending upon Character Ranges. -as_cr_letters='abcdefghijklmnopqrstuvwxyz' -as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' -as_cr_Letters=$as_cr_letters$as_cr_LETTERS -as_cr_digits='0123456789' -as_cr_alnum=$as_cr_Letters$as_cr_digits - - - as_lineno_1=$LINENO as_lineno_1a=$LINENO - as_lineno_2=$LINENO as_lineno_2a=$LINENO - eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && - test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { - # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) - sed -n ' - p - /[$]LINENO/= - ' <$as_myself | - sed ' - s/[$]LINENO.*/&-/ - t lineno - b - :lineno - N - :loop - s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ - t loop - s/-\n.*// - ' >$as_me.lineno && - chmod +x "$as_me.lineno" || - { printf "%s\n" "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } - - # If we had to re-execute with $CONFIG_SHELL, we're ensured to have - # already done that, so ensure we don't try to do so again and fall - # in an infinite loop. This has already happened in practice. - _as_can_reexec=no; export _as_can_reexec - # Don't try to exec as it changes $[0], causing all sort of problems - # (the dirname of $[0] is not the place where we might find the - # original and so on. Autoconf is especially sensitive to this). - . "./$as_me.lineno" - # Exit status is that of the last command. - exit -} - - -# Determine whether it's possible to make 'echo' print without a newline. -# These variables are no longer used directly by Autoconf, but are AC_SUBSTed -# for compatibility with existing Makefiles. -ECHO_C= ECHO_N= ECHO_T= -case `echo -n x` in #((((( --n*) - case `echo 'xy\c'` in - *c*) ECHO_T=' ';; # ECHO_T is single tab character. - xy) ECHO_C='\c';; - *) echo `echo ksh88 bug on AIX 6.1` > /dev/null - ECHO_T=' ';; - esac;; -*) - ECHO_N='-n';; -esac - -# For backward compatibility with old third-party macros, we provide -# the shell variables $as_echo and $as_echo_n. New code should use -# AS_ECHO(["message"]) and AS_ECHO_N(["message"]), respectively. -as_echo='printf %s\n' -as_echo_n='printf %s' - - -rm -f conf$$ conf$$.exe conf$$.file -if test -d conf$$.dir; then - rm -f conf$$.dir/conf$$.file -else - rm -f conf$$.dir - mkdir conf$$.dir 2>/dev/null -fi -if (echo >conf$$.file) 2>/dev/null; then - if ln -s conf$$.file conf$$ 2>/dev/null; then - as_ln_s='ln -s' - # ... but there are two gotchas: - # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. - # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -pR'. - ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || - as_ln_s='cp -pR' - elif ln conf$$.file conf$$ 2>/dev/null; then - as_ln_s=ln - else - as_ln_s='cp -pR' - fi -else - as_ln_s='cp -pR' -fi -rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file -rmdir conf$$.dir 2>/dev/null - -if mkdir -p . 2>/dev/null; then - as_mkdir_p='mkdir -p "$as_dir"' -else - test -d ./-p && rmdir ./-p - as_mkdir_p=false -fi - -as_test_x='test -x' -as_executable_p=as_fn_executable_p - -# Sed expression to map a string onto a valid CPP name. -as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" - -# Sed expression to map a string onto a valid variable name. -as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" - -SHELL=${CONFIG_SHELL-/bin/sh} - - -test -n "$DJDIR" || exec 7<&0 &1 - -# Name of the host. -# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, -# so uname gets run too. -ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` - -# -# Initializations. -# -ac_default_prefix=/usr/local -ac_clean_files= -ac_config_libobj_dir=. -LIBOBJS= -cross_compiling=no -subdirs= -MFLAGS= -MAKEFLAGS= - -# Identity of this package. -PACKAGE_NAME='unbound' -PACKAGE_TARNAME='unbound' -PACKAGE_VERSION='1.20.0' -PACKAGE_STRING='unbound 1.20.0' -PACKAGE_BUGREPORT='unbound-bugs@nlnetlabs.nl or https://github.com/NLnetLabs/unbound/issues' -PACKAGE_URL='' - -# Factoring default headers for most tests. -ac_includes_default="\ -#include -#ifdef HAVE_STDIO_H -# include -#endif -#ifdef HAVE_STDLIB_H -# include -#endif -#ifdef HAVE_STRING_H -# include -#endif -#ifdef HAVE_INTTYPES_H -# include -#endif -#ifdef HAVE_STDINT_H -# include -#endif -#ifdef HAVE_STRINGS_H -# include -#endif -#ifdef HAVE_SYS_TYPES_H -# include -#endif -#ifdef HAVE_SYS_STAT_H -# include -#endif -#ifdef HAVE_UNISTD_H -# include -#endif" - -ac_header_c_list= -ac_func_c_list= -ac_subst_vars='LTLIBOBJS -date -version -INSTALLTARGET -ALLTARGET -SOURCEFILE -SOURCEDETERMINE -IPSET_OBJ -IPSET_SRC -IPSECMOD_HEADER -IPSECMOD_OBJ -CACHEDB_OBJ -CACHEDB_SRC -DNSCRYPT_OBJ -DNSCRYPT_SRC -ENABLE_DNSCRYPT -ENABLE_DNSCRYPT_XCHACHA20 -DNSTAP_OBJ -DNSTAP_SRC -DNSTAP_SOCKET_TESTBIN -DNSTAP_SOCKET_PATH -opt_dnstap_socket_path -ENABLE_DNSTAP -PROTOBUFC_LIBS -PROTOBUFC_CFLAGS -PROTOC_C -UBSYMS -EXTRALINK -COMMON_OBJ_ALL_SYMBOLS -LIBOBJ_WITHOUT_CTIME -LIBOBJ_WITHOUT_CTIMEARC4 -WIN_CHECKCONF_OBJ_LINK -WIN_CONTROL_OBJ_LINK -WIN_UBANCHOR_OBJ_LINK -WIN_HOST_OBJ_LINK -WIN_DAEMON_OBJ_LINK -WIN_DAEMON_OBJ -WIN_DAEMON_SRC -WINAPPS -WINDRES -CHECKLOCK_OBJ -staticexe -PC_LIBEVENT_DEPENDENCY -UNBOUND_EVENT_UNINSTALL -UNBOUND_EVENT_INSTALL -SUBNET_HEADER -SUBNET_OBJ -PC_LIBBSD_DEPENDENCY -SSLLIB -HAVE_SSL -PC_CRYPTO_DEPENDENCY -CONFIG_DATE -GCC_DOCKER_LINTFLAGS -NETBSD_LINTFLAGS -PYUNBOUND_UNINSTALL -PYUNBOUND_INSTALL -PYUNBOUND_TARGET -PYUNBOUND_OBJ -WITH_PYUNBOUND -PYTHONMOD_UNINSTALL -PYTHONMOD_INSTALL -PYTHONMOD_HEADER -PYTHONMOD_OBJ -WITH_PYTHONMODULE -swig -SWIG_LIB -SWIG -PC_PY_DEPENDENCY -PYTHON_LIBS -PY_MAJOR_VERSION -PYTHON_SITE_PKG -PYTHON_LDFLAGS -PYTHON_CPPFLAGS -PYTHON -PYTHON_VERSION -DYNLIBMOD_EXTRALIBS -DYNLIBMOD_HEADER -DYNLIBMOD_OBJ -WITH_DYNLIBMODULE -PTHREAD_CFLAGS_ONLY -PTHREAD_CFLAGS -PTHREAD_LIBS -PTHREAD_CXX -PTHREAD_CC -ax_pthread_config -ASYNCLOOK_ALLOCCHECK_EXTRA_OBJ -SLDNS_ALLOCCHECK_EXTRA_OBJ -USE_SYSTEMD_FALSE -USE_SYSTEMD_TRUE -SYSTEMD_DAEMON_LIBS -SYSTEMD_DAEMON_CFLAGS -SYSTEMD_LIBS -SYSTEMD_CFLAGS -RUNTIME_PATH -LIBOBJS -CPP -PKG_CONFIG_LIBDIR -PKG_CONFIG_PATH -PKG_CONFIG -LT_SYS_LIBRARY_PATH -OTOOL64 -OTOOL -LIPO -NMEDIT -DSYMUTIL -MANIFEST_TOOL -AWK -RANLIB -ac_ct_AR -DLLTOOL -OBJDUMP -LN_S -NM -ac_ct_DUMPBIN -DUMPBIN -LD -FGREP -EGREP -SED -LIBTOOL -AR -host_os -host_vendor -host_cpu -host -build_os -build_vendor -build_cpu -build -libtool -STRIP -doxygen -YFLAGS -YACC -LEXLIB -LEX_OUTPUT_ROOT -LEX -debug_enabled -DEPFLAG -GREP -UNBOUND_USERNAME -UNBOUND_ROOTCERT_FILE -UNBOUND_ROOTKEY_FILE -UNBOUND_PIDFILE -UNBOUND_SHARE_DIR -UNBOUND_CHROOT_DIR -UNBOUND_RUN_DIR -ub_conf_dir -ub_conf_file -UNBOUND_LOCALSTATE_DIR -UNBOUND_SYSCONF_DIR -UNBOUND_SBIN_DIR -OBJEXT -EXEEXT -ac_ct_CC -CPPFLAGS -LDFLAGS -CFLAGS -CC -LIBUNBOUND_AGE -LIBUNBOUND_REVISION -LIBUNBOUND_CURRENT -UNBOUND_VERSION_MICRO -UNBOUND_VERSION_MINOR -UNBOUND_VERSION_MAJOR -target_alias -host_alias -build_alias -LIBS -ECHO_T -ECHO_N -ECHO_C -DEFS -mandir -localedir -libdir -psdir -pdfdir -dvidir -htmldir -infodir -docdir -oldincludedir -includedir -runstatedir -localstatedir -sharedstatedir -sysconfdir -datadir -datarootdir -libexecdir -sbindir -bindir -program_transform_name -prefix -exec_prefix -PACKAGE_URL -PACKAGE_BUGREPORT -PACKAGE_STRING -PACKAGE_VERSION -PACKAGE_TARNAME -PACKAGE_NAME -PATH_SEPARATOR -SHELL' -ac_subst_files='' -ac_user_opts=' -enable_option_checking -with_conf_file -with_run_dir -with_chroot_dir -with_share_dir -with_pidfile -with_rootkey_file -with_rootcert_file -with_username -enable_checking -enable_debug -enable_flto -enable_pie -enable_relro_now -enable_shared -enable_static -with_pic -enable_fast_install -with_aix_soname -with_gnu_ld -with_sysroot -enable_libtool_lock -enable_rpath -enable_largefile -enable_systemd -enable_alloc_checks -enable_alloc_lite -enable_alloc_nonregional -with_pthreads -with_solaris_threads -with_syslog_facility -with_dynlibmodule -with_pyunbound -with_pythonmodule -enable_swig_version_check -with_nss -with_nettle -with_ssl -with_libbsd -enable_sha1 -enable_sha2 -enable_subnet -enable_gost -enable_ecdsa -enable_dsa -with_deprecate_rsa_1024 -enable_ed25519 -enable_ed448 -enable_event_api -enable_tfo_client -enable_tfo_server -with_libevent -with_libexpat -with_libhiredis -with_libnghttp2 -enable_static_exe -enable_fully_static -enable_lock_checks -enable_allsymbols -enable_dnstap -with_dnstap_socket_path -with_protobuf_c -enable_dnscrypt -with_libsodium -enable_cachedb -enable_ipsecmod -enable_ipset -with_libmnl -enable_explicit_port_randomisation -enable_linux_ip_local_port_range -with_libunbound_only -' - ac_precious_vars='build_alias -host_alias -target_alias -CC -CFLAGS -LDFLAGS -LIBS -CPPFLAGS -YACC -YFLAGS -LT_SYS_LIBRARY_PATH -PKG_CONFIG -PKG_CONFIG_PATH -PKG_CONFIG_LIBDIR -CPP -SYSTEMD_CFLAGS -SYSTEMD_LIBS -SYSTEMD_DAEMON_CFLAGS -SYSTEMD_DAEMON_LIBS *** 25657 LINES SKIPPED *** From nobody Mon Jul 15 15:29:19 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN5hv6mqDz5R7sm; Mon, 15 Jul 2024 15: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN5hv6DG4z43f4; Mon, 15 Jul 2024 15: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=1721057359; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=iHFHzFVZQdO+KzWoQy25K9t2b0h49Pcp8XeimrR2HVI=; b=nWg5h9bIzui1wwPr8LZt6kexKXF1TXb5oPr1RLSJ0u9c8D9PpNwGFnIdGvFVcBcAiX9TIg mehTO4tCdOWe2wOqf517yCwffK1c0NUCKXkQEiit87cGWSHEVhVqfD2PZ1ejsAl5eKeAmM U1EUNVcOjk2HgtDn+AQSy2Jedx34G6k+X3ab+o0eDXfIpJlK3tI1dkWsdMJ0bMdVY/5Kvt eQXJpwKmF4ptDr/crtovb6H9Ta7GrJD8mFT4cnHG95UqBuLQsRYzbBt7qMJudtR8574gVo jX6GqiRweDzg+4UJATRR2OtKW7/15LyRTpKD4mUmIShe9GbOMw+DbbYO6jymXw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721057359; a=rsa-sha256; cv=none; b=ORXtAFzXmnaantrzUh79GEEUe6yIJGseAMqAbHIiIkK1TnvMM04oSIh2Rav24C7fg2nuz7 xWiu4jyF8d7pP6eSzOHZikhzlIyrNwL3PrYRTg0TmjTVNblJf+W8vBQuIbCsxj2Pg1Ch6V Xg7iQ+u6bK7xOPThuPijOtrRa4MyxpWbj0gdK4yhgBxAI8G6Xvvl6TYTMjKnXnTYyyZIFw UnHFuJ8Y13ZS/AQlylKOVF1ePTnORuZ8UR2IMLrhXmN0+2l9uaF0QaOpVWVsNAhfb3mAPC OQhhkBxpWBgJecmq3agDI3pHrGwUZYzof9o7LvlD8nr2t9WsWHhr761mlIU0Nw== 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=1721057359; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=iHFHzFVZQdO+KzWoQy25K9t2b0h49Pcp8XeimrR2HVI=; b=FL7GUzkhGMhTBZoZmOw7eDA7LyZNpIkj3mQYtTDoj8fuKMLD8cAgbQHARZyIcPRKu4Pv1e VDUgwvRmbw7fqTIS7BFpJ9Mr756gJQnZYv1Ef9RwfCJj/crTWlddUDcmpv3VGW4hrsyxRJ MRKIT6Jc+YMjP6pC3CgXdeRrhVr+SOAMvH8ZIgWbxmVOErJ4Rd9JyxkJz6kmL/YedARba1 8VuBJNvfZZ6DRE1Px59cwxVLYboUc5LNE6bvfUGV5NxC+pjuCEM99xn/WwyWvxlgdLXlt2 mtXmy0DQhvD3fGUDeqvWh5PwF9sYbDIKBuVzlY+9o0nJv51zw83ym3Qleoue8A== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN5hv5qSSzyB5; Mon, 15 Jul 2024 15:29:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FFTJrx049846; Mon, 15 Jul 2024 15:29:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FFTJuT049843; Mon, 15 Jul 2024 15:29:19 GMT (envelope-from git) Date: Mon, 15 Jul 2024 15:29:19 GMT Message-Id: <202407151529.46FFTJuT049843@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mark Johnston Subject: git: 6af3d5996244 - main - cxgbe: Flush transmitted packets more regularly in netmap mode List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 6af3d59962449c66688361598163dd174cc5fb2a Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=6af3d59962449c66688361598163dd174cc5fb2a commit 6af3d59962449c66688361598163dd174cc5fb2a Author: Mark Johnston AuthorDate: 2024-05-21 19:18:32 +0000 Commit: Mark Johnston CommitDate: 2024-07-15 15:26:59 +0000 cxgbe: Flush transmitted packets more regularly in netmap mode Previously, when transmitting short runs of packets via cxgbe_nm_tx(), we would wait until a large number of packets were buffered before scheduling a task to clean transmit buffers. Obtained from: np --- sys/dev/cxgbe/t4_netmap.c | 25 ++++++++++++------------- 1 file changed, 12 insertions(+), 13 deletions(-) diff --git a/sys/dev/cxgbe/t4_netmap.c b/sys/dev/cxgbe/t4_netmap.c index 0377f65acc3e..e53fb5054316 100644 --- a/sys/dev/cxgbe/t4_netmap.c +++ b/sys/dev/cxgbe/t4_netmap.c @@ -1025,29 +1025,28 @@ cxgbe_nm_tx(struct adapter *sc, struct sge_nm_txq *nm_txq, nm_txq->pidx = 0; } - if (npkt == 0 && npkt_remaining == 0) { + if (npkt + npkt_remaining == 0) { /* All done. */ - if (lazy_tx_credit_flush == 0) { + if (lazy_tx_credit_flush == 0 || + NMIDXDIFF(nm_txq, equiqidx) >= nm_txq->sidx / 2) { wr->equiq_to_len16 |= htobe32(F_FW_WR_EQUEQ | F_FW_WR_EQUIQ); nm_txq->equeqidx = nm_txq->pidx; nm_txq->equiqidx = nm_txq->pidx; + } else if (NMIDXDIFF(nm_txq, equeqidx) >= 64) { + wr->equiq_to_len16 |= htobe32(F_FW_WR_EQUEQ); + nm_txq->equeqidx = nm_txq->pidx; } ring_nm_txq_db(sc, nm_txq); return; } - - if (NMIDXDIFF(nm_txq, equiqidx) >= nm_txq->sidx / 2) { - wr->equiq_to_len16 |= htobe32(F_FW_WR_EQUEQ | - F_FW_WR_EQUIQ); - nm_txq->equeqidx = nm_txq->pidx; - nm_txq->equiqidx = nm_txq->pidx; - } else if (NMIDXDIFF(nm_txq, equeqidx) >= 64) { - wr->equiq_to_len16 |= htobe32(F_FW_WR_EQUEQ); - nm_txq->equeqidx = nm_txq->pidx; - } - if (NMIDXDIFF(nm_txq, dbidx) >= 2 * SGE_MAX_WR_NDESC) + if (NMIDXDIFF(nm_txq, dbidx) >= 2 * SGE_MAX_WR_NDESC) { + if (NMIDXDIFF(nm_txq, equeqidx) >= 64) { + wr->equiq_to_len16 |= htobe32(F_FW_WR_EQUEQ); + nm_txq->equeqidx = nm_txq->pidx; + } ring_nm_txq_db(sc, nm_txq); + } } /* Will get called again. */ From nobody Mon Jul 15 16:22:43 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN6tY02gsz5RDt5; Mon, 15 Jul 2024 16:22:45 +0000 (UTC) (envelope-from jhb@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 "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN6tX6KRfz48jV; Mon, 15 Jul 2024 16:22:44 +0000 (UTC) (envelope-from jhb@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721060564; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=pqhiN+bjpxuJlhc9YcJ1i6l5UhZ6AHlgTFyODDS2Gqc=; b=XrgP8h3hu9Gw5iI5Uv7bc4VnokjH5FI09YwjmZ93kdl0DBglCBG7ZoQq/WJDAtKQDAcnYb a/YP2DotmZbrhi3rM5NieX4/jhd7xnUFGjh3qUt8GPM6FGGu3vLKapYR0UQsD73iBe25tF Kt2/ZgCiiA+r/SJSvRNbD5TtVBJfyvgb6IMbyS+GAuVtK2I8UF6V9uqS9LHyHRxEg7C7pk 0TWxmSN97x18EmZ8xwX8+s1wJdW49xs3SajbvOsbt0LVQ126VxJB/QInaq1avh6sM1nEWL SjLpIwgUYckws2XYbG73/dFjiqQHu3SPzolBr/watrX4divt05jI+bE+FGC3sw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721060564; a=rsa-sha256; cv=none; b=G/O+kyi+T7fiVPJ4iyS5KMevYjkpBosY4GU36hiBOHzPYULSl32xww1mdiDhVvFd81qbGs zEKu52r2nh261/czIk093wuwP+vgu+HWedQ61IMbhSqbAon0WVreW6UNWpsxFlznbsoBRb pf/5QSPyfdTI+3CuRW6vSPUuNHooK4S/XhLPg8kc7AhRDOGS4TjJsQg+ul0Nz/asyZajP8 DeImp3Qa8l5vy+FeEKq/TXwm+6Xl8sn1AXe48rEMW2XT5FSLD3bzxH/xFnlrrEqtrUR4Yw j9i31sygIeZ6c1rs1tIKPtERJeSiPRSo/pkxYTLHvt4GLjrlyyO42lNCGeMnFg== 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=1721060564; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=pqhiN+bjpxuJlhc9YcJ1i6l5UhZ6AHlgTFyODDS2Gqc=; b=f94pD1pOcQ+Yu6Da5P4HuhSSDNzsFKC6jyQXrH9ELIPOeVOhQ78az1xIqj2+1IzlKR4Umd 6KbWRbaHkVCtIx7lbrprQ4kUOxo5BBuunI3wf15Pmgg5T3Q7V74PXxMEllLRSFzaFf8j28 WiLKGQLcRv0Zx1ceCabR1k7e3uq47Fgh8zDXQBPt/Qy/iJfOotjtVnfWAnn4UX9dpeAcBt /5KGMq3tt4HjVJQxhFuhEdaxkXknaV+zwVE2WmWnKNRaqXkxxLZGR8/O7e/HKva74b3ZQd gFPOqIuCfNjZ5KBa2db/SYVZje9vJTSj0ohabfefbMw3VWceewq7Mq1WRTNScw== Received: from [IPV6:2601:5c0:4200:b830:d8c4:b767:290b:ce25] (unknown [IPv6:2601:5c0:4200:b830:d8c4:b767:290b:ce25]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: jhb) by smtp.freebsd.org (Postfix) with ESMTPSA id 4WN6tX4WcTz1N41; Mon, 15 Jul 2024 16:22:44 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Message-ID: <81cfe7ad-cbee-4122-abef-e47ce2b34f05@FreeBSD.org> Date: Mon, 15 Jul 2024 12:22:43 -0400 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: git: 87ee63bac69d - main - locks: add a runtime check for missing turnstile Content-Language: en-US To: Mateusz Guzik , src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org References: <202407111107.46BB7uSb007077@gitrepo.freebsd.org> From: John Baldwin In-Reply-To: <202407111107.46BB7uSb007077@gitrepo.freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 7/11/24 07:07, Mateusz Guzik wrote: > The branch main has been updated by mjg: > > URL: https://cgit.FreeBSD.org/src/commit/?id=87ee63bac69dc49291f55590b8baa57cad6c7d85 > > commit 87ee63bac69dc49291f55590b8baa57cad6c7d85 > Author: Mateusz Guzik > AuthorDate: 2024-07-11 00:17:27 +0000 > Commit: Mateusz Guzik > CommitDate: 2024-07-11 11:06:52 +0000 > > locks: add a runtime check for missing turnstile > > There are sometimes bugs which result in the unlock fast path failing, > which in turns causes a not-helpful crash report when dereferencing a > NULL turnstile. Help debugging such cases by pointing out what happened > along with some debug. > > Sponsored by: Rubicon Communications, LLC ("Netgate") > --- > sys/kern/kern_mutex.c | 4 +++- > sys/kern/kern_rwlock.c | 16 ++++++++++++---- > 2 files changed, 15 insertions(+), 5 deletions(-) > > diff --git a/sys/kern/kern_mutex.c b/sys/kern/kern_mutex.c > index 90361b23c09a..0fa624cc4bb1 100644 > --- a/sys/kern/kern_mutex.c > +++ b/sys/kern/kern_mutex.c > @@ -1053,7 +1053,9 @@ __mtx_unlock_sleep(volatile uintptr_t *c, uintptr_t v) > turnstile_chain_lock(&m->lock_object); > _mtx_release_lock_quick(m); > ts = turnstile_lookup(&m->lock_object); > - MPASS(ts != NULL); > + if (__predict_false(ts == NULL)) { > + panic("got NULL turnstile on mutex %p v %zx", m, v); > + } Hmm, this is just an expanded KASSERT() but always on rather than conditional on INVARIANTS? Do you have examples of the type of bugs that cause this? (Is it unlocking a freed mutex or the like?) We generally hide all these types of checks under INVARIANTS rather than shipping them in release kernels. -- John Baldwin From nobody Mon Jul 15 17:43:43 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN8h02x87z5RMrZ; Mon, 15 Jul 2024 17:43: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN8h016vJz4J5l; Mon, 15 Jul 2024 17:43:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721065424; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=xaQhgrzg/ocb5pXKRVxhzYQc665x/8dGTPJc8Ser2YY=; b=P3MJwMbnL8oGU/NjdnHzwNiUejdWtVdZpb8NsvujkHscLA2SBarGoz5AojiFzFa77KbaAl /RScpqJrpzyOinv9KFoo5YhiOi+A8lKmbehJZU9MYpbt2XGWEIVQxIjnRaKqo1/ZxSEKOj 9y+2N5lZdDK53Lvn044kcgLat2//tluaB4MlhNosbTOv4jqNtAXQ1UJ8/mtNl71vJZH8IB O0NUAwuiT9g1cTVN7byJn28Q4SGKkZ4uZmNIQg4p3Iv6SMWZANiP7x6hJ8TcsUBGE9s6OQ 7tn/sMHt1lWlKCgSunnnELG9US4H4VqUPWMKFyfA+uAkTnVlbNPCbEnJ4XGNng== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721065424; a=rsa-sha256; cv=none; b=bQUEF9HEIGQUqubHULRvYV+3SHIu1KhnhoubgCMw19O/pPaJOonWCnimW2HPYtHcjWcGrQ HHuNasQXChDz+7lgL8rOhTYbH/AisB3H1P6WcMQD8EFttNcuIVrKmDZ/H/G2q0VE36Gj0L /jVydpZLEPAyklv3WIQ1lOfqMv+PT5bmsWlpWkbfEjgx5FwrQ6i8lTzcEPFWlwNPHHXr4w EHhHJzijHKaVwITnCWvomSWXwXAGog8JAo9oKnTlU8QJQwwJsRgES+aKeQJu5H9pluWwhe zYsvIRVviY3ypcfApTny2Jk8ZMyHI5dMExLw3mxg80uk2MJsvyEkCksainMeTA== 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=1721065424; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=xaQhgrzg/ocb5pXKRVxhzYQc665x/8dGTPJc8Ser2YY=; b=sL5q2C4KB20vNbDpP/4qotAMObMVno+stL1c3Iy4A7WGngsJY+5joDS/jM1UNPnDVZSuHy A+2f6W67/SdX7Yda0rCSzfPZtW5JmlDcjX0GsTlPqVZmQsAeaqLTvlIVvXrq3G6zZCQlvu InaSgniL1AATFUYCbIvLgVLAndZ9tGdd4Y8kUqtBunp3SH7qAOk4LMfC2vyG0BclL6NCnP CwXdpohJOMPCc9QQXx+haKEDbP45bI4FWStoXac/Rej52eg4ZpydCEAwaBb1WS4OU+LWaX BUegGRQBbC/LqzkPidZT+oyiyoltD0KZ3gIfj0XQzG8/xd2c3rLc1nbGgkphKA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WN8h00kJJz12js; Mon, 15 Jul 2024 17:43:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FHhin5086135; Mon, 15 Jul 2024 17:43:44 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FHhhaS086132; Mon, 15 Jul 2024 17:43:43 GMT (envelope-from git) Date: Mon, 15 Jul 2024 17:43:43 GMT Message-Id: <202407151743.46FHhhaS086132@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Michael Osipov Subject: git: ac6dc5cde729 - main - dhclient: Ignore SIP servers DHCP option defined in RFC 3361 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: michaelo X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: ac6dc5cde729a602252a0b80f82424861d2eb7b5 Auto-Submitted: auto-generated The branch main has been updated by michaelo: URL: https://cgit.FreeBSD.org/src/commit/?id=ac6dc5cde729a602252a0b80f82424861d2eb7b5 commit ac6dc5cde729a602252a0b80f82424861d2eb7b5 Author: Yuichiro NAITO AuthorDate: 2024-07-04 07:57:02 +0000 Commit: Michael Osipov CommitDate: 2024-07-15 17:42:17 +0000 dhclient: Ignore SIP servers DHCP option defined in RFC 3361 Ignore SIP servers dhcp option to shut up the warning message. This option is defined in the RFC 3361 and sent from NSD-G1000T router. PR: 280119 Reviewed by: jrm (mentor), brooks MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D45873 --- sbin/dhclient/dhclient.c | 1 + sbin/dhclient/dhcp.h | 1 + 2 files changed, 2 insertions(+) diff --git a/sbin/dhclient/dhclient.c b/sbin/dhclient/dhclient.c index 8179a5c34209..62e55eb4d01f 100644 --- a/sbin/dhclient/dhclient.c +++ b/sbin/dhclient/dhclient.c @@ -2618,6 +2618,7 @@ check_option(struct client_lease *l, int option) case DHO_BOOTFILE_NAME: case DHO_DHCP_USER_CLASS_ID: case DHO_URL: + case DHO_SIP_SERVERS: case DHO_END: return (1); case DHO_CLASSLESS_ROUTES: diff --git a/sbin/dhclient/dhcp.h b/sbin/dhclient/dhcp.h index 300deb464238..99b69613934f 100644 --- a/sbin/dhclient/dhcp.h +++ b/sbin/dhclient/dhcp.h @@ -172,6 +172,7 @@ struct dhcp_packet { #define DHO_DHCP_USER_CLASS_ID 77 #define DHO_URL 114 #define DHO_DOMAIN_SEARCH 119 +#define DHO_SIP_SERVERS 120 #define DHO_CLASSLESS_ROUTES 121 #define DHO_END 255 From nobody Mon Jul 15 17:59:42 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN92j4gTCz5RNWv; Mon, 15 Jul 2024 17:59:57 +0000 (UTC) (envelope-from mjguzik@gmail.com) Received: from mail-ej1-x62d.google.com (mail-ej1-x62d.google.com [IPv6:2a00:1450:4864:20::62d]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "WR4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN92j2rMLz4KYq; Mon, 15 Jul 2024 17:59:57 +0000 (UTC) (envelope-from mjguzik@gmail.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-ej1-x62d.google.com with SMTP id a640c23a62f3a-a77ec5d3b0dso581569666b.0; Mon, 15 Jul 2024 10:59:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1721066396; x=1721671196; darn=freebsd.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=2GRnwiHQMUEEXdUbRZ6GSckdat1ZukdaXXDsjKRGehY=; b=CM0NkkQEA01Jko9PHZn8cfu2LTpDRMcGy3zicXjukVFNq/nOXUNjLI8Xwk97MVrhSl yO+RaHex6/rBZxuJhofBmzdKdk7eNnigJDoTrOW2qIqtxGJQ3Ui0A5nk3T8ltY503Zhk 2rfcHS78r6w+ZC+JJfJRLI5OOh5/ZW8/+RjXQHTghoLy2KRVtltvR0WBlpi9HUHJFu7g fqYZAl2aIiQMHWqxC242+FkwxNLES2i8ep/CRAzFQCvQpj0mDAzgJEn8hPee1dS3zPuO Pbs2vO7pq2xF8PbBseMFybL6bTHquUtkmZbFDsDzOo0t5HpT7oSphQHD6bmXF1iCW2aI bJDQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721066396; x=1721671196; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=2GRnwiHQMUEEXdUbRZ6GSckdat1ZukdaXXDsjKRGehY=; b=DXBHa7G8i9XEoosep2afNU3oIWpNVwJ9I/KO+q215JmaHDdZwVfLh+1i7K/LrSLl/p Fzaf4GnkmuGcTj3a0vHTM1oXTj+r2B2ZFbTTX+wyntUDVIJ9A5mwCQn+qtKnVHbOaxaZ VSznogkVOIs07BE4wisWRumKWsrhaReW1s4ho7L1c5HM8mfhSyuP3gnVir18/TAisdjW dbdmaUoO2dSETdS81Ei3ccgZu91/HuYjtlU3Pa7bCwlhEnUc1eltz5LZURnSDTeZuuCE Nhqq2tXa1VptS80XUAIWnDXQjhHc26P01Nz8ummg74dcIqjNyVGffONJeUh5/VrnNYip 4Ejg== X-Forwarded-Encrypted: i=1; AJvYcCUCaoLnngoRNey19kkFGCX0AzgRB4o0t9AL1AFJWcjHCFvJWNDFKBoNq7Elnb1bGRhdStMbEJhnl8DZ+ZLvi0S58kL+LaZU+cXBIjPR3hKEjrhZh5A3iB9YVUpX8P7Ktnx5EsrHXzJhua2ZAHuQFKz9NNne5E0uXGViWJyI56EEYaDwrABq1KNr5Fu3jGY= X-Gm-Message-State: AOJu0YwZTUK5FdMvonNYJpyNml9bFzyskqySLEhRWpEPzIBxyxULCR19 d2aedS0pyOldrfIVvi9H1ofROWN8rMEXShFc34FX7yZNBjXwfvhhlYf5Jw3jEIBzUkNSIdRlTQo oqahdQunSiKcV/GQLmvXoD1BIDMvoHzfLSpM= X-Google-Smtp-Source: AGHT+IEtn0Eq+xGfJrUcd5FYZbJ7sEI8HGUUtkw0CCzYkxWyRnhOY72GznVYRhDu0tpU37RyMMKvQWaRgGoGMnWSOHI= X-Received: by 2002:a17:906:d69:b0:a75:3c2d:cd90 with SMTP id a640c23a62f3a-a79e6afae3dmr34639766b.65.1721066395563; Mon, 15 Jul 2024 10:59:55 -0700 (PDT) List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 References: <202407111107.46BB7uSb007077@gitrepo.freebsd.org> <81cfe7ad-cbee-4122-abef-e47ce2b34f05@FreeBSD.org> In-Reply-To: <81cfe7ad-cbee-4122-abef-e47ce2b34f05@FreeBSD.org> From: Mateusz Guzik Date: Mon, 15 Jul 2024 19:59:42 +0200 Message-ID: Subject: Re: git: 87ee63bac69d - main - locks: add a runtime check for missing turnstile To: John Baldwin Cc: Mateusz Guzik , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable 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:15169, ipnet:2a00:1450::/32, country:US] X-Rspamd-Queue-Id: 4WN92j2rMLz4KYq On Mon, Jul 15, 2024 at 6:22=E2=80=AFPM John Baldwin wrot= e: > > On 7/11/24 07:07, Mateusz Guzik wrote: > > The branch main has been updated by mjg: > > > > URL: https://cgit.FreeBSD.org/src/commit/?id=3D87ee63bac69dc49291f55590= b8baa57cad6c7d85 > > > > commit 87ee63bac69dc49291f55590b8baa57cad6c7d85 > > Author: Mateusz Guzik > > AuthorDate: 2024-07-11 00:17:27 +0000 > > Commit: Mateusz Guzik > > CommitDate: 2024-07-11 11:06:52 +0000 > > > > locks: add a runtime check for missing turnstile > > > > There are sometimes bugs which result in the unlock fast path fail= ing, > > which in turns causes a not-helpful crash report when dereferencin= g a > > NULL turnstile. Help debugging such cases by pointing out what hap= pened > > along with some debug. > > > > Sponsored by: Rubicon Communications, LLC ("Netgate") > > --- > > sys/kern/kern_mutex.c | 4 +++- > > sys/kern/kern_rwlock.c | 16 ++++++++++++---- > > 2 files changed, 15 insertions(+), 5 deletions(-) > > > > diff --git a/sys/kern/kern_mutex.c b/sys/kern/kern_mutex.c > > index 90361b23c09a..0fa624cc4bb1 100644 > > --- a/sys/kern/kern_mutex.c > > +++ b/sys/kern/kern_mutex.c > > @@ -1053,7 +1053,9 @@ __mtx_unlock_sleep(volatile uintptr_t *c, uintptr= _t v) > > turnstile_chain_lock(&m->lock_object); > > _mtx_release_lock_quick(m); > > ts =3D turnstile_lookup(&m->lock_object); > > - MPASS(ts !=3D NULL); > > + if (__predict_false(ts =3D=3D NULL)) { > > + panic("got NULL turnstile on mutex %p v %zx", m, v); > > + } > > Hmm, this is just an expanded KASSERT() but always on rather than conditi= onal on INVARIANTS? > > Do you have examples of the type of bugs that cause this? (Is it unlocki= ng a freed mutex > or the like?) We generally hide all these types of checks under INVARIAN= TS rather than > shipping them in release kernels. > Use-after-free, overflow, underflow, bitflip or what have you all can fail the fast path. Once that happens and the kernel crashes with a null pointer deref, here is a crash at netgate which prodded this: calltrap() at calltrap+0x8/frame 0xfffffe0106720920 --- trap 0xc, rip =3D 0xffffffff80d5ab70, rsp =3D 0xfffffe01067209f0, rbp =3D 0xfffffe0106720a00 --- turnstile_broadcast() at turnstile_broadcast+0x40/frame 0xfffffe0106720a00 __rw_wunlock_hard() at __rw_wunlock_hard+0x9e/frame 0xfffffe0106720a30 nd6_resolve_slow() at nd6_resolve_slow+0x2d7/frame 0xfffffe0106720aa0 nd6_resolve() at nd6_resolve+0x125/frame 0xfffffe0106720b10 ether_output() at ether_output+0x4e7/frame 0xfffffe0106720ba0 ip_output_send() at ip_output_send+0xdc/frame 0xfffffe0106720be0 ip_output() at ip_output+0x1295/frame 0xfffffe0106720ce0 ip_forward() at ip_forward+0x3c2/frame 0xfffffe0106720d90 ip_input() at ip_input+0x705/frame 0xfffffe0106720df0 swi_net() at swi_net+0x138/frame 0xfffffe0106720e60 ithread_loop() at ithread_loop+0x257/frame 0xfffffe0106720ef0 fork_exit() at fork_exit+0x7f/frame 0xfffffe0106720f30 fork_trampoline() at fork_trampoline+0xe/frame 0xfffffe0106720f30 --- trap 0, rip =3D 0, rsp =3D 0, rbp =3D 0 --- Neither the register dump nor anything in the backtrace indicate what happe= ned. Since the kernel is going down anyway, one may as well get some debug from = it. --=20 Mateusz Guzik From nobody Mon Jul 15 18:21:54 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN9X334rsz5RQJy; Mon, 15 Jul 2024 18:21:55 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN9X32dS1z4MPH; Mon, 15 Jul 2024 18:21:55 +0000 (UTC) (envelope-from jhb@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721067715; 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=jzuUbGVycZXQs86mrYXN32yYlJIWAprhEjXNy8UvMmc=; b=sUC/DiL1Kk46R4wN35AZPnBg7/ZPtjiCc72kSR7pZLcHbySLGe2O+MA6mWawV62JcVB07P pYAXst9cAxKt8ILiaJCZhE//zt3KI30LggCo/W5QDZyLg75XqatCW6cINktWT8+q6Lmtk9 9/aLzW8F0Kp7rt4DYF10NJgn099rJBzWQjczAoc4QU0AH4DmTLCJzrLjjjNwXfIvdgdJ5j wvo9YxgdPRtYczu2Cq87fhIeIPtjccIGKrQuAKy+tQy3O5PpaWqld4yciO+aFr2mc2PN2U AP/o7gpzOrCJp8n3l78s24cK0iWhfabhCEWGgfvty7rTptmZ8cUs76SDxN3Wfw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721067715; a=rsa-sha256; cv=none; b=xT+ll4n4I+JE7l1pIioSsk8tIEw5Y6pGpcvsF3DUgvpvBtgafPyJeIGX2p/xB5Ea+W4OJL QfBNVwQjR/4PNumQSFH2OnDRVzof5Lt4teo4fDZ7aQoErEXEU+WbEb8sRMASM5iH86CpmK lVS0Vayxoavlj+Vs1lxQHIroX1bE3Az9FQYAYcu04zCZLlIliaqewei7a0hZzyrQrnaLSq Pzf3FHviPZ8izNXRWdqfkcwD1FMCG76P5lgszzoy5nyzqb4VZv9sJLpYeB2JTgQL/8PBpu 8WUd6brlRL1h9ZeUeoeZzjPPI0puhdV7KjBpS9hux+dtFdUweSuxbPkIyJPF3Q== 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=1721067715; 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=jzuUbGVycZXQs86mrYXN32yYlJIWAprhEjXNy8UvMmc=; b=kKnYGli4ACaB2fMJ3t+PhMGFx+U98xwjtP+k0drbbZ7vg+hodf/HYiDnChQXMi70q8N1+R al9etB29EEsp3bcdCQlypuAcSsTQvI2mjmDuqGH/G+yp749pmW7MbUo3xneKh+JRjFIzw1 d3eCC6CIEpInRXeswtOoCmeow8u4P/u9QsnMrNGLMz+mPuem1ZMTm1o3Z3wT4SLTW2RYqN Xwc9yxQ6O/mlEDvFIgyFPotpZgSRL5bmCTzyErns31YjIh1eiukmk9p/RMdQgXWhG3zdhn LIz0yfQsCKhZiae6dV3+GBfupSKBwk4jsFmL0P6M3O/nLZsgqpzoHTgspJ3qLA== Received: from [IPV6:2601:5c0:4200:b830:d8c4:b767:290b:ce25] (unknown [IPv6:2601:5c0:4200:b830:d8c4:b767:290b:ce25]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: jhb) by smtp.freebsd.org (Postfix) with ESMTPSA id 4WN9X30cC5z1Q9m; Mon, 15 Jul 2024 18:21:55 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Message-ID: Date: Mon, 15 Jul 2024 14:21:54 -0400 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: git: 87ee63bac69d - main - locks: add a runtime check for missing turnstile Content-Language: en-US To: Mateusz Guzik Cc: Mateusz Guzik , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org References: <202407111107.46BB7uSb007077@gitrepo.freebsd.org> <81cfe7ad-cbee-4122-abef-e47ce2b34f05@FreeBSD.org> From: John Baldwin In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit On 7/15/24 13:59, Mateusz Guzik wrote: > On Mon, Jul 15, 2024 at 6:22ā€ÆPM John Baldwin wrote: >> >> On 7/11/24 07:07, Mateusz Guzik wrote: >>> The branch main has been updated by mjg: >>> >>> URL: https://cgit.FreeBSD.org/src/commit/?id=87ee63bac69dc49291f55590b8baa57cad6c7d85 >>> >>> commit 87ee63bac69dc49291f55590b8baa57cad6c7d85 >>> Author: Mateusz Guzik >>> AuthorDate: 2024-07-11 00:17:27 +0000 >>> Commit: Mateusz Guzik >>> CommitDate: 2024-07-11 11:06:52 +0000 >>> >>> locks: add a runtime check for missing turnstile >>> >>> There are sometimes bugs which result in the unlock fast path failing, >>> which in turns causes a not-helpful crash report when dereferencing a >>> NULL turnstile. Help debugging such cases by pointing out what happened >>> along with some debug. >>> >>> Sponsored by: Rubicon Communications, LLC ("Netgate") >>> --- >>> sys/kern/kern_mutex.c | 4 +++- >>> sys/kern/kern_rwlock.c | 16 ++++++++++++---- >>> 2 files changed, 15 insertions(+), 5 deletions(-) >>> >>> diff --git a/sys/kern/kern_mutex.c b/sys/kern/kern_mutex.c >>> index 90361b23c09a..0fa624cc4bb1 100644 >>> --- a/sys/kern/kern_mutex.c >>> +++ b/sys/kern/kern_mutex.c >>> @@ -1053,7 +1053,9 @@ __mtx_unlock_sleep(volatile uintptr_t *c, uintptr_t v) >>> turnstile_chain_lock(&m->lock_object); >>> _mtx_release_lock_quick(m); >>> ts = turnstile_lookup(&m->lock_object); >>> - MPASS(ts != NULL); >>> + if (__predict_false(ts == NULL)) { >>> + panic("got NULL turnstile on mutex %p v %zx", m, v); >>> + } >> >> Hmm, this is just an expanded KASSERT() but always on rather than conditional on INVARIANTS? >> >> Do you have examples of the type of bugs that cause this? (Is it unlocking a freed mutex >> or the like?) We generally hide all these types of checks under INVARIANTS rather than >> shipping them in release kernels. >> > > Use-after-free, overflow, underflow, bitflip or what have you all can > fail the fast path. > > Once that happens and the kernel crashes with a null pointer deref, > here is a crash at netgate which prodded this: > calltrap() at calltrap+0x8/frame 0xfffffe0106720920 > --- trap 0xc, rip = 0xffffffff80d5ab70, rsp = 0xfffffe01067209f0, rbp > = 0xfffffe0106720a00 --- > turnstile_broadcast() at turnstile_broadcast+0x40/frame 0xfffffe0106720a00 > __rw_wunlock_hard() at __rw_wunlock_hard+0x9e/frame 0xfffffe0106720a30 > nd6_resolve_slow() at nd6_resolve_slow+0x2d7/frame 0xfffffe0106720aa0 > nd6_resolve() at nd6_resolve+0x125/frame 0xfffffe0106720b10 > ether_output() at ether_output+0x4e7/frame 0xfffffe0106720ba0 > ip_output_send() at ip_output_send+0xdc/frame 0xfffffe0106720be0 > ip_output() at ip_output+0x1295/frame 0xfffffe0106720ce0 > ip_forward() at ip_forward+0x3c2/frame 0xfffffe0106720d90 > ip_input() at ip_input+0x705/frame 0xfffffe0106720df0 > swi_net() at swi_net+0x138/frame 0xfffffe0106720e60 > ithread_loop() at ithread_loop+0x257/frame 0xfffffe0106720ef0 > fork_exit() at fork_exit+0x7f/frame 0xfffffe0106720f30 > fork_trampoline() at fork_trampoline+0xe/frame 0xfffffe0106720f30 > --- trap 0, rip = 0, rsp = 0, rbp = 0 --- > > Neither the register dump nor anything in the backtrace indicate what happened. > > Since the kernel is going down anyway, one may as well get some debug from it. If you don't mind the extra branches for sanity checks, why not just run with INVARIANTS? That is, what makes these particular assertions different from other assertions such that they should be on unconditionally? The last line below applies to pretty much every other assertion in the tree. -- John Baldwin From nobody Mon Jul 15 18:23:48 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN9ZT6fThz5RQSH for ; Mon, 15 Jul 2024 18:24:01 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-oa1-x2c.google.com (mail-oa1-x2c.google.com [IPv6:2001:4860:4864:20::2c]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "WR4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN9ZT3Gmmz4Myr for ; Mon, 15 Jul 2024 18:24:01 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-oa1-x2c.google.com with SMTP id 586e51a60fabf-25e1610e359so2153010fac.1 for ; Mon, 15 Jul 2024 11:24:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20230601.gappssmtp.com; s=20230601; t=1721067840; x=1721672640; darn=freebsd.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=+FeK4rsYc3PvyuiwoL3i9ECQcZPHLPXmxK+rGOvob1c=; b=DEknPNOToIGYbcLi/Uo0+PxW5pDlrQZQrdvxQ8RhvsyLhm4fDM6zzXFFPHiE4bjGxV ISuekCf1AAAxoQ23W8jIRTQeEoCD3Xj05qdLs3dNusKcNHs8nEM2GCTuTUyn6zwa2kA6 ScAmdtE4HR30c+2S1VaGYYdVxSJghS3qC99xiouyA/ju9RGfHOS703aJfs6xsJJLD0Dk 0srJ7I5KcE8bumEZHQ0Dx9uHP8M3gDZmtYpTBkx2IvTI42z8+ZTebBDgJiNeLu9rZxs1 WrYgCqFlTQMC5aE3VFcpP2ZaYHNLeHaDFdm1dYgnD4FOc2XrgGP9+Oka7RgoU0Wy/3zf MVMQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721067840; x=1721672640; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=+FeK4rsYc3PvyuiwoL3i9ECQcZPHLPXmxK+rGOvob1c=; b=LH3n55hy9LUiItn+MAeC0qQpja4gItfJJy6wrbzAkZ3kiCUD40RcD4FjafoqqrLHpN NpG5wDjrBainhnrO0RgAI5MjQEOlYq3RvkLLmtbGXx77DXZ1uLx8LBF+e2krjqveW07J bp0BvvDJsJy7XVDZFdBokFVwIYB/tAbBY5fbTUEAY20a7UP7NzGmRs9QgL9PRaDrDaD2 H6I0e3Pf40Rtq8KkrsoXhS2uu+b2AWuldjCDvklmzc5/xPRRSs7ozYWIYvXzeA0DWNnZ hAi/sZWHRHM4fIWFeazWMAVsq5x4uPLBpkKpu4uMgcgD3WZm4DdW44mSoJ1DssSvel8r u7tg== X-Forwarded-Encrypted: i=1; AJvYcCXVgteljvBhnTGBa/Olci3hNWY3qWByrRFwp0VurHKz9iFBQMhPCWNAgTU2iiHRI0972s5FbRwnTVeMB+f/8MLo6HQts8X5WiRBTlfdTlN1 X-Gm-Message-State: AOJu0YzPapy4rSloxqblCBCCQr47UGabcqrVtBlt969JeZh9gvV2XuCs WUjuVHUCeYwEMiX5KQCCuW92lATxqxaWxpRiwq4y94uql86+8ZX0DrNvVRXJhTSklpHsE/BwFuV d0qkDU/uIQdij+5p3t4SyIjplmnOLeu23bF4j8g== X-Google-Smtp-Source: AGHT+IEjqP8FeQ4Qxmnj7S3na/9H22DqmiiKj7zi2t9NBco/eQaqEkBI35wQ0T24tY8uziwi0l8NQb/OteauYVGL08U= X-Received: by 2002:a05:6871:b20:b0:250:70bb:1a97 with SMTP id 586e51a60fabf-260ba5785d7mr27692fac.24.1721067839928; Mon, 15 Jul 2024 11:23:59 -0700 (PDT) List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 References: <202407140600.46E60JKl047510@gitrepo.freebsd.org> In-Reply-To: From: Warner Losh Date: Mon, 15 Jul 2024 12:23:48 -0600 Message-ID: Subject: Re: git: 60f098f84119 - main - arch: Update to remove armv6 To: Ed Maste Cc: Warner Losh , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Content-Type: multipart/alternative; boundary="0000000000003bde24061d4d550a" 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:15169, ipnet:2001:4860:4864::/48, country:US] X-Rspamd-Queue-Id: 4WN9ZT3Gmmz4Myr --0000000000003bde24061d4d550a Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Mon, Jul 15, 2024 at 7:03=E2=80=AFAM Ed Maste wrote= : > On Sun, 14 Jul 2024 at 02:00, Warner Losh wrote: > > > > .Dv aarch64 > > will support execution of > > -.Dv armv6 > > -or > > .Dv armv7 > > binaries if the CPU implements > > .Dv AArch32 > > -execution state, however older arm binaries aren't supported. > > +execution state, however older arm binaries are not supported by > > +.Fx . > > Do older 32-bit Arm userland binaries actually not work? Would > "support execution of 32-bit Arm binaries if the CPU implements the > AArch32 execution state" be accurate? > armv7 works. armv6 likely works since they are quite similar to armv7. The only difference is in userland APIs. armv4 and v5 do not work if they used RAS (atomics). We don't implement the kernel part of RAS anymore, so those cannot work today. So nothing threaded will work. Some non-threaded things might work, but I don't think anybody has tested it, or seen if there's other, currently unknown, issues. So if you want to run an armv7 binary AND the CPU implements aarch32 execution states, then you will succeed. if armv6 and aarch64 it may work, but isn't supported. Otherwise, it won't work (though some trivial examples of armv4/armv5 might work). So I omitted the edge case details: armv6 likely will work, but is unsupported. armv4 and armv5 binaries generally won't work, though some restricted cases might work. In both of these cases, if they don't work or break in the future, we don't care (as a project). Clear as mud, eh? Warner --0000000000003bde24061d4d550a Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


=
On Mon, Jul 15, 2024 at 7:03=E2=80=AF= AM Ed Maste <emaste@freebsd.org> wrote:
On = Sun, 14 Jul 2024 at 02:00, Warner Losh <imp@freebsd.org> wrote:
>
>=C2=A0 .Dv aarch64
>=C2=A0 will support execution of
> -.Dv armv6
> -or
>=C2=A0 .Dv armv7
>=C2=A0 binaries if the CPU implements
>=C2=A0 .Dv AArch32
> -execution state, however older arm binaries aren't supported.
> +execution state, however older arm binaries are not supported by
> +.Fx .

Do older 32-bit Arm userland binaries actually not work? Would
"support execution of 32-bit Arm binaries if the CPU implements the AArch32 execution state" be accurate?

<= div>armv7 works.

armv6 likely works since they are= quite similar to armv7. The only difference is in userland APIs.

armv4 and v5 do not work if they used RAS (atomics). We don= 't implement the kernel part of RAS anymore, so those cannot work today= . So nothing threaded will work. Some non-threaded things might work, but I= don't think anybody has tested it, or seen if there's other, curre= ntly unknown, issues.

So if you want to run an arm= v7 binary AND the CPU implements aarch32 execution states, then you will su= cceed. if armv6 and aarch64 it may work, but isn't supported. Otherwise= , it won't work (though some trivial examples of armv4/armv5 might work= ).

So I omitted the edge case details: armv6 likel= y will work, but is unsupported. armv4 and armv5 binaries generally won'= ;t work, though some restricted cases might work. In both of these cases, i= f they don't work or break in the future, we don't care (as a proje= ct).

Clear as mud, eh?

Wa= rner
--0000000000003bde24061d4d550a-- From nobody Mon Jul 15 18:33:23 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN9nZ653qz5RRJV; Mon, 15 Jul 2024 18:33:38 +0000 (UTC) (envelope-from mjguzik@gmail.com) Received: from mail-ed1-x531.google.com (mail-ed1-x531.google.com [IPv6:2a00:1450:4864:20::531]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "WR4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN9nZ5LpSz4NWY; Mon, 15 Jul 2024 18:33:38 +0000 (UTC) (envelope-from mjguzik@gmail.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-ed1-x531.google.com with SMTP id 4fb4d7f45d1cf-58be2b8b6b2so5872401a12.3; Mon, 15 Jul 2024 11:33:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1721068417; x=1721673217; darn=freebsd.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=xF1hyUVdsj3LgPWBbm/9cuYRl0QMg1woOnLVTjx/o84=; b=lsRYuYU8c3BJPn2aXq2Yyv7ipRuUaUcwa4+u7mcmsg6Xm5rAQbTdqzLxjypOIq8UDs 4Di3QMwkBYkGIkURsIx4ZwsLbicT4URBoTtbiCfHsXD/2uCCHzbghZppOUizvH50irHd 4ng5rA3BgkHLDacjqublHaPje2XELpa7F/kS9W/LeI/m7URfqU4yMcDSKEbX5SJMwt9X sIcjECelO5lmG6mX05mOu0b9kM+8kw8bNB3xGI7m56RyNx2nBGLuUo2XwwFYBZ6excD/ 1MMD5PbxK1luxotYsVv1l+xWxayqepQjJgZwWCuZPya1g3pUAMSEZOHAp43NpII02i9e ZfFA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721068417; x=1721673217; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=xF1hyUVdsj3LgPWBbm/9cuYRl0QMg1woOnLVTjx/o84=; b=QxqrJIM5IF8Pf5i3bnX+v98fKQSwEH3GVNhikPrIUl1gQLdWOOu68IYq2b6GfNlz76 me/uw6IgNxRU4KvEruxwMhMcW0ptSrE/lGi9AYXSyBrJjRlmYqTcRLFwtmSuBJCe0cen SA8NEnu6XjvRdJrAPqWwd+0xgix3+KlwsTk2eCmawhHLPqyFpMK791rN2ILx3AlZ19s3 cD+nCNFQJOlLcZroT+ZYCKbJOpe1Cyka6Qc7Ohjt6r/YTXFDLeELflvT1wAvjgzuI+lE NEUK8OQ1wORK8Yjm7kXan+sakO0Kpy4pXZchP3goHgbEWqQNuwN6Dgcm/xvO5g+whSbY jAig== X-Forwarded-Encrypted: i=1; AJvYcCUmryvIzhqg6Jstn9p6UBHCmSxlevv5BVyzEscWQjibE9XUi5VFtuYkh6WiMxWTcOHl38M8EtWAW0VDKIZS97g+P0E/5nmlnyrmnEEI7EiWBlsKcHYWKNc6Wz4JTy3OdK7rptLaN4R4I5BLfDwRR96sgO2hMlgHpbBUNAk3s+A1MbQxcND7cmlMVePaZGU= X-Gm-Message-State: AOJu0Yxz7QWyXg3B+ZZJkty3eouzOd4nmqpXXCJ4KObx24Z5ffm0JJHg E9vB/doP4BSuxQdLjl0Sqn3JneQcjKKMIWxTBRNwaiqaoALLTjamenmtMNIH2nOI2jwZmxSplsg rBAnSeJN/cZ75KURRU+c8oRTt+FtnnvuF X-Google-Smtp-Source: AGHT+IFKGsKaBB/nLKGr+DS41fZ9h1zdnSGvo/+C+yC5j84C3Uuhe4F5uyAnXpMxljcVMY8aUdLeS+IQAYigzpsQU0s= X-Received: by 2002:a17:906:7311:b0:a72:81f5:85b6 with SMTP id a640c23a62f3a-a79e6a48054mr48428466b.18.1721068416843; Mon, 15 Jul 2024 11:33:36 -0700 (PDT) List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 References: <202407111107.46BB7uSb007077@gitrepo.freebsd.org> <81cfe7ad-cbee-4122-abef-e47ce2b34f05@FreeBSD.org> In-Reply-To: From: Mateusz Guzik Date: Mon, 15 Jul 2024 20:33:23 +0200 Message-ID: Subject: Re: git: 87ee63bac69d - main - locks: add a runtime check for missing turnstile To: John Baldwin Cc: Mateusz Guzik , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable 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:15169, ipnet:2a00:1450::/32, country:US] X-Rspamd-Queue-Id: 4WN9nZ5LpSz4NWY On Mon, Jul 15, 2024 at 8:21=E2=80=AFPM John Baldwin wrot= e: > > On 7/15/24 13:59, Mateusz Guzik wrote: > > On Mon, Jul 15, 2024 at 6:22=E2=80=AFPM John Baldwin = wrote: > >> > >> On 7/11/24 07:07, Mateusz Guzik wrote: > >>> The branch main has been updated by mjg: > >>> > >>> URL: https://cgit.FreeBSD.org/src/commit/?id=3D87ee63bac69dc49291f555= 90b8baa57cad6c7d85 > >>> > >>> commit 87ee63bac69dc49291f55590b8baa57cad6c7d85 > >>> Author: Mateusz Guzik > >>> AuthorDate: 2024-07-11 00:17:27 +0000 > >>> Commit: Mateusz Guzik > >>> CommitDate: 2024-07-11 11:06:52 +0000 > >>> > >>> locks: add a runtime check for missing turnstile > >>> > >>> There are sometimes bugs which result in the unlock fast path f= ailing, > >>> which in turns causes a not-helpful crash report when dereferen= cing a > >>> NULL turnstile. Help debugging such cases by pointing out what = happened > >>> along with some debug. > >>> > >>> Sponsored by: Rubicon Communications, LLC ("Netgate") > >>> --- > >>> sys/kern/kern_mutex.c | 4 +++- > >>> sys/kern/kern_rwlock.c | 16 ++++++++++++---- > >>> 2 files changed, 15 insertions(+), 5 deletions(-) > >>> > >>> diff --git a/sys/kern/kern_mutex.c b/sys/kern/kern_mutex.c > >>> index 90361b23c09a..0fa624cc4bb1 100644 > >>> --- a/sys/kern/kern_mutex.c > >>> +++ b/sys/kern/kern_mutex.c > >>> @@ -1053,7 +1053,9 @@ __mtx_unlock_sleep(volatile uintptr_t *c, uintp= tr_t v) > >>> turnstile_chain_lock(&m->lock_object); > >>> _mtx_release_lock_quick(m); > >>> ts =3D turnstile_lookup(&m->lock_object); > >>> - MPASS(ts !=3D NULL); > >>> + if (__predict_false(ts =3D=3D NULL)) { > >>> + panic("got NULL turnstile on mutex %p v %zx", m, v); > >>> + } > >> > >> Hmm, this is just an expanded KASSERT() but always on rather than cond= itional on INVARIANTS? > >> > >> Do you have examples of the type of bugs that cause this? (Is it unlo= cking a freed mutex > >> or the like?) We generally hide all these types of checks under INVAR= IANTS rather than > >> shipping them in release kernels. > >> > > > > Use-after-free, overflow, underflow, bitflip or what have you all can > > fail the fast path. > > > > Once that happens and the kernel crashes with a null pointer deref, > > here is a crash at netgate which prodded this: > > calltrap() at calltrap+0x8/frame 0xfffffe0106720920 > > --- trap 0xc, rip =3D 0xffffffff80d5ab70, rsp =3D 0xfffffe01067209f0, r= bp > > =3D 0xfffffe0106720a00 --- > > turnstile_broadcast() at turnstile_broadcast+0x40/frame 0xfffffe0106720= a00 > > __rw_wunlock_hard() at __rw_wunlock_hard+0x9e/frame 0xfffffe0106720a30 > > nd6_resolve_slow() at nd6_resolve_slow+0x2d7/frame 0xfffffe0106720aa0 > > nd6_resolve() at nd6_resolve+0x125/frame 0xfffffe0106720b10 > > ether_output() at ether_output+0x4e7/frame 0xfffffe0106720ba0 > > ip_output_send() at ip_output_send+0xdc/frame 0xfffffe0106720be0 > > ip_output() at ip_output+0x1295/frame 0xfffffe0106720ce0 > > ip_forward() at ip_forward+0x3c2/frame 0xfffffe0106720d90 > > ip_input() at ip_input+0x705/frame 0xfffffe0106720df0 > > swi_net() at swi_net+0x138/frame 0xfffffe0106720e60 > > ithread_loop() at ithread_loop+0x257/frame 0xfffffe0106720ef0 > > fork_exit() at fork_exit+0x7f/frame 0xfffffe0106720f30 > > fork_trampoline() at fork_trampoline+0xe/frame 0xfffffe0106720f30 > > --- trap 0, rip =3D 0, rsp =3D 0, rbp =3D 0 --- > > > > Neither the register dump nor anything in the backtrace indicate what h= appened. > > > > Since the kernel is going down anyway, one may as well get some debug f= rom it. > > If you don't mind the extra branches for sanity checks, why not just run = with > INVARIANTS? That is, what makes these particular assertions different fr= om > other assertions such that they should be on unconditionally? The last l= ine below > applies to pretty much every other assertion in the tree. > This adds a branch in the slowpath, a spot which should relatively rarely execute compared to the fast path. On top of that the branch at hand does not do any extra memory accesses or complex arithmetic. So no, I don't think I may as well run with INVARIANTS. --=20 Mateusz Guzik From nobody Mon Jul 15 18:40:05 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WN9xM0BB9z5RRkh; Mon, 15 Jul 2024 18:40:23 +0000 (UTC) (envelope-from mjguzik@gmail.com) Received: from mail-ed1-x52e.google.com (mail-ed1-x52e.google.com [IPv6:2a00:1450:4864:20::52e]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "WR4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WN9xL1fjyz4PCk; Mon, 15 Jul 2024 18:40:22 +0000 (UTC) (envelope-from mjguzik@gmail.com) Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20230601 header.b=QBcJW8t9; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of mjguzik@gmail.com designates 2a00:1450:4864:20::52e as permitted sender) smtp.mailfrom=mjguzik@gmail.com Received: by mail-ed1-x52e.google.com with SMTP id 4fb4d7f45d1cf-58ba3e38028so6093881a12.0; Mon, 15 Jul 2024 11:40:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1721068819; x=1721673619; darn=freebsd.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=G+6QyDVCDF7/HAcqlVRTaApi0lrEQ0HqhF3gG5u5Ez8=; b=QBcJW8t9tcLKrq4MCQUPdgVQ2lgVV5Hb+iwJ5B0gaWdM+oOndglsiZgnc8FOwGdlHn zKNsF3Fq3ukWs84QudyQ/KXuII03Cirk4M5GzmdWCM4PyRL6i+3BVTAC2bDfIz0CjDVV xRX8GRWsOv4XlVa4zhgnrpSVIR/AntcYqF6apb2S0bVxNugnZ3nKTOBr/vstLoXhwUGU vrBDm0MGCEKccE/ZKGRCBYiUvnob3/amTWBGdQ6chaNx7Q7mheFYTcZd4U6xiHV+gyJ9 2FewMQZi+gMyQfQRGYcLo/2ZYReSGzElOv1wi+zFQJuHV1FaGWW79gRwCuZ/lU9m83gz /ctA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721068819; x=1721673619; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=G+6QyDVCDF7/HAcqlVRTaApi0lrEQ0HqhF3gG5u5Ez8=; b=kbn1AHCOcVDLk25HqUF/wDGg5ZmI0iHzYxO8R3m1fboPqqfjhOjOUyHOKrvwTCnBFE Gv0wB7ax99zUerXYnv0Ei8EFIGsWsR++qM7muEQoa4Veufz8fetBGP4FmqtzuShEPOJC sCjl1bbH1SjbcncISWDvIp99AeDxd0j8U+SLjQg1NcoIwR+sBV0NnWffk1P5UKPvJ4hH wiOvyaJ8Aljt21KVyoJjgdTJTdOrP2jqQvVxHhxtuwyA3GdfCaLEmAB1cUql+NW8kOHV jVDlThBf35f/2r0GicKpRvPp7mGQ80LnKi4rTfAoI46SfYq+GIS5UHNSkG4+uJDfYA9Q yaxQ== X-Forwarded-Encrypted: i=1; AJvYcCV6JM8ejYqYgMBsPIBGx2KtIYEgXVp/h2gNlgJk/10Z+gK5/rt99YnFRN16nzhy2+J2fuEJpD11nd+b8h1JMlr1mbMctEoYta3ndL8nNwv4WYYCGhKdGXduEHuVnQn1IVp3iY9Qp58LurlnNfxfnEg2+k0QABKPMdlYfac5LE5HmknA7V107YH7o9KUPQY= X-Gm-Message-State: AOJu0YyQ3fXomxwhv0JbHXjuEgh85YsPNYWsFz6zMNfRzHROqNc+Sq10 iEVshNKSHCG1aQVKG8+Z+EXUqpNmTpf6mpZVJkFU5HYDgnOIWI9E7WCzc6txE6mfiYTvn8Se+sT gCKxaoQa1qZ79WsOI6SVpg16RmP6prLoQ X-Google-Smtp-Source: AGHT+IESwKX3NnCWob+lxqX043NKTYDAH5Xpct/KYn5G84AcgL+z7ES9xeGIi3tDMRM/SWomNUTY4QbeeehrRtMhTpI= X-Received: by 2002:a17:906:1545:b0:a77:dd1c:6273 with SMTP id a640c23a62f3a-a79e69389a6mr31211866b.12.1721068818592; Mon, 15 Jul 2024 11:40:18 -0700 (PDT) List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 References: <202407111107.46BB7uSb007077@gitrepo.freebsd.org> <81cfe7ad-cbee-4122-abef-e47ce2b34f05@FreeBSD.org> In-Reply-To: From: Mateusz Guzik Date: Mon, 15 Jul 2024 20:40:05 +0200 Message-ID: Subject: Re: git: 87ee63bac69d - main - locks: add a runtime check for missing turnstile To: John Baldwin Cc: Mateusz Guzik , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spamd-Bar: --- X-Spamd-Result: default: False [-3.98 / 15.00]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_SHORT(-0.98)[-0.983]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20230601]; R_SPF_ALLOW(-0.20)[+ip6:2a00:1450:4000::/36]; MIME_GOOD(-0.10)[text/plain]; MISSING_XM_UA(0.00)[]; ASN(0.00)[asn:15169, ipnet:2a00:1450::/32, country:US]; RCVD_COUNT_ONE(0.00)[1]; MIME_TRACE(0.00)[0:+]; ARC_NA(0.00)[]; FREEMAIL_ENVFROM(0.00)[gmail.com]; TO_DN_SOME(0.00)[]; FREEMAIL_FROM(0.00)[gmail.com]; RCVD_IN_DNSWL_NONE(0.00)[2a00:1450:4864:20::52e:from]; RCPT_COUNT_FIVE(0.00)[5]; FROM_EQ_ENVFROM(0.00)[]; FROM_HAS_DN(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com:dkim]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MID_RHS_MATCH_FROMTLD(0.00)[]; RCVD_TLS_LAST(0.00)[]; MLMMJ_DEST(0.00)[dev-commits-src-all@freebsd.org,dev-commits-src-main@freebsd.org]; DKIM_TRACE(0.00)[gmail.com:+] X-Rspamd-Queue-Id: 4WN9xL1fjyz4PCk On Mon, Jul 15, 2024 at 8:33=E2=80=AFPM Mateusz Guzik w= rote: > > On Mon, Jul 15, 2024 at 8:21=E2=80=AFPM John Baldwin wr= ote: > > > > On 7/15/24 13:59, Mateusz Guzik wrote: > > > On Mon, Jul 15, 2024 at 6:22=E2=80=AFPM John Baldwin wrote: > > >> > > >> On 7/11/24 07:07, Mateusz Guzik wrote: > > >>> The branch main has been updated by mjg: > > >>> > > >>> URL: https://cgit.FreeBSD.org/src/commit/?id=3D87ee63bac69dc49291f5= 5590b8baa57cad6c7d85 > > >>> > > >>> commit 87ee63bac69dc49291f55590b8baa57cad6c7d85 > > >>> Author: Mateusz Guzik > > >>> AuthorDate: 2024-07-11 00:17:27 +0000 > > >>> Commit: Mateusz Guzik > > >>> CommitDate: 2024-07-11 11:06:52 +0000 > > >>> > > >>> locks: add a runtime check for missing turnstile > > >>> > > >>> There are sometimes bugs which result in the unlock fast path= failing, > > >>> which in turns causes a not-helpful crash report when derefer= encing a > > >>> NULL turnstile. Help debugging such cases by pointing out wha= t happened > > >>> along with some debug. > > >>> > > >>> Sponsored by: Rubicon Communications, LLC ("Netgate") > > >>> --- > > >>> sys/kern/kern_mutex.c | 4 +++- > > >>> sys/kern/kern_rwlock.c | 16 ++++++++++++---- > > >>> 2 files changed, 15 insertions(+), 5 deletions(-) > > >>> > > >>> diff --git a/sys/kern/kern_mutex.c b/sys/kern/kern_mutex.c > > >>> index 90361b23c09a..0fa624cc4bb1 100644 > > >>> --- a/sys/kern/kern_mutex.c > > >>> +++ b/sys/kern/kern_mutex.c > > >>> @@ -1053,7 +1053,9 @@ __mtx_unlock_sleep(volatile uintptr_t *c, uin= tptr_t v) > > >>> turnstile_chain_lock(&m->lock_object); > > >>> _mtx_release_lock_quick(m); > > >>> ts =3D turnstile_lookup(&m->lock_object); > > >>> - MPASS(ts !=3D NULL); > > >>> + if (__predict_false(ts =3D=3D NULL)) { > > >>> + panic("got NULL turnstile on mutex %p v %zx", m, v); > > >>> + } > > >> > > >> Hmm, this is just an expanded KASSERT() but always on rather than co= nditional on INVARIANTS? > > >> > > >> Do you have examples of the type of bugs that cause this? (Is it un= locking a freed mutex > > >> or the like?) We generally hide all these types of checks under INV= ARIANTS rather than > > >> shipping them in release kernels. > > >> > > > > > > Use-after-free, overflow, underflow, bitflip or what have you all can > > > fail the fast path. > > > > > > Once that happens and the kernel crashes with a null pointer deref, > > > here is a crash at netgate which prodded this: > > > calltrap() at calltrap+0x8/frame 0xfffffe0106720920 > > > --- trap 0xc, rip =3D 0xffffffff80d5ab70, rsp =3D 0xfffffe01067209f0,= rbp > > > =3D 0xfffffe0106720a00 --- > > > turnstile_broadcast() at turnstile_broadcast+0x40/frame 0xfffffe01067= 20a00 > > > __rw_wunlock_hard() at __rw_wunlock_hard+0x9e/frame 0xfffffe0106720a3= 0 > > > nd6_resolve_slow() at nd6_resolve_slow+0x2d7/frame 0xfffffe0106720aa0 > > > nd6_resolve() at nd6_resolve+0x125/frame 0xfffffe0106720b10 > > > ether_output() at ether_output+0x4e7/frame 0xfffffe0106720ba0 > > > ip_output_send() at ip_output_send+0xdc/frame 0xfffffe0106720be0 > > > ip_output() at ip_output+0x1295/frame 0xfffffe0106720ce0 > > > ip_forward() at ip_forward+0x3c2/frame 0xfffffe0106720d90 > > > ip_input() at ip_input+0x705/frame 0xfffffe0106720df0 > > > swi_net() at swi_net+0x138/frame 0xfffffe0106720e60 > > > ithread_loop() at ithread_loop+0x257/frame 0xfffffe0106720ef0 > > > fork_exit() at fork_exit+0x7f/frame 0xfffffe0106720f30 > > > fork_trampoline() at fork_trampoline+0xe/frame 0xfffffe0106720f30 > > > --- trap 0, rip =3D 0, rsp =3D 0, rbp =3D 0 --- > > > > > > Neither the register dump nor anything in the backtrace indicate what= happened. > > > > > > Since the kernel is going down anyway, one may as well get some debug= from it. > > > > If you don't mind the extra branches for sanity checks, why not just ru= n with > > INVARIANTS? That is, what makes these particular assertions different = from > > other assertions such that they should be on unconditionally? The last= line below > > applies to pretty much every other assertion in the tree. > > > > This adds a branch in the slowpath, a spot which should relatively > rarely execute compared to the fast path. On top of that the branch at > hand does not do any extra memory accesses or complex arithmetic. > > So no, I don't think I may as well run with INVARIANTS. How about this: if you strongly about this branch, feel free to revert the commit, I'm just going to keep the change at Netgate. But should you do it, make sure to not add avoidable branches in your stuff= . Cheers. --=20 Mateusz Guzik From nobody Mon Jul 15 18:45:41 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNB3T3Mqpz5RSDc; Mon, 15 Jul 2024 18:45: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNB3T2v78z4Q7N; Mon, 15 Jul 2024 18:45:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721069141; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=LKXLZyxcmIlaq/41bjkKldpUvYzmuWaFM8c9v6fdA5A=; b=SgAvNfgffeHofxHiV1RFBqf4nI929CXvUmm0RPNej0d25AnIqfuiPQK9W1YO6jWX1Tgsa+ WeV+9uaGKJ8hbi+l2BMtkRuDlD3cbzbEaXQCoUdB4j49Mr1LNpyvVCOt6ReW4v0IB7osU7 8QS05Ommtw4UAg5a8/2d1MxAtnRhKCPDp9oeKULWKNp2aK2xvp9GFONmlgowW8o0uaPRs+ i+o0389aKTPIkL7JUjUoLVT6PSAjWlbXz3O0/fhyzv/4DGgIK/zkTbXi8ou/o3mw5aPrYy X8RgkVa4RzA4C1BN2P7boo10WUGrshbz85LWGVPsKZj4yfLqsfs8I6SOZBixVw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721069141; a=rsa-sha256; cv=none; b=sriIMlnkJEmE0DiP99wDDuXYiIscfvGDDuPHwtRi7VvemOngBDFoGnG2r3fkqKJRdp6Lnu PBkvK3kK1zOs4E2Ei+AYxVhcWlYE4lzNcpXpYdUax7Wyu6ombp4lHWCCNzCWVjB6tWSNWR nmEB0fFxY5ZFdGP2O3Qw3FQ8qZDDYQMcfyUFa01LccCreXnW0X/+4hFWJ//AFrwQYS6bi+ Pmb+GTXMERKl9KDXq/xFU/YFSrzHk7LbpVB4ZVwDqiF7lQw8LlVs/XF4u9aLlQTLb+Zi0s L2jnhKvl+7qJgr9plBD9fxA+ZMsy408GtgkVPuHJ7tfdVdH0UPZqyW93vL1zHQ== 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=1721069141; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=LKXLZyxcmIlaq/41bjkKldpUvYzmuWaFM8c9v6fdA5A=; b=Q3y/tOJcErCZKJZrhy7yM0axXZLOPTA9RqyTJ8QKt5dfaQY+3vjsrd6czdsYTLKHaXOrEv IVGP7IvxrGp38nVJuZTKchtgli1PfYyLNF2VuFySQ1xhE9eLuRwSYZODif1eiZ2sca5/A0 BHY9clhsyA7Q0hwhe1vgiFK3Bq6yWmThH0oAjmDYpwfePPzLQ13kfTcNhArEtxgKr+R+nH GbRfU08mgxroPec6vWf1y3Pa6vwsPIlmxOpKfMRZFRmB68t5iNzyoAmOVrVIsOAIhgG6wD YdH0kRPXuy5x3WTt1JPQprYIWLz50Wfc5GymuG0mBTilo5re7rZmq9gUEm5OKA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNB3T2N7Kz13jl; Mon, 15 Jul 2024 18:45:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FIjf47087293; Mon, 15 Jul 2024 18:45:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FIjfsB087290; Mon, 15 Jul 2024 18:45:41 GMT (envelope-from git) Date: Mon, 15 Jul 2024 18:45:41 GMT Message-Id: <202407151845.46FIjfsB087290@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: bf9a275b24f6 - stable/14 - OpenSSH: correct logic error in ObscureKeystrokeTiming List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: emaste X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: bf9a275b24f6655616cc691555fe1a36ed5e4338 Auto-Submitted: auto-generated The branch stable/14 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=bf9a275b24f6655616cc691555fe1a36ed5e4338 commit bf9a275b24f6655616cc691555fe1a36ed5e4338 Author: Ed Maste AuthorDate: 2024-07-01 13:14:15 +0000 Commit: Ed Maste CommitDate: 2024-07-15 18:45:16 +0000 OpenSSH: correct logic error in ObscureKeystrokeTiming Cherry-pick fix: upstream: when sending ObscureKeystrokeTiming chaff packets, we can't rely on channel_did_enqueue to tell that there is data to send. This flag indicates that the channels code enqueued a packet on _this_ ppoll() iteration, not that data was enqueued in _any_ ppoll() iteration in the timeslice. ok markus@ OpenBSD-Commit-ID: 009b74fd2769b36b5284a0188ade182f00564136 Obtained from: openssh-portable 146c420d29d0 Reviewed by: gordon Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D45823 (cherry picked from commit b81424adf7181d816c10b1345aaa3305ab0ec304) --- crypto/openssh/clientloop.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/crypto/openssh/clientloop.c b/crypto/openssh/clientloop.c index 8ec36af94b3f..6dcd6c8535aa 100644 --- a/crypto/openssh/clientloop.c +++ b/crypto/openssh/clientloop.c @@ -608,8 +608,9 @@ obfuscate_keystroke_timing(struct ssh *ssh, struct timespec *timeout, if (timespeccmp(&now, &chaff_until, >=)) { /* Stop if there have been no keystrokes for a while */ stop_reason = "chaff time expired"; - } else if (timespeccmp(&now, &next_interval, >=)) { - /* Otherwise if we were due to send, then send chaff */ + } else if (timespeccmp(&now, &next_interval, >=) && + !ssh_packet_have_data_to_write(ssh)) { + /* If due to send but have no data, then send chaff */ if (send_chaff(ssh)) nchaff++; } From nobody Mon Jul 15 18:45:42 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNB3V3RVjz5RRsQ; Mon, 15 Jul 2024 18:45: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNB3V3DvVz4Q9j; Mon, 15 Jul 2024 18:45:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721069142; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VPDLNFpU/ubIHFuXNDX3cRK1CERD8T9Qc24w7XVnjuU=; b=yzEe4Cs6AfIoU+IbzTH7h5BakUUCfbCTOCYOfgvJbwtSQ9JK2xwfDJNpcQasDVRVn14XUC 74jDH3tk2DG3XuMrP/FGdT5zNxi57mqusqYpD8WTdYvFjZG3+5SNoE0hWGwyJn7iFuF7Ao 7oHQ3X1CRcGKTq06Enk+1xdYQ/SXPaCeHF6ENqrO6dWVC9+kpw9MPcX8YGO1ghnnTCbdkM lkIxxwo7sZIbidkmpgZen5epqrQBbDLpy19SuRJI5fQuZ87R04x9GaR89DBuSfV2YagyIf 0TE174mxbF3oxoXkZDJ6mh9I7z+USKyBdIQzjej4AzmltpFqzzNnKa+TAc4h8Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721069142; a=rsa-sha256; cv=none; b=JahepuUkiN1IPwJ9YytqA6UhDl9xMkDQbyFOBKFP0KhZZOTfFg0+Z6LB4nNeVmRtQuUdjQ bwfvtOyom6cHuaOs7zlzXVRw42Wtconnryyfnhn/1PRGuDZDR8ZRFeieQZBmOZ3RiAGdtv ZZd4K9zn/8QWe3iFFluan4xk8LhuwoZbJKYsOIeewEt2Ztg0ikCAasSWi/DHAhzjww86Yi fnUhbgc6VnTz7PZCoUeJWkO2NnjjPQj1rBN3/0twKhzpl0UMNz09IpgVu5JHCttbA9vTVO QNLQyCxEXsvqGF0FOomHtMfcr6LIKeCDkgrn0BQm9R7ZX70z8A6Z/u9/EBrqcg== 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=1721069142; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VPDLNFpU/ubIHFuXNDX3cRK1CERD8T9Qc24w7XVnjuU=; b=VYlXBjOvHTT5EVXHzAh+sr+UZIv4nf32CJq5YQVVHXoUWU4EOarJ0tyqtVpIEuRhjnbbVJ DL1h9MvnHiJ0hkEkiI4AdaBu8eUiIScoJPC3WTk9lcftsbpqJS6GNfEVXsbzF9fP6TXEja nk74KzbvnOUgPV1JK/cu8TJxb8j+TpCsCvFKAKf4fTED0RIOjP9ku3DPejp5Xg0TGmNJah yQKV9M/FwaY52S1bslEctpdQG80ySuqmGsCp2RF+SsE+4xBcFTHWowmcQi3qBHBrZhvvvp RSPEAmuY0zSnLKkmRvrfytT3a9GFpG48GkI61ndTD9DCumjTJfWmz8ueq3ZJog== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNB3V2nw1z13Vf; Mon, 15 Jul 2024 18:45:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FIjgUM087350; Mon, 15 Jul 2024 18:45:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FIjg9x087347; Mon, 15 Jul 2024 18:45:42 GMT (envelope-from git) Date: Mon, 15 Jul 2024 18:45:42 GMT Message-Id: <202407151845.46FIjg9x087347@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: 60f78f8ed14d - stable/14 - openssh: use '' instead of `' in config.h List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: emaste X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 60f78f8ed14d5e66ce689532e18282a09a1a4e72 Auto-Submitted: auto-generated The branch stable/14 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=60f78f8ed14d5e66ce689532e18282a09a1a4e72 commit 60f78f8ed14d5e66ce689532e18282a09a1a4e72 Author: Ed Maste AuthorDate: 2024-07-01 14:45:43 +0000 Commit: Ed Maste CommitDate: 2024-07-15 18:45:16 +0000 openssh: use '' instead of `' in config.h Autoconf 2.72 uses '' rather tha `' in comments in config.h, from autoconf commit 64df9b4523fe ("Autoconf now quotes 'like this' instead of `like this'"). Switch quoting style now to minimize diffs on the next OpenSSH update and config.h regen. Reviewed by: gordon, philip Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D45840 (cherry picked from commit 94416c6939f431b29286a71bb2797e749df9645c) --- crypto/openssh/config.h | 614 ++++++++++++++++++++++++------------------------ 1 file changed, 307 insertions(+), 307 deletions(-) diff --git a/crypto/openssh/config.h b/crypto/openssh/config.h index 5e7e93992829..6462ff16d8d9 100644 --- a/crypto/openssh/config.h +++ b/crypto/openssh/config.h @@ -196,19 +196,19 @@ /* Define if you have ut_addr_v6 in utmpx.h */ /* #undef HAVE_ADDR_V6_IN_UTMPX */ -/* Define to 1 if you have the `arc4random' function. */ +/* Define to 1 if you have the 'arc4random' function. */ #define HAVE_ARC4RANDOM 1 -/* Define to 1 if you have the `arc4random_buf' function. */ +/* Define to 1 if you have the 'arc4random_buf' function. */ #define HAVE_ARC4RANDOM_BUF 1 -/* Define to 1 if you have the `arc4random_stir' function. */ +/* Define to 1 if you have the 'arc4random_stir' function. */ /* #undef HAVE_ARC4RANDOM_STIR */ -/* Define to 1 if you have the `arc4random_uniform' function. */ +/* Define to 1 if you have the 'arc4random_uniform' function. */ #define HAVE_ARC4RANDOM_UNIFORM 1 -/* Define to 1 if you have the `asprintf' function. */ +/* Define to 1 if you have the 'asprintf' function. */ #define HAVE_ASPRINTF 1 /* OpenBSD's gcc has bounded */ @@ -220,52 +220,52 @@ /* OpenBSD's gcc has sentinel */ /* #undef HAVE_ATTRIBUTE__SENTINEL__ */ -/* Define to 1 if you have the `aug_get_machine' function. */ +/* Define to 1 if you have the 'aug_get_machine' function. */ /* #undef HAVE_AUG_GET_MACHINE */ -/* Define to 1 if you have the `auth_hostok' function. */ +/* Define to 1 if you have the 'auth_hostok' function. */ #define HAVE_AUTH_HOSTOK 1 -/* Define to 1 if you have the `auth_timeok' function. */ +/* Define to 1 if you have the 'auth_timeok' function. */ #define HAVE_AUTH_TIMEOK 1 -/* Define to 1 if you have the `b64_ntop' function. */ +/* Define to 1 if you have the 'b64_ntop' function. */ /* #undef HAVE_B64_NTOP */ -/* Define to 1 if you have the `b64_pton' function. */ +/* Define to 1 if you have the 'b64_pton' function. */ /* #undef HAVE_B64_PTON */ /* Define if you have the basename function. */ #define HAVE_BASENAME 1 -/* Define to 1 if you have the `bcopy' function. */ +/* Define to 1 if you have the 'bcopy' function. */ #define HAVE_BCOPY 1 -/* Define to 1 if you have the `bcrypt_pbkdf' function. */ +/* Define to 1 if you have the 'bcrypt_pbkdf' function. */ /* #undef HAVE_BCRYPT_PBKDF */ -/* Define to 1 if you have the `bindresvport_sa' function. */ +/* Define to 1 if you have the 'bindresvport_sa' function. */ #define HAVE_BINDRESVPORT_SA 1 -/* Define to 1 if you have the `blf_enc' function. */ +/* Define to 1 if you have the 'blf_enc' function. */ /* #undef HAVE_BLF_ENC */ /* Define to 1 if you have the header file. */ /* #undef HAVE_BLF_H */ -/* Define to 1 if you have the `Blowfish_expand0state' function. */ +/* Define to 1 if you have the 'Blowfish_expand0state' function. */ /* #undef HAVE_BLOWFISH_EXPAND0STATE */ -/* Define to 1 if you have the `Blowfish_expandstate' function. */ +/* Define to 1 if you have the 'Blowfish_expandstate' function. */ /* #undef HAVE_BLOWFISH_EXPANDSTATE */ -/* Define to 1 if you have the `Blowfish_initstate' function. */ +/* Define to 1 if you have the 'Blowfish_initstate' function. */ /* #undef HAVE_BLOWFISH_INITSTATE */ -/* Define to 1 if you have the `Blowfish_stream2word' function. */ +/* Define to 1 if you have the 'Blowfish_stream2word' function. */ /* #undef HAVE_BLOWFISH_STREAM2WORD */ -/* Define to 1 if you have the `BN_is_prime_ex' function. */ +/* Define to 1 if you have the 'BN_is_prime_ex' function. */ #define HAVE_BN_IS_PRIME_EX 1 /* Define to 1 if you have the header file. */ @@ -277,7 +277,7 @@ /* Define to 1 if you have the header file. */ /* #undef HAVE_BSTRING_H */ -/* Define to 1 if you have the `bzero' function. */ +/* Define to 1 if you have the 'bzero' function. */ #define HAVE_BZERO 1 /* calloc(0, x) returns NULL */ @@ -289,10 +289,10 @@ /* Define to 1 if you have the header file. */ #define HAVE_CAPSICUM_HELPERS_H 1 -/* Define to 1 if you have the `cap_rights_limit' function. */ +/* Define to 1 if you have the 'cap_rights_limit' function. */ #define HAVE_CAP_RIGHTS_LIMIT 1 -/* Define to 1 if you have the `clock' function. */ +/* Define to 1 if you have the 'clock' function. */ #define HAVE_CLOCK 1 /* Have clock_gettime */ @@ -301,10 +301,10 @@ /* define if you have clock_t data type */ #define HAVE_CLOCK_T 1 -/* Define to 1 if you have the `closefrom' function. */ +/* Define to 1 if you have the 'closefrom' function. */ #define HAVE_CLOSEFROM 1 -/* Define to 1 if you have the `close_range' function. */ +/* Define to 1 if you have the 'close_range' function. */ #define HAVE_CLOSE_RANGE 1 /* Define if gai_strerror() returns const char * */ @@ -313,7 +313,7 @@ /* Define if your system uses ancillary data style file descriptor passing */ #define HAVE_CONTROL_IN_MSGHDR 1 -/* Define to 1 if you have the `crypt' function. */ +/* Define to 1 if you have the 'crypt' function. */ #define HAVE_CRYPT 1 /* Define to 1 if you have the header file. */ @@ -328,111 +328,111 @@ /* Define if your libraries define daemon() */ #define HAVE_DAEMON 1 -/* Define to 1 if you have the declaration of `AI_NUMERICSERV', and to 0 if +/* Define to 1 if you have the declaration of 'AI_NUMERICSERV', and to 0 if you don't. */ #define HAVE_DECL_AI_NUMERICSERV 1 -/* Define to 1 if you have the declaration of `authenticate', and to 0 if you +/* Define to 1 if you have the declaration of 'authenticate', and to 0 if you don't. */ /* #undef HAVE_DECL_AUTHENTICATE */ -/* Define to 1 if you have the declaration of `bzero', and to 0 if you don't. +/* Define to 1 if you have the declaration of 'bzero', and to 0 if you don't. */ #define HAVE_DECL_BZERO 1 -/* Define to 1 if you have the declaration of `ftruncate', and to 0 if you +/* Define to 1 if you have the declaration of 'ftruncate', and to 0 if you don't. */ #define HAVE_DECL_FTRUNCATE 1 -/* Define to 1 if you have the declaration of `getentropy', and to 0 if you +/* Define to 1 if you have the declaration of 'getentropy', and to 0 if you don't. */ #define HAVE_DECL_GETENTROPY 1 -/* Define to 1 if you have the declaration of `getpeereid', and to 0 if you +/* Define to 1 if you have the declaration of 'getpeereid', and to 0 if you don't. */ #define HAVE_DECL_GETPEEREID 1 -/* Define to 1 if you have the declaration of `GLOB_NOMATCH', and to 0 if you +/* Define to 1 if you have the declaration of 'GLOB_NOMATCH', and to 0 if you don't. */ #define HAVE_DECL_GLOB_NOMATCH 1 -/* Define to 1 if you have the declaration of `GSS_C_NT_HOSTBASED_SERVICE', +/* Define to 1 if you have the declaration of 'GSS_C_NT_HOSTBASED_SERVICE', and to 0 if you don't. */ /* #undef HAVE_DECL_GSS_C_NT_HOSTBASED_SERVICE */ -/* Define to 1 if you have the declaration of `howmany', and to 0 if you +/* Define to 1 if you have the declaration of 'howmany', and to 0 if you don't. */ #define HAVE_DECL_HOWMANY 1 -/* Define to 1 if you have the declaration of `h_errno', and to 0 if you +/* Define to 1 if you have the declaration of 'h_errno', and to 0 if you don't. */ #define HAVE_DECL_H_ERRNO 1 -/* Define to 1 if you have the declaration of `loginfailed', and to 0 if you +/* Define to 1 if you have the declaration of 'loginfailed', and to 0 if you don't. */ /* #undef HAVE_DECL_LOGINFAILED */ -/* Define to 1 if you have the declaration of `loginrestrictions', and to 0 if +/* Define to 1 if you have the declaration of 'loginrestrictions', and to 0 if you don't. */ /* #undef HAVE_DECL_LOGINRESTRICTIONS */ -/* Define to 1 if you have the declaration of `loginsuccess', and to 0 if you +/* Define to 1 if you have the declaration of 'loginsuccess', and to 0 if you don't. */ /* #undef HAVE_DECL_LOGINSUCCESS */ -/* Define to 1 if you have the declaration of `MAXSYMLINKS', and to 0 if you +/* Define to 1 if you have the declaration of 'MAXSYMLINKS', and to 0 if you don't. */ #define HAVE_DECL_MAXSYMLINKS 1 -/* Define to 1 if you have the declaration of `memmem', and to 0 if you don't. +/* Define to 1 if you have the declaration of 'memmem', and to 0 if you don't. */ #define HAVE_DECL_MEMMEM 1 -/* Define to 1 if you have the declaration of `NFDBITS', and to 0 if you +/* Define to 1 if you have the declaration of 'NFDBITS', and to 0 if you don't. */ #define HAVE_DECL_NFDBITS 1 -/* Define to 1 if you have the declaration of `offsetof', and to 0 if you +/* Define to 1 if you have the declaration of 'offsetof', and to 0 if you don't. */ #define HAVE_DECL_OFFSETOF 1 -/* Define to 1 if you have the declaration of `O_NONBLOCK', and to 0 if you +/* Define to 1 if you have the declaration of 'O_NONBLOCK', and to 0 if you don't. */ #define HAVE_DECL_O_NONBLOCK 1 -/* Define to 1 if you have the declaration of `passwdexpired', and to 0 if you +/* Define to 1 if you have the declaration of 'passwdexpired', and to 0 if you don't. */ /* #undef HAVE_DECL_PASSWDEXPIRED */ -/* Define to 1 if you have the declaration of `readv', and to 0 if you don't. +/* Define to 1 if you have the declaration of 'readv', and to 0 if you don't. */ #define HAVE_DECL_READV 1 -/* Define to 1 if you have the declaration of `setauthdb', and to 0 if you +/* Define to 1 if you have the declaration of 'setauthdb', and to 0 if you don't. */ /* #undef HAVE_DECL_SETAUTHDB */ -/* Define to 1 if you have the declaration of `SHUT_RD', and to 0 if you +/* Define to 1 if you have the declaration of 'SHUT_RD', and to 0 if you don't. */ #define HAVE_DECL_SHUT_RD 1 -/* Define to 1 if you have the declaration of `UINT32_MAX', and to 0 if you +/* Define to 1 if you have the declaration of 'UINT32_MAX', and to 0 if you don't. */ #define HAVE_DECL_UINT32_MAX 1 -/* Define to 1 if you have the declaration of `writev', and to 0 if you don't. +/* Define to 1 if you have the declaration of 'writev', and to 0 if you don't. */ #define HAVE_DECL_WRITEV 1 -/* Define to 1 if you have the declaration of `_getlong', and to 0 if you +/* Define to 1 if you have the declaration of '_getlong', and to 0 if you don't. */ #define HAVE_DECL__GETLONG 0 -/* Define to 1 if you have the declaration of `_getshort', and to 0 if you +/* Define to 1 if you have the declaration of '_getshort', and to 0 if you don't. */ #define HAVE_DECL__GETSHORT 0 -/* Define to 1 if you have the `DES_crypt' function. */ +/* Define to 1 if you have the 'DES_crypt' function. */ #define HAVE_DES_CRYPT 1 /* Define if you have /dev/ptmx */ @@ -444,40 +444,40 @@ /* Define to 1 if you have the header file. */ #define HAVE_DIRENT_H 1 -/* Define to 1 if you have the `dirfd' function. */ +/* Define to 1 if you have the 'dirfd' function. */ #define HAVE_DIRFD 1 -/* Define to 1 if you have the `dirname' function. */ +/* Define to 1 if you have the 'dirname' function. */ #define HAVE_DIRNAME 1 -/* Define to 1 if you have the `dlopen' function. */ +/* Define to 1 if you have the 'dlopen' function. */ #define HAVE_DLOPEN 1 -/* Define to 1 if you have the `DSA_generate_parameters_ex' function. */ +/* Define to 1 if you have the 'DSA_generate_parameters_ex' function. */ #define HAVE_DSA_GENERATE_PARAMETERS_EX 1 -/* Define to 1 if you have the `EC_KEY_METHOD_new' function. */ +/* Define to 1 if you have the 'EC_KEY_METHOD_new' function. */ #define HAVE_EC_KEY_METHOD_NEW 1 /* Define to 1 if you have the header file. */ #define HAVE_ELF_H 1 -/* Define to 1 if you have the `endgrent' function. */ +/* Define to 1 if you have the 'endgrent' function. */ #define HAVE_ENDGRENT 1 /* Define to 1 if you have the header file. */ #define HAVE_ENDIAN_H 1 -/* Define to 1 if you have the `endutent' function. */ +/* Define to 1 if you have the 'endutent' function. */ /* #undef HAVE_ENDUTENT */ -/* Define to 1 if you have the `endutxent' function. */ +/* Define to 1 if you have the 'endutxent' function. */ #define HAVE_ENDUTXENT 1 -/* Define to 1 if you have the `err' function. */ +/* Define to 1 if you have the 'err' function. */ #define HAVE_ERR 1 -/* Define to 1 if you have the `errx' function. */ +/* Define to 1 if you have the 'errx' function. */ #define HAVE_ERRX 1 /* Define to 1 if you have the header file. */ @@ -486,73 +486,73 @@ /* Define if your system has /etc/default/login */ /* #undef HAVE_ETC_DEFAULT_LOGIN */ -/* Define to 1 if you have the `EVP_chacha20' function. */ +/* Define to 1 if you have the 'EVP_chacha20' function. */ #define HAVE_EVP_CHACHA20 1 -/* Define to 1 if you have the `EVP_CIPHER_CTX_get_iv' function. */ +/* Define to 1 if you have the 'EVP_CIPHER_CTX_get_iv' function. */ /* #undef HAVE_EVP_CIPHER_CTX_GET_IV */ -/* Define to 1 if you have the `EVP_CIPHER_CTX_get_updated_iv' function. */ +/* Define to 1 if you have the 'EVP_CIPHER_CTX_get_updated_iv' function. */ #define HAVE_EVP_CIPHER_CTX_GET_UPDATED_IV 1 -/* Define to 1 if you have the `EVP_CIPHER_CTX_iv' function. */ +/* Define to 1 if you have the 'EVP_CIPHER_CTX_iv' function. */ #define HAVE_EVP_CIPHER_CTX_IV 1 -/* Define to 1 if you have the `EVP_CIPHER_CTX_iv_noconst' function. */ +/* Define to 1 if you have the 'EVP_CIPHER_CTX_iv_noconst' function. */ #define HAVE_EVP_CIPHER_CTX_IV_NOCONST 1 -/* Define to 1 if you have the `EVP_CIPHER_CTX_set_iv' function. */ +/* Define to 1 if you have the 'EVP_CIPHER_CTX_set_iv' function. */ /* #undef HAVE_EVP_CIPHER_CTX_SET_IV */ -/* Define to 1 if you have the `EVP_DigestFinal_ex' function. */ +/* Define to 1 if you have the 'EVP_DigestFinal_ex' function. */ #define HAVE_EVP_DIGESTFINAL_EX 1 -/* Define to 1 if you have the `EVP_DigestInit_ex' function. */ +/* Define to 1 if you have the 'EVP_DigestInit_ex' function. */ #define HAVE_EVP_DIGESTINIT_EX 1 -/* Define to 1 if you have the `EVP_MD_CTX_cleanup' function. */ +/* Define to 1 if you have the 'EVP_MD_CTX_cleanup' function. */ /* #undef HAVE_EVP_MD_CTX_CLEANUP */ -/* Define to 1 if you have the `EVP_MD_CTX_copy_ex' function. */ +/* Define to 1 if you have the 'EVP_MD_CTX_copy_ex' function. */ #define HAVE_EVP_MD_CTX_COPY_EX 1 -/* Define to 1 if you have the `EVP_MD_CTX_init' function. */ +/* Define to 1 if you have the 'EVP_MD_CTX_init' function. */ /* #undef HAVE_EVP_MD_CTX_INIT */ -/* Define to 1 if you have the `EVP_PKEY_get_raw_private_key' function. */ +/* Define to 1 if you have the 'EVP_PKEY_get_raw_private_key' function. */ #define HAVE_EVP_PKEY_GET_RAW_PRIVATE_KEY 1 -/* Define to 1 if you have the `EVP_PKEY_get_raw_public_key' function. */ +/* Define to 1 if you have the 'EVP_PKEY_get_raw_public_key' function. */ #define HAVE_EVP_PKEY_GET_RAW_PUBLIC_KEY 1 -/* Define to 1 if you have the `EVP_sha256' function. */ +/* Define to 1 if you have the 'EVP_sha256' function. */ #define HAVE_EVP_SHA256 1 -/* Define to 1 if you have the `EVP_sha384' function. */ +/* Define to 1 if you have the 'EVP_sha384' function. */ #define HAVE_EVP_SHA384 1 -/* Define to 1 if you have the `EVP_sha512' function. */ +/* Define to 1 if you have the 'EVP_sha512' function. */ #define HAVE_EVP_SHA512 1 /* Define if you have ut_exit in utmp.h */ /* #undef HAVE_EXIT_IN_UTMP */ -/* Define to 1 if you have the `explicit_bzero' function. */ +/* Define to 1 if you have the 'explicit_bzero' function. */ #define HAVE_EXPLICIT_BZERO 1 -/* Define to 1 if you have the `explicit_memset' function. */ +/* Define to 1 if you have the 'explicit_memset' function. */ /* #undef HAVE_EXPLICIT_MEMSET */ -/* Define to 1 if you have the `fchmod' function. */ +/* Define to 1 if you have the 'fchmod' function. */ #define HAVE_FCHMOD 1 -/* Define to 1 if you have the `fchmodat' function. */ +/* Define to 1 if you have the 'fchmodat' function. */ #define HAVE_FCHMODAT 1 -/* Define to 1 if you have the `fchown' function. */ +/* Define to 1 if you have the 'fchown' function. */ #define HAVE_FCHOWN 1 -/* Define to 1 if you have the `fchownat' function. */ +/* Define to 1 if you have the 'fchownat' function. */ #define HAVE_FCHOWNAT 1 /* Use F_CLOSEM fcntl for closefrom */ @@ -561,109 +561,109 @@ /* Define to 1 if you have the header file. */ #define HAVE_FCNTL_H 1 -/* Define to 1 if the system has the type `fd_mask'. */ +/* Define to 1 if the system has the type 'fd_mask'. */ #define HAVE_FD_MASK 1 /* Define to 1 if you have the header file. */ /* #undef HAVE_FEATURES_H */ -/* Define to 1 if you have the `fido_assert_set_clientdata' function. */ +/* Define to 1 if you have the 'fido_assert_set_clientdata' function. */ /* #undef HAVE_FIDO_ASSERT_SET_CLIENTDATA */ -/* Define to 1 if you have the `fido_cred_prot' function. */ +/* Define to 1 if you have the 'fido_cred_prot' function. */ /* #undef HAVE_FIDO_CRED_PROT */ -/* Define to 1 if you have the `fido_cred_set_clientdata' function. */ +/* Define to 1 if you have the 'fido_cred_set_clientdata' function. */ /* #undef HAVE_FIDO_CRED_SET_CLIENTDATA */ -/* Define to 1 if you have the `fido_cred_set_prot' function. */ +/* Define to 1 if you have the 'fido_cred_set_prot' function. */ /* #undef HAVE_FIDO_CRED_SET_PROT */ -/* Define to 1 if you have the `fido_dev_get_touch_begin' function. */ +/* Define to 1 if you have the 'fido_dev_get_touch_begin' function. */ /* #undef HAVE_FIDO_DEV_GET_TOUCH_BEGIN */ -/* Define to 1 if you have the `fido_dev_get_touch_status' function. */ +/* Define to 1 if you have the 'fido_dev_get_touch_status' function. */ /* #undef HAVE_FIDO_DEV_GET_TOUCH_STATUS */ -/* Define to 1 if you have the `fido_dev_is_winhello' function. */ +/* Define to 1 if you have the 'fido_dev_is_winhello' function. */ /* #undef HAVE_FIDO_DEV_IS_WINHELLO */ -/* Define to 1 if you have the `fido_dev_supports_cred_prot' function. */ +/* Define to 1 if you have the 'fido_dev_supports_cred_prot' function. */ /* #undef HAVE_FIDO_DEV_SUPPORTS_CRED_PROT */ /* Define to 1 if you have the header file. */ #define HAVE_FLOATINGPOINT_H 1 -/* Define to 1 if you have the `flock' function. */ +/* Define to 1 if you have the 'flock' function. */ #define HAVE_FLOCK 1 -/* Define to 1 if you have the `fmt_scaled' function. */ +/* Define to 1 if you have the 'fmt_scaled' function. */ /* #undef HAVE_FMT_SCALED */ -/* Define to 1 if you have the `fnmatch' function. */ +/* Define to 1 if you have the 'fnmatch' function. */ #define HAVE_FNMATCH 1 /* Define to 1 if you have the header file. */ #define HAVE_FNMATCH_H 1 -/* Define to 1 if you have the `freeaddrinfo' function. */ +/* Define to 1 if you have the 'freeaddrinfo' function. */ #define HAVE_FREEADDRINFO 1 -/* Define to 1 if you have the `freezero' function. */ +/* Define to 1 if you have the 'freezero' function. */ /* #undef HAVE_FREEZERO */ -/* Define to 1 if the system has the type `fsblkcnt_t'. */ +/* Define to 1 if the system has the type 'fsblkcnt_t'. */ #define HAVE_FSBLKCNT_T 1 -/* Define to 1 if the system has the type `fsfilcnt_t'. */ +/* Define to 1 if the system has the type 'fsfilcnt_t'. */ #define HAVE_FSFILCNT_T 1 -/* Define to 1 if you have the `fstatfs' function. */ +/* Define to 1 if you have the 'fstatfs' function. */ #define HAVE_FSTATFS 1 -/* Define to 1 if you have the `fstatvfs' function. */ +/* Define to 1 if you have the 'fstatvfs' function. */ #define HAVE_FSTATVFS 1 -/* Define to 1 if you have the `futimes' function. */ +/* Define to 1 if you have the 'futimes' function. */ #define HAVE_FUTIMES 1 -/* Define to 1 if you have the `gai_strerror' function. */ +/* Define to 1 if you have the 'gai_strerror' function. */ #define HAVE_GAI_STRERROR 1 -/* Define to 1 if you have the `getaddrinfo' function. */ +/* Define to 1 if you have the 'getaddrinfo' function. */ #define HAVE_GETADDRINFO 1 -/* Define to 1 if you have the `getaudit' function. */ +/* Define to 1 if you have the 'getaudit' function. */ /* #undef HAVE_GETAUDIT */ -/* Define to 1 if you have the `getaudit_addr' function. */ +/* Define to 1 if you have the 'getaudit_addr' function. */ /* #undef HAVE_GETAUDIT_ADDR */ -/* Define to 1 if you have the `getcwd' function. */ +/* Define to 1 if you have the 'getcwd' function. */ #define HAVE_GETCWD 1 -/* Define to 1 if you have the `getentropy' function. */ +/* Define to 1 if you have the 'getentropy' function. */ #define HAVE_GETENTROPY 1 -/* Define to 1 if you have the `getgrouplist' function. */ +/* Define to 1 if you have the 'getgrouplist' function. */ #define HAVE_GETGROUPLIST 1 -/* Define to 1 if you have the `getgrset' function. */ +/* Define to 1 if you have the 'getgrset' function. */ /* #undef HAVE_GETGRSET */ -/* Define to 1 if you have the `getlastlogxbyname' function. */ +/* Define to 1 if you have the 'getlastlogxbyname' function. */ /* #undef HAVE_GETLASTLOGXBYNAME */ -/* Define to 1 if you have the `getline' function. */ +/* Define to 1 if you have the 'getline' function. */ #define HAVE_GETLINE 1 -/* Define to 1 if you have the `getluid' function. */ +/* Define to 1 if you have the 'getluid' function. */ /* #undef HAVE_GETLUID */ -/* Define to 1 if you have the `getnameinfo' function. */ +/* Define to 1 if you have the 'getnameinfo' function. */ #define HAVE_GETNAMEINFO 1 -/* Define to 1 if you have the `getopt' function. */ +/* Define to 1 if you have the 'getopt' function. */ #define HAVE_GETOPT 1 /* Define to 1 if you have the header file. */ @@ -675,73 +675,73 @@ /* Define if your libraries define getpagesize() */ #define HAVE_GETPAGESIZE 1 -/* Define to 1 if you have the `getpeereid' function. */ +/* Define to 1 if you have the 'getpeereid' function. */ #define HAVE_GETPEEREID 1 -/* Define to 1 if you have the `getpeerucred' function. */ +/* Define to 1 if you have the 'getpeerucred' function. */ /* #undef HAVE_GETPEERUCRED */ -/* Define to 1 if you have the `getpgid' function. */ +/* Define to 1 if you have the 'getpgid' function. */ #define HAVE_GETPGID 1 -/* Define to 1 if you have the `getpgrp' function. */ +/* Define to 1 if you have the 'getpgrp' function. */ #define HAVE_GETPGRP 1 -/* Define to 1 if you have the `getpwanam' function. */ +/* Define to 1 if you have the 'getpwanam' function. */ /* #undef HAVE_GETPWANAM */ -/* Define to 1 if you have the `getrandom' function. */ +/* Define to 1 if you have the 'getrandom' function. */ #define HAVE_GETRANDOM 1 -/* Define to 1 if you have the `getrlimit' function. */ +/* Define to 1 if you have the 'getrlimit' function. */ #define HAVE_GETRLIMIT 1 /* Define if getrrsetbyname() exists */ /* #undef HAVE_GETRRSETBYNAME */ -/* Define to 1 if you have the `getseuserbyname' function. */ +/* Define to 1 if you have the 'getseuserbyname' function. */ /* #undef HAVE_GETSEUSERBYNAME */ -/* Define to 1 if you have the `getsid' function. */ +/* Define to 1 if you have the 'getsid' function. */ #define HAVE_GETSID 1 -/* Define to 1 if you have the `gettimeofday' function. */ +/* Define to 1 if you have the 'gettimeofday' function. */ #define HAVE_GETTIMEOFDAY 1 -/* Define to 1 if you have the `getttyent' function. */ +/* Define to 1 if you have the 'getttyent' function. */ #define HAVE_GETTTYENT 1 -/* Define to 1 if you have the `getutent' function. */ +/* Define to 1 if you have the 'getutent' function. */ /* #undef HAVE_GETUTENT */ -/* Define to 1 if you have the `getutid' function. */ +/* Define to 1 if you have the 'getutid' function. */ /* #undef HAVE_GETUTID */ -/* Define to 1 if you have the `getutline' function. */ +/* Define to 1 if you have the 'getutline' function. */ /* #undef HAVE_GETUTLINE */ -/* Define to 1 if you have the `getutxent' function. */ +/* Define to 1 if you have the 'getutxent' function. */ #define HAVE_GETUTXENT 1 -/* Define to 1 if you have the `getutxid' function. */ +/* Define to 1 if you have the 'getutxid' function. */ #define HAVE_GETUTXID 1 -/* Define to 1 if you have the `getutxline' function. */ +/* Define to 1 if you have the 'getutxline' function. */ #define HAVE_GETUTXLINE 1 -/* Define to 1 if you have the `getutxuser' function. */ +/* Define to 1 if you have the 'getutxuser' function. */ #define HAVE_GETUTXUSER 1 -/* Define to 1 if you have the `get_default_context_with_level' function. */ +/* Define to 1 if you have the 'get_default_context_with_level' function. */ /* #undef HAVE_GET_DEFAULT_CONTEXT_WITH_LEVEL */ -/* Define to 1 if you have the `glob' function. */ +/* Define to 1 if you have the 'glob' function. */ #define HAVE_GLOB 1 /* Define to 1 if you have the header file. */ #define HAVE_GLOB_H 1 -/* Define to 1 if you have the `group_from_gid' function. */ +/* Define to 1 if you have the 'group_from_gid' function. */ #define HAVE_GROUP_FROM_GID 1 /* Define to 1 if you have the header file. */ @@ -765,7 +765,7 @@ /* Define if HEADER.ad exists in arpa/nameser.h */ #define HAVE_HEADER_AD 1 -/* Define to 1 if you have the `HMAC_CTX_init' function. */ +/* Define to 1 if you have the 'HMAC_CTX_init' function. */ /* #undef HAVE_HMAC_CTX_INIT */ /* Define if you have ut_host in utmp.h */ @@ -789,22 +789,22 @@ /* Define to 1 if you have the header file. */ #define HAVE_IFADDRS_H 1 -/* Define to 1 if you have the `inet_aton' function. */ +/* Define to 1 if you have the 'inet_aton' function. */ #define HAVE_INET_ATON 1 -/* Define to 1 if you have the `inet_ntoa' function. */ +/* Define to 1 if you have the 'inet_ntoa' function. */ #define HAVE_INET_NTOA 1 -/* Define to 1 if you have the `inet_ntop' function. */ +/* Define to 1 if you have the 'inet_ntop' function. */ #define HAVE_INET_NTOP 1 -/* Define to 1 if you have the `innetgr' function. */ +/* Define to 1 if you have the 'innetgr' function. */ #define HAVE_INNETGR 1 /* define if you have int64_t data type */ #define HAVE_INT64_T 1 -/* Define to 1 if the system has the type `intmax_t'. */ +/* Define to 1 if the system has the type 'intmax_t'. */ #define HAVE_INTMAX_T 1 /* Define to 1 if you have the header file. */ @@ -813,25 +813,25 @@ /* define if you have intxx_t data type */ #define HAVE_INTXX_T 1 -/* Define to 1 if the system has the type `in_addr_t'. */ +/* Define to 1 if the system has the type 'in_addr_t'. */ #define HAVE_IN_ADDR_T 1 -/* Define to 1 if the system has the type `in_port_t'. */ +/* Define to 1 if the system has the type 'in_port_t'. */ #define HAVE_IN_PORT_T 1 /* Define if you have isblank(3C). */ #define HAVE_ISBLANK 1 -/* Define to 1 if you have the `killpg' function. */ +/* Define to 1 if you have the 'killpg' function. */ #define HAVE_KILLPG 1 -/* Define to 1 if you have the `krb5_cc_new_unique' function. */ +/* Define to 1 if you have the 'krb5_cc_new_unique' function. */ /* #undef HAVE_KRB5_CC_NEW_UNIQUE */ -/* Define to 1 if you have the `krb5_free_error_message' function. */ +/* Define to 1 if you have the 'krb5_free_error_message' function. */ /* #undef HAVE_KRB5_FREE_ERROR_MESSAGE */ -/* Define to 1 if you have the `krb5_get_error_message' function. */ +/* Define to 1 if you have the 'krb5_get_error_message' function. */ /* #undef HAVE_KRB5_GET_ERROR_MESSAGE */ /* Define to 1 if you have the header file. */ @@ -846,10 +846,10 @@ /* Define to 1 if you have the header file. */ /* #undef HAVE_LIBAUDIT_H */ -/* Define to 1 if you have the `bsm' library (-lbsm). */ +/* Define to 1 if you have the 'bsm' library (-lbsm). */ /* #undef HAVE_LIBBSM */ -/* Define to 1 if you have the `dl' library (-ldl). */ +/* Define to 1 if you have the 'dl' library (-ldl). */ #define HAVE_LIBDL 1 /* Define to 1 if you have the header file. */ @@ -858,25 +858,25 @@ /* Define if system has libiaf that supports set_id */ /* #undef HAVE_LIBIAF */ -/* Define to 1 if you have the `network' library (-lnetwork). */ +/* Define to 1 if you have the 'network' library (-lnetwork). */ /* #undef HAVE_LIBNETWORK */ -/* Define to 1 if you have the `pam' library (-lpam). */ +/* Define to 1 if you have the 'pam' library (-lpam). */ #define HAVE_LIBPAM 1 /* Define to 1 if you have the header file. */ /* #undef HAVE_LIBPROC_H */ -/* Define to 1 if you have the `socket' library (-lsocket). */ +/* Define to 1 if you have the 'socket' library (-lsocket). */ /* #undef HAVE_LIBSOCKET */ /* Define to 1 if you have the header file. */ #define HAVE_LIBUTIL_H 1 -/* Define to 1 if you have the `xnet' library (-lxnet). */ +/* Define to 1 if you have the 'xnet' library (-lxnet). */ /* #undef HAVE_LIBXNET */ -/* Define to 1 if you have the `z' library (-lz). */ +/* Define to 1 if you have the 'z' library (-lz). */ #define HAVE_LIBZ 1 /* Define to 1 if you have the header file. */ @@ -894,65 +894,65 @@ /* Define to 1 if you have the header file. */ /* #undef HAVE_LINUX_SECCOMP_H */ -/* Define to 1 if you have the `llabs' function. */ +/* Define to 1 if you have the 'llabs' function. */ #define HAVE_LLABS 1 /* Define to 1 if you have the header file. */ #define HAVE_LOCALE_H 1 -/* Define to 1 if you have the `localtime_r' function. */ +/* Define to 1 if you have the 'localtime_r' function. */ #define HAVE_LOCALTIME_R 1 -/* Define to 1 if you have the `login' function. */ +/* Define to 1 if you have the 'login' function. */ /* #undef HAVE_LOGIN */ /* Define to 1 if you have the header file. */ #define HAVE_LOGIN_CAP_H 1 -/* Define to 1 if you have the `login_getcapbool' function. */ +/* Define to 1 if you have the 'login_getcapbool' function. */ #define HAVE_LOGIN_GETCAPBOOL 1 -/* Define to 1 if you have the `login_getpwclass' function. */ +/* Define to 1 if you have the 'login_getpwclass' function. */ #define HAVE_LOGIN_GETPWCLASS 1 /* Define to 1 if you have the header file. */ /* #undef HAVE_LOGIN_H */ -/* Define to 1 if you have the `logout' function. */ +/* Define to 1 if you have the 'logout' function. */ /* #undef HAVE_LOGOUT */ -/* Define to 1 if you have the `logwtmp' function. */ +/* Define to 1 if you have the 'logwtmp' function. */ /* #undef HAVE_LOGWTMP */ -/* Define to 1 if the system has the type `long double'. */ +/* Define to 1 if the system has the type 'long double'. */ #define HAVE_LONG_DOUBLE 1 -/* Define to 1 if the system has the type `long long'. */ +/* Define to 1 if the system has the type 'long long'. */ #define HAVE_LONG_LONG 1 /* Define to 1 if you have the header file. */ /* #undef HAVE_MAILLOCK_H */ -/* Define to 1 if your system has a GNU libc compatible `malloc' function, and +/* Define to 1 if your system has a GNU libc compatible 'malloc' function, and to 0 otherwise. */ #define HAVE_MALLOC 1 -/* Define to 1 if you have the `mblen' function. */ +/* Define to 1 if you have the 'mblen' function. */ #define HAVE_MBLEN 1 -/* Define to 1 if you have the `mbtowc' function. */ +/* Define to 1 if you have the 'mbtowc' function. */ #define HAVE_MBTOWC 1 -/* Define to 1 if you have the `memmem' function. */ +/* Define to 1 if you have the 'memmem' function. */ #define HAVE_MEMMEM 1 -/* Define to 1 if you have the `memmove' function. */ +/* Define to 1 if you have the 'memmove' function. */ #define HAVE_MEMMOVE 1 -/* Define to 1 if you have the `memset_s' function. */ +/* Define to 1 if you have the 'memset_s' function. */ #define HAVE_MEMSET_S 1 -/* Define to 1 if you have the `mkdtemp' function. */ +/* Define to 1 if you have the 'mkdtemp' function. */ #define HAVE_MKDTEMP 1 /* define if you have mode_t data type */ @@ -979,50 +979,50 @@ /* Define if you are on NeXT */ /* #undef HAVE_NEXT */ -/* Define to 1 if the system has the type `nfds_t'. */ +/* Define to 1 if the system has the type 'nfds_t'. */ #define HAVE_NFDS_T 1 -/* Define to 1 if you have the `ngetaddrinfo' function. */ +/* Define to 1 if you have the 'ngetaddrinfo' function. */ /* #undef HAVE_NGETADDRINFO */ -/* Define to 1 if you have the `nl_langinfo' function. */ +/* Define to 1 if you have the 'nl_langinfo' function. */ #define HAVE_NL_LANGINFO 1 -/* Define to 1 if you have the `nsleep' function. */ +/* Define to 1 if you have the 'nsleep' function. */ /* #undef HAVE_NSLEEP */ -/* Define to 1 if you have the `ogetaddrinfo' function. */ +/* Define to 1 if you have the 'ogetaddrinfo' function. */ /* #undef HAVE_OGETADDRINFO */ /* Define if you have an old version of PAM which takes only one argument to pam_strerror */ /* #undef HAVE_OLD_PAM */ -/* Define to 1 if you have the `openlog_r' function. */ +/* Define to 1 if you have the 'openlog_r' function. */ /* #undef HAVE_OPENLOG_R */ -/* Define to 1 if you have the `openpty' function. */ +/* Define to 1 if you have the 'openpty' function. */ #define HAVE_OPENPTY 1 /* as a macro */ #define HAVE_OPENSSL_ADD_ALL_ALGORITHMS 1 -/* Define to 1 if you have the `OpenSSL_version' function. */ +/* Define to 1 if you have the 'OpenSSL_version' function. */ #define HAVE_OPENSSL_VERSION 1 -/* Define to 1 if you have the `OpenSSL_version_num' function. */ +/* Define to 1 if you have the 'OpenSSL_version_num' function. */ #define HAVE_OPENSSL_VERSION_NUM 1 /* Define if you have Digital Unix Security Integration Architecture */ /* #undef HAVE_OSF_SIA */ -/* Define to 1 if you have the `pam_getenvlist' function. */ +/* Define to 1 if you have the 'pam_getenvlist' function. */ #define HAVE_PAM_GETENVLIST 1 /* Define to 1 if you have the header file. */ /* #undef HAVE_PAM_PAM_APPL_H */ -/* Define to 1 if you have the `pam_putenv' function. */ +/* Define to 1 if you have the 'pam_putenv' function. */ #define HAVE_PAM_PUTENV 1 /* Define to 1 if you have the header file. */ @@ -1034,74 +1034,74 @@ /* define if you have pid_t data type */ #define HAVE_PID_T 1 -/* Define to 1 if you have the `pledge' function. */ +/* Define to 1 if you have the 'pledge' function. */ /* #undef HAVE_PLEDGE */ -/* Define to 1 if you have the `poll' function. */ +/* Define to 1 if you have the 'poll' function. */ #define HAVE_POLL 1 /* Define to 1 if you have the header file. */ #define HAVE_POLL_H 1 -/* Define to 1 if you have the `ppoll' function. */ +/* Define to 1 if you have the 'ppoll' function. */ #define HAVE_PPOLL 1 -/* Define to 1 if you have the `prctl' function. */ +/* Define to 1 if you have the 'prctl' function. */ /* #undef HAVE_PRCTL */ -/* Define to 1 if you have the `priv_basicset' function. */ +/* Define to 1 if you have the 'priv_basicset' function. */ /* #undef HAVE_PRIV_BASICSET */ /* Define to 1 if you have the header file. */ /* #undef HAVE_PRIV_H */ -/* Define to 1 if you have the `procctl' function. */ +/* Define to 1 if you have the 'procctl' function. */ #define HAVE_PROCCTL 1 /* Define if you have /proc/$pid/fd */ /* #undef HAVE_PROC_PID */ -/* Define to 1 if you have the `proc_pidinfo' function. */ *** 593 LINES SKIPPED *** From nobody Mon Jul 15 18:46:37 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNB4Y4Vcpz5RS69; Mon, 15 Jul 2024 18:46: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNB4Y3wkTz4QTf; Mon, 15 Jul 2024 18:46:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721069197; h=from:from:reply-to:subject:subject: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/19X+NuUI1oqMaMf64+Lx6v/8WPFbM87CDXMhgX5aY=; b=RAAJh1AQaTjRW0O/qKyXF0SPMDpXJY/dzZSg+earqgWJWoqXpX1ikURFMUHsIEWXcso+HI D+eaJVk/CNAgbWumg+hdFSlaPeIl6DSHsltxKTUFEy/h9PN7ebdlw6PWBnSNyaMCLRBcto rftBWfvZS+DoXSqxJyJ4X8G2WdapwY68EXROBpIoXKWHFM0DaHbH+ouD8M8b3HQPrqHXYG uByq5BHkP+U2ZtqwUI6QyPeYJXLSad31aSV8VcAj4mxKsAE4IVZdjmFbx1jwXFp+0odfll 1R0kwNtBKo3oBmXORPEQhSpQfFpafnBxoJOtRNUXLJHP3wKMkhWiAaVpzx+kcQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721069197; a=rsa-sha256; cv=none; b=p3jzZYncYIdymlgy5iHKTI/6Zmy8MsIm5ZnKUFcJYZmsRjVS+GttDD/yAqLTTux7mPNpYq jWN8XmEusk8nWfg/GUpwEQI1OHbns35mb0l/nUdCMmGW+B6UNep6/kYukOyYPOTcTJt3LE WVlyL+chuLEv3Y3ESGuMYvO/SrnMiDetbNKMHXBRB9purAM75H7NuSTKb/sLvgBH9pZsEJ kuwmFq/ShXNflCwR4cdi+f5u2w7ov2wiRuBn0ViiPv2K/zp3g4MCFwXOiWc4YYHtlMfm+/ MLYzRvdGYKZ9aj2W3mcxah673NEWclzrEyDW8GX/dHX5IZQHsHjwVmcUCHMkeQ== 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=1721069197; h=from:from:reply-to:subject:subject: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/19X+NuUI1oqMaMf64+Lx6v/8WPFbM87CDXMhgX5aY=; b=aNYOaShZFitVLYfjQRhW58HuwJaPoKv8RMJCXAyJiQxLqFjycuPAqEgYEzs8Bf0rXPULW7 LurSa8D5S6NOBdxbgc4YzTRsWItWjOyVEwCJLUXZY97/hbIAWtkvh5qlvnQjy8lLe429vZ nlN6GWBm2AkN6TYAmdwdYw0Vd/qDuitey47fIY88DZTbzBlke5R4+OH2egF3PMOwgMc5MZ vEpnZOhSHb5PNAxS6JFGPCaqjD4n0qFTTlFYNcEJxizJu0QRAZU9gmoS/FY5non/ARu7Vh uva7mJfdAeJgbyID+qijApBU8eTylXZBSJZFwGRkWf6xkFk+D0c2kk4P1udo3g== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNB4Y3R1nz13vK; Mon, 15 Jul 2024 18:46:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FIkb57087651; Mon, 15 Jul 2024 18:46:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FIkbX3087648; Mon, 15 Jul 2024 18:46:37 GMT (envelope-from git) Date: Mon, 15 Jul 2024 18:46:37 GMT Message-Id: <202407151846.46FIkbX3087648@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Adrian Chadd Subject: git: 2589197adb19 - main - net80211: migrate the group/unicast key check into inline functions List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: adrian X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 2589197adb199ec37f132dd7e279eb0795713f1e Auto-Submitted: auto-generated The branch main has been updated by adrian: URL: https://cgit.FreeBSD.org/src/commit/?id=2589197adb199ec37f132dd7e279eb0795713f1e commit 2589197adb199ec37f132dd7e279eb0795713f1e Author: Adrian Chadd AuthorDate: 2024-06-06 17:28:03 +0000 Commit: Adrian Chadd CommitDate: 2024-07-15 18:45:30 +0000 net80211: migrate the group/unicast key check into inline functions The way that net80211 and drivers are checking for the /type/ of key is to check if it's in the vap WEP key array and if so, it's a group key. If not, it's a unicast key. That's not only kind of terrible, but it's also going to be problematic with future 802.11 support (for multiple unicast keys and IGTK keys for management frame protection.) So as part of this, remove the places where this is done and instead use a pair inline functions - ieee80211_is_key_global() and ieee80211_is_key_unicast(). They currenly still use the same logic but the drivers and net80211 stack isn't doing it itself. There are still open questions about why keys are not being correctly tagged as GROUP, GTK, PTK, etc. That will be investigated and addressed in follow-up work as a pre-cursor to MFP, IGTK, etc. as mentioned above. Testing: * iwn, rtwn - STA mode Differential Revision: https://reviews.freebsd.org/D45516 --- sys/dev/ath/if_ath_keycache.c | 3 +-- sys/dev/mwl/if_mwl.c | 3 +-- sys/dev/rtwn/if_rtwn_cam.c | 6 ++---- sys/dev/usb/wlan/if_rsu.c | 7 +++---- sys/dev/usb/wlan/if_rum.c | 10 ++++------ sys/dev/wpi/if_wpi.c | 11 +++++------ sys/net80211/ieee80211.c | 31 +++++++++++++++++++++++++++++++ sys/net80211/ieee80211_crypto.c | 16 ++++++++-------- sys/net80211/ieee80211_var.h | 5 +++++ 9 files changed, 60 insertions(+), 32 deletions(-) diff --git a/sys/dev/ath/if_ath_keycache.c b/sys/dev/ath/if_ath_keycache.c index bc94273bf5ce..a58625ad2803 100644 --- a/sys/dev/ath/if_ath_keycache.c +++ b/sys/dev/ath/if_ath_keycache.c @@ -434,8 +434,7 @@ ath_key_alloc(struct ieee80211vap *vap, struct ieee80211_key *k, /* * Only global keys should have key index assigned. */ - if (!(&vap->iv_nw_keys[0] <= k && - k < &vap->iv_nw_keys[IEEE80211_WEP_NKID])) { + if (!ieee80211_is_key_global(vap, k)) { /* should not happen */ DPRINTF(sc, ATH_DEBUG_KEYCACHE, "%s: bogus group key\n", __func__); diff --git a/sys/dev/mwl/if_mwl.c b/sys/dev/mwl/if_mwl.c index 479f3144dce3..49b8b3279c7f 100644 --- a/sys/dev/mwl/if_mwl.c +++ b/sys/dev/mwl/if_mwl.c @@ -1519,8 +1519,7 @@ mwl_key_alloc(struct ieee80211vap *vap, struct ieee80211_key *k, if (k->wk_keyix != IEEE80211_KEYIX_NONE || (k->wk_flags & IEEE80211_KEY_GROUP)) { - if (!(&vap->iv_nw_keys[0] <= k && - k < &vap->iv_nw_keys[IEEE80211_WEP_NKID])) { + if (!ieee80211_is_key_global(vap, k)) { /* should not happen */ DPRINTF(sc, MWL_DEBUG_KEYCACHE, "%s: bogus group key\n", __func__); diff --git a/sys/dev/rtwn/if_rtwn_cam.c b/sys/dev/rtwn/if_rtwn_cam.c index 864c13d78285..d142cd0476e4 100644 --- a/sys/dev/rtwn/if_rtwn_cam.c +++ b/sys/dev/rtwn/if_rtwn_cam.c @@ -113,8 +113,7 @@ rtwn_key_alloc(struct ieee80211vap *vap, struct ieee80211_key *k, struct rtwn_softc *sc = vap->iv_ic->ic_softc; int i, start; - if (&vap->iv_nw_keys[0] <= k && - k < &vap->iv_nw_keys[IEEE80211_WEP_NKID]) { + if (ieee80211_is_key_global(vap, k)) { *keyix = ieee80211_crypto_get_key_wepidx(vap, k); if (sc->sc_hwcrypto != RTWN_CRYPTO_FULL) k->wk_flags |= IEEE80211_KEY_SWCRYPT; @@ -308,8 +307,7 @@ rtwn_process_key(struct ieee80211vap *vap, const struct ieee80211_key *k, return (1); } - if (&vap->iv_nw_keys[0] <= k && - k < &vap->iv_nw_keys[IEEE80211_WEP_NKID]) { + if (ieee80211_is_key_global(vap, k)) { if (sc->sc_hwcrypto == RTWN_CRYPTO_FULL) { struct rtwn_vap *rvp = RTWN_VAP(vap); diff --git a/sys/dev/usb/wlan/if_rsu.c b/sys/dev/usb/wlan/if_rsu.c index e000d1fb5992..c967435250ee 100644 --- a/sys/dev/usb/wlan/if_rsu.c +++ b/sys/dev/usb/wlan/if_rsu.c @@ -1526,10 +1526,10 @@ rsu_key_alloc(struct ieee80211vap *vap, struct ieee80211_key *k, struct rsu_softc *sc = vap->iv_ic->ic_softc; int is_checked = 0; - if (&vap->iv_nw_keys[0] <= k && - k < &vap->iv_nw_keys[IEEE80211_WEP_NKID]) { + if (ieee80211_is_key_global(vap, k)) { *keyix = ieee80211_crypto_get_key_wepidx(vap, k); } else { + /* Note: assumes this is a pairwise key */ if (vap->iv_opmode != IEEE80211_M_STA) { *keyix = 0; /* TODO: obtain keyix from node id */ @@ -1570,8 +1570,7 @@ rsu_process_key(struct ieee80211vap *vap, const struct ieee80211_key *k, } /* Handle group keys. */ - if (&vap->iv_nw_keys[0] <= k && - k < &vap->iv_nw_keys[IEEE80211_WEP_NKID]) { + if (ieee80211_is_key_global(vap, k)) { KASSERT(k->wk_keyix < nitems(sc->group_keys), ("keyix %u > %zu\n", k->wk_keyix, nitems(sc->group_keys))); diff --git a/sys/dev/usb/wlan/if_rum.c b/sys/dev/usb/wlan/if_rum.c index 2720f2ffedcb..edf92e2222b4 100644 --- a/sys/dev/usb/wlan/if_rum.c +++ b/sys/dev/usb/wlan/if_rum.c @@ -1468,8 +1468,7 @@ rum_tx_crypto_flags(struct rum_softc *sc, struct ieee80211_node *ni, flags |= RT2573_TX_CIP_MODE(mode); /* Do not trust GROUP flag */ - if (!(k >= &vap->iv_nw_keys[0] && - k < &vap->iv_nw_keys[IEEE80211_WEP_NKID])) + if (ieee80211_is_key_unicast(vap, k)) flags |= RT2573_TX_KEY_PAIR; else pos += 0 * RT2573_SKEY_MAX; /* vap id */ @@ -3006,8 +3005,7 @@ rum_key_alloc(struct ieee80211vap *vap, struct ieee80211_key *k, struct rum_softc *sc = vap->iv_ic->ic_softc; uint8_t i; - if (!(&vap->iv_nw_keys[0] <= k && - k < &vap->iv_nw_keys[IEEE80211_WEP_NKID])) { + if (ieee80211_is_key_unicast(vap, k)) { if (!(k->wk_flags & IEEE80211_KEY_SWCRYPT)) { RUM_LOCK(sc); for (i = 0; i < RT2573_ADDR_MAX; i++) { @@ -3044,7 +3042,7 @@ rum_key_set(struct ieee80211vap *vap, const struct ieee80211_key *k) return 1; } - group = k >= &vap->iv_nw_keys[0] && k < &vap->iv_nw_keys[IEEE80211_WEP_NKID]; + group = ieee80211_is_key_global(vap, k); return !rum_cmd_sleepable(sc, k, sizeof(*k), 0, group ? rum_group_key_set_cb : rum_pair_key_set_cb); @@ -3061,7 +3059,7 @@ rum_key_delete(struct ieee80211vap *vap, const struct ieee80211_key *k) return 1; } - group = k >= &vap->iv_nw_keys[0] && k < &vap->iv_nw_keys[IEEE80211_WEP_NKID]; + group = ieee80211_is_key_global(vap, k); return !rum_cmd_sleepable(sc, k, sizeof(*k), 0, group ? rum_group_key_del_cb : rum_pair_key_del_cb); diff --git a/sys/dev/wpi/if_wpi.c b/sys/dev/wpi/if_wpi.c index fc5cf02f3a25..11b8a749090d 100644 --- a/sys/dev/wpi/if_wpi.c +++ b/sys/dev/wpi/if_wpi.c @@ -4641,8 +4641,8 @@ again: return !error; } - if (!(kflags & WPI_KFLAG_MULTICAST) && &vap->iv_nw_keys[0] <= k && - k < &vap->iv_nw_keys[IEEE80211_WEP_NKID]) { + if (!(kflags & WPI_KFLAG_MULTICAST) && + ieee80211_is_key_global(vap, k)) { kflags |= WPI_KFLAG_MULTICAST; node.kflags = htole16(kflags); @@ -4726,8 +4726,8 @@ again: return !error; } - if (!(kflags & WPI_KFLAG_MULTICAST) && &vap->iv_nw_keys[0] <= k && - k < &vap->iv_nw_keys[IEEE80211_WEP_NKID]) { + if (!(kflags & WPI_KFLAG_MULTICAST) && + ieee80211_is_key_global(vap, k)) { kflags |= WPI_KFLAG_MULTICAST; node.kflags = htole16(kflags); @@ -4782,8 +4782,7 @@ wpi_process_key(struct ieee80211vap *vap, const struct ieee80211_key *k, } /* Handle group keys. */ - if (&vap->iv_nw_keys[0] <= k && - k < &vap->iv_nw_keys[IEEE80211_WEP_NKID]) { + if (ieee80211_is_key_global(vap, k)) { WPI_NT_LOCK(sc); if (set) wvp->wv_gtk |= WPI_VAP_KEY(k->wk_keyix); diff --git a/sys/net80211/ieee80211.c b/sys/net80211/ieee80211.c index 9f91e31d13a6..ecf87020b066 100644 --- a/sys/net80211/ieee80211.c +++ b/sys/net80211/ieee80211.c @@ -2679,3 +2679,34 @@ ieee80211_channel_type_char(const struct ieee80211_channel *c) return 'b'; return 'f'; } + +/* + * Determine whether the given key in the given VAP is a global key. + * (key index 0..3, shared between all stations on a VAP.) + * + * This is either a WEP key or a GROUP key. + * + * Note this will NOT return true if it is a IGTK key. + */ +bool +ieee80211_is_key_global(const struct ieee80211vap *vap, + const struct ieee80211_key *key) +{ + return (&vap->iv_nw_keys[0] <= key && + key < &vap->iv_nw_keys[IEEE80211_WEP_NKID]); +} + +/* + * Determine whether the given key in the given VAP is a unicast key. + */ +bool +ieee80211_is_key_unicast(const struct ieee80211vap *vap, + const struct ieee80211_key *key) +{ + /* + * This is a short-cut for now; eventually we will need + * to support multiple unicast keys, IGTK, etc) so we + * will absolutely need to fix the key flags. + */ + return (!ieee80211_is_key_global(vap, key)); +} diff --git a/sys/net80211/ieee80211_crypto.c b/sys/net80211/ieee80211_crypto.c index 829653ff1335..d70b3aa4a24a 100644 --- a/sys/net80211/ieee80211_crypto.c +++ b/sys/net80211/ieee80211_crypto.c @@ -62,8 +62,8 @@ static int null_key_alloc(struct ieee80211vap *vap, struct ieee80211_key *k, ieee80211_keyix *keyix, ieee80211_keyix *rxkeyix) { - if (!(&vap->iv_nw_keys[0] <= k && - k < &vap->iv_nw_keys[IEEE80211_WEP_NKID])) { + + if (!ieee80211_is_key_global(vap, k)) { /* * Not in the global key table, the driver should handle this * by allocating a slot in the h/w key table/cache. In @@ -606,9 +606,9 @@ ieee80211_crypto_get_key_wepidx(const struct ieee80211vap *vap, const struct ieee80211_key *k) { - if (k >= &vap->iv_nw_keys[0] && - k < &vap->iv_nw_keys[IEEE80211_WEP_NKID]) + if (ieee80211_is_key_global(vap, k)) { return (k - vap->iv_nw_keys); + } return (-1); } @@ -618,11 +618,11 @@ ieee80211_crypto_get_key_wepidx(const struct ieee80211vap *vap, uint8_t ieee80211_crypto_get_keyid(struct ieee80211vap *vap, struct ieee80211_key *k) { - if (k >= &vap->iv_nw_keys[0] && - k < &vap->iv_nw_keys[IEEE80211_WEP_NKID]) + if (ieee80211_is_key_global(vap, k)) { return (k - vap->iv_nw_keys); - else - return (0); + } + + return (0); } struct ieee80211_key * diff --git a/sys/net80211/ieee80211_var.h b/sys/net80211/ieee80211_var.h index c827984b5f37..53139a3852b8 100644 --- a/sys/net80211/ieee80211_var.h +++ b/sys/net80211/ieee80211_var.h @@ -824,6 +824,11 @@ char ieee80211_channel_type_char(const struct ieee80211_channel *c); #define ieee80211_get_home_channel(_ic) ((_ic)->ic_bsschan) #define ieee80211_get_vap_desired_channel(_iv) ((_iv)->iv_des_chan) +bool ieee80211_is_key_global(const struct ieee80211vap *vap, + const struct ieee80211_key *key); +bool ieee80211_is_key_unicast(const struct ieee80211vap *vap, + const struct ieee80211_key *key); + void ieee80211_radiotap_attach(struct ieee80211com *, struct ieee80211_radiotap_header *th, int tlen, uint32_t tx_radiotap, From nobody Mon Jul 15 18:46:38 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNB4Z5VGYz5RSBd; Mon, 15 Jul 2024 18:46: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNB4Z508Rz4QZJ; Mon, 15 Jul 2024 18:46:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721069198; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ofI+1mYPVlBQCzjLcQ+7Nz2nVNQ5QUIDBi6PgiHF5ak=; b=IbyflN9JykeVMpxXlxq/4JDZ6XQwFLkL5afXsSRZnlyUY9PBb6ohLqYYG3sIeloNCR4Zln cTTkUBhFB1kCy4BGkA835yxAt7yYTTxZuFbUhSEWRI7RIsBhvDJAcnRJFX6s13GnUsSXXJ mG5S0iO+SdWrWVP2NReRN7q44UB46torpfbOEpV4emfGZjdS97w6uoeI60Q2DwfAY+91s5 vgrTCBh/U5wNEztY0xTqg3fZsMGXeRXzozPjBY4v5z37yzMvmOII1x5HspGQVKi6U2U2tI YZf3C3Q36G6+c0He/H6aFqeJyhPJlc+5z1I5w0efHPg1r9a4z5/kuCVjfYAhVQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721069198; a=rsa-sha256; cv=none; b=j2tK/sUUA7xoHm/KI8FN5eZNVFlmZiX8tEWANtNEJsfSvfAdZ/ilxEc1KmQUapnIsDFwrX hfXH52iu0i4Brj3jSmVUwSukvd0pUXbIO3PxA+BTsznzBHetOJX4WTrRcWMGqO7b3hm6j+ Wiz6Gakd8WKM7dyovoydGoF7Luh7Ly96l3UdyW5+H4hryj3CZxggs/cN1xEO8KflNdsvmG vMTXATGQCUqeZJv8pVT1Gt3baP9Z0+EH2HHF28lLY+GVzD8iW7aOJk/9UDGRDRe8v0w2h3 C8T0K78U5K7KYBfyuO6htT2uKXwf7d+IotiqVQSPbvhoa3oXcYKi4/MuYfjHmA== 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=1721069198; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ofI+1mYPVlBQCzjLcQ+7Nz2nVNQ5QUIDBi6PgiHF5ak=; b=f0FNmhn2o26kyTmHqG9Wi5enZDl5sc4L/orJDsUyv5cQL+dOXnV1Sl50SL4MxPB6Q5obRg fD47AN4ty0/g/+J9LuHuRjrG9iLdcKtqcjZtDHuBDKcTU9PP2jmgs2f50k+lQS9/4dTvjS jEW5dclrNO5uPJtchFcuPPNeC+6nrfrzYC0tE7zyfUN38Dg0BWrqmUV7Bjli2iDVMnCn2x r9VJczFrYjPO0uGu7HsCkl83txKtCY66VryIMy5NfrzeT2rq6iFiNk8NN3FWi7KH89g7uY BFFjlnfNJOOmFl7HHh1U7JY8rN2c50Mjolf8y4fYwQsl2ZzEPA2N6doVpnIROg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNB4Z4blNz13jm; Mon, 15 Jul 2024 18:46:38 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FIkcWj087693; Mon, 15 Jul 2024 18:46:38 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FIkc3i087690; Mon, 15 Jul 2024 18:46:38 GMT (envelope-from git) Date: Mon, 15 Jul 2024 18:46:38 GMT Message-Id: <202407151846.46FIkc3i087690@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Adrian Chadd Subject: git: 3ab5e2977883 - main - net80211: fix RSN capability parsing List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: adrian X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 3ab5e29778835065d80cbb6610ece981ac65c4c7 Auto-Submitted: auto-generated The branch main has been updated by adrian: URL: https://cgit.FreeBSD.org/src/commit/?id=3ab5e29778835065d80cbb6610ece981ac65c4c7 commit 3ab5e29778835065d80cbb6610ece981ac65c4c7 Author: Adrian Chadd AuthorDate: 2024-07-09 16:54:21 +0000 Commit: Adrian Chadd CommitDate: 2024-07-15 18:45:40 +0000 net80211: fix RSN capability parsing The RSN capability field may be the last two bytes in the IE. 802.11-2016 9.4.2.25.1 (General) doesn't require anything afterwards - the PMKID/List and Group Management Cipher Suite are optional. Thus having a check of len > 2 will miss the situation where it IS the last field. This showed up when developing MFP, as I'm using optional MFP at home and optional MFP doesn't encrypt group management frames. (It should only add the BIP message integrity check IE in each action frame.) Differential Revision: https://reviews.freebsd.org/D45936 --- sys/net80211/ieee80211_hostap.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/sys/net80211/ieee80211_hostap.c b/sys/net80211/ieee80211_hostap.c index 82d8f8b2907b..1d741ca4d7bf 100644 --- a/sys/net80211/ieee80211_hostap.c +++ b/sys/net80211/ieee80211_hostap.c @@ -1539,9 +1539,14 @@ ieee80211_parse_rsn(struct ieee80211vap *vap, const uint8_t *frm, rsn->rsn_keymgmt = RSN_ASE_8021X_PSK; /* optional RSN capabilities */ - if (len > 2) + if (len >= 2) { rsn->rsn_caps = le16dec(frm); - /* XXXPMKID */ + frm += 2, len -= 2; + } + + /* XXX PMK Count / PMKID */ + + /* XXX Group Cipher Management Suite */ return 0; } From nobody Mon Jul 15 19:15:52 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNBkJ5lVMz5RVTq; Mon, 15 Jul 2024 19:15: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNBkJ5JHFz4Wgl; Mon, 15 Jul 2024 19:15:52 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721070952; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=yAxBPDXfYLpgTC8ygs+gYqX3hmB2HyJa89aA0k4ajJw=; b=lamCgb2fIxJuZSl2AHQgShZ0VSw/OXZ+eaCjr4pFTOMY7w1IdVwQLuvG2Eurf15slNov2d 8aXh2iCAglJ1ia2wpufpIhCLoiuBpCG8VqleFIoK3k/xVFQSe8X5UrCTPanCXpm9bCKN1L Us7WBcrxXqHoalN20dJZ7UvTVq2ZhdPc/KvueStY9cX7qUfH2oeUbgXYkKRJ443UiuMXan 8bRemOX9jLwWM8mQT1zHc7MQ+M9YYMlO9mIA0qUIyz9RblUU4fZQ68AnNPhVngnpW5JhCz OrdXw2WaIUGfHaERlgpzE76Jgi0ulT5JdYBMot+jq0PFdvukzq34xND6X7U0oA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721070952; a=rsa-sha256; cv=none; b=YjJD4n4J+6o3EP6cGq4MslWszDO47qL92I29NYp84SnHqbzf6U5s28q3efQAmQdgw48t7c 7wwk+ZwNbPEfE6C2GhlVY8yYk1ZOIH+XjuJOG4zvFzkmNxMUPINIcYfCd4uNvL0DCyJk07 yYoeNRkdNEV6IF656n7L00BLtympTz0TnlPiq3CEWc+H1dcQ0ctDs3Q7EvRxt/mML9QUEA j5U7/Y44OPe3tRFPqYKC03wSvP3kBXaqU3RNZHFiCR6mYC80zFjWZqZQFc3D1XrW2aSzT9 qg2xuS0KeEsYawfe/L97r5zwCIJiRj1H9wapEzAt5u2SSMrz9bJtVd8kAyAtsQ== 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=1721070952; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=yAxBPDXfYLpgTC8ygs+gYqX3hmB2HyJa89aA0k4ajJw=; b=h+tu1/JdOOlMt/dqA6hvE1pNolriZzdK+L5ZIadQqQv7y/qgz3mMxXawmv0Ab/7OGfMJlq TZnSOTkOavxavCwfWGVyrnk2mOLadUwINWpFqdgfQrFLTyrVIYuGLP5PKNtdLiGQ57xXvq yExCc7rrTnBNs0m68T0LN64pcw/Xm/k87Yy3l1ciWkTWAM8ZHT8ZPZfezqThajtXRU1ipq +/rmXgKMcD8TyNMcMf1CNPVzBhVnJPJF/WXKfU166F9FzmPJytHw1fWPamC+I49LB4yXyA PzcIzje2LCe8U83FjAlvjbsKuOTPC2w7g1RWzGz5K34pYE4dx9B4nW30pNzNYg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNBkJ4mThz14qh; Mon, 15 Jul 2024 19:15:52 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FJFq9I039307; Mon, 15 Jul 2024 19:15:52 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FJFqdO039304; Mon, 15 Jul 2024 19:15:52 GMT (envelope-from git) Date: Mon, 15 Jul 2024 19:15:52 GMT Message-Id: <202407151915.46FJFqdO039304@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 0a34d050ae8e - main - acpi: Narrow workaround for broken interrupt settings on x86 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 0a34d050ae8ea14feddd3d2a62fd2f612613b2c5 Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=0a34d050ae8ea14feddd3d2a62fd2f612613b2c5 commit 0a34d050ae8ea14feddd3d2a62fd2f612613b2c5 Author: John Baldwin AuthorDate: 2024-07-15 19:13:08 +0000 Commit: John Baldwin CommitDate: 2024-07-15 19:13:51 +0000 acpi: Narrow workaround for broken interrupt settings on x86 Commit 9a7bf07ccdc1 from 2016 introduced a workaround for some broken BIOSes that specified active-lo instead of active-hi polarity for ISA IRQs for UARTs. The workaround assumed that edge-sensitive ISA IRQs on x86 should always be active-hi. However, some recent AMD systems actually use active-lo edge-sensitive ISA IRQs (and not just for UARTs, but also for the keyboard and PS/2 mouse devices) and the override causes interrupts to be dropped resulting in boot time hangs, non-working keyboards, etc. Add a hw.acpi.override_isa_irq_polarity tunable (readable as a sysctl post-boot) to control this quirk. It can be set to 1 to force enable the override and 0 to disable it. The log of original message mentions an Intel motherboard as the sample case, so default the tunable to 1 on systems with an Intel CPU and 0 otherwise. Special thanks to Matthias Lanter for tracking down boot time issues on recent AMD systems to mismatched interrupt polarity. PR: 270707 Reported by: aixdroix_OSS@protonmail.com, Michael Dexter Reported by: mfw_burn@pm.me, Hannes Hfauswedell Reported by: Matthias Lanter Reported by: William Bulley Reviewed by: imp, emaste MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D45554 --- share/man/man4/acpi.4 | 8 +++++++- sys/dev/acpica/acpi.c | 19 +++++++++++++++++++ sys/dev/acpica/acpi_resource.c | 11 ++++------- sys/dev/acpica/acpivar.h | 12 ++++++++++++ 4 files changed, 42 insertions(+), 8 deletions(-) diff --git a/share/man/man4/acpi.4 b/share/man/man4/acpi.4 index 434e97d529f5..cdad3ceeedfc 100644 --- a/share/man/man4/acpi.4 +++ b/share/man/man4/acpi.4 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd October 12, 2021 +.Dd July 15, 2024 .Dt ACPI 4 .Os .Sh NAME @@ -256,6 +256,12 @@ is a valid list of two interfaces .Qq Li FreeBSD and .Qq Li Linux . +.It Va hw.acpi.hw.acpi.override_isa_irq_polarity (x86) +Forces active-lo polarity for edge-triggered ISA interrupts. +Some older systems incorrectly specify active-lo polarity for ISA +interrupts and this override fixes those systems. +This override is enabled by default on systems with Intel CPUs, +but can be enabled or disabled by setting the tunable explicitly. .It Va hw.acpi.reset_video Enables calling the VESA reset BIOS vector on the resume path. This can fix some graphics cards that have problems such as LCD white-out diff --git a/sys/dev/acpica/acpi.c b/sys/dev/acpica/acpi.c index 24d7027f165d..91a1636f2808 100644 --- a/sys/dev/acpica/acpi.c +++ b/sys/dev/acpica/acpi.c @@ -55,6 +55,8 @@ #if defined(__i386__) || defined(__amd64__) #include #include +#include +#include #endif #include #include @@ -297,6 +299,10 @@ int acpi_susp_bounce; SYSCTL_INT(_debug_acpi, OID_AUTO, suspend_bounce, CTLFLAG_RW, &acpi_susp_bounce, 0, "Don't actually suspend, just test devices."); +#if defined(__amd64__) || defined(__i386__) +int acpi_override_isa_irq_polarity; +#endif + /* * ACPI standard UUID for Device Specific Data Package * "Device Properties UUID for _DSD" Rev. 2.0 @@ -611,6 +617,19 @@ acpi_attach(device_t dev) OID_AUTO, "handle_reboot", CTLFLAG_RW, &sc->acpi_handle_reboot, 0, "Use ACPI Reset Register to reboot"); +#if defined(__amd64__) || defined(__i386__) + /* + * Enable workaround for incorrect ISA IRQ polarity by default on + * systems with Intel CPUs. + */ + if (cpu_vendor_id == CPU_VENDOR_INTEL) + acpi_override_isa_irq_polarity = 1; + SYSCTL_ADD_INT(&sc->acpi_sysctl_ctx, SYSCTL_CHILDREN(sc->acpi_sysctl_tree), + OID_AUTO, "override_isa_irq_polarity", CTLFLAG_RDTUN, + &acpi_override_isa_irq_polarity, 0, + "Force active-hi polarity for edge-triggered ISA IRQs"); +#endif + /* * Default to 1 second before sleeping to give some machines time to * stabilize. diff --git a/sys/dev/acpica/acpi_resource.c b/sys/dev/acpica/acpi_resource.c index 87b82a574beb..1257ed30cc65 100644 --- a/sys/dev/acpica/acpi_resource.c +++ b/sys/dev/acpica/acpi_resource.c @@ -159,14 +159,11 @@ acpi_config_intr(device_t dev, ACPI_RESOURCE *res) } #if defined(__amd64__) || defined(__i386__) - /* - * XXX: Certain BIOSes have buggy AML that specify an IRQ that is - * edge-sensitive and active-lo. However, edge-sensitive IRQs - * should be active-hi. Force IRQs with an ISA IRQ value to be - * active-hi instead. - */ - if (irq < 16 && trig == ACPI_EDGE_SENSITIVE && pol == ACPI_ACTIVE_LOW) + if (irq < 16 && trig == ACPI_EDGE_SENSITIVE && pol == ACPI_ACTIVE_LOW && + acpi_override_isa_irq_polarity) { + device_printf(dev, "forcing active-hi polarity for IRQ %u\n", irq); pol = ACPI_ACTIVE_HIGH; + } #endif BUS_CONFIG_INTR(dev, irq, (trig == ACPI_EDGE_SENSITIVE) ? INTR_TRIGGER_EDGE : INTR_TRIGGER_LEVEL, (pol == ACPI_ACTIVE_HIGH) ? diff --git a/sys/dev/acpica/acpivar.h b/sys/dev/acpica/acpivar.h index 2322ab96014b..a71eb9b47eb7 100644 --- a/sys/dev/acpica/acpivar.h +++ b/sys/dev/acpica/acpivar.h @@ -234,6 +234,18 @@ extern int acpi_quirks; #define ACPI_Q_TIMER (1 << 1) #define ACPI_Q_MADT_IRQ0 (1 << 2) +#if defined(__amd64__) || defined(__i386__) +/* + * Certain Intel BIOSes have buggy AML that specify an IRQ that is + * edge-sensitive and active-lo. Normally, edge-sensitive IRQs should + * be active-hi. If this value is non-zero, edge-sensitive ISA IRQs + * are forced to be active-hi instead. At least some AMD systems use + * active-lo edge-sensitive ISA IRQs, so this setting is only enabled + * by default on systems with Intel CPUs. + */ +extern int acpi_override_isa_irq_polarity; +#endif + /* * Plug and play information for device matching. Matching table format * is compatible with ids parameter of ACPI_ID_PROBE bus method. From nobody Mon Jul 15 19:15:53 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNBkL0r8Jz5RVRT; Mon, 15 Jul 2024 19:15: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNBkK5vspz4WS4; Mon, 15 Jul 2024 19:15:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721070953; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=raARJ4BItTPCU43qM4kVSTknuC8xF3EvU4v74IfQyUA=; b=VgyfzeCNSKcH8FSUkCB8IomJEzuwuRKVcq+SAV2VG6ppFrJacAjqoKeM+ti1XqbyWOZoPU y312hhXlD5X2F+WaY4Vl9gtMVmFsANHBEwEE8F3nfodialLf8kL8Aabf+8zXGK3ehDfPEI AO7+MvmfYdIkhvI6Ld0ZOKt+brvy61O5lWpk+PF/dlhOvU3X+2LVUBQbcSpinnSLOh5k71 KaonQ23JsxcA2tbKjmZmnFzKRRv7mCDMnIEoRiA+Gi33JYGoFZ8uhiucGlynN9WT1yvhDl 3+524taCXVqS2u5j/QWqVBJj0xHllF7IflNKDU5T3TcFIWv86RAdeHrdOqU27Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721070953; a=rsa-sha256; cv=none; b=oxUuMw1qaAuW7Qo2ncfU7cyoT8yxBzcLalMZLfOfs9YE7ZwL/3lqeHUGSdN5E6YAaU0/jX 5zGcs3JTdI0fBhxt5SRC5f3tA7yWAjh8lD02JANRMyvQ212VpRRSx0w+LUv03DuR5BDs1q 7waix3WFgWWW1FLsKTIl/eu4a8kYUAW1pqPBgCVcYpqdBQ06dhZk/nNisXmPw8GbUPeAxq UPk1uB7toMNzlE+s6+Hyqc2LqTpSscyA79gKmm/s5BpIkEPbV/7jBZZFU8xIVGs4ri2F5V 46R6+E+un2W/mg9XHDCJ7u5+1s2dfzCexZztV+Xk0Cw3Xkja4u++lPjshTzlkA== 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=1721070953; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=raARJ4BItTPCU43qM4kVSTknuC8xF3EvU4v74IfQyUA=; b=GDtqYqEDvGLpPijUpM1HCdGTQXL9bQaogOJIPu+R8hJQHyeoNrsXxB3amriB7hbFiE/44f YO9eJ5D7I8dJYtXre9Mov9oiwGhTz54OqjiTOV/m4kLs6Sb6CXD5UykTqsrI39uYHZMdAp QxJjaXAy2nHIugY1AtizNXLfaAseZQckC5sVd3PCgI2FYDN85eKQV5tbTIFv7tmdWyiYav A5gFuR5OfS6Mxj8QTOQE/HL9WM1GPng9ef5lKOG9/49k1gr6CErItwYnP0xcya8BnFBAIK 3QrDY56yZXdowrnELg+GSfuS4K0y9aZ/1Zcl2hD8lZe926Zbno18yldBjqwOYA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNBkK5VlDz14FK; Mon, 15 Jul 2024 19:15:53 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FJFrVr039365; Mon, 15 Jul 2024 19:15:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FJFr7L039362; Mon, 15 Jul 2024 19:15:53 GMT (envelope-from git) Date: Mon, 15 Jul 2024 19:15:53 GMT Message-Id: <202407151915.46FJFr7L039362@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 9cc06bf7aa28 - main - amd64 GENERIC: Switch uart hints from "isa" to "acpi" List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9cc06bf7aa2846c35483de567779bb8afc289f53 Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=9cc06bf7aa2846c35483de567779bb8afc289f53 commit 9cc06bf7aa2846c35483de567779bb8afc289f53 Author: John Baldwin AuthorDate: 2024-07-15 19:14:01 +0000 Commit: John Baldwin CommitDate: 2024-07-15 19:15:29 +0000 amd64 GENERIC: Switch uart hints from "isa" to "acpi" This causes these hints to be only used to wire device unit numbers for serial ports enumerated by ACPI but will not create ISA device nodes if ACPI doesn't enumerate them. Note that IRQ hints are not used for wiring so have been removed. PR: 270707 Reported by: aixdroix_OSS@protonmail.com, Michael Dexter Reported by: mfw_burn@pm.me, Hannes Hfauswedell Reported by: Matthias Lanter Reported by: William Bulley Reviewed by: imp MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D45945 --- sys/amd64/conf/GENERIC.hints | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/sys/amd64/conf/GENERIC.hints b/sys/amd64/conf/GENERIC.hints index 7c2a3f28b9ce..4f6121c7cf77 100644 --- a/sys/amd64/conf/GENERIC.hints +++ b/sys/amd64/conf/GENERIC.hints @@ -6,13 +6,11 @@ hint.psm.0.at="atkbdc" hint.psm.0.irq="12" hint.sc.0.at="isa" hint.sc.0.flags="0x100" -hint.uart.0.at="isa" +hint.uart.0.at="acpi" hint.uart.0.port="0x3F8" hint.uart.0.flags="0x10" -hint.uart.0.irq="4" -hint.uart.1.at="isa" +hint.uart.1.at="acpi" hint.uart.1.port="0x2F8" -hint.uart.1.irq="3" hint.atrtc.0.at="isa" hint.atrtc.0.port="0x70" hint.atrtc.0.irq="8" From nobody Mon Jul 15 19:20:41 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNBqv0Vg0z5RVqY; Mon, 15 Jul 2024 19:20:43 +0000 (UTC) (envelope-from jhb@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 "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNBqt5bGlz4Xkk; Mon, 15 Jul 2024 19:20:42 +0000 (UTC) (envelope-from jhb@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721071242; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=EPAPmbwXKfNrY2d0Wx8aNxbT7JKNQHKGC1yXxefQjzc=; b=ydzJQo637h4nldceTZbAasKodsaIQgauFa/a0RPGTyemXU2+sJ7DxI325/RNvzEIw7cwRl wrRemVsWqaF4uD5789S+q4K4VCtKpOvN5SjLi0CpDPwd4XI2TGTlCN218Soc+IswVmgnmP R5YKFRM+9lTjtVuMdW7Fw4E/pRo6XrAtXJlRB8TWKF5gok6K06HEARy+mlmmP+1Q6mQHWh ZeLopzu3NRUxbkYQaiiI97fuxGYd5e+s+MIcUZs7wh05X/kE7hi4XlRU/oeUShOtPY/aZS om1RNTu6ggfsRE9/lFHpJ1lZzt7zeT6vzliThF/pYrXh34XixHeFM6lQVgC+CA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721071242; a=rsa-sha256; cv=none; b=G7OEQdqaBLZDYLdyKCvOVF7Un8riyDH630DEdbYaNodNNRfBguAUZ0+iILOac5ceOQyxTA GWyQKfSryrErb8cPwoVl1zVtLvzjV7A7dPh1sxryc/HOLtf/ksu6ctIDCjM3lqjRBU+SJw 8lUQK+4jmKVQs2opnJHK1H9u8nJ2fQmn7D0HvUpdJkkyTArDWnlbP1aMGD1XIMm5S1unlG oGjVn+PJ9ngE4jBl2GBK62Xb7njn6nQGygdSkqEVPMCrxxu16nOnwlBHk9UGznLVaE6tVz VBSzirORKzCSk+NRtuiIMMIvf6MaRPk2WQdxErvXZ6H74BKu0QzjJS3GOTVClg== 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=1721071242; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=EPAPmbwXKfNrY2d0Wx8aNxbT7JKNQHKGC1yXxefQjzc=; b=wO9WRZueAZPyqQpr4sQKJI9b1thk1VUo4tb047H7WV6pxEykKgsheZL0Xb1pA+S6oY5VKE xvFttndNSB4va/1Iwr7/l24OSWcK1hT9nTkt0hPA5QTPaUay48hS3UJTwVNxJ6itknXTQ/ 1AU+PR2v9TZeuxyKGSPQIDroamp6kAQHWXXI7DulJWSMMDn0dOI75Adpe6fZCrXgfpUOew xJod4mGQ7b7e7IHkAlks3wHBqXRdhIGk8FMexkTR28DfgHaOrw2tP9xR80VvMaslm/WLbP DnNjCguBYm6VAgWVCBc1gdK4flDb+drH8aKgIHo/Ewue8CMEXb2BHp4DMlIHzw== Received: from [IPV6:2601:5c0:4200:b830:28d3:efa9:9f5c:a97f] (unknown [IPv6:2601:5c0:4200:b830:28d3:efa9:9f5c:a97f]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: jhb) by smtp.freebsd.org (Postfix) with ESMTPSA id 4WNBqt3xt2z1Prx; Mon, 15 Jul 2024 19:20:42 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Message-ID: Date: Mon, 15 Jul 2024 15:20:41 -0400 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: git: 9cc06bf7aa28 - main - amd64 GENERIC: Switch uart hints from "isa" to "acpi" Content-Language: en-US From: John Baldwin To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org References: <202407151915.46FJFr7L039362@gitrepo.freebsd.org> In-Reply-To: <202407151915.46FJFr7L039362@gitrepo.freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 7/15/24 15:15, John Baldwin wrote: > The branch main has been updated by jhb: > > URL: https://cgit.FreeBSD.org/src/commit/?id=9cc06bf7aa2846c35483de567779bb8afc289f53 > > commit 9cc06bf7aa2846c35483de567779bb8afc289f53 > Author: John Baldwin > AuthorDate: 2024-07-15 19:14:01 +0000 > Commit: John Baldwin > CommitDate: 2024-07-15 19:15:29 +0000 > > amd64 GENERIC: Switch uart hints from "isa" to "acpi" > > This causes these hints to be only used to wire device unit numbers > for serial ports enumerated by ACPI but will not create ISA device > nodes if ACPI doesn't enumerate them. Note that IRQ hints are not > used for wiring so have been removed. > > PR: 270707 > Reported by: aixdroix_OSS@protonmail.com, Michael Dexter > Reported by: mfw_burn@pm.me, Hannes Hfauswedell > Reported by: Matthias Lanter > Reported by: William Bulley > Reviewed by: imp > MFC after: 1 week > Differential Revision: https://reviews.freebsd.org/D45945 > --- > sys/amd64/conf/GENERIC.hints | 6 ++---- > 1 file changed, 2 insertions(+), 4 deletions(-) > > diff --git a/sys/amd64/conf/GENERIC.hints b/sys/amd64/conf/GENERIC.hints > index 7c2a3f28b9ce..4f6121c7cf77 100644 > --- a/sys/amd64/conf/GENERIC.hints > +++ b/sys/amd64/conf/GENERIC.hints > @@ -6,13 +6,11 @@ hint.psm.0.at="atkbdc" > hint.psm.0.irq="12" > hint.sc.0.at="isa" > hint.sc.0.flags="0x100" > -hint.uart.0.at="isa" > +hint.uart.0.at="acpi" > hint.uart.0.port="0x3F8" > hint.uart.0.flags="0x10" > -hint.uart.0.irq="4" > -hint.uart.1.at="isa" > +hint.uart.1.at="acpi" > hint.uart.1.port="0x2F8" > -hint.uart.1.irq="3" > hint.atrtc.0.at="isa" > hint.atrtc.0.port="0x70" > hint.atrtc.0.irq="8" Warner would like to purge more of this file (almost all of it) which is probably correct. Warner believes that the uart0 flags to set serial console aren't needed for loaders from FreeBSD 9+ due to the hw.uart.* tunables modern loaders set. I'm less certain about hints for "fixed" devices such as attimer0, atrtc0, and atkbdc0. I feel like some systems have failed to enumerate those in the past, though such systems may be i386-only. The sc0 hints I think can go away once we fully deprecate sc(4) in favor of only vt(4). I've chosen to leave i386 alone as there's still some ancient i386 cruft, but on amd64 we have a higher bar (e.g. ACPI is de facto required for amd64). Also, i386 kernels have one foot in the grave already. This commit is also somewhat narrow in scope as I plan to merge it back to 13 and 14. -- John Baldwin From nobody Mon Jul 15 20:13:17 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WND0Z57h0z5RZ4j; Mon, 15 Jul 2024 20:13:18 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WND0Z410tz4cjL; Mon, 15 Jul 2024 20:13:18 +0000 (UTC) (envelope-from jhb@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721074398; 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=U1wox1LMz6GN2mnC/H1991KjuCABxi23L7xTfPwshLY=; b=jv9PFZUaFXK0wzbjb39OkuHlyiEZbwIP2vEadNGwEJBLL3kWgiCOskOmdgnCm7TpOI3YPI pm7ImG0qO23HtyVMUxREYHX0dFzJDuoaDsCRvfe20qWSol3dTeKeuIdmfi46VffhAu3IbQ u0vU5Qnc/dRXiN8x3AQHE3Rq//H3fddWot889JSZCh+87a1pUF7IPhQbtjwHD+nXNF/6SP LwU6TrduDL9r10hngAlVc8YcQf81judUKvohs7bND5U/harKRGRNB6AEfr228GVPSavq0Y g0v15NvMi5C/9rNUNbZA3hKtvL9tOZir36/svPWPUGn2scRYk1IbZTQx5kFMcw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721074398; a=rsa-sha256; cv=none; b=afADPdE70DXWmjP4Jj4R8+lO8DDifv81aiNBJahIA/Fzd5sf2UVYnApn8LnoOkDNTE0Yon 6KJ4Gv7Z7Sv5bANEzryqoVYDXyot7Iv0ZZsVM932xda8k1aa/b/3D4ru0PO5911Y7cmkue HCElLx2+CVQHeDZjRHR5zV2IOnzQYgKeeF7+7bsFx4FYg7gSSIILd3GO7vqig9xrXlbYMN I6kMqxElMKGUtCAdov0naJ0EtIVGvmbyfIkvOuVswX7r05Tk14bHE32aBIxa8cHV5galI3 odXO9wUOoyKVKA+mPabL6kUhX9y2yRSSejhv+m55GlHAh8s9oE+auT4XHRP3Ig== 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=1721074398; 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=U1wox1LMz6GN2mnC/H1991KjuCABxi23L7xTfPwshLY=; b=eMofur4F4DERStJ7RDGMW3UdLdA2SUR1YJ2gOTDqTa0mN8jC6/6CyobablIt8kgdPUekX+ VI1PpUiBeEQKmkmFCcx8UVtl5u7vIy0AE/gIVfJd8dkbo/ANlUKg5nA5yCc1t3ajdrB8af j+F5sFO7GhxEOMb22wZ4mbQnThAGSiddDSaNr58q5is/F1q4Ig0fxXWYkqYb5D1gmVuiA4 L32/xEb5Xjjngz1L6zzL5HfNKPbQeqldZvmiTmsaIeU7Wj4OVb5sXVehKqZQBAYUaDK5qo 2dV0Ww5QmWrMijZT14Mr70VwGdShfIr9GLnN/t43wGktvjLrh/7TSIydsSZZXQ== Received: from [IPV6:2601:5c0:4200:b830:28d3:efa9:9f5c:a97f] (unknown [IPv6:2601:5c0:4200:b830:28d3:efa9:9f5c:a97f]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: jhb) by smtp.freebsd.org (Postfix) with ESMTPSA id 4WND0Z1qqQz1RLl; Mon, 15 Jul 2024 20:13:18 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Message-ID: <752a3f0a-438e-4465-a8ae-47700e79306d@FreeBSD.org> Date: Mon, 15 Jul 2024 16:13:17 -0400 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: git: 87ee63bac69d - main - locks: add a runtime check for missing turnstile Content-Language: en-US To: Mateusz Guzik Cc: Mateusz Guzik , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org References: <202407111107.46BB7uSb007077@gitrepo.freebsd.org> <81cfe7ad-cbee-4122-abef-e47ce2b34f05@FreeBSD.org> From: John Baldwin In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit On 7/15/24 14:40, Mateusz Guzik wrote: > On Mon, Jul 15, 2024 at 8:33ā€ÆPM Mateusz Guzik wrote: >> >> On Mon, Jul 15, 2024 at 8:21ā€ÆPM John Baldwin wrote: >>> >>> On 7/15/24 13:59, Mateusz Guzik wrote: >>>> On Mon, Jul 15, 2024 at 6:22ā€ÆPM John Baldwin wrote: >>>>> >>>>> On 7/11/24 07:07, Mateusz Guzik wrote: >>>>>> The branch main has been updated by mjg: >>>>>> >>>>>> URL: https://cgit.FreeBSD.org/src/commit/?id=87ee63bac69dc49291f55590b8baa57cad6c7d85 >>>>>> >>>>>> commit 87ee63bac69dc49291f55590b8baa57cad6c7d85 >>>>>> Author: Mateusz Guzik >>>>>> AuthorDate: 2024-07-11 00:17:27 +0000 >>>>>> Commit: Mateusz Guzik >>>>>> CommitDate: 2024-07-11 11:06:52 +0000 >>>>>> >>>>>> locks: add a runtime check for missing turnstile >>>>>> >>>>>> There are sometimes bugs which result in the unlock fast path failing, >>>>>> which in turns causes a not-helpful crash report when dereferencing a >>>>>> NULL turnstile. Help debugging such cases by pointing out what happened >>>>>> along with some debug. >>>>>> >>>>>> Sponsored by: Rubicon Communications, LLC ("Netgate") >>>>>> --- >>>>>> sys/kern/kern_mutex.c | 4 +++- >>>>>> sys/kern/kern_rwlock.c | 16 ++++++++++++---- >>>>>> 2 files changed, 15 insertions(+), 5 deletions(-) >>>>>> >>>>>> diff --git a/sys/kern/kern_mutex.c b/sys/kern/kern_mutex.c >>>>>> index 90361b23c09a..0fa624cc4bb1 100644 >>>>>> --- a/sys/kern/kern_mutex.c >>>>>> +++ b/sys/kern/kern_mutex.c >>>>>> @@ -1053,7 +1053,9 @@ __mtx_unlock_sleep(volatile uintptr_t *c, uintptr_t v) >>>>>> turnstile_chain_lock(&m->lock_object); >>>>>> _mtx_release_lock_quick(m); >>>>>> ts = turnstile_lookup(&m->lock_object); >>>>>> - MPASS(ts != NULL); >>>>>> + if (__predict_false(ts == NULL)) { >>>>>> + panic("got NULL turnstile on mutex %p v %zx", m, v); >>>>>> + } >>>>> >>>>> Hmm, this is just an expanded KASSERT() but always on rather than conditional on INVARIANTS? >>>>> >>>>> Do you have examples of the type of bugs that cause this? (Is it unlocking a freed mutex >>>>> or the like?) We generally hide all these types of checks under INVARIANTS rather than >>>>> shipping them in release kernels. >>>>> >>>> >>>> Use-after-free, overflow, underflow, bitflip or what have you all can >>>> fail the fast path. >>>> >>>> Once that happens and the kernel crashes with a null pointer deref, >>>> here is a crash at netgate which prodded this: >>>> calltrap() at calltrap+0x8/frame 0xfffffe0106720920 >>>> --- trap 0xc, rip = 0xffffffff80d5ab70, rsp = 0xfffffe01067209f0, rbp >>>> = 0xfffffe0106720a00 --- >>>> turnstile_broadcast() at turnstile_broadcast+0x40/frame 0xfffffe0106720a00 >>>> __rw_wunlock_hard() at __rw_wunlock_hard+0x9e/frame 0xfffffe0106720a30 >>>> nd6_resolve_slow() at nd6_resolve_slow+0x2d7/frame 0xfffffe0106720aa0 >>>> nd6_resolve() at nd6_resolve+0x125/frame 0xfffffe0106720b10 >>>> ether_output() at ether_output+0x4e7/frame 0xfffffe0106720ba0 >>>> ip_output_send() at ip_output_send+0xdc/frame 0xfffffe0106720be0 >>>> ip_output() at ip_output+0x1295/frame 0xfffffe0106720ce0 >>>> ip_forward() at ip_forward+0x3c2/frame 0xfffffe0106720d90 >>>> ip_input() at ip_input+0x705/frame 0xfffffe0106720df0 >>>> swi_net() at swi_net+0x138/frame 0xfffffe0106720e60 >>>> ithread_loop() at ithread_loop+0x257/frame 0xfffffe0106720ef0 >>>> fork_exit() at fork_exit+0x7f/frame 0xfffffe0106720f30 >>>> fork_trampoline() at fork_trampoline+0xe/frame 0xfffffe0106720f30 >>>> --- trap 0, rip = 0, rsp = 0, rbp = 0 --- >>>> >>>> Neither the register dump nor anything in the backtrace indicate what happened. >>>> >>>> Since the kernel is going down anyway, one may as well get some debug from it. >>> >>> If you don't mind the extra branches for sanity checks, why not just run with >>> INVARIANTS? That is, what makes these particular assertions different from >>> other assertions such that they should be on unconditionally? The last line below >>> applies to pretty much every other assertion in the tree. >>> >> >> This adds a branch in the slowpath, a spot which should relatively >> rarely execute compared to the fast path. On top of that the branch at >> hand does not do any extra memory accesses or complex arithmetic. >> >> So no, I don't think I may as well run with INVARIANTS. > > How about this: if you strongly about this branch, feel free to revert > the commit, I'm just going to keep the change at Netgate. > > But should you do it, make sure to not add avoidable branches in your stuff. It's more that I think this is an unusual case (unconditional assertions rather than conditional on INVARIANTS) such that it's probably worth being a bit more explicit about that in the log with the rationale, etc. That is, I don't think "runtime check" quite communicates that you are intentionally doing an unconditional assertion, and a bit more detail about the specific types of bugs might have been useful in the log as well. I think it's fine if we want to have some checks that are always on, but it's currently quite rare so needs a bit more rationale in the log than other changes is all. -- John Baldwin From nobody Mon Jul 15 20:18:06 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WND662Y00z5RZhQ; Mon, 15 Jul 2024 20:18: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WND6622nGz4dD2; Mon, 15 Jul 2024 20:18:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721074686; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Xoe3szaHstUvtgEZAHAl36dMXFLwd+zRetXm223FeKo=; b=uBRNn9HMBT1Ir9QZ3QpbnVsX+janaZH06BTNuuU9FgbD/OfHDLv8wCURImIyltDRMXTGyw OdPv9wIFL3xF2Gg6n4XLWzehbBLP5mau2062F50x8flUWBATLyctiLJQNupG/juSsJWK+S qjZ8qqrF5LBFyB5yRwmmgONavRUv8Q5u4J/ShnmWqN8EexZms3/h8YNz51lfTO0VOJ58jv nqLKj7Vq3hBk4Wxmf8WUIh/yFfbfUyr9RY5t+efs+Chww+pDsog4/uS2LtiPqXB8ddgkt1 o0feTfzoE3/m51EwxnHZ9PqxGCSo7NY+HwtU3UPJdg8gYiinvb3tUi6RMG/PYA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721074686; a=rsa-sha256; cv=none; b=BRE3StriMm1FpB7/iVc3jeAzx7taGrpmzQecx+7971Hb2Foagr2GvgrP8Z2cxnsV/MsT98 fQ29Lk0LZmi2tbBTnP238CYl8TXaLQt+g6ry8FPWjn09JcTYQLV1r8lpNrDXObgCSHwWbV qbBMElmg8CVb0mrD8JSViIh/yWaGqfVx0+9euNDoVZ2j9I8erNLgVM3n9OOAO72hc3jbFT /HqvyBzY0pg1vf35vf4XIk4KsIInxG2t7AgjBnBAjtk2eyutYklrBJxNRVxyCikcOUJ0y6 DyVx8iYwfhQ3S8XjGKP9Hj9uUWeS9Fb8ylv/ZfqghWbFmsSdkDeJgHY7W0yw1w== 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=1721074686; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Xoe3szaHstUvtgEZAHAl36dMXFLwd+zRetXm223FeKo=; b=ds9gowrEQhbVebciQ6LINzHnyeyWaAi3TBp2uGQZKA8nJvHP1tIo/4bVhqMWy0DdoqUUxP tvOuu/YrUqgksrRazQBCkN+MLXwcCO+s3zKZQZ4LHz6Q6q8hOqcchsIrAxe5gHYNbYuifW WgAvva0Qr6mKne+1AIBkUGER2FSVbyvCgC/GK2SwLt8G54/Qle7T8IsnqFss718P8OoTZ2 zSN67RqfofMyGLwua90g9JHtRtFqEEaT9PZtSVnJUO6rGOO/jhjxJn7JrkF2H+YV0epG9V 3uuupW6MofQdfPHZLizGFcmavorGH7534OUlcG2D8JqhSAMVcXlBhoysLqrJ6Q== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WND661XNLz15fv; Mon, 15 Jul 2024 20:18:06 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FKI6mo041764; Mon, 15 Jul 2024 20:18:06 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FKI6pV041761; Mon, 15 Jul 2024 20:18:06 GMT (envelope-from git) Date: Mon, 15 Jul 2024 20:18:06 GMT Message-Id: <202407152018.46FKI6pV041761@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kyle Evans Subject: git: 5862c891bb7c - main - kern: zero out stack buffer after copying out random bits List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kevans X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 5862c891bb7c588aa00538d85eb26ffe77d3f709 Auto-Submitted: auto-generated The branch main has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=5862c891bb7c588aa00538d85eb26ffe77d3f709 commit 5862c891bb7c588aa00538d85eb26ffe77d3f709 Author: Kyle Evans AuthorDate: 2024-07-15 20:17:47 +0000 Commit: Kyle Evans CommitDate: 2024-07-15 20:17:47 +0000 kern: zero out stack buffer after copying out random bits The kern.arandom sysctl handler uses an intermediate buffer on the stack to hold random data that it subsequently copies out to the sysctl request. Err on the side of caution and zero out the stack buffer after we're done with it to avoid a potential entropy leak later on. Reviewed by: cem, emaste, markj MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D45978 --- sys/kern/kern_mib.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/sys/kern/kern_mib.c b/sys/kern/kern_mib.c index 5724ed3f6932..fe6e49865682 100644 --- a/sys/kern/kern_mib.c +++ b/sys/kern/kern_mib.c @@ -182,10 +182,14 @@ sysctl_kern_arnd(SYSCTL_HANDLER_ARGS) { char buf[256]; size_t len; + int error; len = MIN(req->oldlen, sizeof(buf)); read_random(buf, len); - return (SYSCTL_OUT(req, buf, len)); + + error = SYSCTL_OUT(req, buf, len); + explicit_bzero(buf, len); + return (error); } SYSCTL_PROC(_kern, KERN_ARND, arandom, From nobody Mon Jul 15 20:22:43 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNDCR2TwKz5Rb4p; Mon, 15 Jul 2024 20:22: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNDCR1psFz4f2R; Mon, 15 Jul 2024 20:22:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721074963; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=/jCwvTx4uNjZsenYc+ZGXdPoMFtIqkCaatHFbFgVZZk=; b=ZcfbwAQ04QW9bBlqug8OSNhXN+WTkASu5Q+C0I9euuw4TX4+i7urQeJSeIXqmqEb4ajyMT ua6Ajc3Gc+yQJb5siiUJhksbu08pXI78urZqZa2cvkawEAROnWhSMn9Dz8teGKBcl3PZ/U o/j4HDjSIQKFK2MsySfrDtjotRfWoVsUcEkPU09Jg/RMe2XbU+9fmSq4LCOD1kSNDHkhjR j1ffYatD4gWj6YoHszXLNKY8HCg5iDlfts4YOt1eIXPiVvd0nsmJpUPH0eCSNh49fa95iL oE4H+WqOtF58Iqhj3/vtvNuBHIPFk15/U4U1G6unlBqey1DDVOpm5Rpw4XEdGw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721074963; a=rsa-sha256; cv=none; b=jtvMS5HMpTZrOSENxIuQ+LL3m3yJ9s/kwfcuiZgvFpjLPtCiRK7prji9lw9IR1+BBHj2lB Ahyo3g9Cbek9N4+fdK5ucs7RGCqUbj7nYlmG9m0SfURKJklcMAw/G/7TNLDTFtjzm1bXjq lJ3Hk/o0oc4uJbibYUg7GE8CfT5GoSWnHUU2W/EmGnZJsTIFcWVbT7j2IyvrJsNaqjQWws Xb6gPlL4ROPFwHqJthQL2kGLl88LbK0lOsBZ1U67Gz4vVzhnHQtiuNoVXrLLAU3TpFYCb1 GHTudBfsr4yo+OTbFs3eY4/BEcUa7OsJek2byOFnA4dPqV0tx/nJkqy8dhpSzA== 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=1721074963; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=/jCwvTx4uNjZsenYc+ZGXdPoMFtIqkCaatHFbFgVZZk=; b=DR9xcwUlcYN4wjdEeIokMJRGJKqahTZesA2sqrDxVlEBtlvIXZtiWPbDtQmnUgedjuOpum tCTomdkjonWHwIyxaUwh94hHMoksnvk9NYndvur1NGaR9ixOTVLdUT0y5vWRiVqdoCb7a7 UWAM+fPW08C85OHUj0JlJ9syDbU8RHPeABnBZy0NLVIiIWF4dYVxmVPIMFEuVuVh7XXpVK hhufCNeGHsLLkFKEfizq2KSSv00fGnzWb++XZ9LyrpsCXgOkASTweV9o3BvAdxtMOH6pge Cz3XSIBNfYUHfaao76+qbR20ou3wPIxj+2wo/9WNe36a/kdreHgWihgTU6/gRw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNDCR1L9Vz16M8; Mon, 15 Jul 2024 20:22:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FKMhmM057608; Mon, 15 Jul 2024 20:22:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FKMhGQ057605; Mon, 15 Jul 2024 20:22:43 GMT (envelope-from git) Date: Mon, 15 Jul 2024 20:22:43 GMT Message-Id: <202407152022.46FKMhGQ057605@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mark Johnston Subject: git: b3877767883e - main - ndp: Fix libxo formatting for the prefix expiry string List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: b3877767883e9b26fbcce47c015ba3eab323bf1b Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=b3877767883e9b26fbcce47c015ba3eab323bf1b commit b3877767883e9b26fbcce47c015ba3eab323bf1b Author: Mark Johnston AuthorDate: 2024-07-15 20:06:24 +0000 Commit: Mark Johnston CommitDate: 2024-07-15 20:22:00 +0000 ndp: Fix libxo formatting for the prefix expiry string Fixes: e1c7783e220b ("ndp(8): add structured output formatting via libxo") MFC after: 1 week Sponsored by: Klara, Inc. Sponsored by: Bell Tower Integration --- usr.sbin/ndp/ndp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/usr.sbin/ndp/ndp.c b/usr.sbin/ndp/ndp.c index dcb3b5e3571b..637aac2823ed 100644 --- a/usr.sbin/ndp/ndp.c +++ b/usr.sbin/ndp/ndp.c @@ -1334,7 +1334,7 @@ plist(void) if (p->expire == 0) xo_emit(", expire=Never{en:permanent/true}"); else if (p->expire >= now.tv_sec) - xo_emit(", expire=%s{e:expires_sec/%d}", + xo_emit(", expire={:expires/%s}{e:expires_sec/%d}", sec2str(expire_in), expire_in); else xo_emit(", expired{e:expires_sec/%d}", expire_in); From nobody Mon Jul 15 20:39:07 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNDZd38Tyz5RcQH for ; Mon, 15 Jul 2024 20:39:21 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-pf1-x42d.google.com (mail-pf1-x42d.google.com [IPv6:2607:f8b0:4864:20::42d]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "WR4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNDZd14Zzz4jC5 for ; Mon, 15 Jul 2024 20:39:21 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-pf1-x42d.google.com with SMTP id d2e1a72fcca58-70af8128081so3210439b3a.1 for ; Mon, 15 Jul 2024 13:39:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20230601.gappssmtp.com; s=20230601; t=1721075959; x=1721680759; darn=freebsd.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=EozCT/G+qHiCfkOJCIVheGyMLt1uyN/SsGhzb/hewYY=; b=QAka6FczISfIDb7rULCUzg7LBbIDIdFJo047OrssaQI3fzN0hTtitQKhXRV67NcgBF OfH60ZxbxnAnUUYSpjY7b2VkR/eNAMG98ZQdIIo6U9zNOMQoQNTAdzqTLQkpvkCrC191 6QJdIphfRprn3KyMpUkSWj2MnhI563vpN7zxRy6drOSmqi8qJaRFSqJdeYUZLiLR73ka 99USnOLJAZo+iZd3jQszT2DlYMZP2OFmVhy0N9ir36Kqv5leHens9n19jFiKsnDpiK/M corOSP5jEgiuXxmpXBA9zIBKpjDJtF8eAaGf0Bt8IamqJURiGtKGANopOEyth+N14ZWW p0ig== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721075959; x=1721680759; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=EozCT/G+qHiCfkOJCIVheGyMLt1uyN/SsGhzb/hewYY=; b=c3IxN+pQAdfxvSBelIw3lzFDlaXPPmzS5ynUuheoQufNZT/2yXzradcFBTVy1bN5c8 IXg70KDUYI0Q2b9YagAGKbCe3il4Qhw1Dqapq3bY2saDGippra7DFanrU5PDYTIXDMgK dGtChgmoZn3LdiyBdvtWykpAQxvOInjbMbHptN1S0XLOcU/yLfCQRhJWwN2L9GYwzvpN IhYEbFwCUwpdIG/DOh4LadTwEAYcTTyD2nbuJunnw2zFE0twS4GS+0OfDnkSxajmWmhl E8a2ESWpqXCtJiwW/1iFjRVCfN7IF51amzCosO+1q1aua+B4+WdC3SnBV5XqEroQamgL f6fw== X-Forwarded-Encrypted: i=1; AJvYcCVkX0401VI8OP3A2lmwNrHS5c9W/BGKtlSq76gPZKTu5Crh22tJ4eOJGjrm/EBqUDQjeeaiB9G389Pq176GyN/LA1CG0H7dEAPf7DmO0xbG X-Gm-Message-State: AOJu0YwAHT+f+t8/hmiLFPGj6JyVvNyAUwxv3vtZWTqZQ19AMIvHTFsn VvPJpVsld16isczJtKbI3Yhfx/9D7sRgu1tkO3y29vgPG/kkQqm0022m/kExhnvFCZnFGbChCTJ jZJdBvnvZ+UqMcVZfGTwYeE+kQLT9Wcfa/8FGFIIntGxJAd6M X-Google-Smtp-Source: AGHT+IHY1iyZAUe6KJtPCTweyjkPmF4sOp4cDlRZOI3ZzFUMPOMgg2+F49xr89imsFigsyHJN7+Cy/caP1t8oM7mH/M= X-Received: by 2002:a05:6a00:3916:b0:706:6af8:e088 with SMTP id d2e1a72fcca58-70c1fb4a270mr281158b3a.3.1721075959420; Mon, 15 Jul 2024 13:39:19 -0700 (PDT) List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 References: <202407151915.46FJFr7L039362@gitrepo.freebsd.org> In-Reply-To: From: Warner Losh Date: Mon, 15 Jul 2024 14:39:07 -0600 Message-ID: Subject: Re: git: 9cc06bf7aa28 - main - amd64 GENERIC: Switch uart hints from "isa" to "acpi" To: John Baldwin Cc: src-committers , "" , "" Content-Type: multipart/alternative; boundary="0000000000003177a1061d4f39af" 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:15169, ipnet:2607:f8b0::/32, country:US] X-Rspamd-Queue-Id: 4WNDZd14Zzz4jC5 --0000000000003177a1061d4f39af Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Mon, Jul 15, 2024, 1:20=E2=80=AFPM John Baldwin wrote: > On 7/15/24 15:15, John Baldwin wrote: > > The branch main has been updated by jhb: > > > > URL: > https://cgit.FreeBSD.org/src/commit/?id=3D9cc06bf7aa2846c35483de567779bb8= afc289f53 > > > > commit 9cc06bf7aa2846c35483de567779bb8afc289f53 > > Author: John Baldwin > > AuthorDate: 2024-07-15 19:14:01 +0000 > > Commit: John Baldwin > > CommitDate: 2024-07-15 19:15:29 +0000 > > > > amd64 GENERIC: Switch uart hints from "isa" to "acpi" > > > > This causes these hints to be only used to wire device unit number= s > > for serial ports enumerated by ACPI but will not create ISA device > > nodes if ACPI doesn't enumerate them. Note that IRQ hints are not > > used for wiring so have been removed. > > > > PR: 270707 > > Reported by: aixdroix_OSS@protonmail.com, Michael Dexter > > Reported by: mfw_burn@pm.me, Hannes Hfauswedell < > h2+fbsdports@fsfe.org> > > Reported by: Matthias Lanter > > Reported by: William Bulley > > Reviewed by: imp > > MFC after: 1 week > > Differential Revision: https://reviews.freebsd.org/D45945 > > --- > > sys/amd64/conf/GENERIC.hints | 6 ++---- > > 1 file changed, 2 insertions(+), 4 deletions(-) > > > > diff --git a/sys/amd64/conf/GENERIC.hints b/sys/amd64/conf/GENERIC.hint= s > > index 7c2a3f28b9ce..4f6121c7cf77 100644 > > --- a/sys/amd64/conf/GENERIC.hints > > +++ b/sys/amd64/conf/GENERIC.hints > > @@ -6,13 +6,11 @@ hint.psm.0.at=3D"atkbdc" > > hint.psm.0.irq=3D"12" > > hint.sc.0.at=3D"isa" > > hint.sc.0.flags=3D"0x100" > > -hint.uart.0.at=3D"isa" > > +hint.uart.0.at=3D"acpi" > > hint.uart.0.port=3D"0x3F8" > > hint.uart.0.flags=3D"0x10" > > -hint.uart.0.irq=3D"4" > > -hint.uart.1.at=3D"isa" > > +hint.uart.1.at=3D"acpi" > > hint.uart.1.port=3D"0x2F8" > > -hint.uart.1.irq=3D"3" > > hint.atrtc.0.at=3D"isa" > > hint.atrtc.0.port=3D"0x70" > > hint.atrtc.0.irq=3D"8" > > Warner would like to purge more of this file (almost all of it) which is > probably correct. Warner believes that the uart0 flags to set serial > console aren't needed for loaders from FreeBSD 9+ due to the hw.uart.* > tunables modern loaders set. I'm less certain about hints for "fixed" > devices such as attimer0, atrtc0, and atkbdc0. I feel like some systems > have failed to enumerate those in the past, though such systems may be > i386-only. The sc0 hints I think can go away once we fully deprecate > sc(4) in favor of only vt(4). > atkbdc likely needs to go. Legacy free systems don't have it and I've helped at least one person in the past whose system hung after accessing ports 60 and 61. attimer is unused on modern systems that have several other options. It likely can go. atrtc isn't needed for uefi, since efirt can get the time much faster. I think it is in acpi but I'm not entirely sure. Sc is unused by and large and is set for removal :) people using it may have to take extra actions... I've chosen to leave i386 alone as there's still some ancient i386 cruft, > but on amd64 we have a higher bar (e.g. ACPI is de facto required for > amd64). Also, i386 kernels have one foot in the grave already. > > This commit is also somewhat narrow in scope as I plan to merge it back > to 13 and 14. > Sounds like a plan. We have time. Warner --=20 > John Baldwin > > --0000000000003177a1061d4f39af Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


On Mon, Jul 15, 2024, 1:20=E2=80=AFPM John Baldwin <= ;jhb@freebsd.org> wrote:
On 7/15/24 15:15, John Baldwin wrote:
> The branch main has been updated by jhb:
>
> URL: https://cgit.FreeBSD.org/src/commit/?id=3D9cc06bf7aa2846c35483de567779bb= 8afc289f53
>
> commit 9cc06bf7aa2846c35483de567779bb8afc289f53
> Author:=C2=A0 =C2=A0 =C2=A0John Baldwin <jhb@FreeBSD.org>
> AuthorDate: 2024-07-15 19:14:01 +0000
> Commit:=C2=A0 =C2=A0 =C2=A0John Baldwin <jhb@FreeBSD.org>
> CommitDate: 2024-07-15 19:15:29 +0000
>
>=C2=A0 =C2=A0 =C2=A0 amd64 GENERIC: Switch uart hints from "isa&qu= ot; to "acpi"
>=C2=A0 =C2=A0 =C2=A0
>=C2=A0 =C2=A0 =C2=A0 This causes these hints to be only used to wire de= vice unit numbers
>=C2=A0 =C2=A0 =C2=A0 for serial ports enumerated by ACPI but will not c= reate ISA device
>=C2=A0 =C2=A0 =C2=A0 nodes if ACPI doesn't enumerate them.=C2=A0 No= te that IRQ hints are not
>=C2=A0 =C2=A0 =C2=A0 used for wiring so have been removed.
>=C2=A0 =C2=A0 =C2=A0
>=C2=A0 =C2=A0 =C2=A0 PR:=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0270707
>=C2=A0 =C2=A0 =C2=A0 Reported by:=C2=A0 =C2=A0 aixdroix_OSS@pr= otonmail.com, Michael Dexter
>=C2=A0 =C2=A0 =C2=A0 Reported by:=C2=A0 =C2=A0 mfw_burn@pm.me, Hannes H= fauswedell <h2+fbsdports@fsfe.org>
>=C2=A0 =C2=A0 =C2=A0 Reported by:=C2=A0 =C2=A0 Matthias Lanter <fr= eebsd@lanter-it.ch>
>=C2=A0 =C2=A0 =C2=A0 Reported by:=C2=A0 =C2=A0 William Bulley <web@umich.= edu>
>=C2=A0 =C2=A0 =C2=A0 Reviewed by:=C2=A0 =C2=A0 imp
>=C2=A0 =C2=A0 =C2=A0 MFC after:=C2=A0 =C2=A0 =C2=A0 1 week
>=C2=A0 =C2=A0 =C2=A0 Differential Revision:=C2=A0 h= ttps://reviews.freebsd.org/D45945
> ---
>=C2=A0 =C2=A0sys/amd64/conf/GENERIC.hints | 6 ++----
>=C2=A0 =C2=A01 file changed, 2 insertions(+), 4 deletions(-)
>
> diff --git a/sys/amd64/conf/GENERIC.hints b/sys/amd64/conf/GENERIC.hin= ts
> index 7c2a3f28b9ce..4f6121c7cf77 100644
> --- a/sys/amd64/conf/GENERIC.hints
> +++ b/sys/amd64/conf/GENERIC.hints
> @@ -6,13 +6,11 @@ hint.psm.0.at=3D"atkbdc"
>=C2=A0 =C2=A0hint.psm.0.irq=3D"12"
>=C2=A0 =C2=A0hint.sc.0.at=3D"isa"
>=C2=A0 =C2=A0hint.sc.0.flags=3D"0x100"
> -hint.uart.0.at=3D"isa"
> +hint.uart.0.at=3D"acpi"
>=C2=A0 =C2=A0hint.uart.0.port=3D"0x3F8"
>=C2=A0 =C2=A0hint.uart.0.flags=3D"0x10"
> -hint.uart.0.irq=3D"4"
> -hint.uart.1.at=3D"isa"
> +hint.uart.1.at=3D"acpi"
>=C2=A0 =C2=A0hint.uart.1.port=3D"0x2F8"
> -hint.uart.1.irq=3D"3"
>=C2=A0 =C2=A0hint.atrtc.0.at=3D"isa"
>=C2=A0 =C2=A0hint.atrtc.0.port=3D"0x70"
>=C2=A0 =C2=A0hint.atrtc.0.irq=3D"8"

Warner would like to purge more of this file (almost all of it) which is probably correct.=C2=A0 Warner believes that the uart0 flags to set serial<= br> console aren't needed for loaders from FreeBSD 9+ due to the hw.uart.*<= br> tunables modern loaders set.=C2=A0 I'm less certain about hints for &qu= ot;fixed"
devices such as attimer0, atrtc0, and atkbdc0.=C2=A0 I feel like some syste= ms
have failed to enumerate those in the past, though such systems may be
i386-only.=C2=A0 The sc0 hints I think can go away once we fully deprecate<= br> sc(4) in favor of only vt(4).

atkbdc likely needs to go. Legacy free systems= don't have it and I've helped at least one person in the past whos= e system hung after accessing ports 60 and 61.

<= /div>
attimer is unused on modern systems that have severa= l other options. It likely can go.

atrtc isn't needed for uefi, since efirt can get the time mu= ch faster. I think it is in acpi but I'm not entirely sure.

Sc is unused by and large and is se= t for removal :)=C2=A0 people using it may have to take extra actions...

I've chosen to leave i386 alone as there's still some ancient i386 = cruft,
but on amd64 we have a higher bar (e.g. ACPI is de facto required for
amd64).=C2=A0 Also, i386 kernels have one foot in the grave already.

This commit is also somewhat narrow in scope as I plan to merge it back
to 13 and 14.

Sounds like a plan. We have time.

<= /div>
Warner

--
John Baldwin

--0000000000003177a1061d4f39af-- From nobody Mon Jul 15 22:44:13 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNHLk0HGsz5QLPb; Mon, 15 Jul 2024 22:44: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNHLj6n70z43B1; Mon, 15 Jul 2024 22:44:13 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721083454; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6gz0o6St523a/33lZqGhCG90oGDP7ow1EtyFZmQS2FI=; b=vkxXLWDPpv9R8rulD+SY6J4cUOK0jZbZm9xoDblAZDori0HBHakp0OcECjr2lly2owEwg2 CKAx0j6DgnVdK+xT2r9h8P5LkJg3OtQnobZVyIuFAQ0hlOPupr10C4wyYfYioNf+v39Q7E eQTyfcHnlGgzxBwTBn4lAd83lIEWciQm8Um+8Mz1V2Xc/Qejeoq4KQVAAxTdEBwLH3F9hy GwhXDe6k4AEcyQWLYEMnSRAtd6ZbhpeN0AsPkkRIUUvecBxv5S1zcs8yfZBGrSMmGfbUHH u/DvOqFd4Hz+Y/mTMwS7xIhd/DpM27mQ4phJ1cCWWuaIVtaD8K4Uh4ipIw+SGg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721083454; a=rsa-sha256; cv=none; b=ll5a9frL4rFiSPz588xkLDiQiCimCg9MMRMKVEnA/f2eWHGZEwbamNDcaBKt6qE5L2O1a1 Cg+QeDYBoWbGPuHGMZOhjDXKRY3XYxbwGKKHFsl05nBCG5NxWHRkTBTbdKCtsvy5X8Vuyh GV9474Wk+kQY/I3+w6RbgBhP7+WPmH+YE9htSM63AurRK4DbrbNvayMVA9UCHyqhJIzgYq ccwb/WT8rGfEu81PFXItdKIIMa27zZ8pLkn2nPrcCom7F3TkTCnWMb1BVgFO+7jgS2Km51 gb/dCZH/UXkXgXe5WeMqj3aLNLm8c+D7UgY06giIEWFbFKmhhjWKsJ+lzNnhIA== 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=1721083454; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6gz0o6St523a/33lZqGhCG90oGDP7ow1EtyFZmQS2FI=; b=hcrAOX5/m071CN3wL8MDBJn1KcERv5xj3HHEeX5JpVcPLB4o1O5Aw6vz72+P+lhoqC/r5B aEJio80aLoDevMPgTb/lpCohyRW7U0ibJCQrcRIclKrEGMdFhD5xFMmDfnBA8NDbz95TVV JriTEfexor5Fholx9BGdlJ8Lz16QxtXe5ss2P69nnlebh8Zd48wzyQggf5hRcEBgzmiGde p2gqHDWfMgd7z+0o2f0aVrb5Lj40Y/yLHALdikyx4WeMj2LPDS78k3UPlqrCHMs1hzYOIr 6Wnqfgw5hO0Bj18hX9R3axvWNqhyAaL4br5MFy53IxUOyhqNk/ITt2D5H/sUlw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNHLj6MwGz19k4; Mon, 15 Jul 2024 22:44:13 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46FMiDt9093865; Mon, 15 Jul 2024 22:44:13 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46FMiDZG093862; Mon, 15 Jul 2024 22:44:13 GMT (envelope-from git) Date: Mon, 15 Jul 2024 22:44:13 GMT Message-Id: <202407152244.46FMiDZG093862@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: e9ac41698b2f - main - Remove residual blank line at start of Makefile List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e9ac41698b2f322d55ccf9da50a3596edb2c1800 Auto-Submitted: auto-generated The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=e9ac41698b2f322d55ccf9da50a3596edb2c1800 commit e9ac41698b2f322d55ccf9da50a3596edb2c1800 Author: Warner Losh AuthorDate: 2024-07-15 04:46:32 +0000 Commit: Warner Losh CommitDate: 2024-07-15 22:43:39 +0000 Remove residual blank line at start of Makefile This is a residual of the $FreeBSD$ removal. MFC After: 3 days (though I'll just run the command on the branches) Sponsored by: Netflix --- Makefile.libcompat | 1 - bin/Makefile | 1 - bin/Makefile.inc | 1 - bin/cat/Makefile | 1 - bin/cat/tests/Makefile | 1 - bin/chflags/Makefile | 1 - bin/chflags/tests/Makefile | 1 - bin/chio/Makefile | 1 - bin/chmod/Makefile | 1 - bin/chmod/tests/Makefile | 1 - bin/cp/Makefile | 1 - bin/cp/tests/Makefile | 1 - bin/cpuset/Makefile | 1 - bin/date/Makefile | 1 - bin/date/tests/Makefile | 1 - bin/dd/Makefile | 1 - bin/dd/tests/Makefile | 1 - bin/df/Makefile | 1 - bin/domainname/Makefile | 1 - bin/echo/Makefile | 1 - bin/echo/tests/Makefile | 1 - bin/ed/Makefile | 1 - bin/ed/test/Makefile | 1 - bin/expr/Makefile | 1 - bin/expr/tests/Makefile | 1 - bin/freebsd-version/Makefile | 1 - bin/getfacl/Makefile | 1 - bin/kenv/Makefile | 1 - bin/kill/Makefile | 1 - bin/ln/Makefile | 1 - bin/ln/tests/Makefile | 1 - bin/ls/Makefile | 1 - bin/ls/tests/Makefile | 1 - bin/mkdir/Makefile | 1 - bin/mkdir/tests/Makefile | 1 - bin/mv/Makefile | 1 - bin/mv/tests/Makefile | 1 - bin/pax/Makefile | 1 - bin/pax/tests/Makefile | 1 - bin/pkill/tests/Makefile | 1 - bin/ps/Makefile | 1 - bin/pwait/Makefile | 1 - bin/pwait/tests/Makefile | 1 - bin/pwd/Makefile | 1 - bin/realpath/Makefile | 1 - bin/rm/Makefile | 1 - bin/rm/tests/Makefile | 1 - bin/rmail/Makefile | 1 - bin/rmdir/Makefile | 1 - bin/rmdir/tests/Makefile | 1 - bin/setfacl/Makefile | 1 - bin/sh/Makefile | 1 - bin/sh/tests/Makefile | 1 - bin/sh/tests/builtins/Makefile | 1 - bin/sh/tests/errors/Makefile | 1 - bin/sh/tests/execution/Makefile | 1 - bin/sh/tests/expansion/Makefile | 1 - bin/sh/tests/invocation/Makefile | 1 - bin/sh/tests/parameters/Makefile | 1 - bin/sh/tests/parser/Makefile | 1 - bin/sh/tests/set-e/Makefile | 1 - bin/sleep/Makefile | 1 - bin/sleep/tests/Makefile | 1 - bin/stty/Makefile | 1 - bin/sync/Makefile | 1 - bin/test/Makefile | 1 - bin/test/tests/Makefile | 1 - bin/tests/Makefile | 1 - bin/timeout/Makefile | 1 - bin/timeout/tests/Makefile | 1 - bin/uuidgen/Makefile | 1 - cddl/Makefile | 1 - cddl/Makefile.inc | 1 - cddl/lib/Makefile | 1 - cddl/lib/Makefile.inc | 1 - cddl/lib/drti/Makefile | 1 - cddl/lib/libavl/Makefile | 1 - cddl/lib/libctf/Makefile | 1 - cddl/lib/libdtrace/Makefile | 1 - cddl/lib/libicp/Makefile | 1 - cddl/lib/libicp_rescue/Makefile | 1 - cddl/lib/libnvpair/Makefile | 1 - cddl/lib/libspl/Makefile | 1 - cddl/lib/libtpool/Makefile | 1 - cddl/lib/libumem/Makefile | 1 - cddl/lib/libuutil/Makefile | 1 - cddl/lib/libzfs/Makefile | 1 - cddl/lib/libzfs_core/Makefile | 1 - cddl/lib/libzfsbootenv/Makefile | 1 - cddl/lib/libzpool/Makefile | 1 - cddl/lib/libzutil/Makefile | 1 - cddl/lib/tests/Makefile | 1 - cddl/sbin/Makefile | 1 - cddl/sbin/Makefile.inc | 1 - cddl/sbin/tests/Makefile | 1 - cddl/sbin/zfs/Makefile | 1 - cddl/sbin/zpool/Makefile | 1 - cddl/share/Makefile | 1 - cddl/share/zfs/Makefile | 1 - cddl/share/zfs/compatibility.d/Makefile | 1 - cddl/tests/Makefile | 1 - cddl/usr.bin/Makefile | 1 - cddl/usr.bin/Makefile.inc | 1 - cddl/usr.bin/ctfconvert/Makefile | 1 - cddl/usr.bin/ctfconvert/tests/Makefile | 1 - cddl/usr.bin/ctfdump/Makefile | 1 - cddl/usr.bin/ctfmerge/Makefile | 1 - cddl/usr.bin/tests/Makefile | 1 - cddl/usr.bin/zinject/Makefile | 1 - cddl/usr.bin/zstream/Makefile | 1 - cddl/usr.bin/ztest/Makefile | 1 - cddl/usr.bin/ztest/tests/Makefile | 1 - cddl/usr.libexec/Makefile | 1 - cddl/usr.libexec/zfs_prepare_disk/Makefile | 1 - cddl/usr.libexec/zpool_influxdb/Makefile | 1 - cddl/usr.sbin/Makefile | 1 - cddl/usr.sbin/Makefile.inc | 1 - cddl/usr.sbin/dtrace/Makefile | 1 - cddl/usr.sbin/dtrace/tests/Makefile | 1 - cddl/usr.sbin/dtrace/tests/amd64/Makefile | 1 - cddl/usr.sbin/dtrace/tests/common/Makefile | 1 - cddl/usr.sbin/dtrace/tests/i386/Makefile | 1 - cddl/usr.sbin/dwatch/Makefile | 1 - cddl/usr.sbin/dwatch/examples/Makefile | 1 - cddl/usr.sbin/dwatch/libexec/Makefile | 1 - cddl/usr.sbin/lockstat/Makefile | 1 - cddl/usr.sbin/plockstat/Makefile | 1 - cddl/usr.sbin/tests/Makefile | 1 - cddl/usr.sbin/zdb/Makefile | 1 - cddl/usr.sbin/zfsd/Makefile | 1 - cddl/usr.sbin/zfsd/Makefile.common | 1 - cddl/usr.sbin/zfsd/tests/Makefile | 1 - cddl/usr.sbin/zhack/Makefile | 1 - contrib/elftoolchain/nm/Makefile | 1 - contrib/file/python/Makefile.am | 1 - contrib/sqlite3/Makefile.am | 1 - crypto/heimdal/base/Makefile.am | 1 - etc/Makefile | 1 - etc/gss/Makefile | 1 - etc/sendmail/Makefile | 1 - gnu/Makefile | 1 - gnu/Makefile.inc | 1 - gnu/lib/Makefile | 1 - gnu/lib/Makefile.inc | 1 - gnu/lib/libdialog/Makefile | 1 - gnu/lib/tests/Makefile | 1 - gnu/tests/Makefile | 1 - gnu/usr.bin/Makefile | 1 - gnu/usr.bin/Makefile.inc | 1 - gnu/usr.bin/dialog/Makefile | 1 - gnu/usr.bin/diff3/Makefile | 1 - gnu/usr.bin/tests/Makefile | 1 - include/arpa/Makefile | 1 - include/gssapi/Makefile | 1 - include/protocols/Makefile | 1 - include/rpc/Makefile | 1 - include/rpcsvc/Makefile | 1 - include/xlocale/Makefile | 1 - kerberos5/Makefile | 1 - kerberos5/Makefile.inc | 1 - kerberos5/lib/Makefile | 1 - kerberos5/lib/Makefile.inc | 1 - kerberos5/lib/libasn1/Makefile | 1 - kerberos5/lib/libgssapi_krb5/Makefile | 1 - kerberos5/lib/libgssapi_ntlm/Makefile | 1 - kerberos5/lib/libgssapi_spnego/Makefile | 1 - kerberos5/lib/libhdb/Makefile | 1 - kerberos5/lib/libheimbase/Makefile | 1 - kerberos5/lib/libheimipcc/Makefile | 1 - kerberos5/lib/libheimipcs/Makefile | 1 - kerberos5/lib/libheimntlm/Makefile | 1 - kerberos5/lib/libhx509/Makefile | 1 - kerberos5/lib/libkadm5clnt/Makefile | 1 - kerberos5/lib/libkadm5srv/Makefile | 1 - kerberos5/lib/libkafs5/Makefile | 1 - kerberos5/lib/libkdc/Makefile | 1 - kerberos5/lib/libkrb5/Makefile | 1 - kerberos5/lib/libroken/Makefile | 1 - kerberos5/lib/libsl/Makefile | 1 - kerberos5/lib/libvers/Makefile | 1 - kerberos5/lib/libwind/Makefile | 1 - kerberos5/libexec/Makefile | 1 - kerberos5/libexec/Makefile.inc | 1 - kerberos5/libexec/digest-service/Makefile | 1 - kerberos5/libexec/hprop/Makefile | 1 - kerberos5/libexec/hpropd/Makefile | 1 - kerberos5/libexec/ipropd-master/Makefile | 1 - kerberos5/libexec/ipropd-slave/Makefile | 1 - kerberos5/libexec/kadmind/Makefile | 1 - kerberos5/libexec/kcm/Makefile | 1 - kerberos5/libexec/kdc/Makefile | 1 - kerberos5/libexec/kdigest/Makefile | 1 - kerberos5/libexec/kfd/Makefile | 1 - kerberos5/libexec/kimpersonate/Makefile | 1 - kerberos5/libexec/kpasswdd/Makefile | 1 - kerberos5/tools/Makefile | 1 - kerberos5/tools/Makefile.inc | 1 - kerberos5/tools/asn1_compile/Makefile | 1 - kerberos5/tools/make-roken/Makefile | 1 - kerberos5/tools/slc/Makefile | 1 - kerberos5/usr.bin/Makefile | 1 - kerberos5/usr.bin/Makefile.inc | 1 - kerberos5/usr.bin/hxtool/Makefile | 1 - kerberos5/usr.bin/kadmin/Makefile | 1 - kerberos5/usr.bin/kcc/Makefile | 1 - kerberos5/usr.bin/kdestroy/Makefile | 1 - kerberos5/usr.bin/kf/Makefile | 1 - kerberos5/usr.bin/kgetcred/Makefile | 1 - kerberos5/usr.bin/kinit/Makefile | 1 - kerberos5/usr.bin/kpasswd/Makefile | 1 - kerberos5/usr.bin/krb5-config/Makefile | 1 - kerberos5/usr.bin/ksu/Makefile | 1 - kerberos5/usr.bin/string2key/Makefile | 1 - kerberos5/usr.bin/verify_krb5_conf/Makefile | 1 - kerberos5/usr.sbin/Makefile | 1 - kerberos5/usr.sbin/Makefile.inc | 1 - kerberos5/usr.sbin/iprop-log/Makefile | 1 - kerberos5/usr.sbin/kstash/Makefile | 1 - kerberos5/usr.sbin/ktutil/Makefile | 1 - lib/Makefile | 1 - lib/atf/libatf-c++/Makefile.inc | 1 - lib/atf/libatf-c++/tests/Makefile | 1 - lib/atf/libatf-c++/tests/Makefile.inc | 1 - lib/atf/libatf-c++/tests/detail/Makefile | 1 - lib/atf/libatf-c/Makefile.inc | 1 - lib/atf/libatf-c/tests/Makefile | 1 - lib/atf/libatf-c/tests/Makefile.inc | 1 - lib/atf/libatf-c/tests/detail/Makefile | 1 - lib/atf/tests/Makefile | 1 - lib/atf/tests/test-programs/Makefile | 1 - lib/clang/Makefile | 1 - lib/clang/Makefile.inc | 1 - lib/clang/headers/Makefile | 1 - lib/clang/libclang/Makefile | 1 - lib/clang/libclangminimal/Makefile | 1 - lib/clang/liblldb/Makefile | 1 - lib/clang/libllvm/Makefile | 1 - lib/clang/libllvmminimal/Makefile | 1 - lib/csu/Makefile | 1 - lib/csu/aarch64/Makefile | 1 - lib/csu/amd64/Makefile | 1 - lib/csu/arm/Makefile | 1 - lib/csu/i386/Makefile | 1 - lib/csu/powerpc/Makefile | 1 - lib/csu/powerpc64/Makefile | 1 - lib/csu/riscv/Makefile | 1 - lib/csu/tests/Makefile | 1 - lib/csu/tests/Makefile.inc | 1 - lib/csu/tests/Makefile.tests | 1 - lib/csu/tests/dso/Makefile | 1 - lib/csu/tests/dynamic/Makefile | 1 - lib/csu/tests/dynamiclib/Makefile | 1 - lib/csu/tests/dynamicpie/Makefile | 1 - lib/csu/tests/static/Makefile | 1 - lib/flua/libjail/Makefile | 1 - lib/geom/Makefile | 1 - lib/geom/Makefile.classes | 1 - lib/geom/Makefile.inc | 1 - lib/geom/cache/Makefile | 1 - lib/geom/concat/Makefile | 1 - lib/geom/eli/Makefile | 1 - lib/geom/journal/Makefile | 1 - lib/geom/label/Makefile | 1 - lib/geom/mirror/Makefile | 1 - lib/geom/mountver/Makefile | 1 - lib/geom/multipath/Makefile | 1 - lib/geom/nop/Makefile | 1 - lib/geom/part/Makefile | 1 - lib/geom/raid/Makefile | 1 - lib/geom/raid3/Makefile | 1 - lib/geom/shsec/Makefile | 1 - lib/geom/stripe/Makefile | 1 - lib/geom/union/Makefile | 1 - lib/geom/virstor/Makefile | 1 - lib/googletest/Makefile | 1 - lib/googletest/Makefile.inc | 1 - lib/googletest/gmock/Makefile | 1 - lib/googletest/gmock/Makefile.inc | 1 - lib/googletest/gmock_main/Makefile | 1 - lib/googletest/gmock_main/Makefile.inc | 1 - lib/googletest/gtest/Makefile | 1 - lib/googletest/gtest/Makefile.inc | 1 - lib/googletest/gtest_main/Makefile | 1 - lib/googletest/gtest_main/Makefile.inc | 1 - lib/googletest/tests/Makefile | 1 - lib/googletest/tests/Makefile.inc | 1 - lib/googletest/tests/gmock/Makefile | 1 - lib/googletest/tests/gmock_main/Makefile | 1 - lib/googletest/tests/gtest/Makefile | 1 - lib/googletest/tests/gtest_main/Makefile | 1 - lib/lib80211/Makefile | 1 - lib/lib9p/Makefile | 1 - lib/libalias/Makefile | 1 - lib/libalias/Makefile.inc | 1 - lib/libalias/libalias/Makefile | 1 - lib/libalias/modules/Makefile | 1 - lib/libalias/modules/Makefile.inc | 1 - lib/libalias/modules/dummy/Makefile | 1 - lib/libalias/modules/ftp/Makefile | 1 - lib/libalias/modules/irc/Makefile | 1 - lib/libalias/modules/nbt/Makefile | 1 - lib/libalias/modules/pptp/Makefile | 1 - lib/libalias/modules/skinny/Makefile | 1 - lib/libalias/modules/smedia/Makefile | 1 - lib/libbe/Makefile | 1 - lib/libbe/tests/Makefile | 1 - lib/libbearssl/Makefile | 1 - lib/libbearssl/Makefile.inc | 1 - lib/libbearssl/Makefile.libsa.inc | 1 - lib/libbegemot/Makefile | 1 - lib/libblacklist/Makefile | 1 - lib/libblocksruntime/Makefile | 1 - lib/libbsdstat/Makefile | 1 - lib/libbsnmp/Makefile | 1 - lib/libbsnmp/Makefile.inc | 1 - lib/libbsnmp/tests/Makefile | 1 - lib/libbz2/Makefile | 1 - lib/libc++/Makefile | 1 - lib/libc++experimental/Makefile | 1 - lib/libc/Makefile | 1 - lib/libc/aarch64/gen/Makefile.inc | 1 - lib/libc/amd64/gen/Makefile.inc | 1 - lib/libc/amd64/stdlib/Makefile.inc | 1 - lib/libc/arm/aeabi/Makefile.inc | 1 - lib/libc/arm/gen/Makefile.inc | 1 - lib/libc/arm/string/Makefile.inc | 1 - lib/libc/capability/Makefile.inc | 1 - lib/libc/compat-43/Makefile.inc | 1 - lib/libc/db/btree/Makefile.inc | 1 - lib/libc/db/db/Makefile.inc | 1 - lib/libc/db/hash/Makefile.inc | 1 - lib/libc/db/man/Makefile.inc | 1 - lib/libc/db/mpool/Makefile.inc | 1 - lib/libc/db/recno/Makefile.inc | 1 - lib/libc/db/test/Makefile | 1 - lib/libc/gdtoa/Makefile.inc | 1 - lib/libc/gen/Makefile.inc | 1 - lib/libc/gmon/Makefile.inc | 1 - lib/libc/i386/Makefile.inc | 1 - lib/libc/i386/gen/Makefile.inc | 1 - lib/libc/i386/stdlib/Makefile.inc | 1 - lib/libc/i386/string/Makefile.inc | 1 - lib/libc/iconv/Makefile.inc | 1 - lib/libc/inet/Makefile.inc | 1 - lib/libc/isc/Makefile.inc | 1 - lib/libc/locale/Makefile.inc | 1 - lib/libc/md/Makefile.inc | 1 - lib/libc/nameser/Makefile.inc | 1 - lib/libc/net/Makefile.inc | 1 - lib/libc/posix1e/Makefile.inc | 1 - lib/libc/powerpc/Makefile.inc | 1 - lib/libc/powerpc/gen/Makefile.common | 1 - lib/libc/powerpc/gen/Makefile.inc | 1 - lib/libc/powerpc64/Makefile.inc | 1 - lib/libc/powerpc64/gen/Makefile.inc | 1 - lib/libc/powerpc64/string/Makefile.inc | 1 - lib/libc/powerpcspe/Makefile.inc | 1 - lib/libc/powerpcspe/gen/Makefile.inc | 1 - lib/libc/quad/Makefile.inc | 1 - lib/libc/quad/TESTS/Makefile | 1 - lib/libc/regex/Makefile.inc | 1 - lib/libc/resolv/Makefile.inc | 1 - lib/libc/riscv/gen/Makefile.inc | 1 - lib/libc/rpc/Makefile.inc | 1 - lib/libc/stdio/Makefile.inc | 1 - lib/libc/stdlib/Makefile.inc | 1 - lib/libc/string/Makefile.inc | 1 - lib/libc/tests/Makefile | 1 - lib/libc/tests/Makefile.netbsd-tests | 1 - lib/libc/tests/c063/Makefile | 1 - lib/libc/tests/db/Makefile | 1 - lib/libc/tests/gen/Makefile | 1 - lib/libc/tests/gen/execve/Makefile | 1 - lib/libc/tests/gen/posix_spawn/Makefile | 1 - lib/libc/tests/hash/Makefile | 1 - lib/libc/tests/iconv/Makefile | 1 - lib/libc/tests/inet/Makefile | 1 - lib/libc/tests/locale/Makefile | 1 - lib/libc/tests/net/Makefile | 1 - lib/libc/tests/net/getaddrinfo/Makefile | 1 - lib/libc/tests/nss/Makefile | 1 - lib/libc/tests/regex/Makefile | 1 - lib/libc/tests/regex/Makefile.inc | 1 - lib/libc/tests/resolv/Makefile | 1 - lib/libc/tests/rpc/Makefile | 1 - lib/libc/tests/setjmp/Makefile | 1 - lib/libc/tests/ssp/Makefile | 1 - lib/libc/tests/stdio/Makefile | 1 - lib/libc/tests/stdlib/Makefile | 1 - lib/libc/tests/stdlib/dynthr_mod/Makefile | 1 - lib/libc/tests/string/Makefile | 1 - lib/libc/tests/sys/Makefile | 1 - lib/libc/tests/termios/Makefile | 1 - lib/libc/tests/time/Makefile | 1 - lib/libc/tests/tls/Makefile | 1 - lib/libc/tests/tls/dso/Makefile | 1 - lib/libc/tests/tls_dso/Makefile | 1 - lib/libc/tests/ttyio/Makefile | 1 - lib/libc/uuid/Makefile.inc | 1 - lib/libc/x86/gen/Makefile.inc | 1 - lib/libc/xdr/Makefile.inc | 1 - lib/libc/yp/Makefile.inc | 1 - lib/libc_nonshared/Makefile | 1 - lib/libc_nonshared/Makefile.iconv | 1 - lib/libcalendar/Makefile | 1 - lib/libcam/Makefile | 1 - lib/libcam/tests/Makefile | 1 - lib/libcapsicum/Makefile | 1 - lib/libcasper/Makefile | 1 - lib/libcasper/Makefile.inc | 1 - lib/libcasper/libcasper/Makefile | 1 - lib/libcasper/services/Makefile | 1 - lib/libcasper/services/Makefile.inc | 1 - lib/libcasper/services/cap_dns/Makefile | 1 - lib/libcasper/services/cap_dns/tests/Makefile | 1 - lib/libcasper/services/cap_fileargs/Makefile | 1 - lib/libcasper/services/cap_fileargs/tests/Makefile | 1 - lib/libcasper/services/cap_grp/Makefile | 1 - lib/libcasper/services/cap_grp/tests/Makefile | 1 - lib/libcasper/services/cap_net/Makefile | 1 - lib/libcasper/services/cap_net/tests/Makefile | 1 - lib/libcasper/services/cap_netdb/Makefile | 1 - lib/libcasper/services/cap_netdb/tests/Makefile | 1 - lib/libcasper/services/cap_pwd/Makefile | 1 - lib/libcasper/services/cap_pwd/tests/Makefile | 1 - lib/libcasper/services/cap_sysctl/Makefile | 1 - lib/libcasper/services/cap_sysctl/tests/Makefile | 1 - lib/libcasper/services/cap_syslog/Makefile | 1 - lib/libcasper/services/tests/Makefile | 1 - lib/libcasper/tests/Makefile | 1 - lib/libcbor/Makefile | 1 - lib/libclang_rt/Makefile | 1 - lib/libclang_rt/Makefile.inc | 1 - lib/libclang_rt/asan-preinit/Makefile | 1 - lib/libclang_rt/asan/Makefile | 1 - lib/libclang_rt/asan_cxx/Makefile | 1 - lib/libclang_rt/asan_dynamic/Makefile | 1 - lib/libclang_rt/asan_static/Makefile | 1 - lib/libclang_rt/cfi/Makefile | 1 - lib/libclang_rt/cfi_diag/Makefile | 1 - lib/libclang_rt/dd/Makefile | 1 - lib/libclang_rt/fuzzer/Makefile | 1 - lib/libclang_rt/fuzzer_interceptors/Makefile | 1 - lib/libclang_rt/fuzzer_no_main/Makefile | 1 - lib/libclang_rt/include/Makefile | 1 - lib/libclang_rt/msan/Makefile | 1 - lib/libclang_rt/msan_cxx/Makefile | 1 - lib/libclang_rt/profile/Makefile | 1 - lib/libclang_rt/safestack/Makefile | 1 - lib/libclang_rt/stats/Makefile | 1 - lib/libclang_rt/stats_client/Makefile | 1 - lib/libclang_rt/tsan/Makefile | 1 - lib/libclang_rt/tsan_cxx/Makefile | 1 - lib/libclang_rt/ubsan_minimal/Makefile | 1 - lib/libclang_rt/ubsan_standalone/Makefile | 1 - lib/libclang_rt/ubsan_standalone_cxx/Makefile | 1 - lib/libclang_rt/xray-basic/Makefile | 1 - lib/libclang_rt/xray-fdr/Makefile | 1 - lib/libclang_rt/xray-profiling/Makefile | 1 - lib/libclang_rt/xray/Makefile | 1 - lib/libcom_err/Makefile | 1 - lib/libcompat/Makefile | 1 - lib/libcompiler_rt/Makefile | 1 - lib/libcrypt/tests/Makefile | 1 - lib/libdevctl/Makefile | 1 - lib/libdevdctl/Makefile | 1 - lib/libdevdctl/tests/Makefile | 1 - lib/libdevinfo/Makefile | 1 - lib/libdevstat/Makefile | 1 - lib/libdl/Makefile | 1 - lib/libdpv/Makefile | 1 - lib/libedit/readline/Makefile | 1 - lib/libelf/Makefile | 1 - lib/libevent1/Makefile | 1 - lib/libexecinfo/Makefile | 1 - lib/libexecinfo/tests/Makefile | 1 - lib/libexpat/Makefile | 1 - lib/libfetch/Makefile | 1 - lib/libfigpar/Makefile | 1 - lib/libgcc_eh/Makefile | 1 - lib/libgcc_eh/Makefile.inc | 1 - lib/libgcc_s/Makefile | 1 - lib/libgeom/Makefile | 1 - lib/libgpio/Makefile | 1 - lib/libgssapi/Makefile | 1 - lib/libiconv_modules/BIG5/Makefile | 1 - lib/libiconv_modules/DECHanyu/Makefile | 1 - lib/libiconv_modules/EUC/Makefile | 1 - lib/libiconv_modules/EUCTW/Makefile | 1 - lib/libiconv_modules/GBK2K/Makefile | 1 - lib/libiconv_modules/HZ/Makefile | 1 - lib/libiconv_modules/ISO2022/Makefile | 1 - lib/libiconv_modules/JOHAB/Makefile | 1 - lib/libiconv_modules/MSKanji/Makefile | 1 - lib/libiconv_modules/Makefile | 1 - lib/libiconv_modules/Makefile.inc | 1 - lib/libiconv_modules/UES/Makefile | 1 - lib/libiconv_modules/UTF1632/Makefile | 1 - lib/libiconv_modules/UTF7/Makefile | 1 - lib/libiconv_modules/UTF8/Makefile | 1 - lib/libiconv_modules/VIQR/Makefile | 1 - lib/libiconv_modules/ZW/Makefile | 1 - lib/libiconv_modules/iconv_none/Makefile | 1 - lib/libiconv_modules/iconv_std/Makefile | 1 - lib/libiconv_modules/mapper_646/Makefile | 1 - lib/libiconv_modules/mapper_none/Makefile | 1 - lib/libiconv_modules/mapper_parallel/Makefile | 1 - lib/libiconv_modules/mapper_serial/Makefile | 1 - lib/libiconv_modules/mapper_std/Makefile | 1 - lib/libiconv_modules/mapper_zone/Makefile | 1 - lib/libifconfig/Makefile | 1 - lib/libipt/Makefile | 1 - lib/libjail/Makefile | 1 - lib/libkiconv/Makefile | 1 - lib/libkvm/Makefile | 1 - lib/libkvm/tests/Makefile | 1 - lib/libldns/Makefile | 1 - lib/liblua/Makefile | 1 - lib/liblutok/Makefile | 1 - lib/liblzma/Makefile | 1 - lib/libmd/Makefile | 1 - lib/libmemstat/Makefile | 1 - lib/libmilter/Makefile | 1 - lib/libmixer/Makefile | 1 - lib/libmp/Makefile | 1 - lib/libmp/tests/Makefile | 1 - lib/libmt/Makefile | 1 - lib/libnetbsd/Makefile | 1 - lib/libnv/Makefile | 1 - lib/libnv/tests/Makefile | 1 - lib/libomp/Makefile | 1 - lib/libopenbsd/Makefile | 1 - lib/libopencsd/Makefile | 1 - lib/libpam/modules/Makefile.inc | 1 - lib/libpam/modules/pam_chroot/Makefile | 1 - lib/libpam/modules/pam_echo/Makefile | 1 - lib/libpam/modules/pam_exec/Makefile | 1 - lib/libpam/modules/pam_ftpusers/Makefile | 1 - lib/libpam/modules/pam_group/Makefile | 1 - lib/libpam/modules/pam_guest/Makefile | 1 - lib/libpam/modules/pam_passwdqc/Makefile | 1 - lib/libpam/modules/pam_rhosts/Makefile | 1 - lib/libpam/modules/pam_xdg/Makefile | 1 - lib/libpam/pam.d/Makefile | 1 - lib/libpathconv/Makefile | 1 - lib/libpathconv/tests/Makefile | 1 - lib/libpfctl/Makefile | 1 - lib/libpmc/Makefile | 1 - lib/libpmc/Makefile.inc | 1 - lib/libpmc/pmu-events/Makefile | 1 - lib/libproc/Makefile | 1 - lib/libproc/Makefile.inc | 1 - lib/libproc/tests/Makefile | 1 - lib/libprocstat/Makefile | 1 - lib/libprocstat/zfs/Makefile | 1 - lib/libregex/Makefile | 1 - lib/libregex/tests/Makefile | 1 - lib/librpcsec_gss/Makefile | 1 - lib/librpcsvc/Makefile | 1 - lib/librss/Makefile | 1 - lib/librt/tests/Makefile | 1 - lib/librtld_db/Makefile | 1 - lib/libsbuf/Makefile | 1 - lib/libsbuf/tests/Makefile | 1 - lib/libsecureboot/Makefile | 1 - lib/libsecureboot/Makefile.inc | 1 - lib/libsecureboot/Makefile.libsa.inc | 1 - lib/libsecureboot/openpgp/Makefile.inc | 1 - lib/libsecureboot/tests/Makefile | 1 - lib/libsm/Makefile | 1 - lib/libsmb/Makefile | 1 - lib/libsmdb/Makefile | 1 - lib/libsmutil/Makefile | 1 - lib/libsqlite3/Makefile | 1 - lib/libssp/Makefile | 1 - lib/libssp_nonshared/Makefile | 1 - lib/libstats/Makefile | 1 - lib/libstdbuf/Makefile | 1 - lib/libstdthreads/Makefile | 1 - lib/libsysdecode/Makefile | 1 - lib/libtelnet/Makefile | 1 - lib/libthr/Makefile | 1 - lib/libthr/arch/aarch64/Makefile.inc | 1 - lib/libthr/sys/Makefile.inc | 1 - lib/libthr/tests/Makefile | 1 - lib/libthr/tests/dlopen/Makefile | 1 - lib/libthr/tests/dlopen/dso/Makefile | 1 - lib/libthr/thread/Makefile.inc | 1 - lib/libthread_db/Makefile | 1 - lib/libucl/Makefile | 1 - lib/libufs/Makefile | 1 - lib/libugidfw/Makefile | 1 - lib/libulog/Makefile | 1 - lib/libunbound/Makefile | 1 - lib/libutil/Makefile | 1 - lib/libutil/tests/Makefile | 1 - lib/libveriexec/Makefile | 1 - lib/libxo/Makefile | 1 - lib/libxo/encoder/Makefile | 1 - lib/libxo/encoder/csv/Makefile | 1 - lib/libxo/libxo/Makefile | 1 - lib/libxo/tests/Makefile | 1 - lib/libxo/tests/encoder/Makefile | 1 - lib/liby/Makefile | 1 - lib/libypclnt/Makefile | 1 - lib/libzstd/Makefile | 1 - lib/msun/aarch64/Makefile.inc | 1 - lib/msun/amd64/Makefile.inc | 1 - lib/msun/arm/Makefile.inc | 1 - lib/msun/i387/Makefile.inc | 1 - lib/msun/powerpc/Makefile.inc | 1 - lib/msun/riscv/Makefile.inc | 1 - lib/msun/tests/Makefile | 1 - lib/ncurses/Makefile | 1 - lib/ncurses/Makefile.inc | 1 - lib/ncurses/form/Makefile | 1 - lib/ncurses/menu/Makefile | 1 - lib/ncurses/ncurses/Makefile | 1 - lib/ncurses/panel/Makefile | 1 - lib/ncurses/tinfo/Makefile | 1 - lib/ofed/Makefile | 1 - lib/ofed/Makefile.inc | 1 - lib/ofed/complib/Makefile | 1 - lib/ofed/include/Makefile | 1 - lib/ofed/libcxgb4/Makefile | 1 - lib/ofed/libibcm/Makefile | 1 - lib/ofed/libibmad/Makefile | 1 - lib/ofed/libibnetdisc/Makefile | 1 - lib/ofed/libibumad/Makefile | 1 - lib/ofed/libibverbs/Makefile | 1 - lib/ofed/libmlx4/Makefile | 1 - lib/ofed/libmlx5/Makefile | 1 - lib/ofed/libopensm/Makefile | 1 - lib/ofed/librdmacm/Makefile | 1 - lib/ofed/libvendor/Makefile | 1 - lib/tests/Makefile | 1 - libexec/Makefile.inc | 1 - libexec/atf/atf-check/Makefile.inc | 1 - libexec/atf/atf-check/tests/Makefile | 1 - libexec/atf/atf-sh/tests/Makefile | 1 - libexec/atf/tests/Makefile | 1 - libexec/atrun/Makefile | 1 - libexec/blacklistd-helper/Makefile | 1 - libexec/bootpd/Makefile.inc | 1 - libexec/comsat/Makefile | 1 - libexec/dma/Makefile | 1 - libexec/dma/Makefile.inc | 1 - libexec/dma/dma-mbox-create/Makefile | 1 - libexec/dma/dmagent/Makefile | 1 - libexec/fingerd/Makefile | 1 - libexec/flua/Makefile | 1 - libexec/ftpd/Makefile | 1 - libexec/getty/Makefile | 1 - libexec/hyperv/Makefile | 1 - libexec/mail.local/Makefile | 1 - libexec/makewhatis.local/Makefile | 1 - libexec/mknetid/Makefile | 1 - libexec/phttpget/Makefile | 1 - libexec/pppoed/Makefile | 1 - libexec/rbootd/Makefile | 1 - libexec/rc/Makefile | 1 - libexec/rc/rc.d/Makefile | 1 - libexec/revnetgroup/Makefile | 1 - libexec/rpc.rquotad/Makefile | 1 - libexec/rpc.rstatd/Makefile | 1 - libexec/rpc.rusersd/Makefile | 1 - libexec/rpc.rwalld/Makefile | 1 - libexec/rpc.sprayd/Makefile | 1 - libexec/rtld-elf/Makefile | 1 - libexec/rtld-elf/amd64/Makefile.inc | 1 - libexec/rtld-elf/arm/Makefile.inc | 1 - libexec/rtld-elf/i386/Makefile.inc | 1 - libexec/rtld-elf/powerpc64/Makefile.inc | 1 - libexec/rtld-elf/tests/Makefile | 1 - libexec/rtld-elf/tests/Makefile.inc | 1 - libexec/rtld-elf/tests/libdeep/Makefile | 1 - libexec/rtld-elf/tests/libpythagoras/Makefile | 1 - libexec/rtld-elf/tests/libval/Makefile | 1 - libexec/rtld-elf/tests/libval2/Makefile | 1 - libexec/rtld-elf/tests/rtld_deepbind/Makefile | 1 - libexec/rtld-elf/tests/target/Makefile | 1 - libexec/rtld-elf32/Makefile | 1 - libexec/save-entropy/Makefile | 1 - libexec/smrsh/Makefile | 1 - libexec/talkd/Makefile | 1 - libexec/tcpd/Makefile | 1 - libexec/tests/Makefile | 1 - libexec/tftp-proxy/Makefile | 1 - libexec/tftpd/Makefile | 1 - libexec/tftpd/tests/Makefile | 1 - libexec/ulog-helper/Makefile | 1 - libexec/ypxfr/Makefile | 1 - rescue/Makefile | 1 - rescue/rescue/Makefile | 1 - sbin/Makefile | 1 - sbin/Makefile.amd64 | 1 - sbin/Makefile.arm | 1 - sbin/Makefile.i386 | 1 - sbin/Makefile.inc | 1 - sbin/Makefile.powerpc64 | 1 - sbin/adjkerntz/Makefile | 1 - sbin/bectl/Makefile | 1 - sbin/bectl/tests/Makefile | 1 - sbin/bsdlabel/Makefile | 1 - sbin/camcontrol/Makefile | 1 - sbin/ccdconfig/Makefile | 1 - sbin/clri/Makefile | 1 - sbin/comcontrol/Makefile | 1 - sbin/conscontrol/Makefile | 1 - sbin/ddb/Makefile | 1 - sbin/decryptcore/Makefile | 1 - sbin/devd/Makefile | 1 - sbin/devd/tests/Makefile | 1 - sbin/devfs/Makefile | 1 - sbin/devmatch/Makefile | 1 - sbin/dhclient/tests/Makefile | 1 - sbin/dmesg/Makefile | 1 - sbin/dump/Makefile | 1 - sbin/dumpfs/Makefile | 1 - sbin/dumpon/Makefile | 1 - sbin/etherswitchcfg/Makefile | 1 - sbin/fdisk/Makefile | 1 - sbin/fsck_ffs/Makefile | 1 - sbin/geom/Makefile | 1 - sbin/ggate/Makefile | 1 - sbin/ggate/Makefile.inc | 1 - sbin/ggate/ggatec/Makefile | 1 - sbin/ggate/ggated/Makefile | 1 - sbin/ggate/ggatel/Makefile | 1 - sbin/growfs/tests/Makefile | 1 - sbin/gvinum/Makefile | 1 - sbin/hastctl/Makefile | 1 - sbin/hastd/Makefile | 1 - sbin/ifconfig/Makefile | 1 - sbin/ifconfig/tests/Makefile | 1 - sbin/init/Makefile | 1 - sbin/ipf/Makefile | 1 - sbin/ipf/Makefile.inc | 1 - sbin/ipf/ipf/Makefile | 1 - sbin/ipf/ipfs/Makefile | 1 - sbin/ipf/ipfstat/Makefile | 1 - sbin/ipf/ipftest/Makefile | 1 - sbin/ipf/ipmon/Makefile | 1 - sbin/ipf/ipnat/Makefile | 1 - sbin/ipf/ippool/Makefile | 1 - sbin/ipf/ipresend/Makefile | 1 - sbin/ipf/ipscan/Makefile | 1 - sbin/ipf/libipf/Makefile | 1 - sbin/ipfw/Makefile | 1 - sbin/ldconfig/Makefile | 1 - sbin/md5/Makefile | 1 - sbin/md5/tests/Makefile | 1 - sbin/mdconfig/Makefile | 1 - sbin/mdconfig/tests/Makefile | 1 - sbin/mdmfs/Makefile | 1 - sbin/mknod/Makefile | 1 - sbin/mksnap_ffs/Makefile | 1 - sbin/mount/Makefile | 1 - sbin/mount_cd9660/Makefile | 1 - sbin/mount_fusefs/Makefile | 1 - sbin/mount_nfs/Makefile | 1 - sbin/mount_nullfs/Makefile | 1 - sbin/mount_udf/Makefile | 1 - sbin/mount_unionfs/Makefile | 1 - sbin/natd/Makefile | 1 - sbin/newfs/Makefile | 1 - sbin/newfs_msdos/Makefile | 1 - sbin/nfsiod/Makefile | 1 - sbin/nos-tun/Makefile | 1 - sbin/nvmecontrol/modules/Makefile | 1 - sbin/nvmecontrol/modules/Makefile.inc | 1 - sbin/nvmecontrol/modules/intel/Makefile | 1 - sbin/nvmecontrol/modules/samsung/Makefile | 1 - sbin/nvmecontrol/modules/wdc/Makefile | 1 - sbin/nvmecontrol/tests/Makefile | 1 - sbin/pfctl/Makefile | 1 - sbin/pfctl/tests/Makefile | 1 - sbin/pfctl/tests/files/Makefile | 1 - sbin/pfilctl/Makefile | 1 - sbin/pflogd/Makefile | 1 - sbin/pflowctl/Makefile | 1 - sbin/ping/Makefile | 1 - sbin/ping/tests/Makefile | 1 - sbin/quotacheck/Makefile | 1 - sbin/reboot/Makefile | 1 - sbin/recoverdisk/Makefile | 1 - sbin/resolvconf/Makefile | 1 - sbin/restore/Makefile | 1 - sbin/route/Makefile | 1 - sbin/route/tests/Makefile | 1 - sbin/routed/Makefile.inc | 1 - sbin/savecore/Makefile | 1 - sbin/shutdown/Makefile | 1 - sbin/swapon/Makefile | 1 - sbin/sysctl/Makefile | 1 - sbin/sysctl/tests/Makefile | 1 - sbin/tests/Makefile | 1 - sbin/tunefs/Makefile | 1 - sbin/umount/Makefile | 1 - sbin/veriexec/Makefile | 1 - secure/Makefile | 1 - secure/Makefile.inc | 1 - secure/caroot/Makefile | 1 - secure/caroot/Makefile.inc | 1 - secure/caroot/trusted/Makefile | 1 - secure/caroot/untrusted/Makefile | 1 - secure/lib/Makefile | 1 - secure/lib/Makefile.inc | 1 - secure/lib/libcrypto/Makefile | 1 - secure/lib/libcrypto/Makefile.common | 1 - secure/lib/libcrypto/Makefile.inc | 1 - secure/lib/libcrypto/engines/Makefile | 1 - secure/lib/libcrypto/engines/Makefile.inc | 1 - secure/lib/libcrypto/engines/capi/Makefile | 1 - secure/lib/libcrypto/engines/devcrypto/Makefile | 1 - secure/lib/libcrypto/engines/loader_attic/Makefile | 1 - secure/lib/libcrypto/engines/padlock/Makefile | 1 - secure/lib/libcrypto/modules/Makefile | 1 - secure/lib/libcrypto/modules/Makefile.inc | 1 - secure/lib/libcrypto/modules/fips/Makefile | 1 - secure/lib/libcrypto/modules/legacy/Makefile | 1 - secure/lib/libssh/Makefile | 1 - secure/lib/libssl/Makefile | 1 - secure/lib/tests/Makefile | 1 - secure/libexec/Makefile | 1 - secure/libexec/Makefile.inc | 1 - secure/libexec/sftp-server/Makefile | 1 - secure/libexec/ssh-keysign/Makefile | 1 - secure/libexec/ssh-pkcs11-helper/Makefile | 1 - secure/libexec/tests/Makefile | 1 - secure/tests/Makefile | 1 - secure/usr.bin/Makefile | 1 - secure/usr.bin/Makefile.inc | 1 - secure/usr.bin/openssl/Makefile | 1 - secure/usr.bin/scp/Makefile | 1 - secure/usr.bin/sftp/Makefile | 1 - secure/usr.bin/ssh-add/Makefile | 1 - secure/usr.bin/ssh-agent/Makefile | 1 - secure/usr.bin/ssh-keygen/Makefile | 1 - secure/usr.bin/ssh-keyscan/Makefile | 1 - secure/usr.bin/ssh/Makefile | 1 - secure/usr.bin/tests/Makefile | 1 - secure/usr.sbin/Makefile | 1 - secure/usr.sbin/Makefile.inc | 1 - secure/usr.sbin/sshd/Makefile | 1 - secure/usr.sbin/tests/Makefile | 1 - share/Makefile | 1 - share/Makefile.inc | 1 - share/colldef/Makefile | 1 - share/ctypedef/Makefile | 1 - share/dict/Makefile | 1 - share/doc/IPv6/Makefile | 1 - share/doc/Makefile | 1 - share/doc/legal/Makefile | 1 - share/doc/legal/Makefile.armv7 | 1 - share/doc/legal/imx/Makefile | 1 - share/doc/legal/intel_ipw/Makefile | 1 - share/doc/legal/intel_iwi/Makefile | 1 - share/doc/legal/intel_iwlwififw/Makefile | 1 - share/doc/legal/intel_iwn/Makefile | 1 - share/doc/legal/intel_wpi/Makefile | 1 - share/doc/legal/realtek/Makefile | 1 - share/doc/llvm/Makefile | 1 - share/doc/llvm/clang/Makefile | 1 - share/doc/papers/Makefile | 1 - share/doc/papers/beyond4.3/Makefile | 1 - share/doc/papers/bufbio/Makefile | 1 - share/doc/papers/contents/Makefile | 1 - share/doc/papers/devfs/Makefile | 1 - share/doc/papers/diskperf/Makefile | 1 - share/doc/papers/fsinterface/Makefile | 1 - share/doc/papers/jail/Makefile | 1 - share/doc/papers/kernmalloc/Makefile | 1 - share/doc/papers/kerntune/Makefile | 1 - share/doc/papers/malloc/Makefile | 1 - share/doc/papers/newvm/Makefile | 1 - share/doc/papers/relengr/Makefile | 1 - share/doc/papers/sysperf/Makefile | 1 - share/doc/papers/timecounter/Makefile | 1 - share/doc/pjdfstest/Makefile | 1 - share/doc/psd/01.cacm/Makefile | 1 - share/doc/psd/02.implement/Makefile | 1 - share/doc/psd/03.iosys/Makefile | 1 - share/doc/psd/04.uprog/Makefile | 1 - share/doc/psd/05.sysman/Makefile | 1 - share/doc/psd/06.Clang/Makefile | 1 - share/doc/psd/12.make/Makefile | 1 - share/doc/psd/15.yacc/Makefile | 1 - share/doc/psd/16.lex/Makefile | 1 - share/doc/psd/17.m4/Makefile | 1 - share/doc/psd/18.gprof/Makefile | 1 - share/doc/psd/20.ipctut/Makefile | 1 - share/doc/psd/21.ipc/Makefile | 1 - share/doc/psd/22.rpcgen/Makefile | 1 - share/doc/psd/23.rpc/Makefile | 1 - share/doc/psd/24.xdr/Makefile | 1 - share/doc/psd/25.xdrrfc/Makefile | 1 - share/doc/psd/26.rpcrfc/Makefile | 1 - share/doc/psd/27.nfsrpc/Makefile | 1 - share/doc/psd/Makefile | 1 - share/doc/psd/contents/Makefile | 1 - share/doc/psd/title/Makefile | 1 - share/doc/smm/01.setup/Makefile | 1 - share/doc/smm/02.config/Makefile | 1 - share/doc/smm/03.fsck/Makefile | 1 - share/doc/smm/04.quotas/Makefile | 1 - share/doc/smm/05.fastfs/Makefile | 1 - share/doc/smm/06.nfs/Makefile | 1 - share/doc/smm/07.lpd/Makefile | 1 - share/doc/smm/08.sendmailop/Makefile | 1 - share/doc/smm/11.timedop/Makefile | 1 - share/doc/smm/12.timed/Makefile | 1 - share/doc/smm/18.net/Makefile | 1 - share/doc/smm/Makefile | 1 - share/doc/smm/contents/Makefile | 1 - share/doc/smm/title/Makefile | 1 - share/doc/usd/04.csh/Makefile | 1 - share/doc/usd/05.dc/Makefile | 1 - share/doc/usd/06.bc/Makefile | 1 - share/doc/usd/07.mail/Makefile | 1 - share/doc/usd/10.exref/Makefile | 1 - share/doc/usd/10.exref/Makefile.inc | 1 - share/doc/usd/10.exref/exref/Makefile | 1 - share/doc/usd/10.exref/summary/Makefile | 1 - share/doc/usd/11.vitut/Makefile | 1 - share/doc/usd/12.vi/Makefile | 1 - share/doc/usd/12.vi/Makefile.inc | 1 - share/doc/usd/12.vi/summary/Makefile | 1 - share/doc/usd/12.vi/vi/Makefile | 1 - share/doc/usd/12.vi/viapwh/Makefile | 1 - share/doc/usd/13.viref/Makefile | 1 - share/doc/usd/18.msdiffs/Makefile | 1 - share/doc/usd/19.memacros/Makefile | 1 - share/doc/usd/20.meref/Makefile | 1 - share/doc/usd/21.troff/Makefile | 1 - share/doc/usd/Makefile | 1 - share/doc/usd/contents/Makefile | 1 - share/doc/usd/title/Makefile | 1 - share/examples/FreeBSD_version/Makefile | 1 - share/examples/find_interface/Makefile | 1 - share/examples/hwpmc/Makefile | 1 - share/examples/ipfilter/Makefile | 1 - share/examples/kld/cdev/Makefile | 1 - share/examples/kld/dyn_sysctl/Makefile | 1 - share/examples/kld/firmware/Makefile | 1 - share/examples/kld/firmware/fwconsumer/Makefile | 1 - share/examples/kld/firmware/fwimage/Makefile | 1 - share/examples/kld/khelp/Makefile | 1 - share/examples/kld/random_adaptor/Makefile | 1 - share/examples/kld/syscall/Makefile | 1 - share/examples/libusb20/Makefile | 1 - share/examples/libvgl/Makefile | 1 - share/examples/perfmon/Makefile | 1 - share/examples/pf/Makefile | 1 - share/examples/scsi_target/Makefile | 1 - share/examples/smbfs/Makefile | 1 - share/examples/smbfs/print/Makefile | 1 - share/examples/tests/Makefile | 1 - share/examples/tests/tests/Makefile | 1 - share/examples/tests/tests/atf/Makefile | 1 - share/examples/tests/tests/plain/Makefile | 1 - share/examples/tests/tests/tap/Makefile | 1 - share/i18n/csmapper/Makefile.inc | 1 - share/i18n/esdb/Makefile.inc | 1 - share/keys/Makefile | 1 - share/keys/pkg/Makefile | 1 - share/keys/pkg/trusted/Makefile | 1 - share/man/Makefile | 1 - share/man/man1/Makefile | 1 - *** 30668 LINES SKIPPED *** From nobody Tue Jul 16 01:38:03 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNMCH67Mpz5QfH2; Tue, 16 Jul 2024 01:38:03 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNMCH5f08z4PRG; Tue, 16 Jul 2024 01:38:03 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721093883; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=I9Kn0W2ZNBseNffDE1hK3XXUkUZGX8YA4ivT8TTpQMI=; b=J5NE0zWQ+3o7CPoOwlVaAPCHwbZmqiTAgM72uHmRfGNKtykhbvr67v0moOzz9PUIQdsQa8 syEJR1m8V3KYhTjuppGjrgO6WxzuRkjmzS5tEDwsu1tgWBUe80FFtTyeUx5w2o/wTKxmrx 13VzzKm88ntT4Lcz8XeMxxKoqWKvhWeBbL96xZShdHaGgw64PQ5ajSW09SYmEK1CFDYb++ gVXxW7ST8sKAk6HvGBYwQ9y0Imv144yf/JzX3cU+z7gC1a09cBpzkKs3LLsBpLo7aDMkAQ A5svr/wfgJshY0vbEu1MTqU+5XrEua8/zBrjQbDj42XJ3Yrjj/lME20MZ2BpSA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721093883; a=rsa-sha256; cv=none; b=SGcbVrLtJsWZ1B+yN05JQTFJLC9K8+KhoqpVjhebt1YB3lESeGI6PZmt6/Eoae43KD7AtU VS3uShfeiDfeu35yiMEoBxDUDkG8ZU8EMoUpZU8Q8sBm+Drw7g72eTr9GpsjtBdSnaIuAU zarV1P+VWxCv5gPHaiTpfnP9FIzpOZoxoC6zvwfY0SPWP0phbmnL3cHB4LoFGhzr4HhVLD t5L4iHlw6xpCbq7kjSgH6rts7PkuUjdvtDceDIIWT8ZWwIrl/ezWEGBKFLcqhbCZ8p4jf/ JLD0LYqxLjqAoKC3eJwcOSMTl7OPqrIbQ5DV3GA/b1tA52pWbEOTZ8QnD7BnbA== 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=1721093883; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=I9Kn0W2ZNBseNffDE1hK3XXUkUZGX8YA4ivT8TTpQMI=; b=EPzpdLLVXL8SkEwxp45gjI16YxUxRp3lmq4gw16epD06LpNdpEvfQ9O85MCPBo60VYcEv0 dfAa8eIuzRj6F7Is+XsRRkHjzgiHgIH56IK53ZrDYz4ddddKzXPCHwDSku/wNdkX6Bk7st lybi7qj/DzpvK8LrhupYQC3sxgsACIEcinxd7y7atGWJi86nJ5zK+vtFT+WKFv+Cvtf55d pqu5Ogv5bAHL6d9+puMssC9MHLozNUOt381gqVAxCQe4txNoBZamqJtCUcz4hqy1NX/s7H 09QIZwp2nSj75O3OYmdqYRdTqeGDzyvskcc5NuTHA7LGbXGHRDEXWTSMygcxmw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNMCH5BgnzGth; Tue, 16 Jul 2024 01:38:03 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46G1c3f7081868; Tue, 16 Jul 2024 01:38:03 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46G1c31B081865; Tue, 16 Jul 2024 01:38:03 GMT (envelope-from git) Date: Tue, 16 Jul 2024 01:38:03 GMT Message-Id: <202407160138.46G1c31B081865@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: a39decd73f82 - main - etcupdate: remove mergemaster cross-reference List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: emaste X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: a39decd73f82c74cbe2cecb8f71ca5d3417e5978 Auto-Submitted: auto-generated The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=a39decd73f82c74cbe2cecb8f71ca5d3417e5978 commit a39decd73f82c74cbe2cecb8f71ca5d3417e5978 Author: Ed Maste AuthorDate: 2024-07-16 01:36:34 +0000 Commit: Ed Maste CommitDate: 2024-07-16 01:37:14 +0000 etcupdate: remove mergemaster cross-reference It will be retired soon. Sponsored by: The FreeBSD Foundation --- usr.sbin/etcupdate/etcupdate.8 | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/usr.sbin/etcupdate/etcupdate.8 b/usr.sbin/etcupdate/etcupdate.8 index 82c36fc9cb68..22d3d91bb6eb 100644 --- a/usr.sbin/etcupdate/etcupdate.8 +++ b/usr.sbin/etcupdate/etcupdate.8 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd August 9, 2022 +.Dd July 15, 2024 .Dt ETCUPDATE 8 .Os .Sh NAME @@ -894,7 +894,6 @@ but it has been removed in the destination directory. .Xr make 1 , .Xr newaliases 1 , .Xr sh 1 , -.Xr mergemaster 8 , .Xr pwd_mkdb 8 , .Xr services_mkdb 8 , .Xr tzsetup 8 From nobody Tue Jul 16 04:48:06 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNRQZ6h0Jz5QyKr; Tue, 16 Jul 2024 04:48: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNRQZ69bkz4g4g; Tue, 16 Jul 2024 04:48:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721105286; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=JkBvu6u+9hC++dEp9bBmCrwBd6KY5pXGNfVhpet53VU=; b=sFHrkNY2cVVoCbgzTChAFtyEsQ0+9WJ8S8wyOXY9cN55kncpH59AcNwqHpOunjCIUigszM DAkWyQYsK/ZjzFaFBKtKA+oNZff10gFYlpmy+wEH0t+Y/wcwzQzeEwcSp9qAo2xR+SY10m wu6lElPPhZhuS3Uf9yXK4J4PwZdpvFEP7jj01h7DYRCyL6g91IxmPfaGyt2OGhca5MuVSE +5nMtAFN7MKSt/1BdhYxOgQ3w+STpW1+hL2qKKmcRyCzZgFC6fGjQZiK+cMICw/AXf30y+ 9jMsi60ijgVMIY/xfKkace1CfFaO0WDCilwz9OO1IlnVob3Bl4hnmdKA6t/Z7Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721105286; a=rsa-sha256; cv=none; b=KfcT9JkQKzvsXHdhDpDLscYkxlcdI+RXDvqCLgqhpvsCSAp2OL31PtQtGD2p8c3rIpdW9W lvbUyToywnSNpDEYgy8M3WhUrXdohTEYjglaNiH4L3yl9sEBG3W4ziHmK3vSFX1i0B4Ap0 xbLv26S7cCtH1dPNIQ7co4gXBvcmmqjQglf/FCkn315CY2tY6zUtxXJ42wTQ/3v/3nFbjj q/TIk2FZ3zMP8VTp9KkkmPbDU4nAusTY2UIS9hMyz1VbknQdL8H+V6qNHBV76niX4VF+3F OERyebuanVeaMt9CYpWTKmSNaiN6rRFK4PHu8cU6DvRowW0X0CanN/5KKVUsEQ== 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=1721105286; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=JkBvu6u+9hC++dEp9bBmCrwBd6KY5pXGNfVhpet53VU=; b=tIw7UtzLq1wyfEiSKqCMcIDNdnSwBKTkC5RzMZV4UvXG7X5+ZRbsfaSRmOacaUipJiuD0I bbdVieFnGBxgfKUnbiaVaHB55UgCsuZbxnOLVIGxUn3yIVGdL6noDidpq36571+EF5OCV4 swEqpZ+UzlIKpO8AH6dbBhlyqwZmgp6IdkVD5ByiLTbEzmnzdLBRRHU8MOhzxLdsD96HmG ZFbtCkQIVIqLSTy6i9t2Ls0p+6McOVlFcAOQ42b7Qk6zvdoRVbH8vyxcWDbPJa5o5MwYax nyVGIFfTtYoVSHvnjOqrNbJoaeNqYiVgDgXm255r9ZqI3ThPcO+pAKRk/H3aJQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNRQZ5mbszMcm; Tue, 16 Jul 2024 04:48:06 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46G4m62C006027; Tue, 16 Jul 2024 04:48:06 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46G4m6Cq006024; Tue, 16 Jul 2024 04:48:06 GMT (envelope-from git) Date: Tue, 16 Jul 2024 04:48:06 GMT Message-Id: <202407160448.46G4m6Cq006024@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Peter Holm Subject: git: 9c73f38cd3ab - main - stress2: Add a new test scenario. Update the exclude list List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: pho X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9c73f38cd3abc21e88ec446d44a35b27ee4439ea Auto-Submitted: auto-generated The branch main has been updated by pho: URL: https://cgit.FreeBSD.org/src/commit/?id=9c73f38cd3abc21e88ec446d44a35b27ee4439ea commit 9c73f38cd3abc21e88ec446d44a35b27ee4439ea Author: Peter Holm AuthorDate: 2024-07-16 04:47:28 +0000 Commit: Peter Holm CommitDate: 2024-07-16 04:47:28 +0000 stress2: Add a new test scenario. Update the exclude list --- tools/test/stress2/misc/all.exclude | 3 ++- tools/test/stress2/misc/swapoff6.sh | 42 +++++++++++++++++++++++++++++++++++++ 2 files changed, 44 insertions(+), 1 deletion(-) diff --git a/tools/test/stress2/misc/all.exclude b/tools/test/stress2/misc/all.exclude index 07cff21a1d9a..f8936d9efee8 100644 --- a/tools/test/stress2/misc/all.exclude +++ b/tools/test/stress2/misc/all.exclude @@ -60,6 +60,7 @@ suj36.sh https://people.freebsd.org/~pho/stress/log/log0392.txt 20221114 swapoff2.sh swap_pager_force_pagein: read from swap failed 20171223 swapoff3.sh Excessive OOM killing 20220403 swapoff5.sh log0005.txt, known issue 20210111 +swapoff6.sh https://people.freebsd.org/~pho/stress/log/log0540.txt 20240716 systrace.sh WiP 20200227 systrace2.sh WiP 20200227 syzkaller16.sh zonelimit issue 20210722 @@ -70,8 +71,8 @@ syzkaller59.sh Page fault 20220625 syzkaller65.sh panic: in_pcblookup_hash_locked: invalid local address 20230318 syzkaller66.sh panic: in_pcbconnect: inp is already connected 20230621 syzkaller67.sh panic: ASan: Invalid access, 8-byte read at ... 20230621 +quota6.sh https://people.freebsd.org/~pho/stress/log/log0456.txt 20240707 truss3.sh WiP 20200915 -unionfs19.sh https://people.freebsd.org/~pho/stress/log/log0519.txt 20240702 # Test not to run for other reasons: diff --git a/tools/test/stress2/misc/swapoff6.sh b/tools/test/stress2/misc/swapoff6.sh new file mode 100755 index 000000000000..b6ab08784f87 --- /dev/null +++ b/tools/test/stress2/misc/swapoff6.sh @@ -0,0 +1,42 @@ +#!/bin/sh + +# +# Copyright (c) 2024 Peter Holm +# +# SPDX-License-Identifier: BSD-2-Clause +# + +# A swap test scenario, using swapoff(8) and sort(1) for VM pressure + +# Out of free pages seen:://people.freebsd.org/~pho/stress/log/log0540.txt + +. ../default.cfg +[ `id -u` -ne 0 ] && echo "Must be root!" && exit 1 + +[ `swapinfo | wc -l` -eq 1 ] && exit 0 +set -u +nmax=`sysctl -n hw.ncpu` +[ $nmax -gt 4 ] && nmax=4 + +for i in `jot $nmax`; do + timeout -k 2m 1m sort /dev/zero & + sleep .`jot -r 1 1 9` +done +while [ `swapinfo | tail -1 | awk '{sub("%","");print $NF}'` -lt 2 ]; do sleep 1; done + +start=`date +%s` +while [ $((`date +%s` - start)) -lt 300 ]; do + while ! swapoff -a > /dev/null 2>&1; do sleep .1; done + swapon -a > /dev/null + ncur=`pgrep sort | wc -l` + if [ $ncur -lt $nmax ]; then + echo "Starting $((nmax - ncur)) sort" + for i in `jot $((nmax - ncur))`; do + timeout -k 2m 1m sort /dev/zero & + sleep .`jot -r 1 1 9` + done + fi +done +pkill -9 sort +wait +exit 0 From nobody Tue Jul 16 05:12:45 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNRz13tqvz5R18Z; Tue, 16 Jul 2024 05:12: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNRz13HfDz4hfG; Tue, 16 Jul 2024 05:12:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721106765; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=z0iL5jmQtQaUjTcp0jSnlvGBdAOQPO6aTvFbApFlIHE=; b=W3coQ/yUPYNQD9BjYlmSFxXRAxo332XqcYekh2JvvoQtclWuMjaZKAUeTb29OF2MjxNHkA egWWBWLTIaZlTc4SuIPe1gjUH7zZdnmlZFUoP4xnOxUGd3AFKKJ1SqPFjJptwkv5sxQ4mU Q5TiMMtGenBeBmafLbSHaLj5HtY0NmeYPmbmPRutaIHA+51c8lq0eV53pHnRdAGLuRnvQK T5FulqqOLkqfUTwKSarJLeQpFOC91L0R2/cGh8RrncGUtyxgeB6IpmDLe+fzozFq/QIRbL WKntf2S0N7/krwtrU+yoSgpK/aPnoYMbMcvTS9UcPKUg9dDxCVnLvRWmEV4muw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721106765; a=rsa-sha256; cv=none; b=iXRDRzXjP+j1yc/RwD4Cu0OU5/WyHILBRqv+LZ91fofxhM71BPzb3dwJqulvGuMcubtGQh oqfWQN8zdy8YKWfkMveO9ye2e8L6V2j0rwhEDQ4TJBWtG0KQEbjYEHC8+g2hPs2tfZrrpi qPmYl9sitZli4/KkXbAh2CjpEW23gxJ2kewQVPbIzQGIqUHBxwgzcyp4nWIifkUxv1zXh1 IpPIBBmjlKX2Uxltzf+HScWV96Zs9iVelHsHTV1pxW1xmyo5xVMkH3jET2mc9BMuGIrw4T bboV6xCt3S3sde8lQDH/v3c2UGX7c02fJ7r2WJD+w01TU0VCx+tThF6NMs89hQ== 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=1721106765; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=z0iL5jmQtQaUjTcp0jSnlvGBdAOQPO6aTvFbApFlIHE=; b=Qx0vWTKULFS8J6/oZNXl2jXm2kAr5rPnjQ6OhSBReSpwDkrnzOY1Cgg6rGq6MgE4JzZW5r 53/MyC0l8jtRLZEgmtsDYJ+e3xCVrDMv3Ud2BBdsiTdQvZFfCT3SHi/fEmWY+VoFIvrCeZ bCG9FR6zWf7UZFwFEgRqWB5Vzy5m7CoqQM1wja4L4FqZNBhoyhkzAZLfls28hgNZ1/NIXX uHFONbQ6DwDqSl2VUOVcHZTGPBIvjamfT37RIw2ls4Bj2/VBlG1ZjiIONX6ZdXO9vNpXnt jyuEsZOKWIY5qBXT8lOlUCWteuMOFxg8nEyYW21i7rLBxIvVmUfmP+zsYC+/Cw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNRz12b9ZzNK2; Tue, 16 Jul 2024 05:12:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46G5Cj5t056394; Tue, 16 Jul 2024 05:12:45 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46G5CjpV056391; Tue, 16 Jul 2024 05:12:45 GMT (envelope-from git) Date: Tue, 16 Jul 2024 05:12:45 GMT Message-Id: <202407160512.46G5CjpV056391@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kyle Evans Subject: git: 838b6caababb - main - openssl: use getrandom(2) instead of probing for getentropy(2) List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kevans X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 838b6caababbaaab65659d40a41c2dd46b3a5fd2 Auto-Submitted: auto-generated The branch main has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=838b6caababbaaab65659d40a41c2dd46b3a5fd2 commit 838b6caababbaaab65659d40a41c2dd46b3a5fd2 Author: Kyle Evans AuthorDate: 2024-07-16 05:12:27 +0000 Commit: Kyle Evans CommitDate: 2024-07-16 05:12:27 +0000 openssl: use getrandom(2) instead of probing for getentropy(2) The probing for getentropy(2) relies on re-declaring getentropy(2) as weak and checking the address, but this is incompatible with the _FORTIFY_SOURCE symbol renaming scheme. It's always present on all supported FreeBSD versions now so we could cut it down to unconditional use, but there's another segment for getrandom(2) already that's cleaner to just add us to. We should upstream this. Reviewed by: kib (earlier version), markj Sponsored by: Klara, Inc. Sponsored by: Stormshield Differential Revision: https://reviews.freebsd.org/D45976 --- .../openssl/providers/implementations/rands/seeding/rand_unix.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/crypto/openssl/providers/implementations/rands/seeding/rand_unix.c b/crypto/openssl/providers/implementations/rands/seeding/rand_unix.c index 750afca58ed7..eadacedbe40c 100644 --- a/crypto/openssl/providers/implementations/rands/seeding/rand_unix.c +++ b/crypto/openssl/providers/implementations/rands/seeding/rand_unix.c @@ -356,7 +356,7 @@ static ssize_t syscall_random(void *buf, size_t buflen) * Note: Sometimes getentropy() can be provided but not implemented * internally. So we need to check errno for ENOSYS */ -# if !defined(__DragonFly__) && !defined(__NetBSD__) +# if !defined(__DragonFly__) && !defined(__NetBSD__) && !defined(__FreeBSD__) # if defined(__GNUC__) && __GNUC__>=2 && defined(__ELF__) && !defined(__hpux) extern int getentropy(void *buffer, size_t length) __attribute__((weak)); @@ -393,11 +393,12 @@ static ssize_t syscall_random(void *buf, size_t buflen) /* Linux supports this since version 3.17 */ # if defined(__linux) && defined(__NR_getrandom) return syscall(__NR_getrandom, buf, buflen, 0); -# elif (defined(__FreeBSD__) || defined(__NetBSD__)) && defined(KERN_ARND) - return sysctl_random(buf, buflen); # elif (defined(__DragonFly__) && __DragonFly_version >= 500700) \ - || (defined(__NetBSD__) && __NetBSD_Version >= 1000000000) + || (defined(__NetBSD__) && __NetBSD_Version >= 1000000000) \ + || defined(__FreeBSD__) return getrandom(buf, buflen, 0); +# elif defined(__NetBSD__) && defined(KERN_ARND) + return sysctl_random(buf, buflen); # else errno = ENOSYS; return -1; From nobody Tue Jul 16 05:12:46 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNRz24WX5z5R12V; Tue, 16 Jul 2024 05:12: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNRz23znXz4hcS; Tue, 16 Jul 2024 05:12:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721106766; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=wNtd19RWvU8J/GiTsAovoUptwPrNcBFrYvYpyRLscd0=; b=lB+IM94zPCj8KQyIR3YNFpEjfMUwJXFdbc2UrPP06mlithoqiNE77VPkVxF2LhsPZL6lI8 sehQ1W0k2QU2jJ7Ykhm0gK4AvXGGK2+YlwDd4ipBU+cC/bJZl9NwLzO0QaQfcCOxlYPuqq MAoYFJ88yRal1qctTuAwqSnhAzgruaCsvIYxWCVPZ9k7PUhsL59zMCNOe6bCg6Df7v43tl ASlJHkP4JQSILaR5qP1oLhT904jV2snm7IDds/UF3piDwC+UlJuWb9IxmBQXUT2GZqAA8H VD3vwual5yrSeMeHMG9ANFz0lQ6xRSz7/61P3pl3/lSrpgL5Aa8eG0C7J7C9Sg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721106766; a=rsa-sha256; cv=none; b=USw+vG5KpTg9jAE4789d9SApz2uDxwzLcOD3mNq4n2SgFqrfOKdoDua5+5DXAHkwzKy9rn 5X5Dj+2Zy99gh547FnqdYPAZ39+DBqhkCS5DqnvXEuk4NBzCWlFqWgUREmvp2Ima+9sChP XIP4THhle4GlWJ8ORKOJPTPKnNthdGLUujf0NV4sYGbv7B2J932nx/LZWrKskFUKkg4qYZ NXFIRjxvj97MSmHbeu/vdCXzoM5jx//KZ3o4TJVvz9IM3viv/8Frf9vB41LnoOpstTXPNb QsJkbRp0CliwW1YYC9xUTpNh3c63Ppm6SIcS/Oo35Io4Yb54D3UQqvkLf7Yr/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=1721106766; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=wNtd19RWvU8J/GiTsAovoUptwPrNcBFrYvYpyRLscd0=; b=vemSdQrVf8IxVBcnuKWnJUUog5eAmGgS5noF8z6HYF5wieRZE3U24xDZGg8OH5kD/dVb7V 9r+5QEM78/dik3RE+6+u+7wzId1GxK4VgGC8ItRy/ZJIQjmJgNfWttevlL/5q9VeMoI//8 aWx7NStHtU3K6PTRE6TxZWjTwEpmrRCQdow5r38xCDj35ZaesBRwqgXGtOt1PmG+AVOsM9 jxmOkVI6sXISwU9ZLn4BfLwUusMEsEmpK7KR90yN+tnSWzHQ4cQJuUPN/X+G1CzIhLijC4 QiyoeXxrQkJj3v9JBNFg6Q/MzNAaO1D3mpMZ6y8rQgo06refGhHXEMjHeWCxKw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNRz23cDHzNQ0; Tue, 16 Jul 2024 05:12:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46G5CkeS056448; Tue, 16 Jul 2024 05:12:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46G5CkwD056445; Tue, 16 Jul 2024 05:12:46 GMT (envelope-from git) Date: Tue, 16 Jul 2024 05:12:46 GMT Message-Id: <202407160512.46G5CkwD056445@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kyle Evans Subject: git: b8730c11a395 - main - include: ssp: fix the build with earlier C standards List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kevans X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: b8730c11a395dacc089311ead1c9e015682a1ccb Auto-Submitted: auto-generated The branch main has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=b8730c11a395dacc089311ead1c9e015682a1ccb commit b8730c11a395dacc089311ead1c9e015682a1ccb Author: Kyle Evans AuthorDate: 2024-07-16 05:12:27 +0000 Commit: Kyle Evans CommitDate: 2024-07-16 05:12:27 +0000 include: ssp: fix the build with earlier C standards `inline` isn't always a keyword, so we should be using __ssp_inline as we do everywhere else in the _FORTIFY_SOURCE support. Variable declarations in a loop initializer are also not always supported, so declare any loop vars in advance. Reviewed by: kib (earlier version), markj Sponsored by: Klara, Inc. Sponsored by: Stormshield Differential Revision: https://reviews.freebsd.org/D45976 --- include/ssp/socket.h | 3 ++- include/ssp/ssp.h | 5 +++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/include/ssp/socket.h b/include/ssp/socket.h index 6c0051ad72dc..30a8f0adf1ea 100644 --- a/include/ssp/socket.h +++ b/include/ssp/socket.h @@ -101,11 +101,12 @@ __ssp_redirect_raw_impl(ssize_t, recvmmsg, recvmmsg, const struct timespec *__restrict timeout)) { const size_t vecsz = __ssp_bos(hdrvec); + size_t i; if (vecsz != (size_t)-1 && vecsz / sizeof(*hdrvec) < vlen) __chk_fail(); - for (size_t i = 0; i < vlen; i++) { + for (i = 0; i < vlen; i++) { __ssp_check_msghdr(&hdrvec[i].msg_hdr); } diff --git a/include/ssp/ssp.h b/include/ssp/ssp.h index bdc14137d45b..a161df31d3d4 100644 --- a/include/ssp/ssp.h +++ b/include/ssp/ssp.h @@ -89,7 +89,7 @@ __ssp_redirect_raw_impl(rtype, fun, symbol, args) { \ #include -static inline int +__ssp_inline int __ssp_overlap(const void *leftp, const void *rightp, __size_t sz) { __uintptr_t left = (__uintptr_t)leftp; @@ -112,11 +112,12 @@ __ssp_inline void __ssp_check_iovec(const struct iovec *iov, int iovcnt) { const size_t iovsz = __ssp_bos(iov); + int i; if (iovsz != (size_t)-1 && iovsz / sizeof(*iov) < (size_t)iovcnt) __chk_fail(); - for (int i = 0; i < iovcnt; i++) { + for (i = 0; i < iovcnt; i++) { if (__ssp_bos(iov[i].iov_base) < iov[i].iov_len) __chk_fail(); } From nobody Tue Jul 16 05:12:47 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNRz40bwFz5R18c; Tue, 16 Jul 2024 05:12: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNRz356pLz4j26; Tue, 16 Jul 2024 05:12:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721106767; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Qg/1v5jpPMMWrCRlzgACbNcHIHk/dTldV6Uq1BtZWw4=; b=xci5oTD6J1EPMwnofAzxNBto1k342P/ZjyCAgXjqbIf22nvsjVt3rK//i+ND7c+cbbWm28 P0HJ/a94aMxSpVp9pOzdVheXqKc0Tmlg/6+gohHoWFiFfMHSjqGFHtToBv4Img8Gg38pE/ m5sGO870cs3LFHftFxNonqBNoC6V6xwIpCfKu58qKu7IXQTzW6HhnP379K2pqGmzuPfjJT QVUIWsiGJwNXJGMaYMXgfX9owv4fqsF4xpzARWt4vPsE1+KiWu1aJu5dihSOhtMmKQESk2 MpktgfwKuRY/OG2K4NTkbqhV2pFs8sf36wtDZEDF7ZTPzIKvpZ8tQzrR1+29ww== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721106767; a=rsa-sha256; cv=none; b=JMo6KUyvecUItNZB6Ccx3pmCvQi+LgQb0Q8mSaJOmPoQa+bs9rdaKatG65rZ3iMD7sMInI +1l4sqm5IiA9V79PZOanZGfCl7xP4Jw6JqeaRhodQfYgGtWiLsP2gZ2bz2E6NZ6ylGwDB7 8HGtPM6HstitvbX4fC47fzkynQXr2L99I84vozCbHf+VDqvjaHqtpPlnZTUQaKoZftx4vi br9SlkL3OcvjVp2nhhokFeu1kBGzr6xlIW85qGBcT6rkFznKsOFvC+WDfsT4E1jze2eBLY 0vF45OICkyvwjJOrMFGCRVIxrA+0DIzIo2dbq5FzYXzCZjB0JvRhwz46oubMGA== 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=1721106767; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Qg/1v5jpPMMWrCRlzgACbNcHIHk/dTldV6Uq1BtZWw4=; b=SG2e4doG+L4mYIEswloFS6IEdzQ9n0VEH2qW6mUzi6OC//VPLc/NaHPGGmZa3TaOn3x73T y/AFddeh2h6bDz8iKrzG6jEgdPI9hXXHYm/CdbNDxwtJQIC5sj5CAgyCwdp7/N3Vh0PGc/ a9e4/Q/GjbUQ+k7xmmbl3jgSvSleAaGdT7f+hKIoTgqg9zHSLxpvavAUoA6oAU6D/xZKsF yzcNSq8YfzEYC5ZAKskyjir47+RiMRhvN3zCEVYA2/Unr3Za8942uggO+N2xiQ9wxRVVxA bIYrMq1pnvl004/8PkmzJSxk7XA+lxozttEfaOOj3/V4KIk7qS274Y2nNXiEEg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNRz34fLPzNQ1; Tue, 16 Jul 2024 05:12:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46G5ClHM056496; Tue, 16 Jul 2024 05:12:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46G5Cljm056493; Tue, 16 Jul 2024 05:12:47 GMT (envelope-from git) Date: Tue, 16 Jul 2024 05:12:47 GMT Message-Id: <202407160512.46G5Cljm056493@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kyle Evans Subject: git: 0c47b9c211ed - main - include: ssp: don't shadow the mempcpy builtin List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kevans X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 0c47b9c211ede221629914ae0c5553586e772109 Auto-Submitted: auto-generated The branch main has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=0c47b9c211ede221629914ae0c5553586e772109 commit 0c47b9c211ede221629914ae0c5553586e772109 Author: Kyle Evans AuthorDate: 2024-07-16 05:12:28 +0000 Commit: Kyle Evans CommitDate: 2024-07-16 05:12:28 +0000 include: ssp: don't shadow the mempcpy builtin GCC emits a warning about shadowing a builtin with our mempcpy declaration, so switch it to using the same model as memcpy() and use the apparently-existing __builtin___mempcpy_chk(). Reviewed by: kib (earlier version), markj Sponsored by: Klara, Inc. Sponsored by: Stormshield Differential Revision: https://reviews.freebsd.org/D45976 --- include/ssp/string.h | 16 ++------------ include/string.h | 2 +- lib/libc/secure/Makefile.inc | 2 +- lib/libc/secure/Symbol.map | 1 + lib/libc/secure/mempcpy_chk.c | 49 +++++++++++++++++++++++++++++++++++++++++++ lib/libc/string/mempcpy.c | 2 +- 6 files changed, 55 insertions(+), 17 deletions(-) diff --git a/include/ssp/string.h b/include/ssp/string.h index b9f2dceb1df5..9f24254d9c01 100644 --- a/include/ssp/string.h +++ b/include/ssp/string.h @@ -106,6 +106,7 @@ __ ## fun ## _ichk(type1 __restrict dst, type2 __restrict src) { \ __BEGIN_DECLS __ssp_bos_icheck3_restrict(memcpy, void *, const void *) +__ssp_bos_icheck3_restrict(mempcpy, void *, const void *) __ssp_bos_icheck3(memmove, void *, const void *) __ssp_bos_icheck3(memset, void *, int) __ssp_bos_icheck2_restrict(stpcpy, char *, const char *) @@ -116,23 +117,10 @@ __ssp_redirect0(int, strerror_r, (int __errnum, char *__buf, size_t __len), (__errnum, __buf, __len)); __ssp_bos_icheck3_restrict(strncpy, char *, const char *) __ssp_bos_icheck3_restrict(strncat, char *, const char *) - -__ssp_redirect_raw_impl(void *, mempcpy, mempcpy, - (void *__restrict buf, const void *__restrict src, size_t len)) -{ - const size_t slen = __ssp_bos(buf); - - if (len > slen) - __chk_fail(); - - if (__ssp_overlap(src, buf, len)) - __chk_fail(); - - return (__ssp_real(mempcpy)(buf, src, len)); -} __END_DECLS #define memcpy(dst, src, len) __ssp_bos_check3(memcpy, dst, src, len) +#define mempcpy(dst, src, len) __ssp_bos_check3(mempcpy, dst, src, len) #define memmove(dst, src, len) __ssp_bos_check3(memmove, dst, src, len) #define memset(dst, val, len) \ __ssp_bos_check3_typed(memset, void *, dst, int, val, len) diff --git a/include/string.h b/include/string.h index c9d3e1add1a1..d9adcf4e0e41 100644 --- a/include/string.h +++ b/include/string.h @@ -68,7 +68,7 @@ void *memmem(const void *, size_t, const void *, size_t) __pure; #endif void *(memmove)(void *, const void *, size_t); #if __BSD_VISIBLE -void *mempcpy(void * __restrict, const void * __restrict, size_t); +void *(mempcpy)(void * __restrict, const void * __restrict, size_t); #endif void *(memset)(void *, int, size_t); #if __POSIX_VISIBLE >= 200809 diff --git a/lib/libc/secure/Makefile.inc b/lib/libc/secure/Makefile.inc index 5d10612e67a8..e5286a5a380f 100644 --- a/lib/libc/secure/Makefile.inc +++ b/lib/libc/secure/Makefile.inc @@ -4,7 +4,7 @@ .PATH: ${LIBC_SRCTOP}/secure # _FORTIFY_SOURCE -SRCS+= fgets_chk.c memcpy_chk.c memmove_chk.c memset_chk.c \ +SRCS+= fgets_chk.c memcpy_chk.c memmove_chk.c mempcpy_chk.c memset_chk.c \ snprintf_chk.c sprintf_chk.c stpcpy_chk.c stpncpy_chk.c \ strcat_chk.c strcpy_chk.c strlcat_chk.c strncat_chk.c strlcpy_chk.c \ strncpy_chk.c vsnprintf_chk.c vsprintf_chk.c diff --git a/lib/libc/secure/Symbol.map b/lib/libc/secure/Symbol.map index 1f12fe059367..df0a2d1ac93d 100644 --- a/lib/libc/secure/Symbol.map +++ b/lib/libc/secure/Symbol.map @@ -8,6 +8,7 @@ FBSD_1.8 { __fgets_chk; __memcpy_chk; __memmove_chk; + __mempcpy_chk; __memset_chk; __snprintf_chk; __sprintf_chk; diff --git a/lib/libc/secure/mempcpy_chk.c b/lib/libc/secure/mempcpy_chk.c new file mode 100644 index 000000000000..ca4ae150bc94 --- /dev/null +++ b/lib/libc/secure/mempcpy_chk.c @@ -0,0 +1,49 @@ +/*- + * + * SPDX-License-Identifier: BSD-2-Clause + * + * Copyright (c) 2006 The NetBSD Foundation, Inc. + * All rights reserved. + * + * This code is derived from software contributed to The NetBSD Foundation + * by Christos Zoulas. + * + * 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 NETBSD FOUNDATION, INC. 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 FOUNDATION OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS + * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN + * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + */ + +#include + +#include +#undef mempcpy + +void * +__mempcpy_chk(void * __restrict dst, const void * __restrict src, size_t len, + size_t slen) +{ + if (len > slen) + __chk_fail(); + + if (__ssp_overlap(src, dst, len)) + __chk_fail(); + + return (mempcpy(dst, src, len)); +} diff --git a/lib/libc/string/mempcpy.c b/lib/libc/string/mempcpy.c index 86e44cdebb85..4ea0af87aef1 100644 --- a/lib/libc/string/mempcpy.c +++ b/lib/libc/string/mempcpy.c @@ -32,7 +32,7 @@ #include void * -__ssp_real(mempcpy)(void *__restrict dst, const void *__restrict src, +(mempcpy)(void *__restrict dst, const void *__restrict src, size_t len) { return ((char *)memcpy(dst, src, len) + len); From nobody Tue Jul 16 05:12:48 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNRz50TD3z5R1By; Tue, 16 Jul 2024 05:12: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNRz463qnz4hyx; Tue, 16 Jul 2024 05:12:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721106768; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=jlZWmQMBljwOg5w/hhfQeBuWwNQRxNS11GMOSGvMcX8=; b=H28E00VqkVAbd4p0SbNqruRzxHp3aM+fwuQ24FMnwjTh9/0Mca9USUbL5pGPAHuLdtq/FY oVcIkhEOqh4z0yT46EwjizOEs+rnVAHEf5evymOiTvIK/KKHu8rPaAayvqjpv3E7OTDDQ/ cWEe4kCGgZPsGin3SYv+ZL7B3hJdVAPpoqwdMp4x0uhWlxeMql9FvwakCRohPoB9EJv8Ys pgL6rPw1/wifBdOltYQVzsYCvASg1lbeXHbKWb3Tkez4EJZPMYlHVxwSzBVJIhu6pd+BdP xXbVpisp3AOYZPKDm0+S2MZy+Ftq/Y6kbB4uqZ+a1GpQ09Wi9XioB/mOB2Titw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721106768; a=rsa-sha256; cv=none; b=ZtEgsw1RWbqn+07tzaWTDTAFxR3UatrSrHLJCHBreKp2ilPIzbecDj3C4OGEJqjsjPQS2N 4N6XhhuGq88eEMYrYplAFAqLTOiBqJzyBzkMTd9UwLJEiFg1iDJPSoRSYKE/KR5FiEI/QN nIsiMXVt8deSBkMXj0cL9if3R5tjzIxCrBoW8eOuMTmo6ptcGl3whLtZGcj031Wtz33Zrt tuWZCsbV/yemtNQVbBGghuGw946NN2OenwFe4yYg29cs7CIQOP+y4P+WyC+ikcsOnuHuVr bca+8RM0T2Qont5hplc83KbcFqb+UkF9YmJHWrF+S+Pd07+l9qks4xFMYNollg== 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=1721106768; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=jlZWmQMBljwOg5w/hhfQeBuWwNQRxNS11GMOSGvMcX8=; b=CcH9dGxiUy7Q5SUV1cd5MHTodjQ3X33wkfC8znSZ+9HDe+5svsxvmMUNpgQz2lGFI8drOL vs6Xj98q7KdyssmvbpPKtwethgMApnXly6cupMGXRzy9Ae4pkrenBvU4pYKzF/5Y4yBuN5 moiG60d5m7EZgsHvqSYhzAZEHyALs2BCoMG12izKFIkfDSlkAWaaHnaIZtMyXJqq5w1lBB XsvNhc8Sb8umuy0uzZrUcf6pmnbtxc6cm6EwlPXT92nqr6IJ6saCGrK5bo5GpTdhIsIUFY dvVWqDFMJlYbdF0h6HANzvGV8LdYcR+hFMcSOaA4YT6fZNS1RNX14Z34s0UQRA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNRz45gZ8zNQ2; Tue, 16 Jul 2024 05:12:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46G5Cmx7056554; Tue, 16 Jul 2024 05:12:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46G5CmgB056551; Tue, 16 Jul 2024 05:12:48 GMT (envelope-from git) Date: Tue, 16 Jul 2024 05:12:48 GMT Message-Id: <202407160512.46G5CmgB056551@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kyle Evans Subject: git: d5f8270917bf - main - libc: switch to __weak_symbol for fortified interpose stubs List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kevans X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: d5f8270917bfee4242778544b990bb7f82f8a4de Auto-Submitted: auto-generated The branch main has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=d5f8270917bfee4242778544b990bb7f82f8a4de commit d5f8270917bfee4242778544b990bb7f82f8a4de Author: Kyle Evans AuthorDate: 2024-07-16 05:12:28 +0000 Commit: Kyle Evans CommitDate: 2024-07-16 05:12:28 +0000 libc: switch to __weak_symbol for fortified interpose stubs GCC doesn't like `#pragma weak macro(foo)`, but that's fine; just slap a __weak_symbol on the definition to more reliably make it weak anyways. Reviewed by: kib (earlier version), markj Sponsored by: Klara, Inc. Sponsored by: Stormshield Differential Revision: https://reviews.freebsd.org/D45976 --- lib/libc/sys/poll.c | 3 +-- lib/libc/sys/ppoll.c | 3 +-- lib/libc/sys/readv.c | 3 +-- lib/libc/sys/recvfrom.c | 3 +-- lib/libc/sys/recvmsg.c | 3 +-- 5 files changed, 5 insertions(+), 10 deletions(-) diff --git a/lib/libc/sys/poll.c b/lib/libc/sys/poll.c index 7a418afbbf49..5e000f7e728f 100644 --- a/lib/libc/sys/poll.c +++ b/lib/libc/sys/poll.c @@ -36,8 +36,7 @@ __weak_reference(__sys_poll, __poll); -#pragma weak __ssp_real(poll) -int +int __weak_symbol __ssp_real(poll)(struct pollfd pfd[], nfds_t nfds, int timeout) { return (INTERPOS_SYS(poll, pfd, nfds, timeout)); diff --git a/lib/libc/sys/ppoll.c b/lib/libc/sys/ppoll.c index ef72a902548b..72c0b5d5e421 100644 --- a/lib/libc/sys/ppoll.c +++ b/lib/libc/sys/ppoll.c @@ -36,8 +36,7 @@ __weak_reference(__sys_ppoll, __ppoll); -#pragma weak __ssp_real(ppoll) -int +int __weak_symbol __ssp_real(ppoll)(struct pollfd pfd[], nfds_t nfds, const struct timespec *__restrict timeout, const sigset_t *__restrict newsigmask) diff --git a/lib/libc/sys/readv.c b/lib/libc/sys/readv.c index d58dba1fc47e..2729f6ed99da 100644 --- a/lib/libc/sys/readv.c +++ b/lib/libc/sys/readv.c @@ -38,8 +38,7 @@ __weak_reference(__sys_readv, __readv); -#pragma weak readv -ssize_t +ssize_t __weak_symbol __ssp_real(readv)(int fd, const struct iovec *iov, int iovcnt) { return (INTERPOS_SYS(readv, fd, iov, iovcnt)); diff --git a/lib/libc/sys/recvfrom.c b/lib/libc/sys/recvfrom.c index 6247b315d078..0cdbd8a4ccaa 100644 --- a/lib/libc/sys/recvfrom.c +++ b/lib/libc/sys/recvfrom.c @@ -37,8 +37,7 @@ __weak_reference(__sys_recvfrom, __recvfrom); -#pragma weak recvfrom -ssize_t +ssize_t __weak_symbol __ssp_real(recvfrom)(int s, void *buf, size_t len, int flags, struct sockaddr * __restrict from, socklen_t * __restrict fromlen) { diff --git a/lib/libc/sys/recvmsg.c b/lib/libc/sys/recvmsg.c index 334049d6cfad..ce0f5e0478cd 100644 --- a/lib/libc/sys/recvmsg.c +++ b/lib/libc/sys/recvmsg.c @@ -37,8 +37,7 @@ __weak_reference(__sys_recvmsg, __recvmsg); -#pragma weak recvmsg -ssize_t +ssize_t __weak_symbol __ssp_real(recvmsg)(int s, struct msghdr *msg, int flags) { return (INTERPOS_SYS(recvmsg, s, msg, flags)); From nobody Tue Jul 16 05:12:49 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNRz6269Xz5R152; Tue, 16 Jul 2024 05:12: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNRz56qlMz4j51; Tue, 16 Jul 2024 05:12:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721106770; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=WRKddcn7Me6Lzr/VR9oErbuY3Ce/86DHeXYK6EdNkiA=; b=b6YQB2ky5oidXJm7XEuvoiC2rsQe/6LIH8SO8L9LGr1gn8h3L/bjtWtXH5ctQRIGr4SYRf 0iQapQYgwLeWfIWHQ7KwI43TdxsrSw5nEv9tSU0gTQdhGumQFZbUpLrp/TIncmPfq9KtfQ 5/QDro3ok0IXLEdVZhBDuBKkZLQ4wFVrTtBQ4x9O1PV6VwWojp6eYlmmPpRf8xKDp0HmoT QU+vvmfMIO3R3O7zYTFln7xNJ8h2UH9x9a3BP/DzCA/0exDZac1x1jDXZfrQwhS2dS0OCO gUI+QCWD51JRCQrUkCHL7pLKhOe5pCrLiL2MFatSh3f3NcOXsH+gRCL1oDkxdQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721106770; a=rsa-sha256; cv=none; b=H8L5XZp+gCy/aVK9Kyb8wRMTle7xuiSVWER2H9GON0RPmJg925+1s+ERuyeV/29L+sHkdz 9gjJ9L5NmQ02sJM5FbdkdwcXOureuAztM7DL4O/8r+z0+984Yw6Kl9oBvDoO7FGG/EJPdR kX56YLMhWdmHnZyMK2MM+TmSkeSPzW14CaNrsPw+2cENWOtKW7rgblJVg+vD3fqsMTI4/W 1vbVmCmW94+H51hpDdjjshAO/Oti162g4unm9+1gJWX2vo9usUHhwRQbKsTq451mIqKcdW yzi87EgkzmHj42YLSxF1QNXBO2ryqaehfFNZYYjcP7gHsFAzIt41/uQ2W0yNIg== 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=1721106770; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=WRKddcn7Me6Lzr/VR9oErbuY3Ce/86DHeXYK6EdNkiA=; b=gXyXS2nHDrTo8+bQQ/pfDaNw08KuDViX4Aa5bpDIdP/aRsHLL1dIuL9fIH9JX6yzv3h1pY 8P8j8xCP/NF+EVOtEUGoq8R6AXKIpW3pGTTXjp4Yaf7ex/GjzeQ06taCLkb3B69Ifv+957 TS62xCH1ACDNbP09v22t+F7maSK6kYb6/4MV5//ZAqFyAlQScCMb7T72jvhsHAyZetB1qs oZIaZJOH1MjoBgAxgoijbehAGz4/PxCFxWPEOkTsr/x9dKsx8HvoqpDVdvC2CsqRgU2bG/ Dh4aIiGQPe29HsZFazDHCrK10aLZqTqKyKZk81pbtsuimTHtSxP3oM+A9UFDkQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNRz56L0bzNQ3; Tue, 16 Jul 2024 05:12:49 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46G5CncE056602; Tue, 16 Jul 2024 05:12:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46G5CnB6056599; Tue, 16 Jul 2024 05:12:49 GMT (envelope-from git) Date: Tue, 16 Jul 2024 05:12:49 GMT Message-Id: <202407160512.46G5CnB6056599@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kyle Evans Subject: git: 4928dcc0ebdb - main - sys/select.h: const'ify the fd_set that __fdset_idx() takes List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kevans X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 4928dcc0ebdb7bac56840930e44c38f8f061f09e Auto-Submitted: auto-generated The branch main has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=4928dcc0ebdb7bac56840930e44c38f8f061f09e commit 4928dcc0ebdb7bac56840930e44c38f8f061f09e Author: Kyle Evans AuthorDate: 2024-07-16 05:12:28 +0000 Commit: Kyle Evans CommitDate: 2024-07-16 05:12:28 +0000 sys/select.h: const'ify the fd_set that __fdset_idx() takes Some callers may be operating on a const fd_set and we don't particularly care, so const'ify it. Reviewed by: kib (earlier version), markj Sponsored by: Klara, Inc. Sponsored by: Stormshield Differential Revision: https://reviews.freebsd.org/D45976 --- sys/sys/select.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/sys/select.h b/sys/sys/select.h index 9b734754b944..fefc9961d63a 100644 --- a/sys/sys/select.h +++ b/sys/sys/select.h @@ -86,7 +86,7 @@ typedef struct fd_set { #define __fdset_idx(p, n) __fdset_idx_(p, n) #else __ssp_inline unsigned long -__fdset_idx(fd_set *p, unsigned long idx) +__fdset_idx(const fd_set *p, unsigned long idx) { __size_t psz = __ssp_bos0(p); unsigned long sidx = __fdset_idx_(p, idx); From nobody Tue Jul 16 05:12:50 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNRz72Xtkz5R1C0; Tue, 16 Jul 2024 05:12: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNRz70dK4z4j5D; Tue, 16 Jul 2024 05:12:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721106771; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=OaRToo7BwhFLuKh+1Ro6CO6VKQbSKmZ34TSMuBMRG+E=; b=fPT4avXypfgXyQV0CjBlKPiWvNJoqetwR9sx1ogIQ2lHaOPyd2IV8/Mrf0Prp/vMifoQfI TRnfBPmlfTEtGxiHm1gGJ4UFI65DG+Xf6AtcajalakQGOnuxSdyIvPnSdqa0zE89+lNT1G evqw8m3Z9PXFou/qVIH8289O1OAqZz7S4/X2C3fYklpusHkh2Bb9uFPrTXzHcbtc8yfJ0g OUVhoZ+UNSgiWsN3iQZ3QRD55fitsXCkOqDA21di9PTefnAVFHXSxVYuNFX23k3IPKo3pF 03aVHwzJLB9watpYBeYNCZm7Bds9GuxTSOxiS2Q7iHR3Qf7KIDF9/Gr4yQ5jfw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721106771; a=rsa-sha256; cv=none; b=cKLcTHd3rL0dMmpCHz7o7WGaD8O0Np2s332gkDVvuzw7AeiX4lo7MzKpHeU2/ygCE1/VSd YDhlyrgEQjVV4k3/PBCkZmnti1IifFJZiakyWneugv9LRD+RLaoPVKSyjgQeDMO3mqSkBT euBBoeQ/V6NHQCkY4oza9d081/xmskJEQhowCtecmcPRefGNqe4gAy82+49O+rYJ7a2Tr1 tDpUs0teaQisjf6GkCLW+ffAKd/3k2CtjuJw2Xwzgks9yQ0DStdI15vYLDXJP1ACqunQpy THLI1UQFORnfpmBJ7zTUlKH0TdxCSKl2sihznMVwdkgHiMJZMF6JQRRCGYJCNQ== 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=1721106771; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=OaRToo7BwhFLuKh+1Ro6CO6VKQbSKmZ34TSMuBMRG+E=; b=bIOyv0Q2uEwT1fIxejOHwt2vLBMMgqiOfIugEMS1YOrzxkeCPJNBCvBvVuuFzGVG3Wu/Yd ldZYEWrUFbo9w0HXJyR+V8OclJ4m3H1CAqHUuHZKIphqMxnNZFXNrkUA7TivhnabtqPFno 51KoCJ6wPcZkc3eKVDcDW0fzpYUzWFrybKMxePyB/hrTXCfJ9DDHg1nv4/YfEWeR9WTt4x W+U+oNuopw+gC5uo5ED6KxmO71vNmwuZrmN22wDhUcHGuMvNI8AGQGQA5mPLZFgY9lK8jB 40uEEscIEkInLNk40y3x3PkXdeTZKqGThQPLnRykY0Z3kR/rqWjBH/wSrhzW5w== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNRz70DTPzN4x; Tue, 16 Jul 2024 05:12:51 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46G5CorT056641; Tue, 16 Jul 2024 05:12:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46G5CoBL056638; Tue, 16 Jul 2024 05:12:50 GMT (envelope-from git) Date: Tue, 16 Jul 2024 05:12:50 GMT Message-Id: <202407160512.46G5CoBL056638@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kyle Evans Subject: git: db3a524c8a96 - main - bsnmpd: FreeBSD has strlcpy(3) List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kevans X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: db3a524c8a965d3adcf03fe08b28b37f63e1126b Auto-Submitted: auto-generated The branch main has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=db3a524c8a965d3adcf03fe08b28b37f63e1126b commit db3a524c8a965d3adcf03fe08b28b37f63e1126b Author: Kyle Evans AuthorDate: 2024-07-16 05:12:29 +0000 Commit: Kyle Evans CommitDate: 2024-07-16 05:12:29 +0000 bsnmpd: FreeBSD has strlcpy(3) Fixes the fortified build of bsnmp, which otherwise fails because of the shadowed declaration. Reviewed by: kib (earlier version), markj Sponsored by: Klara, Inc. Sponsored by: Stormshield Differential Revision: https://reviews.freebsd.org/D45976 --- usr.sbin/bsnmpd/Makefile.inc | 1 + 1 file changed, 1 insertion(+) diff --git a/usr.sbin/bsnmpd/Makefile.inc b/usr.sbin/bsnmpd/Makefile.inc index 876d6f891e7f..7f666307467c 100644 --- a/usr.sbin/bsnmpd/Makefile.inc +++ b/usr.sbin/bsnmpd/Makefile.inc @@ -1,2 +1,3 @@ +CFLAGS+= -DHAVE_STRLCPY PACKAGE= bsnmp .include "../Makefile.inc" From nobody Tue Jul 16 07:35:01 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNW8Y22XZz5Ql9w; Tue, 16 Jul 2024 07:36:13 +0000 (UTC) (envelope-from Alexander@Leidinger.net) Received: from mailgate.Leidinger.net (mailgate.leidinger.net [IPv6:2a00:1828:2000:313::1:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature ECDSA (P-256) client-digest SHA256) (Client CN "mailgate.leidinger.net", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNW8X5mF9z4w1v; Tue, 16 Jul 2024 07:36:12 +0000 (UTC) (envelope-from Alexander@Leidinger.net) Authentication-Results: mx1.freebsd.org; none List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=leidinger.net; s=outgoing-alex; t=1721115356; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=1603q+GmBkN3MqMH4LDM9c8JhL+PoDWWcyOC8TCwnn8=; b=ETaW6Iv+9FWSddVBxM20cVK+l2IP+TlPwh0Y+sOMPQeG7m9tJBojEByGoQOqp3SwPvYTe4 KK7azuThdxmAUZs/FH0HCo9QBbwcSJHxm4zkBU2C7h4Q46eXnv1N+m4Rm6SG8v++64OAmQ RyzYmf1dx7+Cb/qrVCK9DOei2IsyWCKpNzLpXqt+wmtCFbEUQgjTZawB6k4IALixItygkH qJWSiIicvAKw6tFkvjMoe8BbA8qCPwsvJWyXpIDL9LTAbltDUGzfr8RH3UNjTI1pPxuamO S7AekynswONIaI4JMJInL6Gh6rt2WlITWzUDc0i0u7PMOgMuhQg1+BsytZT60A== Date: Tue, 16 Jul 2024 09:35:01 +0200 From: Alexander Leidinger To: John Baldwin Cc: Mateusz Guzik , Mateusz Guzik , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Subject: Re: git: 87ee63bac69d - main - locks: add a runtime check for missing turnstile In-Reply-To: <752a3f0a-438e-4465-a8ae-47700e79306d@FreeBSD.org> References: <202407111107.46BB7uSb007077@gitrepo.freebsd.org> <81cfe7ad-cbee-4122-abef-e47ce2b34f05@FreeBSD.org> <752a3f0a-438e-4465-a8ae-47700e79306d@FreeBSD.org> Message-ID: <281b2b20d14c3a90614e6ee8127666dd@Leidinger.net> Organization: No organization, this is a private message. Content-Type: multipart/signed; protocol="application/pgp-signature"; boundary="=_9fc0b88989e8e38f60dd43ff24786617"; micalg=pgp-sha256 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:34240, ipnet:2a00:1828::/32, country:DE] X-Rspamd-Queue-Id: 4WNW8X5mF9z4w1v This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --=_9fc0b88989e8e38f60dd43ff24786617 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=US-ASCII; format=flowed Am 2024-07-15 22:13, schrieb John Baldwin: > bugs might have been useful in the log as well. I think it's fine if > we want > to have some checks that are always on, but it's currently quite rare > so > needs a bit more rationale in the log than other changes is all. Is this a "we want to keep this permanent" change, or is this a "we see bugs, we don't know more, let's add this to have more people stumble upon it with more info until we know what is causing this and then remove it together with a fix" change? I would tend to understand it as the later (which maybe should lead to a commit to comment this part as such). Bye, Alexander. -- http://www.Leidinger.net Alexander@Leidinger.net: PGP 0x8F31830F9F2772BF http://www.FreeBSD.org netchild@FreeBSD.org : PGP 0x8F31830F9F2772BF --=_9fc0b88989e8e38f60dd43ff24786617 Content-Type: application/pgp-signature; name=signature.asc Content-Disposition: attachment; filename=signature.asc; size=833 Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEER9UlYXp1PSd08nWXEg2wmwP42IYFAmaWIrQACgkQEg2wmwP4 2Ia65g/9HiFZJNNmbByeSuE59TVZ6jOL+CwLAepcZd7Lbv1U0p7PwXheYn41cCnb YbMQPiPv0nLdF5N/chs8XQwrIC9gxje80Sf2uJlNM7NTTlCyuDUiAnP+WaqhHOdu NxSsXrgltiZRbS6toVWlP348wFMR5FJ/gtjihlHV23D13mR1RkFdaxGnqn/Ru5cZ m5ICMs6NZm+aN+DokWPSri+sXmqkMKmDTwKhQG6ZOctgXGj9EFpRuaQs/F53DVZR Dhaysotl+78qdz4FK9iKYLZetBJvHHyxOGmOeTPWE5+tkH1QbBzK/lXV4A2mAPL/ 5aZ/Md7W/lNXjqnwrb7jV9tSfDwn5inieoKMj0EzkjNriN33XOOxiRotP25Es+Qx vpKQ2nQshNArRgGSrg4+jZcKZHPgawri3tgLM1DGJW01vuN7H9pt0LMnMhlLgLq1 8BlAVARN49ebV3o8SqXfpSWnIvqjNemz/R9SypMsRFvpmTnBCqo2xNKMWPQl47yI bhY06ulpByTl/cKyxFB/JG4cx3PMeMhv21+SnrtatnBxhUhge5GzncGyMO0nAmrm 6B44A3ExTu/IHm8UgjJONLBujyeg2mGYRoBpUmQHFNtdX/06bbqEyj1a5y0cBaUD k8s74bI/7y9fRnJAIuJjAKiH/E2kqd5+Q4PvcWlsA4O2inDvKvk= =kqCO -----END PGP SIGNATURE----- --=_9fc0b88989e8e38f60dd43ff24786617-- From nobody Tue Jul 16 12:26:52 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNdbx0Qm5z5RDTJ; Tue, 16 Jul 2024 12:26: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNdbx06qyz47D7; Tue, 16 Jul 2024 12:26:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721132813; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=CYgYPgYvyBNe63eZDzLoKza6Md7QoPrLEnHyweV6nBU=; b=ZE/YyJiL9pE+b3Ztar9Jhq9LVxbZ/1v6KGDAudTi13kZwOlr8PrqSezhNhG6FI1JzKsE2j Pbd+iEr2/2AwPbvmJzxXT30qeJMRt+DQPH+kEtGgEqtHUaqRYHYiZH8CmpWYS/1O4bIDWH /5BRaCA6Z1QXgU8/XuXsFbwEWDQxNH2nyMtW7gXa2vfnEcLHSYjAAXMKgK/EE+uuvlU7Jd 3+hSrcgT2+0jcQkSJLp43IoqZtHOzYndC6IcCy36JoAPhkN18OFwD3DxT4fV9JtoP0iz29 YrN7d1pH84QgxJq7I7kVSqqdjqA4LkM1YyM5fu05cWSwCd0p0vpXMsnNfmooaA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721132813; a=rsa-sha256; cv=none; b=kEIQvTMaG1/h0Du7kAkffp2JSD0CyFC3EmcGBOLNScV3PV5OjYkk68Oh+YdE1jdRNtydoW VkWfVkXXAHa5fBo2dM+frccBBRXsN59XWlWfh32qqpDIFq9idpQNLiP4nHFGTqyTWCbTaU QpMnPiuFkDsGZ38PQmxTg/sY3gH0UUJdE7pUU1Kl44WoyIlauX/NQNyE6HoYQCaTKWOFzR o1lIwLZ9qWpnaXMhooq5XSp3sm89llaihESIfjOS2Ehba9DKyKWyy7NQDp+N/y5rxR9ksD mJj5WUXszQn2hhhsJo7z/gwjBvwSzfkP9VAU7ZPuhaiXumrSgfTxMTVgl6CfKQ== 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=1721132813; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=CYgYPgYvyBNe63eZDzLoKza6Md7QoPrLEnHyweV6nBU=; b=bwF3+rE74fZtDC5165EjvER4OE1WpRbe35j5ZeL2tv+LIbwbiYSaG+TO8w6sCPeBeMu7Z7 p9CsCvJZDcGOkJKK7H/zFIBOYLO9RVS6oZ+q1eNakBitxQ7FpD8u57ymo16ZAVFRbY9d3Y 1YBJcw2plxb0Nx03RQ7dEQ+nfh/P6M9iUmWZtjztIdm9hqkkCxYskyWYBf46rw4t22Rtqt RbbpK3wYZ8Yhrg2cotknGEVT4Zl/oKY9l3CIdGYkBvdT1jamazF673AvQX9/lj6ntbV40j 5kPEeY6T/pQ05id3FWvR/R9h1Fn0yP/ZD0nAExJIJiDqd06JbGjmo4DESwEtuw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNdbw6jBMzc2Y; Tue, 16 Jul 2024 12:26:52 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46GCQqFH084133; Tue, 16 Jul 2024 12:26:52 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46GCQq3B084130; Tue, 16 Jul 2024 12:26:52 GMT (envelope-from git) Date: Tue, 16 Jul 2024 12:26:52 GMT Message-Id: <202407161226.46GCQq3B084130@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: f2055611fe56 - main - mergemaster: remove from the tree List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: emaste X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: f2055611fe5624017bd7769c8dc6419c348806ff Auto-Submitted: auto-generated The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=f2055611fe5624017bd7769c8dc6419c348806ff commit f2055611fe5624017bd7769c8dc6419c348806ff Author: Ed Maste AuthorDate: 2023-09-09 13:17:16 +0000 Commit: Ed Maste CommitDate: 2024-07-16 12:25:54 +0000 mergemaster: remove from the tree Mergemaster has been deprecated for many years, replaced by etcupdate(8). Remove it now, in advance of FreeBSD 15.0. PR: 252417 Reviewed by: imp Relnotes: Yes Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D45622 --- ObsoleteFiles.inc | 4 + targets/pseudo/userland/Makefile.depend | 1 - usr.sbin/Makefile | 1 - usr.sbin/mergemaster/Makefile | 5 - usr.sbin/mergemaster/Makefile.depend | 10 - usr.sbin/mergemaster/mergemaster.8 | 485 ---------- usr.sbin/mergemaster/mergemaster.sh | 1568 ------------------------------- 7 files changed, 4 insertions(+), 2070 deletions(-) diff --git a/ObsoleteFiles.inc b/ObsoleteFiles.inc index 19eefda42fe9..f8f0309d6ccf 100644 --- a/ObsoleteFiles.inc +++ b/ObsoleteFiles.inc @@ -51,6 +51,10 @@ # xargs -n1 | sort | uniq -d; # done +# 20240716: retire mergemaster +OLD_FILES+=usr/sbin/mergemaster +OLD_FILES+=usr/share/man/man8/mergemaster.8.gz + # 20240527: csh: Remove hardlink /.cshrc OLD_FILES+=.cshrc diff --git a/targets/pseudo/userland/Makefile.depend b/targets/pseudo/userland/Makefile.depend index 378531b68cc1..6a844630c999 100644 --- a/targets/pseudo/userland/Makefile.depend +++ b/targets/pseudo/userland/Makefile.depend @@ -589,7 +589,6 @@ DIRDEPS+= \ usr.sbin/makemap \ usr.sbin/manctl \ usr.sbin/memcontrol \ - usr.sbin/mergemaster \ usr.sbin/mfiutil \ usr.sbin/mixer \ usr.sbin/mld6query \ diff --git a/usr.sbin/Makefile b/usr.sbin/Makefile index 9d6c90d09461..e039cea6ee16 100644 --- a/usr.sbin/Makefile +++ b/usr.sbin/Makefile @@ -38,7 +38,6 @@ SUBDIR= adduser \ mailwrapper \ makefs \ memcontrol \ - mergemaster \ mfiutil \ mixer \ mlxcontrol \ diff --git a/usr.sbin/mergemaster/Makefile b/usr.sbin/mergemaster/Makefile deleted file mode 100644 index 2edda1b9bc05..000000000000 --- a/usr.sbin/mergemaster/Makefile +++ /dev/null @@ -1,5 +0,0 @@ -SCRIPTS=mergemaster.sh -MAN= mergemaster.8 - -.include - diff --git a/usr.sbin/mergemaster/Makefile.depend b/usr.sbin/mergemaster/Makefile.depend deleted file mode 100644 index 11aba52f82cf..000000000000 --- a/usr.sbin/mergemaster/Makefile.depend +++ /dev/null @@ -1,10 +0,0 @@ -# Autogenerated - do NOT edit! - -DIRDEPS = \ - - -.include - -.if ${DEP_RELDIR} == ${_DEP_RELDIR} -# local dependencies - needed for -jN in clean tree -.endif diff --git a/usr.sbin/mergemaster/mergemaster.8 b/usr.sbin/mergemaster/mergemaster.8 deleted file mode 100644 index 20d746de347c..000000000000 --- a/usr.sbin/mergemaster/mergemaster.8 +++ /dev/null @@ -1,485 +0,0 @@ -.\" Copyright (c) 1998-2011 Douglas Barton -.\" All rights reserved. -.\" -.\" Redistribution and use in source and binary forms, with or without -.\" modification, are permitted provided that the following conditions -.\" are met: -.\" 1. Redistributions of source code must retain the above copyright -.\" notice, this list of conditions and the following disclaimer. -.\" 2. Redistributions in binary form must reproduce the above copyright -.\" notice, this list of conditions and the following disclaimer in the -.\" documentation and/or other materials provided with the distribution. -.\" -.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND -.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE -.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS -.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) -.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF -.\" SUCH DAMAGE. -.\" -.Dd April 16, 2024 -.Dt MERGEMASTER 8 -.Os -.Sh NAME -.Nm mergemaster -.Nd merge configuration files, et al during an upgrade -.Sh SYNOPSIS -.Nm -.Op Fl scrvhpCP -.Op Fl a|iFU -.Op Fl -run-updates=[always|never] -.Op Fl m Ar /path/to/sources -.Op Fl t Ar /path/to/temp/root -.Op Fl d -.Op Fl u Ar N -.Op Fl w Ar N -.Op Fl A Ar Target architecture -.Op Fl D Ar /destdir/path -.Sh DESCRIPTION -.Bf -symbolic -The -.Nm -utility is deprecated and may not be available in -.Fx 15.0 -or later. -Users are advised to use -.Xr etcupdate 8 -instead. -.Ef -.Pp -The -.Nm -utility is a Bourne shell script which is designed to aid you -in updating the various configuration and other files -associated with -.Fx . -It is -.Sy HIGHLY -recommended that you back up your -.Pa /etc -directory before beginning this process. -.Pp -The script uses -.Pa /usr/src/Makefile -to build a temporary root environment from -.Pa / -down, populating that environment with the various -files. -You can specify a different source directory -with the -.Fl m -command line option, or specify the destination -directory with the -.Fl D -option. -It then compares each file in that environment -to its installed counterpart. -When the script finds a -change in the new file, or there is no installed -version of the new file it gives you four options to -deal with it. -You can install the new file as is, -delete the new file, merge the old and new -files (as appropriate) using -.Xr sdiff 1 -or leave the file in the temporary root environment to -merge by hand later. -.Pp -By default it creates the temporary root in -.Pa /var/tmp/temproot -and compares the -Version Control System (VCS) Id strings ($FreeBSD) -for files that have them, deleting -the temporary file if the strings match. -If there is -no Id string, or if the strings are different it -compares the files themselves. -You can -also specify that the script ignore the Id strings and -compare every file with the -.Fl s -option. -Using the -.Fl F -option -.Nm -will install the new file for you if they differ only by -VCS strings. -.Pp -The merge menu option is designed to let you easily combine your -customizations from the old version of a file into the new one. -While you can use the merge function to incorporate changes from -files that you have not customized, -it is not recommended. -.Pp -The -.Nm -utility checks your umask and issues a warning for anything -other than 022. -While it is not mandatory to grant -world read permissions for most configuration files, you -may run into problems without them. -If you choose a -umask other than 022 and experience trouble later this -could be the cause. -.Pa /etc/master.passwd -is treated as a special case. -If you choose to install -this file or a merged version of it the file permissions -are always 600 (rw-------) for security reasons. -After -installing an updated version of this file you should -probably run -.Xr pwd_mkdb 8 -with the -.Fl p -option to rebuild your password databases -and recreate -.Pa /etc/passwd . -.Pp -The script uses the owner and group ids -that the files are created with by -.Pa /usr/src/etc/Makefile , -and file permissions as specified by the umask. -Unified diffs are used by default to display any -differences unless you choose context diffs. -.Pp -The -.Nm -utility will source scripts that you specify right before -it starts the comparison, and after it is done running. -The easiest way to handle this is to place the path -to the script(s) in the appropriate variables in your -.Pa .mergemasterrc -file. -The script sourced before comparison is named in -.Ev MM_PRE_COMPARE_SCRIPT , -and the one sourced after the script is done is -.Ev MM_EXIT_SCRIPT . -This is the recommended way to specify local modifications, -or files that you want to give special handling to. -This includes files that you want to be deleted without -being compared. -Because the named scripts are sourced from within -.Nm , -all of the script's variables are available for use in -your custom script. -You can also use -.Pa /etc/mergemaster.rc -which will be read before -.Pa .mergemasterrc . -Options specified on the command line are updated last, -and therefore can override both files. -.Pp -When the comparison is done if there are any files remaining -in the temproot directory they will be listed, and if the -.Fl a -option is not in use the user will be given the option of -deleting the temproot directory. -If there are no files remaining in the temproot directory -it will be deleted. -.Pp -The options are as follows: -.Bl -tag -width Fl -.It Fl s -Perform a strict comparison, diffing every pair of files. -This comparison is performed line by line, -without regard to VCS Ids. -.It Fl c -Use context diffs instead of unified diffs. -.It Fl r -Re-run -.Nm -on a previously cleaned directory, skipping the creation of -the temporary root environment. -This option is compatible -with all other options. -.It Fl v -Be more verbose about the process. -You should probably use -this option the first time you run -.Nm . -This option also gives you a list of files that exist -only in the installed version of -.Pa /etc . -.It Fl a -Run automatically. -This option will leave all the files that -differ from the installed versions in the temporary directory -to be dealt with by hand. -If the -.Pa temproot -directory exists, it creates a new one in a previously -non-existent directory. -This option unsets the verbose flag, -and is not compatible with -.Fl i , -.Fl F , -or -.Fl U . -Setting -.Fl a -makes -.Fl w -superfluous. -.It Fl h -Display usage and help information. -.It Fl i -Automatically install any files that do not exist in the -destination directory. -.It Fl p -Pre-buildworld mode. -Compares only files known to be essential to the success of -{build|install}world, i.e., -.Pa /etc/group -and -.Pa /etc/master.passwd . -.It Fl F -If the files differ only by VCS Id ($FreeBSD) -install the new file. -.It Fl C -After a standard -.Nm -run, -compares your rc.conf[.local] options to the defaults. -.It Fl P -Preserve files that you replace in -.Pa /var/tmp/mergemaster/preserved-files- , -or another directory you specify in your -.Nm -rc file. -.It Fl U -Attempt to auto upgrade files that have not been user modified. -This option can be dangerous when there are critical changes -in the new versions that affect your running system. -.It Fl -run-updates=[always|never] -Specify always or never to run newaliases, pwd_mkdb, etc. -at the end of the comparison run. -If this option is omitted the default is to prompt the user -for each update as necessary. -.It Fl m Ar /path/to/sources -Specify the path to the directory where you want to do the -.Xr make 1 . -(In other words, where your sources are, but -s was already -taken.) -In older versions of -.Nm -the path to -.Pa src/etc -was required. -.Nm -will convert the path if this older method is used. -.It Fl t Ar /path/to/temp/root -Create the temporary root environment in -.Pa /path/to/temp/root -instead of the default -.Pa /var/tmp/temproot . -.It Fl d -Add the date and time to the name of the temporary -root directory. -If -.Fl t -is specified, this option must -follow it if you want the date added too. -.It Fl u Ar N -Specify a numeric umask. -The default is 022. -.It Fl w Ar N -Supply an alternate screen width to the -.Xr sdiff 1 -command in numbers of columns. -The default is 80. -.It Fl A Ar Target architecture -Specify an alternative -.Ev TARGET_ARCH -architecture name. -.It Fl D Ar /path -Specify the destination directory for the installed files. -.El -.Sh ENVIRONMENT -The -.Nm -utility uses the -.Ev PAGER -environment variable if set. -Otherwise it uses -.Xr less 1 . -If -.Ev PAGER -specifies a program outside -its -limited -.Ev PATH -without specifying the full path, -.Nm -prompts you with options on how to proceed. -The -.Ev MM_PRE_COMPARE_SCRIPT -and -.Ev MM_EXIT_SCRIPT -variables are used as described above. -Other variables that are used by the script internally -can be specified in -.Pa .mergemasterrc -as described in more detail below. -.Sh FILES -.Bl -tag -width $HOME/.mergemasterrc -compact -.It Pa /etc/mergemaster.rc -.It Pa $HOME/.mergemasterrc -.El -.Pp -The -.Nm -utility will -.Ic .\& -(source) these files if they exist. -Command line options -will override rc file options. -.Pa $HOME/.mergemasterrc -overrides -.Pa /etc/mergemaster.rc . -Here is an example -with all values commented out: -.Bd -literal -# These are options for mergemaster, with their default values listed -# The following options have command line overrides -# -# The target architecture (-A, unset by default) -#ARCHSTRING='TARGET_ARCH=' -# -# Sourcedir is the directory to do the 'make' in (-m) -#SOURCEDIR='/usr/src' -# -# Directory to install the temporary root environment into (-t) -#TEMPROOT='/var/tmp/temproot' -# -# Specify the destination directory for the installed files (-D) -#DESTDIR= -# -# Strict comparison skips the VCS Id test and compares every file (-s) -#STRICT=no -# -# Type of diff, such as unified, context, etc. (-c) -#DIFF_FLAG='-u' -# -# Install the new file if it differs only by VCS Id ($FreeBSD, -F) -#FREEBSD_ID= -# -# Verbose mode includes more details and additional checks (-v) -#VERBOSE= -# -# Automatically install files that do not exist on the system already (-i) -#AUTO_INSTALL= -# -# Automatically upgrade files that have not been user modified (-U) -# ***DANGEROUS*** -#AUTO_UPGRADE= -# -# Either always or never run newaliases, pwd_mkdb at the end (--run-updates) -#RUN_UPDATES= -# -# Compare /etc/rc.conf[.local] to /etc/defaults/rc.conf (-C) -#COMP_CONFS= -# -# Preserve files that you replace (-P) -#PRESERVE_FILES= -#PRESERVE_FILES_DIR=/var/tmp/mergemaster/preserved-files-`date +%y%m%d-%H%M%S` -# -# The umask for mergemaster to compare the default file's modes to (-u) -#NEW_UMASK=022 -# -# The following options have no command line overrides -# -# Files to always avoid comparing -#IGNORE_FILES='/etc/motd /etc/printcap foo bar' -# -# Additional options for diff. This will get unset when using -s. -#DIFF_OPTIONS='-Bb' # Ignore changes in whitespace -# -# Location to store the list of mtree values for AUTO_UPGRADE purposes -#MTREEDB='/var/db' -# -# For those who just cannot stand including the full path to PAGER -#DONT_CHECK_PAGER= -# -# If you set 'yes' above, make sure to include the PATH to your pager -#PATH=/bin:/usr/bin:/usr/sbin -# -# Delete stale files in /etc/rc.d without prompting -#DELETE_STALE_RC_FILES= -# -# Specify the path to scripts to run before the comparison starts, -# and/or after the script has finished its work -#MM_PRE_COMPARE_SCRIPT= -#MM_EXIT_SCRIPT= -.Ed -.Sh EXIT STATUS -Exit status is 0 on successful completion, or if the user bails out -manually at some point during execution. -.Pp -Exit status is 1 if it fails for one of the following reasons: -.Pp -Invalid command line option -.Pp -Failure to create the temporary root environment -.Pp -Failure to populate the temporary root -.Pp -Presence of the 'nodev' option in -.Pa /etc/fstab -.Pp -Failure to install a file -.Sh EXAMPLES -Typically all you will need to do is type -.Nm -at the prompt and the script will do all the work for you. -.Pp -To use context diffs and have -.Nm -explain more things as it goes along, use: -.Pp -.Dl # mergemaster -cv -.Pp -To specify that -.Nm -put the temporary root environment in -.Pa /usr/tmp/root , -use: -.Pp -.Dl # mergemaster -t /usr/tmp/root -.Pp -To specify a 110 column screen with a strict -comparison, use: -.Pp -.Dl # mergemaster -sw 110 -.Sh SEE ALSO -.Xr diff 1 , -.Xr make 1 , -.Xr less 1 , -.Xr sdiff 1 , -.Xr etcupdate 8 , -.Xr pwd_mkdb 8 -.Pp -.Pa /usr/src/etc/Makefile -.Rs -.%U https://docs.freebsd.org/en/books/handbook/cutting-edge/#makeworld -.%T The FreeBSD Handbook -.Re -.Sh HISTORY -The -.Nm -utility was first publicly available on one of my -web pages in a much simpler form under the name -.Pa comproot -on 13 March 1998. -The idea for creating the -temporary root environment comes from Nik Clayton's -make world tutorial which is referenced above. -.Sh AUTHORS -This manual page and the script itself were written by -.An Douglas Barton Aq Mt dougb@FreeBSD.org . diff --git a/usr.sbin/mergemaster/mergemaster.sh b/usr.sbin/mergemaster/mergemaster.sh deleted file mode 100755 index 572415164101..000000000000 --- a/usr.sbin/mergemaster/mergemaster.sh +++ /dev/null @@ -1,1568 +0,0 @@ -#!/bin/sh - -# mergemaster - -# Compare files created by /usr/src/etc/Makefile (or the directory -# the user specifies) with the currently installed copies. - -# Copyright (c) 1998-2012 Douglas Barton, All rights reserved -# Please see detailed copyright below - -PATH=/bin:/usr/bin:/usr/sbin - -display_usage () { - VERSION_NUMBER=`grep "[$]FreeBSD:" $0 | cut -d ' ' -f 4` - echo "mergemaster version ${VERSION_NUMBER}" - echo 'Usage: mergemaster [-scrvhpCP] [-a|[-iFU]] [--run-updates=always|never]' - echo ' [-m /path] [-t /path] [-d] [-u N] [-w N] [-A arch] [-D /path]' - echo "Options:" - echo " -s Strict comparison (diff every pair of files)" - echo " -c Use context diff instead of unified diff" - echo " -r Re-run on a previously cleaned directory (skip temproot creation)" - echo " -v Be more verbose about the process, include additional checks" - echo " -a Leave all files that differ to merge by hand" - echo " -h Display more complete help" - echo ' -i Automatically install files that do not exist in destination directory' - echo ' -p Pre-buildworld mode, only compares crucial files' - echo ' -F Install files that differ only by revision control Id ($FreeBSD)' - echo ' -C Compare local rc.conf variables to the defaults' - echo ' -P Preserve files that are overwritten' - echo " -U Attempt to auto upgrade files that have not been user modified" - echo ' ***DANGEROUS***' - echo ' --run-updates= Specify always or never to run newalises, pwd_mkdb, etc.' - echo '' - echo " -m /path/directory Specify location of source to do the make in" - echo " -t /path/directory Specify temp root directory" - echo " -d Add date and time to directory name (e.g., /var/tmp/temproot.`date +%m%d.%H.%M`)" - echo " -u N Specify a numeric umask" - echo " -w N Specify a screen width in columns to sdiff" - echo " -A architecture Alternative architecture name to pass to make" - echo ' -D /path/directory Specify the destination directory to install files to' - echo '' -} - -display_help () { - echo "* To specify a directory other than /var/tmp/temproot for the" - echo " temporary root environment, use -t /path/to/temp/root" - echo "* The -w option takes a number as an argument for the column width" - echo " of the screen. The default is 80." - echo '* The -a option causes mergemaster to run without prompting.' -} - -# Loop allowing the user to use sdiff to merge files and display the merged -# file. -merge_loop () { - case "${VERBOSE}" in - '') ;; - *) - echo " *** Type h at the sdiff prompt (%) to get usage help" - ;; - esac - echo '' - MERGE_AGAIN=yes - while [ "${MERGE_AGAIN}" = "yes" ]; do - # Prime file.merged so we don't blat the owner/group id's - cp -p "${COMPFILE}" "${COMPFILE}.merged" - sdiff -o "${COMPFILE}.merged" --text --suppress-common-lines \ - --width=${SCREEN_WIDTH:-80} "${DESTDIR}${COMPFILE#.}" "${COMPFILE}" - INSTALL_MERGED=V - while [ "${INSTALL_MERGED}" = "v" -o "${INSTALL_MERGED}" = "V" ]; do - echo '' - echo " Use 'i' to install merged file" - echo " Use 'r' to re-do the merge" - echo " Use 'v' to view the merged file" - echo " Default is to leave the temporary file to deal with by hand" - echo '' - echo -n " *** How should I deal with the merged file? [Leave it for later] " - read INSTALL_MERGED - - case "${INSTALL_MERGED}" in - [iI]) - mv "${COMPFILE}.merged" "${COMPFILE}" - echo '' - if mm_install "${COMPFILE}"; then - echo " *** Merged version of ${COMPFILE} installed successfully" - else - echo " *** Problem installing ${COMPFILE}, it will remain to merge by hand later" - fi - unset MERGE_AGAIN - ;; - [rR]) - rm "${COMPFILE}.merged" - ;; - [vV]) - ${PAGER} "${COMPFILE}.merged" - ;; - '') - echo " *** ${COMPFILE} will remain for your consideration" - unset MERGE_AGAIN - ;; - *) - echo "invalid choice: ${INSTALL_MERGED}" - INSTALL_MERGED=V - ;; - esac - done - done -} - -# Loop showing user differences between files, allow merge, skip or install -# options -diff_loop () { - - HANDLE_COMPFILE=v - - while [ "${HANDLE_COMPFILE}" = "v" -o "${HANDLE_COMPFILE}" = "V" -o \ - "${HANDLE_COMPFILE}" = "NOT V" ]; do - if [ -f "${DESTDIR}${COMPFILE#.}" -a -f "${COMPFILE}" ]; then - if [ -n "${AUTO_UPGRADE}" -a -n "${CHANGED}" ]; then - case "${CHANGED}" in - *:${DESTDIR}${COMPFILE#.}:*) ;; # File has been modified - *) - echo '' - echo " *** ${COMPFILE} has not been user modified." - echo '' - - if mm_install "${COMPFILE}"; then - echo " *** ${COMPFILE} upgraded successfully" - echo '' - # Make the list print one file per line - AUTO_UPGRADED_FILES="${AUTO_UPGRADED_FILES} ${DESTDIR}${COMPFILE#.} -" - else - echo " *** Problem upgrading ${COMPFILE}, it will remain to merge by hand" - fi - return - ;; - esac - fi - if [ "${HANDLE_COMPFILE}" = "v" -o "${HANDLE_COMPFILE}" = "V" ]; then - echo '' - echo ' ====================================================================== ' - echo '' - ( - echo " *** Displaying differences between installed version and ${COMPFILE}:" - echo '' - diff ${DIFF_FLAG} ${DIFF_OPTIONS} "${DESTDIR}${COMPFILE#.}" "${COMPFILE}" - ) | ${PAGER} - echo '' - fi - else - echo '' - echo " *** There is no installed version of ${COMPFILE}" - echo '' - case "${AUTO_INSTALL}" in - [Yy][Ee][Ss]) - echo '' - if mm_install "${COMPFILE}"; then - echo " *** ${COMPFILE} installed successfully" - echo '' - # Make the list print one file per line - AUTO_INSTALLED_FILES="${AUTO_INSTALLED_FILES} ${DESTDIR}${COMPFILE#.} -" - else - echo " *** Problem installing ${COMPFILE}, it will remain to merge by hand" - fi - return - ;; - *) - NO_INSTALLED=yes - ;; - esac - fi - - echo " Use 'd' to delete the temporary ${COMPFILE}" - echo " Use 'i' to install the temporary ${COMPFILE}" - case "${NO_INSTALLED}" in - '') - echo " Use 'm' to merge the temporary and installed versions" - echo " Use 'v' to view the diff results again" - ;; - esac - echo '' - echo " Default is to leave the temporary file to deal with by hand" - echo '' - echo -n "How should I deal with this? [Leave it for later] " - read HANDLE_COMPFILE - - case "${HANDLE_COMPFILE}" in - [dD]) - rm "${COMPFILE}" - echo '' - echo " *** Deleting ${COMPFILE}" - ;; - [iI]) - echo '' - if mm_install "${COMPFILE}"; then - echo " *** ${COMPFILE} installed successfully" - else - echo " *** Problem installing ${COMPFILE}, it will remain to merge by hand" - fi - ;; - [mM]) - case "${NO_INSTALLED}" in - '') - # interact with user to merge files - merge_loop - ;; - *) - echo '' - echo " *** There is no installed version of ${COMPFILE}" - echo '' - HANDLE_COMPFILE="NOT V" - ;; - esac # End of "No installed version of file but user selected merge" test - ;; - [vV]) - continue - ;; - '') - echo '' - echo " *** ${COMPFILE} will remain for your consideration" - ;; - *) - # invalid choice, show menu again. - echo "invalid choice: ${HANDLE_COMPFILE}" - echo '' - HANDLE_COMPFILE="NOT V" - continue - ;; - esac # End of "How to handle files that are different" - done - unset NO_INSTALLED - echo '' - case "${VERBOSE}" in - '') ;; - *) - sleep 3 - ;; - esac -} - -press_to_continue () { - local DISCARD - echo -n ' *** Press the [Enter] or [Return] key to continue ' - read DISCARD -} - -# Set the default path for the temporary root environment -# -TEMPROOT='/var/tmp/temproot' - -# Read /etc/mergemaster.rc first so the one in $HOME can override -# -if [ -r /etc/mergemaster.rc ]; then - . /etc/mergemaster.rc -fi - -# Read .mergemasterrc before command line so CLI can override -# -if [ -r "$HOME/.mergemasterrc" ]; then - . "$HOME/.mergemasterrc" -fi - -for var in "$@" ; do - case "$var" in - --run-updates*) - RUN_UPDATES=`echo ${var#--run-updates=} | tr [:upper:] [:lower:]` - ;; - *) - newopts="$newopts $var" - ;; - esac -done - -set -- $newopts -unset var newopts - -# Check the command line options -# -while getopts ":ascrvhipCPm:t:du:w:D:A:FU" COMMAND_LINE_ARGUMENT ; do - case "${COMMAND_LINE_ARGUMENT}" in - A) - ARCHSTRING='TARGET_ARCH='${OPTARG} - ;; - F) - FREEBSD_ID=yes - ;; - U) - AUTO_UPGRADE=yes - ;; - s) - STRICT=yes - unset DIFF_OPTIONS - ;; - c) - DIFF_FLAG='-c' - ;; - r) - RERUN=yes - ;; - v) - case "${AUTO_RUN}" in - '') VERBOSE=yes ;; - esac - ;; - a) - AUTO_RUN=yes - unset VERBOSE - ;; - h) - display_usage - display_help - exit 0 - ;; - i) - AUTO_INSTALL=yes - ;; - C) - COMP_CONFS=yes - ;; - P) - PRESERVE_FILES=yes - ;; - p) - PRE_WORLD=yes - unset COMP_CONFS - unset AUTO_RUN - ;; - m) - SOURCEDIR=${OPTARG} - ;; - t) - TEMPROOT=${OPTARG} - ;; - d) - TEMPROOT=${TEMPROOT}.`date +%m%d.%H.%M` - ;; - u) - NEW_UMASK=${OPTARG} - ;; - w) - SCREEN_WIDTH=${OPTARG} - ;; - D) - DESTDIR=${OPTARG} - ;; - *) - display_usage - exit 1 - ;; - esac -done - -if [ -n "$AUTO_RUN" ]; then - if [ -n "$FREEBSD_ID" -o -n "$AUTO_UPGRADE" -o -n "$AUTO_INSTALL" ]; then - echo '' - echo "*** You have included the -a option along with one or more options" - echo ' that indicate that you wish mergemaster to actually make updates' - echo ' (-F, -U, or -i), however these options are not compatible.' - echo ' Please read mergemaster(8) for more information.' - echo '' - exit 1 - fi -fi - -# Assign the location of the mtree database -# -MTREEDB=${MTREEDB:-${DESTDIR}/var/db} -MTREEFILE="${MTREEDB}/mergemaster.mtree" - -# Don't force the user to set this in the mergemaster rc file -if [ -n "${PRESERVE_FILES}" -a -z "${PRESERVE_FILES_DIR}" ]; then - PRESERVE_FILES_DIR=/var/tmp/mergemaster/preserved-files-`date +%y%m%d-%H%M%S` - mkdir -p ${PRESERVE_FILES_DIR} -fi - -# Check for the mtree database in DESTDIR -case "${AUTO_UPGRADE}" in -'') ;; # If the option is not set no need to run the test or warn the user -*) - if [ ! -s "${MTREEFILE}" ]; then - echo '' - echo "*** Unable to find mtree database (${MTREEFILE})." - echo " Skipping auto-upgrade on this run." - echo " It will be created for the next run when this one is complete." - echo '' - case "${AUTO_RUN}" in - '') - press_to_continue - ;; - esac - unset AUTO_UPGRADE - fi *** 1175 LINES SKIPPED *** From nobody Tue Jul 16 15:54:46 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNkCp6NLMz5RWYW; Tue, 16 Jul 2024 15:54: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNkCp5tFlz4Ycl; Tue, 16 Jul 2024 15:54:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721145286; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Mmsw2ykDJ54HnPEDr3cbvYBtv5RlCs6bumVjzjYvtaM=; b=WTWEWOTZ1uYxwOLWGOSafvz0XV6P/525FT8h4/9QHOInHu3Tk+Y1G4VC8jPzPrfx4EIG3q M4N9XxSP5HE9xsnL4RR62Ywb7Pvmn5FGdWnQa8cWg7z5x0SphiQnmEPxZHQZ9KPcXaRvxT dm52+I53MGuJ0JtSFcGaMidaP0OUCl0nDBM+RRovcGRCmtWjPCuupJ54+RUD628/Nclect mEykDwGi0KU698FJ4Lb1XbZVliehbbyszZ91JOftUMglLAnfnBmP3RMZZFX7Qdc+vWmy0C bY8jDQP819e6QVBiQ4NJlnc6koXRsnHWieIG5xPFhKWuDXKafmUd5j91xcM0Pg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721145286; a=rsa-sha256; cv=none; b=wWl+ia8i/np4oHrRLVE8VnLlPHuBj48DvDfUTie39NZQJjdbubvjUbe1EAZ905+OMugZ9k I04PU/GKfevcvrkYsWIhs+kNnnBPGH1KAb31Ea6yBZa68AmILCsfLTvwOUFbCk63vYXuAZ kKRkZo+aMf+wahdfaN84ZA9dMg22BCK0IldAnJythPrU5wiAsafV7Vs4tCG11dkhDhLV6U 5LSfIMkrzuixqV0R6f1ZL7yXofz4TgFEoRsz6KL6VfR2d/JAHLjFYv1yWHLNiSST4QnX97 ntQ4iXpK7EZX0GA79jOn6N/fbAGB5NjReSwsmBVBW24MJx8qpj0iFzYOTSbxHQ== 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=1721145286; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Mmsw2ykDJ54HnPEDr3cbvYBtv5RlCs6bumVjzjYvtaM=; b=sTou3A5x1Za7TnQSiN8iJlEWdJvHXAc9iCGRdi5KliIknHN29ok+hD99PTrLjaEWSfe+aI G+RGylddagF/RgqERMd5sivnrOTvCKD+4nU3JDRWOp9mTvyxb2/cKgRNcNfmzwtxsa4qcH F0dc7fcOyTMZ6xdhhnYu73EIDx06bNxj66iGF4QBJXGfO0PyDKeG3o9SzhR4qvuuH4lJ1T J9dj1hDyu5c1Ma+SRiXmxW/Cxp8S4qKEkwT0DK2cAhE2AY1YBxEUodYzvFaeLHqqmR7Ejw 5v7XjrvCG25kJuQfBPhjtHBCqEe7x3G/8AnVs+buJVvmP94ZoXHO+qKPXV0vKA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNkCp5LyjzjXD; Tue, 16 Jul 2024 15:54:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46GFskK0040875; Tue, 16 Jul 2024 15:54:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46GFskrM040872; Tue, 16 Jul 2024 15:54:46 GMT (envelope-from git) Date: Tue, 16 Jul 2024 15:54:46 GMT Message-Id: <202407161554.46GFskrM040872@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: a948a61a822f - stable/13 - if_vxlan(4): Move the allocating of statistics counters below if_alloc() List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: zlei X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: a948a61a822f82a99ac58a412621e5546eac6be3 Auto-Submitted: auto-generated The branch stable/13 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=a948a61a822f82a99ac58a412621e5546eac6be3 commit a948a61a822f82a99ac58a412621e5546eac6be3 Author: Zhenlei Huang AuthorDate: 2024-07-16 15:53:18 +0000 Commit: Zhenlei Huang CommitDate: 2024-07-16 15:53:18 +0000 if_vxlan(4): Move the allocating of statistics counters below if_alloc() The MFS of the fix [1] is done but the prerequisite [2] has not been MFCed to stable/13 branch yet. This results in another potential leak condition in stable/13 branch. Well `if_alloc(IFT_ETHER)` shall not fail, but just in case. This is a direct commit to stable/13. 1. e729e750806d if_vxlan(4): Plug a memory leak 2. 4787572d0580 ifnet: make if_alloc_domain() never fail Reviewed by: kp Fixes: 12bd1341d2aa if_vxlan(4): Plug a memory leak Differential Revision: https://reviews.freebsd.org/D45972 --- sys/net/if_vxlan.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/net/if_vxlan.c b/sys/net/if_vxlan.c index 2cc9f60cba87..3c074952864c 100644 --- a/sys/net/if_vxlan.c +++ b/sys/net/if_vxlan.c @@ -3216,13 +3216,13 @@ vxlan_clone_create(struct if_clone *ifc, int unit, caddr_t params) goto fail; } - vxlan_stats_alloc(sc); ifp = if_alloc(IFT_ETHER); if (ifp == NULL) { error = ENOSPC; goto fail; } + vxlan_stats_alloc(sc); sc->vxl_ifp = ifp; rm_init(&sc->vxl_lock, "vxlanrm"); callout_init_rw(&sc->vxl_callout, &sc->vxl_lock, 0); From nobody Tue Jul 16 18:06:21 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNn7f1pDfz5Rj4w; Tue, 16 Jul 2024 18:06: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNn7f1QPBz4nfK; Tue, 16 Jul 2024 18:06:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721153182; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=wirJcECwkg3PlZt3UqjILAPp54gWj3y25SuEnveuVv0=; b=xszPRLpiN45iq15rmDdMoA0k6jQ7EqebhPimkf/bJxcKJXAq4+5Jv8IVrQG402y0uysnDe BEUPLXFiRV3dBfHDJFGTwiT8zWqYgNz8Hyqk5TtGVENPdy1vG8kXyZowAxXVOTgMrpqf0I YcwCkEBy13ECDFopWWZGdYW6elt24GRU35ERQzuJTnxHypr9VY+1zTARqgUmdq3wvC/FzT G969dQmCxOzH52+pjidUy7Cf1aVvMK0zztmiZCEq0aoKzjv+mq6PeYV+OymdNBkEtywB8j hexUeTQ7MMDbFTM/gecKSuySjLt5adF5Xb56KH25MsX24A74Pl2i/SHJbz3Z2Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721153182; a=rsa-sha256; cv=none; b=jmSViLReeB2XdAg3x2pbWd/8BsTIjVHQC8dt7xMHzhUhQOPpHrmfyf+Ed5vmm1pO2qwuqv yF/rRpFSPnn8jFqr+/D4jX5a6go/mvhZuibwRbBCSnDGVo0O4aR1qNzVS+qgdnCtgeucyi rjfK51DoTbaxxfldcqitKySyBQDvrCaA12R6hsXM3Qk6ogLJIqDCr5lVwWJcX2/ieW5Zdg 1jDLclLi9oyqH2nPIHNhPt3uq+AnwO1luG5MMC2Q7lGcTCkUnw4Cas1S+NpmEC3JdnKigX /CGhlXpp2L1bl50ANDMsQyiHajgzBdZP4k0uXW/WgRmBu+k0gElbumTfyuqgyg== 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=1721153182; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=wirJcECwkg3PlZt3UqjILAPp54gWj3y25SuEnveuVv0=; b=IMGbuR/2qHZMUCKuXSzIR8wWioP1/CwFpW6f10h9s/xPnim4Z1xzWgSlr32UzzIC/iB2xS akRdv0yRHr6D48DLAi12aaimKlHtSWAqIGvHYVmnuD16wFXpBtwytt9UpnHgmU8JrlwBGD qLltFGTd9M+rAjxGrz0joDVCyMGOmGp2G2i7Q5jwJhxDWcwWPJSM9c1FzTvt41PdWxcEnJ vjs9ns9Ka9nCl6jdJK/R2kqDzDQbrrt5N7VvRXVY3T8VaNk+h7YEKRRWUWhG8W87vkqvCo gqJ5iUOyDc6uX1qLKqOWOtrf2wX8aV2MAPMt4PRxuXhV7GsmUC/m6VttsXAzjQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNn7f0v1szmlC; Tue, 16 Jul 2024 18:06:22 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46GI6Msb061491; Tue, 16 Jul 2024 18:06:22 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46GI6Lxx061485; Tue, 16 Jul 2024 18:06:21 GMT (envelope-from git) Date: Tue, 16 Jul 2024 18:06:21 GMT Message-Id: <202407161806.46GI6Lxx061485@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Stefan =?utf-8?Q?E=C3=9Fer?= Subject: git: f91626be616b - stable/14 - contrib/bc: upgrade to version 6.7.6 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: se X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: f91626be616bf35f7437913d3e11b488d6607d1e Auto-Submitted: auto-generated The branch stable/14 has been updated by se: URL: https://cgit.FreeBSD.org/src/commit/?id=f91626be616bf35f7437913d3e11b488d6607d1e commit f91626be616bf35f7437913d3e11b488d6607d1e Author: Stefan EƟer AuthorDate: 2024-07-09 05:49:27 +0000 Commit: Stefan EƟer CommitDate: 2024-07-16 18:05:14 +0000 contrib/bc: upgrade to version 6.7.6 This update fixes a potential issue when flushing stdout on exit fails: longjmp could use an uninitialized target address variable. Most files are included in this commit due to a changed date in the copyright note. (cherry picked from commit a970610a3af63b3f4df5b69d91c6b4093a00ed8f) --- contrib/bc/LICENSE.md | 4 +- contrib/bc/MEMORY_BUGS.md | 7 + contrib/bc/Makefile.in | 2 +- contrib/bc/NEWS.md | 7 + contrib/bc/NOTICE.md | 2 +- contrib/bc/README.md | 6 +- contrib/bc/compile_flags.txt | 15 + contrib/bc/configure.sh | 20 +- contrib/bc/gen/bc_help.txt | 2 +- contrib/bc/gen/dc_help.txt | 2 +- contrib/bc/gen/lib.bc | 2 +- contrib/bc/gen/lib2.bc | 2 +- contrib/bc/gen/strgen.c | 4 +- contrib/bc/gen/strgen.sh | 4 +- contrib/bc/include/args.h | 2 +- contrib/bc/include/bc.h | 21 +- contrib/bc/include/bcl.h | 2 +- contrib/bc/include/dc.h | 5 +- contrib/bc/include/file.h | 26 +- contrib/bc/include/history.h | 2 +- contrib/bc/include/lang.h | 2 +- contrib/bc/include/lex.h | 2 +- contrib/bc/include/library.h | 2 +- contrib/bc/include/num.h | 2 +- contrib/bc/include/opt.h | 2 +- contrib/bc/include/parse.h | 2 +- contrib/bc/include/program.h | 2 +- contrib/bc/include/rand.h | 7 +- contrib/bc/include/read.h | 2 +- contrib/bc/include/status.h | 6 +- contrib/bc/include/vector.h | 2 +- contrib/bc/include/version.h | 4 +- contrib/bc/include/vm.h | 12 +- contrib/bc/locales/de_DE.ISO8859-1.msg | 2 +- contrib/bc/locales/de_DE.UTF-8.msg | 2 +- contrib/bc/locales/en_US.msg | 2 +- contrib/bc/locales/es_ES.ISO8859-1.msg | 2 +- contrib/bc/locales/es_ES.UTF-8.msg | 2 +- contrib/bc/locales/fr_FR.ISO8859-1.msg | 2 +- contrib/bc/locales/fr_FR.UTF-8.msg | 2 +- contrib/bc/locales/ja_JP.UTF-8.msg | 2 +- contrib/bc/locales/ja_JP.eucJP.msg | 2 +- contrib/bc/locales/nl_NL.ISO8859-1.msg | 2 +- contrib/bc/locales/nl_NL.UTF-8.msg | 2 +- contrib/bc/locales/pl_PL.ISO8859-2.msg | 2 +- contrib/bc/locales/pl_PL.UTF-8.msg | 2 +- contrib/bc/locales/pt_PT.ISO8859-1.msg | 2 +- contrib/bc/locales/pt_PT.UTF-8.msg | 2 +- contrib/bc/locales/ru_RU.CP1251.msg | 2 +- contrib/bc/locales/ru_RU.CP866.msg | 2 +- contrib/bc/locales/ru_RU.ISO8859-5.msg | 2 +- contrib/bc/locales/ru_RU.KOI8-R.msg | 2 +- contrib/bc/locales/ru_RU.UTF-8.msg | 2 +- contrib/bc/locales/zh_CN.GB18030.msg | 2 +- contrib/bc/locales/zh_CN.GB2312.msg | 2 +- contrib/bc/locales/zh_CN.GBK.msg | 2 +- contrib/bc/locales/zh_CN.UTF-8.msg | 2 +- contrib/bc/locales/zh_CN.eucCN.msg | 2 +- contrib/bc/manuals/bc/A.1 | 681 +++++++++++++++++---------------- contrib/bc/manuals/bc/A.1.md | 5 +- contrib/bc/manuals/bc/E.1 | 482 +++++++++++------------ contrib/bc/manuals/bc/E.1.md | 5 +- contrib/bc/manuals/bc/EH.1 | 474 ++++++++++++----------- contrib/bc/manuals/bc/EH.1.md | 5 +- contrib/bc/manuals/bc/EHN.1 | 474 ++++++++++++----------- contrib/bc/manuals/bc/EHN.1.md | 5 +- contrib/bc/manuals/bc/EN.1 | 482 +++++++++++------------ contrib/bc/manuals/bc/EN.1.md | 5 +- contrib/bc/manuals/bc/H.1 | 673 ++++++++++++++++---------------- contrib/bc/manuals/bc/H.1.md | 5 +- contrib/bc/manuals/bc/HN.1 | 673 ++++++++++++++++---------------- contrib/bc/manuals/bc/HN.1.md | 5 +- contrib/bc/manuals/bc/N.1 | 681 +++++++++++++++++---------------- contrib/bc/manuals/bc/N.1.md | 5 +- contrib/bc/manuals/bcl.3 | 95 ++--- contrib/bc/manuals/bcl.3.md | 2 +- contrib/bc/manuals/dc/A.1 | 478 +++++++++++------------ contrib/bc/manuals/dc/A.1.md | 2 +- contrib/bc/manuals/dc/E.1 | 376 +++++++++--------- contrib/bc/manuals/dc/E.1.md | 2 +- contrib/bc/manuals/dc/EH.1 | 368 +++++++++--------- contrib/bc/manuals/dc/EH.1.md | 2 +- contrib/bc/manuals/dc/EHN.1 | 368 +++++++++--------- contrib/bc/manuals/dc/EHN.1.md | 2 +- contrib/bc/manuals/dc/EN.1 | 376 +++++++++--------- contrib/bc/manuals/dc/EN.1.md | 2 +- contrib/bc/manuals/dc/H.1 | 470 ++++++++++++----------- contrib/bc/manuals/dc/H.1.md | 2 +- contrib/bc/manuals/dc/HN.1 | 470 ++++++++++++----------- contrib/bc/manuals/dc/HN.1.md | 2 +- contrib/bc/manuals/dc/N.1 | 478 +++++++++++------------ contrib/bc/manuals/dc/N.1.md | 2 +- contrib/bc/scripts/exec-install.sh | 2 +- contrib/bc/scripts/format.sh | 2 +- contrib/bc/scripts/functions.sh | 2 +- contrib/bc/scripts/karatsuba.py | 2 +- contrib/bc/scripts/link.sh | 2 +- contrib/bc/scripts/lint.sh | 2 +- contrib/bc/scripts/locale_install.sh | 2 +- contrib/bc/scripts/locale_uninstall.sh | 2 +- contrib/bc/scripts/sqrt_frac_guess.bc | 2 +- contrib/bc/scripts/sqrt_int_guess.bc | 2 +- contrib/bc/scripts/sqrt_random.bc | 2 +- contrib/bc/scripts/sqrt_random.sh | 2 +- contrib/bc/src/args.c | 2 +- contrib/bc/src/bc.c | 6 +- contrib/bc/src/bc_lex.c | 2 +- contrib/bc/src/bc_parse.c | 2 +- contrib/bc/src/data.c | 4 +- contrib/bc/src/dc.c | 6 +- contrib/bc/src/dc_lex.c | 2 +- contrib/bc/src/dc_parse.c | 2 +- contrib/bc/src/file.c | 34 +- contrib/bc/src/history.c | 2 +- contrib/bc/src/lang.c | 2 +- contrib/bc/src/lex.c | 2 +- contrib/bc/src/library.c | 2 +- contrib/bc/src/main.c | 16 +- contrib/bc/src/num.c | 76 +++- contrib/bc/src/opt.c | 2 +- contrib/bc/src/parse.c | 2 +- contrib/bc/src/program.c | 2 +- contrib/bc/src/rand.c | 2 +- contrib/bc/src/read.c | 2 +- contrib/bc/src/vector.c | 2 +- contrib/bc/src/vm.c | 62 ++- contrib/bc/tests/all.sh | 2 +- contrib/bc/tests/bc/timeconst.sh | 2 +- contrib/bc/tests/bcl.c | 2 +- contrib/bc/tests/dc/scripts/easter.sh | 2 +- contrib/bc/tests/error.sh | 2 +- contrib/bc/tests/errors.sh | 2 +- contrib/bc/tests/history.py | 6 +- contrib/bc/tests/history.sh | 2 +- contrib/bc/tests/other.sh | 6 +- contrib/bc/tests/read.sh | 2 +- contrib/bc/tests/script.sh | 2 +- contrib/bc/tests/scripts.sh | 2 +- contrib/bc/tests/stdin.sh | 2 +- contrib/bc/tests/test.sh | 2 +- 140 files changed, 4449 insertions(+), 4236 deletions(-) diff --git a/contrib/bc/LICENSE.md b/contrib/bc/LICENSE.md index 74441065df35..c8f6758e6d4b 100644 --- a/contrib/bc/LICENSE.md +++ b/contrib/bc/LICENSE.md @@ -1,6 +1,6 @@ # License -Copyright (c) 2018-2023 Gavin D. Howard +Copyright (c) 2018-2024 Gavin D. Howard Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: @@ -60,7 +60,7 @@ The files `src/rand.c` and `include/rand.h` are under the following copyrights and license: Copyright (c) 2014-2017 Melissa O'Neill and PCG Project contributors
-Copyright (c) 2018-2023 Gavin D. Howard +Copyright (c) 2018-2024 Gavin D. Howard Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in diff --git a/contrib/bc/MEMORY_BUGS.md b/contrib/bc/MEMORY_BUGS.md index 12e0b854e9d8..2e41ad3d75c9 100644 --- a/contrib/bc/MEMORY_BUGS.md +++ b/contrib/bc/MEMORY_BUGS.md @@ -23,6 +23,13 @@ existed in. The first version without this bug is `6.0.2`. +* In versions `3.0.0` until `6.7.5` (inclusive) of `bc` and `dc`, there is a + possible out-of-bounds read when there is an error flushing `stdout` on exit + because such an error would cause `bc` and `dc` to attempt to use a `jmp_buf` + when none exists. + + The first version without this bug is `6.7.6`. + * In versions `5.0.0` until `6.0.4` (inclusive) of `bc`, there is an out-of-bounds access if a non-local (non-`auto`) variable is set to a string with `asciify()`, then the function is redefined with a use of the same diff --git a/contrib/bc/Makefile.in b/contrib/bc/Makefile.in index e1309cd6d6b3..4adb76ddaa17 100644 --- a/contrib/bc/Makefile.in +++ b/contrib/bc/Makefile.in @@ -1,7 +1,7 @@ # # SPDX-License-Identifier: BSD-2-Clause # -# Copyright (c) 2018-2023 Gavin D. Howard and contributors. +# Copyright (c) 2018-2024 Gavin D. Howard and contributors. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/NEWS.md b/contrib/bc/NEWS.md index 32e74de31231..95de7e5182c4 100644 --- a/contrib/bc/NEWS.md +++ b/contrib/bc/NEWS.md @@ -1,5 +1,12 @@ # News +## 6.7.6 + +This is a production release to fix one bug. + +The bug was that `bc` attempted to jump out when flushing `stdout` on exit, but +there is no jump buf at that point. + ## 6.7.5 This is a production release to fix one small bug. diff --git a/contrib/bc/NOTICE.md b/contrib/bc/NOTICE.md index c0d3ded5797a..35536b2c27d7 100644 --- a/contrib/bc/NOTICE.md +++ b/contrib/bc/NOTICE.md @@ -1,6 +1,6 @@ # Notice -Copyright 2018-2023 Gavin D. Howard and contributors. +Copyright 2018-2024 Gavin D. Howard and contributors. ## Contributors diff --git a/contrib/bc/README.md b/contrib/bc/README.md index 943ca89eee2c..696e6186b8bd 100644 --- a/contrib/bc/README.md +++ b/contrib/bc/README.md @@ -48,7 +48,7 @@ POSIX-compatible systems that are known to work: * FreeBSD * OpenBSD * NetBSD -* Mac OSX +* macOS * Solaris* (as long as the Solaris version supports POSIX 2008) * AIX * HP-UX* (except for history) @@ -347,6 +347,8 @@ that is because it is more robust. See the [benchmarks][19]. Below is a non-comprehensive list of extensions that this `bc` and `dc` have that all others do not. +* **The `!` operator has higher precedence than the `!` operator in other `bc` + implementations.** * An extended math library. (See [here][30] for more information.) * A command-line prompt. * Turning on and off digit clamping. (Digit clamping is about how to treat @@ -427,7 +429,7 @@ Other projects based on this bc are: * [FreeBSD `bc`][23]. While the `bc` in FreeBSD is kept up-to-date, it is better to [report bugs there][24], as well as [submit patches][25], and the maintainers of the package will contact me if necessary. -* [Mac OSX `bc`][35]. Any bugs in that `bc` should be reported to me, but do +* [macOS `bc`][35]. Any bugs in that `bc` should be reported to me, but do expect bugs because the version is old. * [Android Open Source `bc`][32]. Any bugs in that `bc` can be reported here. diff --git a/contrib/bc/compile_flags.txt b/contrib/bc/compile_flags.txt new file mode 100644 index 000000000000..7a08c87f3876 --- /dev/null +++ b/contrib/bc/compile_flags.txt @@ -0,0 +1,15 @@ +-Weverything +-pedantic +-Wno-unsafe-buffer-usage +-D_POSIX_C_SOURCE=200809L +-D_XOPEN_SOURCE=700 +-D_BSD_SOURCE +-D_GNU_SOURCE +-D_DEFAULT_SOURCE +-Iinclude/ +-DBC_DEBUG=1 +-DBC_ENABLED=1 +-DDC_ENABLED=1 +-DBC_ENABLE_EXTRA_MATH=1 +-DBC_ENABLE_HISTORY=1 +-DBC_ENABLE_NLS=1 diff --git a/contrib/bc/configure.sh b/contrib/bc/configure.sh index 9292f094bb17..43bb502ea817 100755 --- a/contrib/bc/configure.sh +++ b/contrib/bc/configure.sh @@ -2,7 +2,7 @@ # # SPDX-License-Identifier: BSD-2-Clause # -# Copyright (c) 2018-2023 Gavin D. Howard and contributors. +# Copyright (c) 2018-2024 Gavin D. Howard and contributors. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: @@ -127,7 +127,7 @@ usage() { printf ' If this option is given along with -e and -r, the last occurrence of\n' printf ' all of the three is used.\n' printf ' -k KARATSUBA_LEN, --karatsuba-len KARATSUBA_LEN\n' - printf ' Set the karatsuba length to KARATSUBA_LEN (default is 64).\n' + printf ' Set the karatsuba length to KARATSUBA_LEN (default is 32).\n' printf ' It is an error if KARATSUBA_LEN is not a number or is less than 16.\n' printf ' -l, --install-all-locales\n' printf ' Installs all locales, regardless of how many are on the system. This\n' @@ -163,7 +163,7 @@ usage() { printf ' Enable the use of libreadline/readline. This is meant for those users\n' printf ' that want vi-like or Emacs-like behavior in history. This option is\n' printf ' ignored if history is disabled. If this option is given along with -e\n' - printf ' and -r, the last occurrence of all of the three is used.\n' + printf ' and -i, the last occurrence of all of the three is used.\n' printf ' -s SETTING, --set-default-on SETTING\n' printf ' Set the default named by SETTING to on. See below for possible values\n' printf ' for SETTING. For multiple instances of the -s or -S for the the same\n' @@ -1671,10 +1671,10 @@ else CPPFLAGS="$CPPFLAGS -D_POSIX_C_SOURCE=200809L -D_XOPEN_SOURCE=700" fi -# Test Mac OSX. This is not in an if statement because regardless of whatever -# the user says, we need to know if we are on Mac OSX. If we are, we have to set +# Test macOS. This is not in an if statement because regardless of whatever the +# user says, we need to know if we are on macOS. If we are, we have to set # _DARWIN_C_SOURCE. -printf 'Testing for Mac OSX...\n' +printf 'Testing for macOS...\n' flags="-DBC_TEST_APPLE -DBC_ENABLE_AFL=0" "$CC" $CPPFLAGS $CFLAGS $flags "-I$scriptdir/include" -E "$scriptdir/src/vm.c" > /dev/null 2>&1 @@ -1682,15 +1682,15 @@ flags="-DBC_TEST_APPLE -DBC_ENABLE_AFL=0" err="$?" if [ "$err" -ne 0 ]; then - printf 'On Mac OSX. Using _DARWIN_C_SOURCE.\n\n' + printf 'On macOS. Using _DARWIN_C_SOURCE.\n\n' apple="-D_DARWIN_C_SOURCE" else - printf 'Not on Mac OSX.\n\n' + printf 'Not on macOS.\n\n' apple="" fi -# We can't use the linker's strip flag on Mac OSX. -if [ "$debug" -eq 0 ] && [ "$apple" == "" ] && [ "$strip_bin" -ne 0 ]; then +# We can't use the linker's strip flag on macOS. +if [ "$debug" -eq 0 ] && [ "$apple" = "" ] && [ "$strip_bin" -ne 0 ]; then LDFLAGS="-s $LDFLAGS" fi diff --git a/contrib/bc/gen/bc_help.txt b/contrib/bc/gen/bc_help.txt index c51ba186db15..489b54a185f1 100644 --- a/contrib/bc/gen/bc_help.txt +++ b/contrib/bc/gen/bc_help.txt @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/gen/dc_help.txt b/contrib/bc/gen/dc_help.txt index 7d9e7ec28d25..df4ede1583a2 100644 --- a/contrib/bc/gen/dc_help.txt +++ b/contrib/bc/gen/dc_help.txt @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/gen/lib.bc b/contrib/bc/gen/lib.bc index b12b23176790..0c9389b8510d 100644 --- a/contrib/bc/gen/lib.bc +++ b/contrib/bc/gen/lib.bc @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/gen/lib2.bc b/contrib/bc/gen/lib2.bc index df51d0c07a8d..d6d9f70fe063 100644 --- a/contrib/bc/gen/lib2.bc +++ b/contrib/bc/gen/lib2.bc @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/gen/strgen.c b/contrib/bc/gen/strgen.c index 2cb3ed9e8475..1394a05c4a76 100644 --- a/contrib/bc/gen/strgen.c +++ b/contrib/bc/gen/strgen.c @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: @@ -68,7 +68,7 @@ static const char* const bc_gen_ex_end = "{{ end }}"; // This is exactly what it looks like. It just slaps a simple license header on // the generated C source file. static const char* const bc_gen_header = - "// Copyright (c) 2018-2023 Gavin D. Howard and contributors.\n" + "// Copyright (c) 2018-2024 Gavin D. Howard and contributors.\n" "// Licensed under the 2-clause BSD license.\n" "// *** AUTOMATICALLY GENERATED FROM %s. DO NOT MODIFY. ***\n\n"; // clang-format on diff --git a/contrib/bc/gen/strgen.sh b/contrib/bc/gen/strgen.sh index 2b8927b5528e..8542bd40ee83 100755 --- a/contrib/bc/gen/strgen.sh +++ b/contrib/bc/gen/strgen.sh @@ -2,7 +2,7 @@ # # SPDX-License-Identifier: BSD-2-Clause # -# Copyright (c) 2018-2023 Gavin D. Howard and contributors. +# Copyright (c) 2018-2024 Gavin D. Howard and contributors. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: @@ -96,7 +96,7 @@ if [ -n "$remove_tabs" ]; then fi cat<data & ~(BC_LEX_CHAR_MSB(1)))) /// A macro to easily build a keyword entry. See bc_lex_kws in src/data.c. -#define BC_LEX_KW_ENTRY(a, b, c) \ - { \ - .data = ((b) & ~(BC_LEX_CHAR_MSB(1))) | BC_LEX_CHAR_MSB(c), .name = a \ - } +#define BC_LEX_KW_ENTRY(a, b, c) \ + { .data = ((b) & ~(BC_LEX_CHAR_MSB(1))) | BC_LEX_CHAR_MSB(c), .name = a } #if BC_ENABLE_EXTRA_MATH @@ -234,7 +233,7 @@ bc_lex_token(BcLex* l); * @param t The token to return operator data for. * @return The operator data for @a t. */ -#define BC_PARSE_OP_DATA(t) bc_parse_ops[((t) -BC_LEX_OP_INC)] +#define BC_PARSE_OP_DATA(t) bc_parse_ops[((t) - BC_LEX_OP_INC)] /** * Returns non-zero if operator @a op is left associative, zero otherwise. @@ -341,7 +340,7 @@ bc_lex_token(BcLex* l); * @param t The token to turn into an instruction. * @return The token as an instruction. */ -#define BC_PARSE_TOKEN_INST(t) ((uchar) ((t) -BC_LEX_NEG + BC_INST_NEG)) +#define BC_PARSE_TOKEN_INST(t) ((uchar) ((t) - BC_LEX_NEG + BC_INST_NEG)) /** * Returns true if the token is a bc keyword. @@ -372,10 +371,8 @@ typedef struct BcParseNext /// A macro to generate a BcParseNext literal from BcParseNext data. See /// src/data.c for examples. -#define BC_PARSE_NEXT(a, ...) \ - { \ - .len = (uchar) (a), BC_PARSE_NEXT_TOKENS(__VA_ARGS__) \ - } +#define BC_PARSE_NEXT(a, ...) \ + { .len = (uchar) (a), BC_PARSE_NEXT_TOKENS(__VA_ARGS__) } /// A status returned by @a bc_parse_expr_err(). It can either return success or /// an error indicating an empty expression. diff --git a/contrib/bc/include/bcl.h b/contrib/bc/include/bcl.h index d3a9f42cdcf8..8e762b694f4d 100644 --- a/contrib/bc/include/bcl.h +++ b/contrib/bc/include/bcl.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/include/dc.h b/contrib/bc/include/dc.h index 9a603c26d1a5..1328f1c63b38 100644 --- a/contrib/bc/include/dc.h +++ b/contrib/bc/include/dc.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: @@ -45,8 +45,9 @@ /** * The main function for dc. It just sets variables and passes its arguments * through to @a bc_vm_boot(). + * @return A status. */ -void +BcStatus dc_main(int argc, char* argv[]); // A reference to the dc help text. diff --git a/contrib/bc/include/file.h b/contrib/bc/include/file.h index 95cfa861a734..86f368db11c6 100644 --- a/contrib/bc/include/file.h +++ b/contrib/bc/include/file.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: @@ -54,6 +54,9 @@ typedef struct BcFile // with the existing code as possible. FILE* f; + // True if errors should be fatal, false otherwise. + bool errors_fatal; + } BcFile; #else // BC_ENABLE_LINE_LIB @@ -64,6 +67,9 @@ typedef struct BcFile // The actual file descriptor. int fd; + // True if errors should be fatal, false otherwise. + bool errors_fatal; + // The buffer for the file. char* buf; @@ -123,23 +129,25 @@ typedef enum BcFlushType /** * Initialize a file. - * @param f The file to initialize. - * @param file The stdio file. + * @param f The file to initialize. + * @param file The stdio file. + * @param errors_fatal True if errors should be fatal, false otherwise. */ void -bc_file_init(BcFile* f, FILE* file); +bc_file_init(BcFile* f, FILE* file, bool errors_fatal); #else // BC_ENABLE_LINE_LIB /** * Initialize a file. - * @param f The file to initialize. - * @param fd The file descriptor. - * @param buf The buffer for the file. - * @param cap The capacity of the buffer. + * @param f The file to initialize. + * @param fd The file descriptor. + * @param buf The buffer for the file. + * @param cap The capacity of the buffer. + * @param errors_fatal True if errors should be fatal, false otherwise. */ void -bc_file_init(BcFile* f, int fd, char* buf, size_t cap); +bc_file_init(BcFile* f, int fd, char* buf, size_t cap, bool errors_fatal); #endif // BC_ENABLE_LINE_LIB diff --git a/contrib/bc/include/history.h b/contrib/bc/include/history.h index 64402c4dffa1..460524bd7b87 100644 --- a/contrib/bc/include/history.h +++ b/contrib/bc/include/history.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/include/lang.h b/contrib/bc/include/lang.h index 97aeeaa98da8..6c8245139719 100644 --- a/contrib/bc/include/lang.h +++ b/contrib/bc/include/lang.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/include/lex.h b/contrib/bc/include/lex.h index ac9b7b6ea69c..d2be3c7526ef 100644 --- a/contrib/bc/include/lex.h +++ b/contrib/bc/include/lex.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/include/library.h b/contrib/bc/include/library.h index 1edd3757444c..9942705a5f36 100644 --- a/contrib/bc/include/library.h +++ b/contrib/bc/include/library.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/include/num.h b/contrib/bc/include/num.h index 6c9dee107f2f..6cead6eb3823 100644 --- a/contrib/bc/include/num.h +++ b/contrib/bc/include/num.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/include/opt.h b/contrib/bc/include/opt.h index 28d9d99a7856..e60328994d8c 100644 --- a/contrib/bc/include/opt.h +++ b/contrib/bc/include/opt.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/include/parse.h b/contrib/bc/include/parse.h index ece413e7bd74..7f0f8768b0db 100644 --- a/contrib/bc/include/parse.h +++ b/contrib/bc/include/parse.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/include/program.h b/contrib/bc/include/program.h index 1df753afad22..e16e5c079d7d 100644 --- a/contrib/bc/include/program.h +++ b/contrib/bc/include/program.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/include/rand.h b/contrib/bc/include/rand.h index e516295d7c5c..aee63b866cf6 100644 --- a/contrib/bc/include/rand.h +++ b/contrib/bc/include/rand.h @@ -13,7 +13,7 @@ * This code is under the following license: * * Copyright (c) 2014-2017 Melissa O'Neill and PCG Project contributors - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -241,10 +241,7 @@ typedef struct BcRandState * @param l The low 64 bits. * @return The constant built from @a h and @a l. */ -#define BC_RAND_CONSTANT(h, l) \ - { \ - .lo = (l), .hi = (h) \ - } +#define BC_RAND_CONSTANT(h, l) { .lo = (l), .hi = (h) } /** * Truncates a PCG state to the number of bits in a random integer. diff --git a/contrib/bc/include/read.h b/contrib/bc/include/read.h index 867dcd7433a3..62e6897635a2 100644 --- a/contrib/bc/include/read.h +++ b/contrib/bc/include/read.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/include/status.h b/contrib/bc/include/status.h index 242514edb476..f579df8c649b 100644 --- a/contrib/bc/include/status.h +++ b/contrib/bc/include/status.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: @@ -60,10 +60,10 @@ #endif // __FreeBSD__ #endif // BC_TEST_FREEBSD -// This is used by configure.sh to test for Mac OSX. +// This is used by configure.sh to test for macOS. #ifdef BC_TEST_APPLE #ifdef __APPLE__ -#error On Mac OSX without _DARWIN_C_SOURCE +#error On macOS without _DARWIN_C_SOURCE #endif // __APPLE__ #endif // BC_TEST_APPLE diff --git a/contrib/bc/include/vector.h b/contrib/bc/include/vector.h index b86be1424537..cad5fc2aa7c3 100644 --- a/contrib/bc/include/vector.h +++ b/contrib/bc/include/vector.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/include/version.h b/contrib/bc/include/version.h index e2576269345d..586691a6e7ef 100644 --- a/contrib/bc/include/version.h +++ b/contrib/bc/include/version.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: @@ -37,6 +37,6 @@ #define BC_VERSION_H /// The current version. -#define VERSION 6.7.5 +#define VERSION 6.7.6 #endif // BC_VERSION_H diff --git a/contrib/bc/include/vm.h b/contrib/bc/include/vm.h index c56cc8e7370a..052c1d14c237 100644 --- a/contrib/bc/include/vm.h +++ b/contrib/bc/include/vm.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: @@ -493,7 +493,7 @@ #define BC_VM_SAFE_RESULT(r) ((r)->t >= BC_RESULT_TEMP) /// The invalid locale catalog return value. -#define BC_VM_INVALID_CATALOG ((nl_catd) -1) +#define BC_VM_INVALID_CATALOG ((nl_catd) - 1) /** * Returns true if the *unsigned* multiplication overflows. @@ -791,8 +791,9 @@ bc_vm_info(const char* const help); * The entrance point for bc/dc together. * @param argc The count of arguments. * @param argv The argument array. + * @return A status. */ -void +BcStatus bc_vm_boot(int argc, char* argv[]); /** @@ -1045,8 +1046,9 @@ bc_vm_fatalError(BcErr e); * A function to call at exit. * @param status The exit status. */ -int -bc_vm_atexit(int status); +BcStatus +bc_vm_atexit(BcStatus status); + #endif // BC_ENABLE_LIBRARY /// A reference to the copyright header. diff --git a/contrib/bc/locales/de_DE.ISO8859-1.msg b/contrib/bc/locales/de_DE.ISO8859-1.msg index 858a3946e8f8..9700ab070b2c 100644 --- a/contrib/bc/locales/de_DE.ISO8859-1.msg +++ b/contrib/bc/locales/de_DE.ISO8859-1.msg @@ -1,7 +1,7 @@ $ $ $ SPDX-License-Identifier: BSD-2-Clause $ $ -$ Copyright (c) 2018-2023 Gavin D. Howard and contributors. +$ Copyright (c) 2018-2024 Gavin D. Howard and contributors. $ $ $ Redistribution and use in source and binary forms, with or without $ modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/locales/de_DE.UTF-8.msg b/contrib/bc/locales/de_DE.UTF-8.msg index 25be4fd79cb9..7b918fc6d1cd 100644 --- a/contrib/bc/locales/de_DE.UTF-8.msg +++ b/contrib/bc/locales/de_DE.UTF-8.msg @@ -1,7 +1,7 @@ $ $ $ SPDX-License-Identifier: BSD-2-Clause $ $ -$ Copyright (c) 2018-2023 Gavin D. Howard and contributors. +$ Copyright (c) 2018-2024 Gavin D. Howard and contributors. $ $ $ Redistribution and use in source and binary forms, with or without $ modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/locales/en_US.msg b/contrib/bc/locales/en_US.msg index 5610496d6e71..4afcbcd1f813 100644 --- a/contrib/bc/locales/en_US.msg +++ b/contrib/bc/locales/en_US.msg @@ -1,7 +1,7 @@ $ $ $ SPDX-License-Identifier: BSD-2-Clause $ $ -$ Copyright (c) 2018-2023 Gavin D. Howard and contributors. +$ Copyright (c) 2018-2024 Gavin D. Howard and contributors. $ $ $ Redistribution and use in source and binary forms, with or without $ modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/locales/es_ES.ISO8859-1.msg b/contrib/bc/locales/es_ES.ISO8859-1.msg index 3bf70753559e..4d022d9bf664 100644 --- a/contrib/bc/locales/es_ES.ISO8859-1.msg +++ b/contrib/bc/locales/es_ES.ISO8859-1.msg @@ -1,7 +1,7 @@ $ $ $ SPDX-License-Identifier: BSD-2-Clause $ $ -$ Copyright (c) 2018-2023 Gavin D. Howard and contributors. +$ Copyright (c) 2018-2024 Gavin D. Howard and contributors. $ $ $ Redistribution and use in source and binary forms, with or without $ modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/locales/es_ES.UTF-8.msg b/contrib/bc/locales/es_ES.UTF-8.msg index 0a5cf26d1621..364cff6ee57f 100644 --- a/contrib/bc/locales/es_ES.UTF-8.msg +++ b/contrib/bc/locales/es_ES.UTF-8.msg @@ -1,7 +1,7 @@ $ $ $ SPDX-License-Identifier: BSD-2-Clause $ $ -$ Copyright (c) 2018-2023 Gavin D. Howard and contributors. +$ Copyright (c) 2018-2024 Gavin D. Howard and contributors. $ $ $ Redistribution and use in source and binary forms, with or without $ modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/locales/fr_FR.ISO8859-1.msg b/contrib/bc/locales/fr_FR.ISO8859-1.msg index f2e07e02b2dc..b4b39866c96e 100644 --- a/contrib/bc/locales/fr_FR.ISO8859-1.msg +++ b/contrib/bc/locales/fr_FR.ISO8859-1.msg @@ -1,7 +1,7 @@ $ $ $ SPDX-License-Identifier: BSD-2-Clause $ $ -$ Copyright (c) 2018-2023 Gavin D. Howard and contributors. +$ Copyright (c) 2018-2024 Gavin D. Howard and contributors. $ $ $ Redistribution and use in source and binary forms, with or without $ modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/locales/fr_FR.UTF-8.msg b/contrib/bc/locales/fr_FR.UTF-8.msg index 1e9e900746a5..c3387e31ae9f 100644 --- a/contrib/bc/locales/fr_FR.UTF-8.msg +++ b/contrib/bc/locales/fr_FR.UTF-8.msg @@ -1,7 +1,7 @@ $ $ $ SPDX-License-Identifier: BSD-2-Clause $ $ -$ Copyright (c) 2018-2023 Gavin D. Howard and contributors. +$ Copyright (c) 2018-2024 Gavin D. Howard and contributors. $ $ $ Redistribution and use in source and binary forms, with or without $ modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/locales/ja_JP.UTF-8.msg b/contrib/bc/locales/ja_JP.UTF-8.msg index d871e9bf6ad2..21640eb9f1cb 100644 --- a/contrib/bc/locales/ja_JP.UTF-8.msg +++ b/contrib/bc/locales/ja_JP.UTF-8.msg @@ -1,7 +1,7 @@ $ $ $ SPDX-License-Identifier: BSD-2-Clause *** 23592 LINES SKIPPED *** From nobody Tue Jul 16 18:06:40 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNn812qp8z5Rhwq; Tue, 16 Jul 2024 18:06: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNn812Z9vz4nry; Tue, 16 Jul 2024 18:06:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721153201; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Ba3JqilmBDGNi/g57ZgokwFefr0PIEV0A2I4hi5d7xY=; b=SOK4fdLj++/wpGk8nWY7AzOfjni43DPN247CanJyfEnhufctUZoZNkX8wms11Qt0Eyg483 Txjs2wd+RGv7ILaD8PVeLa2qXPyMw5ycVompnhyTbwviWNvMJQ6hVAn1NkmloYqn0z9LOC HL2/+6cqZdOJCFgn8MGwYNkYiHRh2456/mwoCi0XqnUbJ+LAXuoQnNz58qZ0h5Z+ayowBk lk9QwwsEOCkIRvMhydM815vMiem1RZaJRctGdr4DOIuOBe5g+agnGMTGwWEMT2CW+FNQzK PDlsbCESbxP0mattsr46oMozeABLh2HfLjlZzDXVVtmEvTOHa/539ccDxKyJhw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721153201; a=rsa-sha256; cv=none; b=SE8/7WtW2P3nTw9cHCTEU0GnG5ZSdUuTdsSP5ZJFqUEbT4VqMW4D9nNQaJSyQhv1U1vwIH Xp0wPcsvffzE/R1SJuIjRRKSNuNLx9W17E+eGIY+7F6zMocqOAw7YWz+1buo3Tgwl8SmnU 7fWp+MlKS8gVAfeOzz9YhEEZNQAxzCBnnTN1s81ALnqzNjAB3MOJqK96Mq4+3BBxf6lZmu wiBN86IQJnkBTrEGA3aPxH5NHiLywTJaZhyX5yl03iu9++fh/glUM2bYgFTcU/fy/4VwlC 7dkU7uwXAbAVdje8tsIChQk3vaBxl7zqagsBU4kGAZ3kVQjgCCqCB0KOxs9k4Q== 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=1721153201; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Ba3JqilmBDGNi/g57ZgokwFefr0PIEV0A2I4hi5d7xY=; b=l2LmgIgjjRNFs/TRwpCmkoeL1K6zL419/nVtwKxIFqRgGoijcEc6bUwQYhHbJgj/SPeNfD X6Kov1baabV+tWCFd/mHKH3K5iJNYog599ztpLO4WgqnvPDNUvLbbuUCtxkjvU4EcUY/Yv gdSqFk1ssGByM6XKpHJJg5Uylrz5hliY9zSkWlhYF0OP1fFKhQjsuu3z1y3CILe5adteQn Ml/EUZuOX8iVhQKApxv8T8auwIX+anfQXy7eJCQ/1RSsTwRaLrN+G+7VxvBtVzAAqebUJt rwxqw4iRGd3tXcMvWMKPY81C9kS09qs4Z15OykWjyWfpf74miOX02X/DMT7dIg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNn8128WFzmlD; Tue, 16 Jul 2024 18:06:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46GI6fhs061670; Tue, 16 Jul 2024 18:06:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46GI6esH061667; Tue, 16 Jul 2024 18:06:40 GMT (envelope-from git) Date: Tue, 16 Jul 2024 18:06:40 GMT Message-Id: <202407161806.46GI6esH061667@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Stefan =?utf-8?Q?E=C3=9Fer?= Subject: git: 4da38c584016 - stable/13 - contrib/bc: upgrade to version 6.7.6 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: se X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 4da38c584016be734f343b99a228d05be773e114 Auto-Submitted: auto-generated The branch stable/13 has been updated by se: URL: https://cgit.FreeBSD.org/src/commit/?id=4da38c584016be734f343b99a228d05be773e114 commit 4da38c584016be734f343b99a228d05be773e114 Author: Stefan EƟer AuthorDate: 2024-07-09 05:49:27 +0000 Commit: Stefan EƟer CommitDate: 2024-07-16 17:52:56 +0000 contrib/bc: upgrade to version 6.7.6 This update fixes a potential issue when flushing stdout on exit fails: longjmp could use an uninitialized target address variable. Most files are included in this commit due to a changed date in the copyright note. (cherry picked from commit a970610a3af63b3f4df5b69d91c6b4093a00ed8f) --- contrib/bc/LICENSE.md | 4 +- contrib/bc/MEMORY_BUGS.md | 7 + contrib/bc/Makefile.in | 2 +- contrib/bc/NEWS.md | 7 + contrib/bc/NOTICE.md | 2 +- contrib/bc/README.md | 6 +- contrib/bc/compile_flags.txt | 15 + contrib/bc/configure.sh | 20 +- contrib/bc/gen/bc_help.txt | 2 +- contrib/bc/gen/dc_help.txt | 2 +- contrib/bc/gen/lib.bc | 2 +- contrib/bc/gen/lib2.bc | 2 +- contrib/bc/gen/strgen.c | 4 +- contrib/bc/gen/strgen.sh | 4 +- contrib/bc/include/args.h | 2 +- contrib/bc/include/bc.h | 21 +- contrib/bc/include/bcl.h | 2 +- contrib/bc/include/dc.h | 5 +- contrib/bc/include/file.h | 26 +- contrib/bc/include/history.h | 2 +- contrib/bc/include/lang.h | 2 +- contrib/bc/include/lex.h | 2 +- contrib/bc/include/library.h | 2 +- contrib/bc/include/num.h | 2 +- contrib/bc/include/opt.h | 2 +- contrib/bc/include/parse.h | 2 +- contrib/bc/include/program.h | 2 +- contrib/bc/include/rand.h | 7 +- contrib/bc/include/read.h | 2 +- contrib/bc/include/status.h | 6 +- contrib/bc/include/vector.h | 2 +- contrib/bc/include/version.h | 4 +- contrib/bc/include/vm.h | 12 +- contrib/bc/locales/de_DE.ISO8859-1.msg | 2 +- contrib/bc/locales/de_DE.UTF-8.msg | 2 +- contrib/bc/locales/en_US.msg | 2 +- contrib/bc/locales/es_ES.ISO8859-1.msg | 2 +- contrib/bc/locales/es_ES.UTF-8.msg | 2 +- contrib/bc/locales/fr_FR.ISO8859-1.msg | 2 +- contrib/bc/locales/fr_FR.UTF-8.msg | 2 +- contrib/bc/locales/ja_JP.UTF-8.msg | 2 +- contrib/bc/locales/ja_JP.eucJP.msg | 2 +- contrib/bc/locales/nl_NL.ISO8859-1.msg | 2 +- contrib/bc/locales/nl_NL.UTF-8.msg | 2 +- contrib/bc/locales/pl_PL.ISO8859-2.msg | 2 +- contrib/bc/locales/pl_PL.UTF-8.msg | 2 +- contrib/bc/locales/pt_PT.ISO8859-1.msg | 2 +- contrib/bc/locales/pt_PT.UTF-8.msg | 2 +- contrib/bc/locales/ru_RU.CP1251.msg | 2 +- contrib/bc/locales/ru_RU.CP866.msg | 2 +- contrib/bc/locales/ru_RU.ISO8859-5.msg | 2 +- contrib/bc/locales/ru_RU.KOI8-R.msg | 2 +- contrib/bc/locales/ru_RU.UTF-8.msg | 2 +- contrib/bc/locales/zh_CN.GB18030.msg | 2 +- contrib/bc/locales/zh_CN.GB2312.msg | 2 +- contrib/bc/locales/zh_CN.GBK.msg | 2 +- contrib/bc/locales/zh_CN.UTF-8.msg | 2 +- contrib/bc/locales/zh_CN.eucCN.msg | 2 +- contrib/bc/manuals/bc/A.1 | 681 +++++++++++++++++---------------- contrib/bc/manuals/bc/A.1.md | 5 +- contrib/bc/manuals/bc/E.1 | 482 +++++++++++------------ contrib/bc/manuals/bc/E.1.md | 5 +- contrib/bc/manuals/bc/EH.1 | 474 ++++++++++++----------- contrib/bc/manuals/bc/EH.1.md | 5 +- contrib/bc/manuals/bc/EHN.1 | 474 ++++++++++++----------- contrib/bc/manuals/bc/EHN.1.md | 5 +- contrib/bc/manuals/bc/EN.1 | 482 +++++++++++------------ contrib/bc/manuals/bc/EN.1.md | 5 +- contrib/bc/manuals/bc/H.1 | 673 ++++++++++++++++---------------- contrib/bc/manuals/bc/H.1.md | 5 +- contrib/bc/manuals/bc/HN.1 | 673 ++++++++++++++++---------------- contrib/bc/manuals/bc/HN.1.md | 5 +- contrib/bc/manuals/bc/N.1 | 681 +++++++++++++++++---------------- contrib/bc/manuals/bc/N.1.md | 5 +- contrib/bc/manuals/bcl.3 | 95 ++--- contrib/bc/manuals/bcl.3.md | 2 +- contrib/bc/manuals/dc/A.1 | 478 +++++++++++------------ contrib/bc/manuals/dc/A.1.md | 2 +- contrib/bc/manuals/dc/E.1 | 376 +++++++++--------- contrib/bc/manuals/dc/E.1.md | 2 +- contrib/bc/manuals/dc/EH.1 | 368 +++++++++--------- contrib/bc/manuals/dc/EH.1.md | 2 +- contrib/bc/manuals/dc/EHN.1 | 368 +++++++++--------- contrib/bc/manuals/dc/EHN.1.md | 2 +- contrib/bc/manuals/dc/EN.1 | 376 +++++++++--------- contrib/bc/manuals/dc/EN.1.md | 2 +- contrib/bc/manuals/dc/H.1 | 470 ++++++++++++----------- contrib/bc/manuals/dc/H.1.md | 2 +- contrib/bc/manuals/dc/HN.1 | 470 ++++++++++++----------- contrib/bc/manuals/dc/HN.1.md | 2 +- contrib/bc/manuals/dc/N.1 | 478 +++++++++++------------ contrib/bc/manuals/dc/N.1.md | 2 +- contrib/bc/scripts/exec-install.sh | 2 +- contrib/bc/scripts/format.sh | 2 +- contrib/bc/scripts/functions.sh | 2 +- contrib/bc/scripts/karatsuba.py | 2 +- contrib/bc/scripts/link.sh | 2 +- contrib/bc/scripts/lint.sh | 2 +- contrib/bc/scripts/locale_install.sh | 2 +- contrib/bc/scripts/locale_uninstall.sh | 2 +- contrib/bc/scripts/sqrt_frac_guess.bc | 2 +- contrib/bc/scripts/sqrt_int_guess.bc | 2 +- contrib/bc/scripts/sqrt_random.bc | 2 +- contrib/bc/scripts/sqrt_random.sh | 2 +- contrib/bc/src/args.c | 2 +- contrib/bc/src/bc.c | 6 +- contrib/bc/src/bc_lex.c | 2 +- contrib/bc/src/bc_parse.c | 2 +- contrib/bc/src/data.c | 4 +- contrib/bc/src/dc.c | 6 +- contrib/bc/src/dc_lex.c | 2 +- contrib/bc/src/dc_parse.c | 2 +- contrib/bc/src/file.c | 34 +- contrib/bc/src/history.c | 2 +- contrib/bc/src/lang.c | 2 +- contrib/bc/src/lex.c | 2 +- contrib/bc/src/library.c | 2 +- contrib/bc/src/main.c | 16 +- contrib/bc/src/num.c | 76 +++- contrib/bc/src/opt.c | 2 +- contrib/bc/src/parse.c | 2 +- contrib/bc/src/program.c | 2 +- contrib/bc/src/rand.c | 2 +- contrib/bc/src/read.c | 2 +- contrib/bc/src/vector.c | 2 +- contrib/bc/src/vm.c | 62 ++- contrib/bc/tests/all.sh | 2 +- contrib/bc/tests/bc/timeconst.sh | 2 +- contrib/bc/tests/bcl.c | 2 +- contrib/bc/tests/dc/scripts/easter.sh | 2 +- contrib/bc/tests/error.sh | 2 +- contrib/bc/tests/errors.sh | 2 +- contrib/bc/tests/history.py | 6 +- contrib/bc/tests/history.sh | 2 +- contrib/bc/tests/other.sh | 6 +- contrib/bc/tests/read.sh | 2 +- contrib/bc/tests/script.sh | 2 +- contrib/bc/tests/scripts.sh | 2 +- contrib/bc/tests/stdin.sh | 2 +- contrib/bc/tests/test.sh | 2 +- 140 files changed, 4449 insertions(+), 4236 deletions(-) diff --git a/contrib/bc/LICENSE.md b/contrib/bc/LICENSE.md index 74441065df35..c8f6758e6d4b 100644 --- a/contrib/bc/LICENSE.md +++ b/contrib/bc/LICENSE.md @@ -1,6 +1,6 @@ # License -Copyright (c) 2018-2023 Gavin D. Howard +Copyright (c) 2018-2024 Gavin D. Howard Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: @@ -60,7 +60,7 @@ The files `src/rand.c` and `include/rand.h` are under the following copyrights and license: Copyright (c) 2014-2017 Melissa O'Neill and PCG Project contributors
-Copyright (c) 2018-2023 Gavin D. Howard +Copyright (c) 2018-2024 Gavin D. Howard Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in diff --git a/contrib/bc/MEMORY_BUGS.md b/contrib/bc/MEMORY_BUGS.md index 12e0b854e9d8..2e41ad3d75c9 100644 --- a/contrib/bc/MEMORY_BUGS.md +++ b/contrib/bc/MEMORY_BUGS.md @@ -23,6 +23,13 @@ existed in. The first version without this bug is `6.0.2`. +* In versions `3.0.0` until `6.7.5` (inclusive) of `bc` and `dc`, there is a + possible out-of-bounds read when there is an error flushing `stdout` on exit + because such an error would cause `bc` and `dc` to attempt to use a `jmp_buf` + when none exists. + + The first version without this bug is `6.7.6`. + * In versions `5.0.0` until `6.0.4` (inclusive) of `bc`, there is an out-of-bounds access if a non-local (non-`auto`) variable is set to a string with `asciify()`, then the function is redefined with a use of the same diff --git a/contrib/bc/Makefile.in b/contrib/bc/Makefile.in index e1309cd6d6b3..4adb76ddaa17 100644 --- a/contrib/bc/Makefile.in +++ b/contrib/bc/Makefile.in @@ -1,7 +1,7 @@ # # SPDX-License-Identifier: BSD-2-Clause # -# Copyright (c) 2018-2023 Gavin D. Howard and contributors. +# Copyright (c) 2018-2024 Gavin D. Howard and contributors. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/NEWS.md b/contrib/bc/NEWS.md index 32e74de31231..95de7e5182c4 100644 --- a/contrib/bc/NEWS.md +++ b/contrib/bc/NEWS.md @@ -1,5 +1,12 @@ # News +## 6.7.6 + +This is a production release to fix one bug. + +The bug was that `bc` attempted to jump out when flushing `stdout` on exit, but +there is no jump buf at that point. + ## 6.7.5 This is a production release to fix one small bug. diff --git a/contrib/bc/NOTICE.md b/contrib/bc/NOTICE.md index c0d3ded5797a..35536b2c27d7 100644 --- a/contrib/bc/NOTICE.md +++ b/contrib/bc/NOTICE.md @@ -1,6 +1,6 @@ # Notice -Copyright 2018-2023 Gavin D. Howard and contributors. +Copyright 2018-2024 Gavin D. Howard and contributors. ## Contributors diff --git a/contrib/bc/README.md b/contrib/bc/README.md index 943ca89eee2c..696e6186b8bd 100644 --- a/contrib/bc/README.md +++ b/contrib/bc/README.md @@ -48,7 +48,7 @@ POSIX-compatible systems that are known to work: * FreeBSD * OpenBSD * NetBSD -* Mac OSX +* macOS * Solaris* (as long as the Solaris version supports POSIX 2008) * AIX * HP-UX* (except for history) @@ -347,6 +347,8 @@ that is because it is more robust. See the [benchmarks][19]. Below is a non-comprehensive list of extensions that this `bc` and `dc` have that all others do not. +* **The `!` operator has higher precedence than the `!` operator in other `bc` + implementations.** * An extended math library. (See [here][30] for more information.) * A command-line prompt. * Turning on and off digit clamping. (Digit clamping is about how to treat @@ -427,7 +429,7 @@ Other projects based on this bc are: * [FreeBSD `bc`][23]. While the `bc` in FreeBSD is kept up-to-date, it is better to [report bugs there][24], as well as [submit patches][25], and the maintainers of the package will contact me if necessary. -* [Mac OSX `bc`][35]. Any bugs in that `bc` should be reported to me, but do +* [macOS `bc`][35]. Any bugs in that `bc` should be reported to me, but do expect bugs because the version is old. * [Android Open Source `bc`][32]. Any bugs in that `bc` can be reported here. diff --git a/contrib/bc/compile_flags.txt b/contrib/bc/compile_flags.txt new file mode 100644 index 000000000000..7a08c87f3876 --- /dev/null +++ b/contrib/bc/compile_flags.txt @@ -0,0 +1,15 @@ +-Weverything +-pedantic +-Wno-unsafe-buffer-usage +-D_POSIX_C_SOURCE=200809L +-D_XOPEN_SOURCE=700 +-D_BSD_SOURCE +-D_GNU_SOURCE +-D_DEFAULT_SOURCE +-Iinclude/ +-DBC_DEBUG=1 +-DBC_ENABLED=1 +-DDC_ENABLED=1 +-DBC_ENABLE_EXTRA_MATH=1 +-DBC_ENABLE_HISTORY=1 +-DBC_ENABLE_NLS=1 diff --git a/contrib/bc/configure.sh b/contrib/bc/configure.sh index 9292f094bb17..43bb502ea817 100755 --- a/contrib/bc/configure.sh +++ b/contrib/bc/configure.sh @@ -2,7 +2,7 @@ # # SPDX-License-Identifier: BSD-2-Clause # -# Copyright (c) 2018-2023 Gavin D. Howard and contributors. +# Copyright (c) 2018-2024 Gavin D. Howard and contributors. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: @@ -127,7 +127,7 @@ usage() { printf ' If this option is given along with -e and -r, the last occurrence of\n' printf ' all of the three is used.\n' printf ' -k KARATSUBA_LEN, --karatsuba-len KARATSUBA_LEN\n' - printf ' Set the karatsuba length to KARATSUBA_LEN (default is 64).\n' + printf ' Set the karatsuba length to KARATSUBA_LEN (default is 32).\n' printf ' It is an error if KARATSUBA_LEN is not a number or is less than 16.\n' printf ' -l, --install-all-locales\n' printf ' Installs all locales, regardless of how many are on the system. This\n' @@ -163,7 +163,7 @@ usage() { printf ' Enable the use of libreadline/readline. This is meant for those users\n' printf ' that want vi-like or Emacs-like behavior in history. This option is\n' printf ' ignored if history is disabled. If this option is given along with -e\n' - printf ' and -r, the last occurrence of all of the three is used.\n' + printf ' and -i, the last occurrence of all of the three is used.\n' printf ' -s SETTING, --set-default-on SETTING\n' printf ' Set the default named by SETTING to on. See below for possible values\n' printf ' for SETTING. For multiple instances of the -s or -S for the the same\n' @@ -1671,10 +1671,10 @@ else CPPFLAGS="$CPPFLAGS -D_POSIX_C_SOURCE=200809L -D_XOPEN_SOURCE=700" fi -# Test Mac OSX. This is not in an if statement because regardless of whatever -# the user says, we need to know if we are on Mac OSX. If we are, we have to set +# Test macOS. This is not in an if statement because regardless of whatever the +# user says, we need to know if we are on macOS. If we are, we have to set # _DARWIN_C_SOURCE. -printf 'Testing for Mac OSX...\n' +printf 'Testing for macOS...\n' flags="-DBC_TEST_APPLE -DBC_ENABLE_AFL=0" "$CC" $CPPFLAGS $CFLAGS $flags "-I$scriptdir/include" -E "$scriptdir/src/vm.c" > /dev/null 2>&1 @@ -1682,15 +1682,15 @@ flags="-DBC_TEST_APPLE -DBC_ENABLE_AFL=0" err="$?" if [ "$err" -ne 0 ]; then - printf 'On Mac OSX. Using _DARWIN_C_SOURCE.\n\n' + printf 'On macOS. Using _DARWIN_C_SOURCE.\n\n' apple="-D_DARWIN_C_SOURCE" else - printf 'Not on Mac OSX.\n\n' + printf 'Not on macOS.\n\n' apple="" fi -# We can't use the linker's strip flag on Mac OSX. -if [ "$debug" -eq 0 ] && [ "$apple" == "" ] && [ "$strip_bin" -ne 0 ]; then +# We can't use the linker's strip flag on macOS. +if [ "$debug" -eq 0 ] && [ "$apple" = "" ] && [ "$strip_bin" -ne 0 ]; then LDFLAGS="-s $LDFLAGS" fi diff --git a/contrib/bc/gen/bc_help.txt b/contrib/bc/gen/bc_help.txt index c51ba186db15..489b54a185f1 100644 --- a/contrib/bc/gen/bc_help.txt +++ b/contrib/bc/gen/bc_help.txt @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/gen/dc_help.txt b/contrib/bc/gen/dc_help.txt index 7d9e7ec28d25..df4ede1583a2 100644 --- a/contrib/bc/gen/dc_help.txt +++ b/contrib/bc/gen/dc_help.txt @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/gen/lib.bc b/contrib/bc/gen/lib.bc index b12b23176790..0c9389b8510d 100644 --- a/contrib/bc/gen/lib.bc +++ b/contrib/bc/gen/lib.bc @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/gen/lib2.bc b/contrib/bc/gen/lib2.bc index df51d0c07a8d..d6d9f70fe063 100644 --- a/contrib/bc/gen/lib2.bc +++ b/contrib/bc/gen/lib2.bc @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/gen/strgen.c b/contrib/bc/gen/strgen.c index 2cb3ed9e8475..1394a05c4a76 100644 --- a/contrib/bc/gen/strgen.c +++ b/contrib/bc/gen/strgen.c @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: @@ -68,7 +68,7 @@ static const char* const bc_gen_ex_end = "{{ end }}"; // This is exactly what it looks like. It just slaps a simple license header on // the generated C source file. static const char* const bc_gen_header = - "// Copyright (c) 2018-2023 Gavin D. Howard and contributors.\n" + "// Copyright (c) 2018-2024 Gavin D. Howard and contributors.\n" "// Licensed under the 2-clause BSD license.\n" "// *** AUTOMATICALLY GENERATED FROM %s. DO NOT MODIFY. ***\n\n"; // clang-format on diff --git a/contrib/bc/gen/strgen.sh b/contrib/bc/gen/strgen.sh index 2b8927b5528e..8542bd40ee83 100755 --- a/contrib/bc/gen/strgen.sh +++ b/contrib/bc/gen/strgen.sh @@ -2,7 +2,7 @@ # # SPDX-License-Identifier: BSD-2-Clause # -# Copyright (c) 2018-2023 Gavin D. Howard and contributors. +# Copyright (c) 2018-2024 Gavin D. Howard and contributors. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: @@ -96,7 +96,7 @@ if [ -n "$remove_tabs" ]; then fi cat<data & ~(BC_LEX_CHAR_MSB(1)))) /// A macro to easily build a keyword entry. See bc_lex_kws in src/data.c. -#define BC_LEX_KW_ENTRY(a, b, c) \ - { \ - .data = ((b) & ~(BC_LEX_CHAR_MSB(1))) | BC_LEX_CHAR_MSB(c), .name = a \ - } +#define BC_LEX_KW_ENTRY(a, b, c) \ + { .data = ((b) & ~(BC_LEX_CHAR_MSB(1))) | BC_LEX_CHAR_MSB(c), .name = a } #if BC_ENABLE_EXTRA_MATH @@ -234,7 +233,7 @@ bc_lex_token(BcLex* l); * @param t The token to return operator data for. * @return The operator data for @a t. */ -#define BC_PARSE_OP_DATA(t) bc_parse_ops[((t) -BC_LEX_OP_INC)] +#define BC_PARSE_OP_DATA(t) bc_parse_ops[((t) - BC_LEX_OP_INC)] /** * Returns non-zero if operator @a op is left associative, zero otherwise. @@ -341,7 +340,7 @@ bc_lex_token(BcLex* l); * @param t The token to turn into an instruction. * @return The token as an instruction. */ -#define BC_PARSE_TOKEN_INST(t) ((uchar) ((t) -BC_LEX_NEG + BC_INST_NEG)) +#define BC_PARSE_TOKEN_INST(t) ((uchar) ((t) - BC_LEX_NEG + BC_INST_NEG)) /** * Returns true if the token is a bc keyword. @@ -372,10 +371,8 @@ typedef struct BcParseNext /// A macro to generate a BcParseNext literal from BcParseNext data. See /// src/data.c for examples. -#define BC_PARSE_NEXT(a, ...) \ - { \ - .len = (uchar) (a), BC_PARSE_NEXT_TOKENS(__VA_ARGS__) \ - } +#define BC_PARSE_NEXT(a, ...) \ + { .len = (uchar) (a), BC_PARSE_NEXT_TOKENS(__VA_ARGS__) } /// A status returned by @a bc_parse_expr_err(). It can either return success or /// an error indicating an empty expression. diff --git a/contrib/bc/include/bcl.h b/contrib/bc/include/bcl.h index d3a9f42cdcf8..8e762b694f4d 100644 --- a/contrib/bc/include/bcl.h +++ b/contrib/bc/include/bcl.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/include/dc.h b/contrib/bc/include/dc.h index 9a603c26d1a5..1328f1c63b38 100644 --- a/contrib/bc/include/dc.h +++ b/contrib/bc/include/dc.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: @@ -45,8 +45,9 @@ /** * The main function for dc. It just sets variables and passes its arguments * through to @a bc_vm_boot(). + * @return A status. */ -void +BcStatus dc_main(int argc, char* argv[]); // A reference to the dc help text. diff --git a/contrib/bc/include/file.h b/contrib/bc/include/file.h index 95cfa861a734..86f368db11c6 100644 --- a/contrib/bc/include/file.h +++ b/contrib/bc/include/file.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: @@ -54,6 +54,9 @@ typedef struct BcFile // with the existing code as possible. FILE* f; + // True if errors should be fatal, false otherwise. + bool errors_fatal; + } BcFile; #else // BC_ENABLE_LINE_LIB @@ -64,6 +67,9 @@ typedef struct BcFile // The actual file descriptor. int fd; + // True if errors should be fatal, false otherwise. + bool errors_fatal; + // The buffer for the file. char* buf; @@ -123,23 +129,25 @@ typedef enum BcFlushType /** * Initialize a file. - * @param f The file to initialize. - * @param file The stdio file. + * @param f The file to initialize. + * @param file The stdio file. + * @param errors_fatal True if errors should be fatal, false otherwise. */ void -bc_file_init(BcFile* f, FILE* file); +bc_file_init(BcFile* f, FILE* file, bool errors_fatal); #else // BC_ENABLE_LINE_LIB /** * Initialize a file. - * @param f The file to initialize. - * @param fd The file descriptor. - * @param buf The buffer for the file. - * @param cap The capacity of the buffer. + * @param f The file to initialize. + * @param fd The file descriptor. + * @param buf The buffer for the file. + * @param cap The capacity of the buffer. + * @param errors_fatal True if errors should be fatal, false otherwise. */ void -bc_file_init(BcFile* f, int fd, char* buf, size_t cap); +bc_file_init(BcFile* f, int fd, char* buf, size_t cap, bool errors_fatal); #endif // BC_ENABLE_LINE_LIB diff --git a/contrib/bc/include/history.h b/contrib/bc/include/history.h index 64402c4dffa1..460524bd7b87 100644 --- a/contrib/bc/include/history.h +++ b/contrib/bc/include/history.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/include/lang.h b/contrib/bc/include/lang.h index 97aeeaa98da8..6c8245139719 100644 --- a/contrib/bc/include/lang.h +++ b/contrib/bc/include/lang.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/include/lex.h b/contrib/bc/include/lex.h index ac9b7b6ea69c..d2be3c7526ef 100644 --- a/contrib/bc/include/lex.h +++ b/contrib/bc/include/lex.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/include/library.h b/contrib/bc/include/library.h index 1edd3757444c..9942705a5f36 100644 --- a/contrib/bc/include/library.h +++ b/contrib/bc/include/library.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/include/num.h b/contrib/bc/include/num.h index 6c9dee107f2f..6cead6eb3823 100644 --- a/contrib/bc/include/num.h +++ b/contrib/bc/include/num.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/include/opt.h b/contrib/bc/include/opt.h index 28d9d99a7856..e60328994d8c 100644 --- a/contrib/bc/include/opt.h +++ b/contrib/bc/include/opt.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/include/parse.h b/contrib/bc/include/parse.h index ece413e7bd74..7f0f8768b0db 100644 --- a/contrib/bc/include/parse.h +++ b/contrib/bc/include/parse.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/include/program.h b/contrib/bc/include/program.h index 1df753afad22..e16e5c079d7d 100644 --- a/contrib/bc/include/program.h +++ b/contrib/bc/include/program.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/include/rand.h b/contrib/bc/include/rand.h index e516295d7c5c..aee63b866cf6 100644 --- a/contrib/bc/include/rand.h +++ b/contrib/bc/include/rand.h @@ -13,7 +13,7 @@ * This code is under the following license: * * Copyright (c) 2014-2017 Melissa O'Neill and PCG Project contributors - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -241,10 +241,7 @@ typedef struct BcRandState * @param l The low 64 bits. * @return The constant built from @a h and @a l. */ -#define BC_RAND_CONSTANT(h, l) \ - { \ - .lo = (l), .hi = (h) \ - } +#define BC_RAND_CONSTANT(h, l) { .lo = (l), .hi = (h) } /** * Truncates a PCG state to the number of bits in a random integer. diff --git a/contrib/bc/include/read.h b/contrib/bc/include/read.h index 867dcd7433a3..62e6897635a2 100644 --- a/contrib/bc/include/read.h +++ b/contrib/bc/include/read.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/include/status.h b/contrib/bc/include/status.h index 242514edb476..f579df8c649b 100644 --- a/contrib/bc/include/status.h +++ b/contrib/bc/include/status.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: @@ -60,10 +60,10 @@ #endif // __FreeBSD__ #endif // BC_TEST_FREEBSD -// This is used by configure.sh to test for Mac OSX. +// This is used by configure.sh to test for macOS. #ifdef BC_TEST_APPLE #ifdef __APPLE__ -#error On Mac OSX without _DARWIN_C_SOURCE +#error On macOS without _DARWIN_C_SOURCE #endif // __APPLE__ #endif // BC_TEST_APPLE diff --git a/contrib/bc/include/vector.h b/contrib/bc/include/vector.h index b86be1424537..cad5fc2aa7c3 100644 --- a/contrib/bc/include/vector.h +++ b/contrib/bc/include/vector.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/include/version.h b/contrib/bc/include/version.h index e2576269345d..586691a6e7ef 100644 --- a/contrib/bc/include/version.h +++ b/contrib/bc/include/version.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: @@ -37,6 +37,6 @@ #define BC_VERSION_H /// The current version. -#define VERSION 6.7.5 +#define VERSION 6.7.6 #endif // BC_VERSION_H diff --git a/contrib/bc/include/vm.h b/contrib/bc/include/vm.h index c56cc8e7370a..052c1d14c237 100644 --- a/contrib/bc/include/vm.h +++ b/contrib/bc/include/vm.h @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: BSD-2-Clause * - * Copyright (c) 2018-2023 Gavin D. Howard and contributors. + * Copyright (c) 2018-2024 Gavin D. Howard and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: @@ -493,7 +493,7 @@ #define BC_VM_SAFE_RESULT(r) ((r)->t >= BC_RESULT_TEMP) /// The invalid locale catalog return value. -#define BC_VM_INVALID_CATALOG ((nl_catd) -1) +#define BC_VM_INVALID_CATALOG ((nl_catd) - 1) /** * Returns true if the *unsigned* multiplication overflows. @@ -791,8 +791,9 @@ bc_vm_info(const char* const help); * The entrance point for bc/dc together. * @param argc The count of arguments. * @param argv The argument array. + * @return A status. */ -void +BcStatus bc_vm_boot(int argc, char* argv[]); /** @@ -1045,8 +1046,9 @@ bc_vm_fatalError(BcErr e); * A function to call at exit. * @param status The exit status. */ -int -bc_vm_atexit(int status); +BcStatus +bc_vm_atexit(BcStatus status); + #endif // BC_ENABLE_LIBRARY /// A reference to the copyright header. diff --git a/contrib/bc/locales/de_DE.ISO8859-1.msg b/contrib/bc/locales/de_DE.ISO8859-1.msg index 858a3946e8f8..9700ab070b2c 100644 --- a/contrib/bc/locales/de_DE.ISO8859-1.msg +++ b/contrib/bc/locales/de_DE.ISO8859-1.msg @@ -1,7 +1,7 @@ $ $ $ SPDX-License-Identifier: BSD-2-Clause $ $ -$ Copyright (c) 2018-2023 Gavin D. Howard and contributors. +$ Copyright (c) 2018-2024 Gavin D. Howard and contributors. $ $ $ Redistribution and use in source and binary forms, with or without $ modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/locales/de_DE.UTF-8.msg b/contrib/bc/locales/de_DE.UTF-8.msg index 25be4fd79cb9..7b918fc6d1cd 100644 --- a/contrib/bc/locales/de_DE.UTF-8.msg +++ b/contrib/bc/locales/de_DE.UTF-8.msg @@ -1,7 +1,7 @@ $ $ $ SPDX-License-Identifier: BSD-2-Clause $ $ -$ Copyright (c) 2018-2023 Gavin D. Howard and contributors. +$ Copyright (c) 2018-2024 Gavin D. Howard and contributors. $ $ $ Redistribution and use in source and binary forms, with or without $ modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/locales/en_US.msg b/contrib/bc/locales/en_US.msg index 5610496d6e71..4afcbcd1f813 100644 --- a/contrib/bc/locales/en_US.msg +++ b/contrib/bc/locales/en_US.msg @@ -1,7 +1,7 @@ $ $ $ SPDX-License-Identifier: BSD-2-Clause $ $ -$ Copyright (c) 2018-2023 Gavin D. Howard and contributors. +$ Copyright (c) 2018-2024 Gavin D. Howard and contributors. $ $ $ Redistribution and use in source and binary forms, with or without $ modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/locales/es_ES.ISO8859-1.msg b/contrib/bc/locales/es_ES.ISO8859-1.msg index 3bf70753559e..4d022d9bf664 100644 --- a/contrib/bc/locales/es_ES.ISO8859-1.msg +++ b/contrib/bc/locales/es_ES.ISO8859-1.msg @@ -1,7 +1,7 @@ $ $ $ SPDX-License-Identifier: BSD-2-Clause $ $ -$ Copyright (c) 2018-2023 Gavin D. Howard and contributors. +$ Copyright (c) 2018-2024 Gavin D. Howard and contributors. $ $ $ Redistribution and use in source and binary forms, with or without $ modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/locales/es_ES.UTF-8.msg b/contrib/bc/locales/es_ES.UTF-8.msg index 0a5cf26d1621..364cff6ee57f 100644 --- a/contrib/bc/locales/es_ES.UTF-8.msg +++ b/contrib/bc/locales/es_ES.UTF-8.msg @@ -1,7 +1,7 @@ $ $ $ SPDX-License-Identifier: BSD-2-Clause $ $ -$ Copyright (c) 2018-2023 Gavin D. Howard and contributors. +$ Copyright (c) 2018-2024 Gavin D. Howard and contributors. $ $ $ Redistribution and use in source and binary forms, with or without $ modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/locales/fr_FR.ISO8859-1.msg b/contrib/bc/locales/fr_FR.ISO8859-1.msg index f2e07e02b2dc..b4b39866c96e 100644 --- a/contrib/bc/locales/fr_FR.ISO8859-1.msg +++ b/contrib/bc/locales/fr_FR.ISO8859-1.msg @@ -1,7 +1,7 @@ $ $ $ SPDX-License-Identifier: BSD-2-Clause $ $ -$ Copyright (c) 2018-2023 Gavin D. Howard and contributors. +$ Copyright (c) 2018-2024 Gavin D. Howard and contributors. $ $ $ Redistribution and use in source and binary forms, with or without $ modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/locales/fr_FR.UTF-8.msg b/contrib/bc/locales/fr_FR.UTF-8.msg index 1e9e900746a5..c3387e31ae9f 100644 --- a/contrib/bc/locales/fr_FR.UTF-8.msg +++ b/contrib/bc/locales/fr_FR.UTF-8.msg @@ -1,7 +1,7 @@ $ $ $ SPDX-License-Identifier: BSD-2-Clause $ $ -$ Copyright (c) 2018-2023 Gavin D. Howard and contributors. +$ Copyright (c) 2018-2024 Gavin D. Howard and contributors. $ $ $ Redistribution and use in source and binary forms, with or without $ modification, are permitted provided that the following conditions are met: diff --git a/contrib/bc/locales/ja_JP.UTF-8.msg b/contrib/bc/locales/ja_JP.UTF-8.msg index d871e9bf6ad2..21640eb9f1cb 100644 --- a/contrib/bc/locales/ja_JP.UTF-8.msg +++ b/contrib/bc/locales/ja_JP.UTF-8.msg @@ -1,7 +1,7 @@ $ $ $ SPDX-License-Identifier: BSD-2-Clause *** 23592 LINES SKIPPED *** From nobody Tue Jul 16 19:17:45 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNpk21r94z5Rp3Z; Tue, 16 Jul 2024 19:17: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNpk219Zkz41QX; Tue, 16 Jul 2024 19:17:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721157466; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=9Q1I72ln81V8Mew8u4dYyWVSfdhSOcLpypEuL/cr9Tw=; b=eNTrRGiSf2hV96w4+75+XkjPQcOWBtzt6l3Xx4B+NBO8Hdx3N4kz5EYQwdAkNzLapZndrh KaDPe6IBJvRSbS6+RJlhypc31UZkmSzMcPrUs6YL7eWfvuiXa+WVQCSafsDATESnF9vEM1 9A9ba+0Z2iz5H8x4SawY5Gwjj6oYMvBCL/C9Hl5wEUQGwg8xlUBlqa4qvy5reP2Wp13e7S 91PJy3enRV8Ga6nMGzQUCIuhnfSPbCI74GzDi4JboSQ8cVsUUnQ30VdVcSWDRgruU/mkSM DY6DDnkplba68cu6Zz3Putg7108rdN9qVLwMJvpyM54k5Digi58zw1ApMeARCA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721157466; a=rsa-sha256; cv=none; b=yIodWv7nZfnv4jY+sCAJwvI5XPvpCqxd02GPXyafVNn6RFZYHxC2xXY2/nkGgWI48k3hcE oi9P7WU5AwYsFJQo7DXtWd7xyx2cOIaKZye/jjR9FyTsYWBsAlWZJOTugxNFY6j+Z9TjXd MtuzeGdGCk5V6cI175owvwasfjBt8Q3faVr+7kvZPKgZyOr6d+Osbrto0ruxip98zjLJgT rYHH9/CfLHIjCCv0SXPfyqI41HmS+uV1PsvYqyvyfBIN9rgNMa19hNNUPZK4+NiiFPHGKx 8TIYKW/jbFftJIfq3cvPkgQpWrDGIzRNLzGILIS4V1HnycUHFoT28uA8Yi+DbA== 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=1721157466; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=9Q1I72ln81V8Mew8u4dYyWVSfdhSOcLpypEuL/cr9Tw=; b=FqCLmWjgGK+zVHyBitbiD5FgY6Hxn/DejQF3SQPM/aBqfoTRJkqnwj9gWwZGpj22J3fh1e /1uZKnferdOZjpXFQoeKJjHWsOftNvaH12ZdrT0TUzbh8EY1+K0vx4ngLXwU3NTHewHtUg 0cpGdPpPikiA7SLSTM/L33hC6DWNsjcca5V7teSTZ3IUmCENNVoEJqYUlG2xBcmugDq8fZ +5Ar5wI/McEm1qwpBeDzQRcMtAiUgxueOdBxHmcTDeORqGpLdim3gJXXn74Cd4RdBIpOSC wGYQU6pEEb78wdNQmIcZf8gve/MTZ38ypjNSVWkcIu/lYQyjpEMLu06tIxw8Fg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNpk20ZVPzpSH; Tue, 16 Jul 2024 19:17:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46GJHjZl081590; Tue, 16 Jul 2024 19:17:45 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46GJHjMk081587; Tue, 16 Jul 2024 19:17:45 GMT (envelope-from git) Date: Tue, 16 Jul 2024 19:17:45 GMT Message-Id: <202407161917.46GJHjMk081587@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: afd67a167799 - main - etcupdate(8): improve phrasing List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: emaste X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: afd67a1677999b0f9d82d29bfd7c767f665e76e8 Auto-Submitted: auto-generated The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=afd67a1677999b0f9d82d29bfd7c767f665e76e8 commit afd67a1677999b0f9d82d29bfd7c767f665e76e8 Author: Ed Maste AuthorDate: 2024-07-16 01:44:11 +0000 Commit: Ed Maste CommitDate: 2024-07-16 19:17:31 +0000 etcupdate(8): improve phrasing Reported by: igor(1) --- usr.sbin/etcupdate/etcupdate.8 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/usr.sbin/etcupdate/etcupdate.8 b/usr.sbin/etcupdate/etcupdate.8 index 22d3d91bb6eb..bf7ddb792907 100644 --- a/usr.sbin/etcupdate/etcupdate.8 +++ b/usr.sbin/etcupdate/etcupdate.8 @@ -485,7 +485,7 @@ as additional parameters to when building a .Dq current tree. -This can be used for to set the +This can be used to set the .Dv TARGET or .Dv TARGET_ARCH From nobody Tue Jul 16 20:01:14 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNqhB56phz5Rs8p; Tue, 16 Jul 2024 20:01: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNqhB4cM9z46Kv; Tue, 16 Jul 2024 20:01:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721160074; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=/UQ1vE8oGBFeYSm+RUEvk/wNIcnjgx2RFmHM2jWrff4=; b=hjGWwdMKhtOgmNxE8qSjePScBuySifwpwqGKkLG5lih6mzBpewlHRM6K4i/ZJO6FYMzNP6 uxknhzAbpNISkWo26OyGR5aA8STI0qliEDjKL4MdlzdANEtKejcuZ068iQb8jRzXifa0G5 tDWKu+ackQtQ5fUozMoLOi2V+XAshV/ZsxCp/FG2ZyMa+jOP0e3ZrBRqlbMTSkoFkXN2Wr NdF3f63HB0h+lThrt42ztP7Hoahv8dsXb5Qrrup4UOWb3OgLHYAZX7D4GEnt93u5Hw8nE3 LSJ4nB+GmP9hjohwf9SbQL2B4qFrtuPQJInDEFHZ8ctoEWDdKII862X1FtIWcw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721160074; a=rsa-sha256; cv=none; b=Sed3cu1r/8J2h0BIK/O3R52CZJnGeUQ+HgB4G2AVFLNdMw9cV0CsKKZO6DezYRCnWqaYBy 8kvvxuK6WP/2WoTf9S1fl3i+M2HF5Z87jORJfC0DofY5DtpK8jQ4zzitHXcp6T2RmgMzSn OZZXCC+bYc+uU5y5U73p1DJF2CT/iI0T1iiunM61Q05KfIFVPvEENHKohNg91pX9IzcWuE ufFtdgvj/4jc/ks+er12bRRH26bb2Jr+ptKjLZjbHABzCNLYkChOZdCx12Ysk4/uI2WlEW DZUUvElVLvJYVCxCtnDvBqI0/1v78bT5YLSGqgsIm7+qHOf6kYA3lWlnemkxiQ== 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=1721160074; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=/UQ1vE8oGBFeYSm+RUEvk/wNIcnjgx2RFmHM2jWrff4=; b=VT0dGhmmbib5tdYb9YRAFD9YyefQM5DVhmyQxTv+k2VbsW2VbU0MbB7qE2Ljpw8+5mTqzY HU8yiHN1EJ4K/ecOznVE7u4lwWyd9uve3aVj3q0TY1ozHRdXvH7OSiegDQ0se+t4IeE4g5 PgbDGjvhytLzrsMpIig+z6t5RSjNFzzqlXZWcsxa6sTkoO7a5fejfMkwOlLHPrXhbjdSdl 9UbNrj3OYZErzmneXClQpKah/QdH3CTbZv0AQZ1KPZojwu80h2g4aSKAm7/Amls7asIjCA BJWnsFNG19hInKlRAs+VF2oBhVIdapf9WK8gDdXmlX+KHK1HW+VOJU+9ffc7KA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNqhB4Cw1zqRR; Tue, 16 Jul 2024 20:01:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46GK1E9O060934; Tue, 16 Jul 2024 20:01:14 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46GK1EJi060931; Tue, 16 Jul 2024 20:01:14 GMT (envelope-from git) Date: Tue, 16 Jul 2024 20:01:14 GMT Message-Id: <202407162001.46GK1EJi060931@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Kenneth D. Merry" Subject: git: 4c0c82355692 - stable/13 - isp(4): Document support for new devices List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: ken X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 4c0c82355692753cf10c35b893fe4b8a01a08e12 Auto-Submitted: auto-generated The branch stable/13 has been updated by ken: URL: https://cgit.FreeBSD.org/src/commit/?id=4c0c82355692753cf10c35b893fe4b8a01a08e12 commit 4c0c82355692753cf10c35b893fe4b8a01a08e12 Author: Joerg Pulz AuthorDate: 2023-07-07 21:43:34 +0000 Commit: Kenneth D. Merry CommitDate: 2024-07-16 19:59:40 +0000 isp(4): Document support for new devices Add 28xx based HBAs to manpage. PR: 271062 Reviewed by: imp, mav Sponsored by: Technical University of Munich Pull Request: https://github.com/freebsd/freebsd-src/pull/726 (cherry picked from commit 2b4ccfbbc65b2f140fab6db998e9654c5c2bb972) --- share/man/man4/isp.4 | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/share/man/man4/isp.4 b/share/man/man4/isp.4 index 810d1ce4650c..350a0ea59a64 100644 --- a/share/man/man4/isp.4 +++ b/share/man/man4/isp.4 @@ -106,6 +106,14 @@ Optical 16Gb FC/FCoE PCIe cards. Optical 16Gb Fibre Channel PCIe cards. .It Qlogic 2740/2742/2764 (aka 2722/2714) Optical 32Gb Fibre Channel PCIe cards. +.It Qlogic QLE2770/QLE2772 (aka 2812) +Optical 32Gb Fibre Channel PCIe cards. +.It Qlogic QLE2774 (aka 2814) +Optical 32Gb Fibre Channel PCIe cards. +.It Qlogic QLE2870/QLE2872 (aka 2812) +Optical 64Gb Fibre Channel PCIe cards. +.It Qlogic QLE2874 (aka 2814) +Optical 64Gb Fibre Channel PCIe cards. .El .Sh CONFIGURATION OPTIONS Target mode support for Fibre Channel adapters may be enabled with the From nobody Tue Jul 16 20:08:14 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNqrH0gXwz5Q8Qm; Tue, 16 Jul 2024 20:08: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNqrH05Ppz470b; Tue, 16 Jul 2024 20:08:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721160495; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=xjKnXAhQm7MvQI+pMTJ4Ab6QLrikryGQh8LUeRTtqwg=; b=NJyWyNG5IDLsScvKqYZ/H7XCDkcvjgdxmCuSGz3lF0W/rVlyJJATPXoZudjaAeEpMQSYjn S6cmCe5Ib7Vm8dpCV8Ef8Dh+kU5+RXXqsV/z3qe/S1YRQEpouRBY8BVRevcerJr+VA3kWJ VYqcAsc3c+jJUvVrws481RILCt7mdRZi7qMqmDiX9WN2UnWYZmYCwd4IapwyKsX+cPDKPp lIoo3yS+pCnRG+lTg/u2KxfteqOMumHizLwhRfdhhkG/UUuoX7Vk6BjjYFrsbfQCaj2uA9 L5/vW8srQ+srzrvj2SQtTHOjbFiGR5Q9FmBudtjgQfFn4bTJ15nlgzULr3A4vQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721160495; a=rsa-sha256; cv=none; b=RI1CL9NGiNAg2Bft8DsVmicxUZBc0G/ZJLQuR9TOc9WAu71taCmnmvW0Wdlg7Kb3/msWGb PLeTGdX4AEEcbaoR1bQ6K/1o45SGjQM/BsMXeSMsKukX2ery6O1/7s7LkazO2fjBm/v+PK D3ViFYktkn+vg0JyC8FQTko3JjJV/b02jy5ZxFqQyOD6Jfc8OlvBrWEFXyHpo3drE1YSKD 0tRuyGtlQ3xWwQ8LH8+6qIbZwr/IDSjxQOvsafMAO2t+3xygxHpDUMCejJpMrDoK/7g+MI hQrYP+H1mpuIQACODbUZNaukL+sHz0GGPIZRal8ixl8l61ZxUkgzAkvV6MP2KA== 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=1721160495; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=xjKnXAhQm7MvQI+pMTJ4Ab6QLrikryGQh8LUeRTtqwg=; b=dxaIOmZnDe12eQoEfZwuK5DuJW/yoat2gP/MKjgyTSsVNtf2k17ZYla0yycLbTPHTfxH6Q wBX3Al4SBWMQBiC3G1EUYaZTC1IIQfJ3NVFeJ92mP5NI6heRKex8CPOY2hWKhgMP37SHit vR9iPPMc/0uB0SeO0J6uW8Ebq4CkRzuqE2hnM2ZUPUh91kkn9nHZPagXcGWOKoBgOaWwBE yJtzYKgsEHRBArsJq9+WofeSRgKeHRQOA/D7VoNZ8Mzd47efXzrhjHWQG/2pv7XRLmjFK1 eJOJfUrCb7BEE/5N2UMO2neTHc60twDcDZjSqFSALDIvTWkNqY1IQ4yDiMh3KQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNqrG6pRBzqVF; Tue, 16 Jul 2024 20:08:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46GK8E5n067496; Tue, 16 Jul 2024 20:08:14 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46GK8Elk067493; Tue, 16 Jul 2024 20:08:14 GMT (envelope-from git) Date: Tue, 16 Jul 2024 20:08:14 GMT Message-Id: <202407162008.46GK8Elk067493@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Kenneth D. Merry" Subject: git: ff9458b30fc3 - stable/14 - Fix the isp(4) driver with 9.x firmware. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: ken X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: ff9458b30fc3b8748f65eca792be7b6e64c639bf Auto-Submitted: auto-generated The branch stable/14 has been updated by ken: URL: https://cgit.FreeBSD.org/src/commit/?id=ff9458b30fc3b8748f65eca792be7b6e64c639bf commit ff9458b30fc3b8748f65eca792be7b6e64c639bf Author: Kenneth D. Merry AuthorDate: 2024-06-21 19:30:59 +0000 Commit: Kenneth D. Merry CommitDate: 2024-07-16 20:04:29 +0000 Fix the isp(4) driver with 9.x firmware. The isp(4) driver (and ispfw(4) firmware) previously only included firmware for Qlogic controllers up to 8Gb. It recently gained firmware for the 27XX and 28XX series controllers along with improved firmware loading capabilities. The 9.x firmware available for the 27XX and 28XX controllers in ispfw(4) adds login state for NVMe devices in the top nibble of the login state in the port database (isp_pdb_24xx_t in ispmbox.h). This breaks the check at the end of isp_getpdb() to make sure the device is in the right login state. As a result, it breaks device discovery for many (perhaps all?) FC devices. In my testing with IBM LTO-6 drives attached to a quad port 16Gb Qlogic 2714, they don't show up when they are directly connected (and in loop mode) or connected via a switch (and in fabric mode). So, mask off the top bits of of the login state before checking it. This shouldn't break anything, because all of the existing login states defined in ispmbox.h are in the low nibble. sys/dev/isp/ispmbox.h: Add a FCP login state mask define, and a NVMe login state shift. sys/dev/isp/isp.c: In isp_getpdb(), make sure we're only looking at the FCP login state bits when we try to determine whether a device is in the right login state. MFC after: 1 week Sponsored by: Spectra Logic Reviewed by: mav Differential Revision: (cherry picked from commit 137b004e2b7ab504abf98c4aad9d52607df47b9a) --- sys/dev/isp/isp.c | 10 +++++++++- sys/dev/isp/ispmbox.h | 6 ++++++ 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/sys/dev/isp/isp.c b/sys/dev/isp/isp.c index ad6dbd1e6f76..7246ea8031ac 100644 --- a/sys/dev/isp/isp.c +++ b/sys/dev/isp/isp.c @@ -1539,7 +1539,15 @@ isp_getpdb(ispsoftc_t *isp, int chan, uint16_t id, isp_pdb_t *pdb) chan, id, pdb->portid, un.bill.pdb_flags, un.bill.pdb_curstate, un.bill.pdb_laststate); - if (un.bill.pdb_curstate < PDB2400_STATE_PLOGI_DONE || un.bill.pdb_curstate > PDB2400_STATE_LOGGED_IN) { + /* + * XXX KDM this is broken for NVMe. Need to determine whether this + * is an NVMe target, and if so, check the NVMe status bits. We are + * probably missing more bits for proper NVMe support, though. + */ + if (((un.bill.pdb_curstate & PDB2400_STATE_FCP_MASK) < + PDB2400_STATE_PLOGI_DONE) + || ((un.bill.pdb_curstate & PDB2400_STATE_FCP_MASK) > + PDB2400_STATE_LOGGED_IN)) { mbs.param[0] = MBOX_NOT_LOGGED_IN; return (mbs.param[0]); } diff --git a/sys/dev/isp/ispmbox.h b/sys/dev/isp/ispmbox.h index c6ac9d9ce971..978ed4dc1638 100644 --- a/sys/dev/isp/ispmbox.h +++ b/sys/dev/isp/ispmbox.h @@ -890,6 +890,10 @@ typedef struct { #define PDB2400_CLASS2 0x0010 #define PDB2400_ADDR_VALID 0x0002 +/* + * For NVMe, the state is the high nibble. For FCP, the state is the low + * nibble. This appears to have changed with the 9.x firmware. + */ #define PDB2400_STATE_PLOGI_PEND 0x03 #define PDB2400_STATE_PLOGI_DONE 0x04 #define PDB2400_STATE_PRLI_PEND 0x05 @@ -897,6 +901,8 @@ typedef struct { #define PDB2400_STATE_PORT_UNAVAIL 0x07 #define PDB2400_STATE_PRLO_PEND 0x09 #define PDB2400_STATE_LOGO_PEND 0x0B +#define PDB2400_STATE_FCP_MASK 0x0f +#define PDB2400_STATE_NVME_SHIFT 4 /* * Common elements from the above two structures that are actually useful to us. From nobody Tue Jul 16 20:08:15 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNqrJ1Jrnz5RsDd; Tue, 16 Jul 2024 20:08: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNqrJ0cXMz47B0; Tue, 16 Jul 2024 20:08:16 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721160496; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=sZHaKssqKje5xGf/A36I8hwB5loS6KU17s4EZf/7i4s=; b=XzbXyvUKOfY7NaOhMcnncM/kmC8VHietyTRmmsiAEtgoyM2T85eXNY3t0vS8dtJ6N8dX02 9qet/dB2hcqinBxbx6WWPh47aqfaN+bj8I7fPfNcsJfkcqIFRqezHCtoLSpxkaHuaV+N6y Dc5cGk5cxifQZiyofw1vczPxxTpkpUsC4yTf5NsMLnsQDW7sKpcrnu2dBvSzA6drlGDRO+ hIHuJA8CAUulbLDcKj3+Q8KSt1Kxzz9yBn7PWtegXDxHbP/5sm7OHhUHpjb7NgemETkHAA KNYRMnrfWy5p5Jcz5RFbwuZfIhiuI80OzZDWzkqn1XE5eE0auqkz890N1xxmbw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721160496; a=rsa-sha256; cv=none; b=VLasMT/Vgwbd/g+h8pJ8XUDs6WmE2aQi8UB0fkrYZoPMLegR/MbchCTF4S6/W8lxNKrIQW 61ebTXHGLBKTZrXB23RFBUsS9B3YLeJJQK5D7MtrweUNg2xP3gPsl/sCfk1nYyCP7nUK/d baP30UjiwTVNslC4xqvECUU6prfUbIo/chDBaSBqsMRhYy/5q/DOz3B4j+Dr0X4bvDek4r BRTQf+o3NDHv4f5sOUbHV0XWbtSXubLpCttLRqr/I7IiEXobOhRUYpTh/einnTYlu9IDyo fQeAFmTXcozRyaN4E/TEBhJ7BftwdDZeQVDGCK/i7kg1yLU+HPgoXOj5dhlBvw== 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=1721160496; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=sZHaKssqKje5xGf/A36I8hwB5loS6KU17s4EZf/7i4s=; b=roEJYvHHreDqepW4wOS6gmiGeiwHBVA0C/W9PtN8EOLMIlsGBDI8wwCUa/yirniMrKjhbX xk47ykuqmMxDTyiADhYJv2LJCXFHyqpX28OJ0BDsOWk43qCeDZmcfFzAlyN68tbXtdXqIq MqDb/nIpicjFLdy/oX0FLjBj0gFfIVgMhdHa5EoTdcZf3SpV5CHvowrCvexwr02rJsQW9L IkikdiVLo3PG+orDA2zXO3ad28r5Pd7hFHrOOEeIErQ7EG2zkL0cqZRPzxIHT5RwYWhKX5 vff1+puUsRDMGhqaOZy/0INc53kNQsTCjeMPnXtFurLdThcR4tLnSfO0phBb3Q== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNqrJ0BcmzqkR; Tue, 16 Jul 2024 20:08:16 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46GK8FCD067559; Tue, 16 Jul 2024 20:08:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46GK8FPI067556; Tue, 16 Jul 2024 20:08:15 GMT (envelope-from git) Date: Tue, 16 Jul 2024 20:08:15 GMT Message-Id: <202407162008.46GK8FPI067556@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Kenneth D. Merry" Subject: git: 44ca5d40f367 - stable/14 - Add an isp(4) tunable to default to ispfw(4) firmware. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: ken X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 44ca5d40f36704ffa2fa55f8f1403c824400b3ba Auto-Submitted: auto-generated The branch stable/14 has been updated by ken: URL: https://cgit.FreeBSD.org/src/commit/?id=44ca5d40f36704ffa2fa55f8f1403c824400b3ba commit 44ca5d40f36704ffa2fa55f8f1403c824400b3ba Author: Kenneth D. Merry AuthorDate: 2024-06-24 19:42:41 +0000 Commit: Kenneth D. Merry CommitDate: 2024-07-16 20:06:39 +0000 Add an isp(4) tunable to default to ispfw(4) firmware. ispfw(4) recently gained firmware for Qlogic 27XX and 28XX FC controllers, and isp(4) now selects the newer of firmware in flash or in ispfw(4) to load for those controllers. This differs from the previous behavior (which remains for older controllers), which was to always load the ispfw(4) firmware if it is available. This adds a loader tunable, hint.isp.N.fwload_force to default to loading the ispfw(4) firmware, whether or not it is newer than the firmware in flash. This allows the user to always use the known firmware version included with the kernel. Note that there is an existing fwload_disable tunable that tells the driver to always load the firmware from flash and ignore ispfw(4). If fwload_disable is set, fwload_force will be ignored. So users with existing fwload_disable tunables will have the same behavior. If a user specifies both fwload_force and fwload_disable for the same controller, the isp(4) driver prints a warning message, and fwload_disable will be honored. The user can see which firmware is active through the dev.isp.N.fw_version* sysctl variables. share/man/man4/isp.4: Document the new loader tunable. sys/dev/isp/isp.c: In isp_load_risc_flash(), changet the decision logic to also consider ISP_CFG_FWLOAD_ONLY. Load the flash firmware and get the version, so the user knows what it is, but if the user set fwload_force, honor that. If the user didn't set fwload_force, the behavior remains to select the newer firmware version. sys/dev/isp/isp_pci.c: Add a new fwload_force tunable. Print out a warning if the user sets both fwload_disable and fwload_force. sys/dev/isp/ispvar.h: Add a new ISP_CFG_FWLOAD_FORCE configuration bit. Reviewed by: mav MFC after: 1 week Sponsored by: Spectra Logic Differential Revision: (cherry picked from commit 31354813f3c6e87532189be77c2f10a017c55472) --- share/man/man4/isp.4 | 17 ++++++++++++++++- sys/dev/isp/isp.c | 18 +++++++++++++++++- sys/dev/isp/isp_pci.c | 9 +++++++++ sys/dev/isp/ispvar.h | 1 + 4 files changed, 43 insertions(+), 2 deletions(-) diff --git a/share/man/man4/isp.4 b/share/man/man4/isp.4 index 350a0ea59a64..dc6a6dbd5d2b 100644 --- a/share/man/man4/isp.4 +++ b/share/man/man4/isp.4 @@ -24,7 +24,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.Dd October 27, 2023 +.Dd June 24, 2024 .Dt ISP 4 .Os .Sh NAME @@ -141,6 +141,21 @@ Limit on number of Extended Message Signaled Interrupts (MSI-X) to be used. .It Va hint.isp. Ns Ar N Ns Va .fwload_disable A hint value to disable loading of firmware provided by .Xr ispfw 4 . +.It Va hint.isp. Ns Ar N Ns Va .fwload_force +A hint value to prefer firmware provided by +.Xr ispfw 4 , +even if it is older than the firmware in flash on the board. +If fwload_disable is also specified, fwload_force will be ignored. +.Pp +By default, with 27XX and newer controllers, the +.Xr isp 4 +driver will use the newer +firmware. +For older controllers, the +.Xr isp 4 +driver will use the firmware provided by +.Xr ispfw 4 +if it is available, and otherwise use the firmware in flash on the board. .It Va hint.isp. Ns Ar N Ns Va .ignore_nvram A hint value to ignore board NVRAM settings for. Otherwise use NVRAM settings. diff --git a/sys/dev/isp/isp.c b/sys/dev/isp/isp.c index 7246ea8031ac..14d8147c3562 100644 --- a/sys/dev/isp/isp.c +++ b/sys/dev/isp/isp.c @@ -457,7 +457,10 @@ isp_reset(ispsoftc_t *isp, int do_load_defaults) if (IS_27XX(isp)) { switch (isp_load_risc(isp, 0)) { case ISP_ABORTED: - /* download ispfw(4) as it's newer than flash */ + /* + * download ispfw(4) as it's newer than flash, or + * the user requested it. + */ dodnld = 1; break; case ISP_SUCCESS: @@ -5223,7 +5226,20 @@ isp_load_risc_flash(ispsoftc_t *isp, uint32_t *srisc_addr, uint32_t faddr) /* If ispfw(4) is loaded compare versions and use the newest */ if (isp->isp_osinfo.ispfw != NULL) { + int ispfw_newer = 0; + if (ISP_FW_NEWER_THANX(fcp->fw_ispfwrev, fcp->fw_flashrev)) { + ispfw_newer = 1; + } + + if (isp->isp_confopts & ISP_CFG_FWLOAD_FORCE) { + isp_prt(isp, ISP_LOGCONFIG, + "Loading RISC with %s ispfw(4) firmware %s", + (ispfw_newer == 0) ? "older" : "newer", + "because fwload_force is set"); + return (ISP_ABORTED); + } + if (ispfw_newer != 0) { isp_prt(isp, ISP_LOGCONFIG, "Loading RISC with newer ispfw(4) firmware"); return (ISP_ABORTED); diff --git a/sys/dev/isp/isp_pci.c b/sys/dev/isp/isp_pci.c index 707f85cc38e7..be99a7ee5428 100644 --- a/sys/dev/isp/isp_pci.c +++ b/sys/dev/isp/isp_pci.c @@ -291,6 +291,15 @@ isp_get_generic_options(device_t dev, ispsoftc_t *isp) isp->isp_confopts |= ISP_CFG_NORELOAD; } tval = 0; + if (resource_int_value(device_get_name(dev), device_get_unit(dev), "fwload_force", &tval) == 0 && tval != 0) { + isp->isp_confopts |= ISP_CFG_FWLOAD_FORCE; + } + if ((isp->isp_confopts & (ISP_CFG_NORELOAD|ISP_CFG_FWLOAD_FORCE)) == + (ISP_CFG_NORELOAD|ISP_CFG_FWLOAD_FORCE)) { + device_printf(dev, "WARNING: both fwload_disable and " + "fwload_force set, ispfw(4) loading disabled\n"); + } + tval = 0; if (resource_int_value(device_get_name(dev), device_get_unit(dev), "ignore_nvram", &tval) == 0 && tval != 0) { isp->isp_confopts |= ISP_CFG_NONVRAM; } diff --git a/sys/dev/isp/ispvar.h b/sys/dev/isp/ispvar.h index 6c3430246b29..abb712a395c1 100644 --- a/sys/dev/isp/ispvar.h +++ b/sys/dev/isp/ispvar.h @@ -612,6 +612,7 @@ struct ispsoftc { #define ISP_CFG_16GB 0x8000 /* force 16Gb connection (26XX only) */ #define ISP_CFG_32GB 0x10000 /* force 32Gb connection (27XX only) */ #define ISP_CFG_64GB 0x20000 /* force 64Gb connection (28XX only) */ +#define ISP_CFG_FWLOAD_FORCE 0x40000 /* Prefer ispfw(4) even if older */ /* * For each channel, the outer layers should know what role that channel From nobody Tue Jul 16 20:19:04 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNr4r2WtVz5Q9SS; Tue, 16 Jul 2024 20:19:08 +0000 (UTC) (envelope-from glebius@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNr4r209cz49X5; Tue, 16 Jul 2024 20:19:08 +0000 (UTC) (envelope-from glebius@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721161148; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=kh1a91itd20Zg/y/ZUW2AeWOcBfItErMltGS6TmU2yQ=; b=whAsJzF6FtTZDKelFXWjpHa/Ym+nIfWIvFqpvc5msxIT6gREjj8It/j/T/8Mm5XggQ/8OC 3f8GvUl/IRUc8A2kSsNLYL52uUgod16ZQ5hjEtbI0iLTV5ld+1naeVktm6jg2ivY8UPmnS bZOjtwDa6gniT8BUTn3WQzuYX8sXZZ8/uHi3dV1ibxvSlRw+ZUXhT0T9Y7qq4gTEu+yvlT 540JkWgphBQBPvfLMowGR987Y2K+F265XnWcTBauavTJubsNruUQTbqU6zVcLp90DYSnhM uXrKrGtDDSWBnLu5T55ZISPJu/xQAmZtMw6zEWn4WpyRKQ28RTrqNagq9JYUbA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721161148; a=rsa-sha256; cv=none; b=G7JFT1FIyibSsYlrXvSabUptsbIexXtMTNpOSPVF1V6fbjHkvbRv9bb1br+eMFOP507LbI mdff6Ipmr7qYW0oDzHqaGUqipQg337yj7VTWMv0gGaqiy/m3LtbnU1RzMxpLKEvWwoyKkk LldqT6QteriERttyqyBI/Su9M4mE4fDoVW7smEwGwy0+s8bgUYbS7dx0Mt/93OqeihV0pi 7ALrPjUze2btP1nLIwdX/1dDGh/OfYdWT0WxgPiJnbMXVqmiSPHlAIamrDDFapb2UrlI50 vpr0rqaXuiS672s8Czpo7k/V3jEqxFvqrSOhfz9/Is0K4jSHWw4DCxdixkshvg== 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=1721161148; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=kh1a91itd20Zg/y/ZUW2AeWOcBfItErMltGS6TmU2yQ=; b=VWmfphwF5lNQiG2U/swQ83XK+5SVXwHI/YMZVc5JCLkYDn/6KHTu8lZNsOQfvkSBn6sX5Q xriGsqS29hSRtpuN/rchmqBVcMQW3ZChJrC59Kctjo3QB7ddiYjWqnOf04kFbYtOGQuPFc ociDnkKyPDX/ww65fE+x8z3qTBUInSGb79sBUIO88rYLf4pKud8tow0vyEZ2Rqo/y6/f8M QhVvKTuMLzP4fZemlLSX5lOFXFYqe6NhP5gsL4+7lp7YkOCdz4/56JhXXemfTwCcEKhg41 2rsCvOFbVOYpOepUWLsZkVow1Y4CneYaG9fBeCpEGur5NIE4hvg/I+F7hmdhmg== Received: from cell.glebi.us (glebi.us [162.251.186.162]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: glebius) by smtp.freebsd.org (Postfix) with ESMTPSA id 4WNr4q2mn8zjJp; Tue, 16 Jul 2024 20:19:07 +0000 (UTC) (envelope-from glebius@freebsd.org) Date: Tue, 16 Jul 2024 13:19:04 -0700 From: Gleb Smirnoff To: Mateusz Guzik Cc: John Baldwin , Mateusz Guzik , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Subject: Re: git: 87ee63bac69d - main - locks: add a runtime check for missing turnstile Message-ID: References: <202407111107.46BB7uSb007077@gitrepo.freebsd.org> <81cfe7ad-cbee-4122-abef-e47ce2b34f05@FreeBSD.org> List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Mateusz, On Mon, Jul 15, 2024 at 07:59:42PM +0200, Mateusz Guzik wrote: M> > > locks: add a runtime check for missing turnstile M> > > M> > > There are sometimes bugs which result in the unlock fast path failing, M> > > which in turns causes a not-helpful crash report when dereferencing a M> > > NULL turnstile. Help debugging such cases by pointing out what happened M> > > along with some debug. M> > > M> > > Sponsored by: Rubicon Communications, LLC ("Netgate") I am quite surprised to see such commit from you. You are known to cut a few instruction branches even pessimizing other people setups (yeah, talking about commits like 5091ca26507b), and now you are adding an absolutely useless branch for literally everyone. The fingerprint of the non-INVARIANTS panic for a destroyed or already unlocked mutex/rwlock is well known to anybody who has been hacking on the FreeBSD kernel for the last 20 years. I am very much surprised it is not familiar to you. The sample panic quoted below just immediately rings the bell for me, and giving feedback on this commit for many people, too. Please revert this. Here is what we have at Netflix and I would suggest you to use same practice at Netgate. If there is a panic/issue that we anticipate at our setup and we want extra debugging to be enabled without INVARIANTS, but we don't want to pollute the open source FreeBSD with our own hacks, we provided NASSERT macro in kassert.h, that works exactly same as KASSERT, but is enabled always. "N" stands for Netflix, but it would equally well work for Netgate ;) So, for a KASSERT that we want to be always enabled, we just flip one character K -> N and of course this diff is super easy to resolve during merges. M> Use-after-free, overflow, underflow, bitflip or what have you all can M> fail the fast path. M> M> Once that happens and the kernel crashes with a null pointer deref, M> here is a crash at netgate which prodded this: M> calltrap() at calltrap+0x8/frame 0xfffffe0106720920 M> --- trap 0xc, rip = 0xffffffff80d5ab70, rsp = 0xfffffe01067209f0, rbp M> = 0xfffffe0106720a00 --- M> turnstile_broadcast() at turnstile_broadcast+0x40/frame 0xfffffe0106720a00 M> __rw_wunlock_hard() at __rw_wunlock_hard+0x9e/frame 0xfffffe0106720a30 M> nd6_resolve_slow() at nd6_resolve_slow+0x2d7/frame 0xfffffe0106720aa0 M> nd6_resolve() at nd6_resolve+0x125/frame 0xfffffe0106720b10 M> ether_output() at ether_output+0x4e7/frame 0xfffffe0106720ba0 M> ip_output_send() at ip_output_send+0xdc/frame 0xfffffe0106720be0 M> ip_output() at ip_output+0x1295/frame 0xfffffe0106720ce0 M> ip_forward() at ip_forward+0x3c2/frame 0xfffffe0106720d90 M> ip_input() at ip_input+0x705/frame 0xfffffe0106720df0 M> swi_net() at swi_net+0x138/frame 0xfffffe0106720e60 M> ithread_loop() at ithread_loop+0x257/frame 0xfffffe0106720ef0 M> fork_exit() at fork_exit+0x7f/frame 0xfffffe0106720f30 M> fork_trampoline() at fork_trampoline+0xe/frame 0xfffffe0106720f30 M> --- trap 0, rip = 0, rsp = 0, rbp = 0 --- M> M> Neither the register dump nor anything in the backtrace indicate what happened. M> M> Since the kernel is going down anyway, one may as well get some debug from it. -- Gleb Smirnoff From nobody Tue Jul 16 20:37:33 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNrV55ZGsz5QCLd; Tue, 16 Jul 2024 20:37: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNrV553Ywz4DyV; Tue, 16 Jul 2024 20:37:33 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721162253; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=bDY7Ij/z0T3jSwwOXCR9phr1JO2S6so0WNWRSF98tX8=; b=pfSNaniUzvuOAILSdwF7KjC36Jb4Z6K8KVmFI87m6XgocTXfonRnaGEFAYM5KKcrAFjDph ioxHSMpxL9UMp3FckWgKH18t8x6fsqIyCMbI9Ey9MVlDknc4Lhxw78kaUa0Oy/jTl0K8NG zIEXC3Iku2XHMuRyKNObrqQpZq3iJNPkScHzulWb0IKStNNC7qqKjzWTL7JNdm+PRNT+U6 AZr2QZxNVyUBlFGE7hgCkMWjcRfq5JH+wkmygNBVorNYO5OD+ryA4L+AkH8xI+7/Dp/kWs lNo0N1bsI375WBvMRULEGuLeM22xlZbCbFk3QvEdjsXR0pEUWwlil9+zvjYONw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721162253; a=rsa-sha256; cv=none; b=S9BY9xz4SJ67X3ZjkaOi72qoMSS4F8XqOXTaoDPJ+OFdedTgUxOOSxPtg2tAUnmFTeg29Q d5+d7KbN13ZbENxh4LCJKjRsZWqbrMFs1is8KbVaBqfASUOFCxT46slgWMAUPYNocIp7ws 99lm06HlT/565ywU8WZbMRZClsqZwXNMiXdiukcRF7OAmqlzRtCUeHX/tddE6B16l48RnW lIudRU/aPBxxKzYl2WgnV0YumTnqVGs/uOFIAIL/ONEKUPYpS0NSVCeBy8QRlVrg4PA5b6 I9QXrUdSn3Zhhc9L9Zb755AIjHAmtfkJiTr+ECajqC0d4qexemhRwkf6Fg+DvQ== 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=1721162253; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=bDY7Ij/z0T3jSwwOXCR9phr1JO2S6so0WNWRSF98tX8=; b=FAn2SMqwyarTp0kaXDir0rxGkzcX6NhvbKe20IyQ2cCRnS/+TYqVI5pbuA4kSZktT1bYx4 q/6SEsv9Hxfsocp+1DOMnI9lBP/9CNErr787wwnlFjKYRzEhJWlRAyCrq69M10bpuL0K2b r94Mp7Psy3ksABBpxka8Ej6/EFHcEzgonkhcmr6nrqBR4crXR04z0oFvoXst9yXUDdptwI 1Uguo3vNZlQadE4C9s551B1672j+f9wNWYXYPXKfmSIxvUoBv9b584lTIDdAyqqlCNbRIv 5/oBZLzN/cg0hVW01Czm/zuDKCuOInoIS0zdX921HoQJ53CNNUhIZTuCe+mLyg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNrV54fjmzqpq; Tue, 16 Jul 2024 20:37:33 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46GKbXJD017787; Tue, 16 Jul 2024 20:37:33 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46GKbXHk017784; Tue, 16 Jul 2024 20:37:33 GMT (envelope-from git) Date: Tue, 16 Jul 2024 20:37:33 GMT Message-Id: <202407162037.46GKbXHk017784@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Kenneth D. Merry" Subject: git: 4c94657e168d - stable/13 - Fix the isp(4) driver with 9.x firmware. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: ken X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 4c94657e168de3f45a423d65289b349fa7d69206 Auto-Submitted: auto-generated The branch stable/13 has been updated by ken: URL: https://cgit.FreeBSD.org/src/commit/?id=4c94657e168de3f45a423d65289b349fa7d69206 commit 4c94657e168de3f45a423d65289b349fa7d69206 Author: Kenneth D. Merry AuthorDate: 2024-06-21 19:30:59 +0000 Commit: Kenneth D. Merry CommitDate: 2024-07-16 20:08:52 +0000 Fix the isp(4) driver with 9.x firmware. The isp(4) driver (and ispfw(4) firmware) previously only included firmware for Qlogic controllers up to 8Gb. It recently gained firmware for the 27XX and 28XX series controllers along with improved firmware loading capabilities. The 9.x firmware available for the 27XX and 28XX controllers in ispfw(4) adds login state for NVMe devices in the top nibble of the login state in the port database (isp_pdb_24xx_t in ispmbox.h). This breaks the check at the end of isp_getpdb() to make sure the device is in the right login state. As a result, it breaks device discovery for many (perhaps all?) FC devices. In my testing with IBM LTO-6 drives attached to a quad port 16Gb Qlogic 2714, they don't show up when they are directly connected (and in loop mode) or connected via a switch (and in fabric mode). So, mask off the top bits of of the login state before checking it. This shouldn't break anything, because all of the existing login states defined in ispmbox.h are in the low nibble. sys/dev/isp/ispmbox.h: Add a FCP login state mask define, and a NVMe login state shift. sys/dev/isp/isp.c: In isp_getpdb(), make sure we're only looking at the FCP login state bits when we try to determine whether a device is in the right login state. MFC after: 1 week Sponsored by: Spectra Logic Reviewed by: mav Differential Revision: (cherry picked from commit 137b004e2b7ab504abf98c4aad9d52607df47b9a) --- sys/dev/isp/isp.c | 10 +++++++++- sys/dev/isp/ispmbox.h | 6 ++++++ 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/sys/dev/isp/isp.c b/sys/dev/isp/isp.c index ad6dbd1e6f76..7246ea8031ac 100644 --- a/sys/dev/isp/isp.c +++ b/sys/dev/isp/isp.c @@ -1539,7 +1539,15 @@ isp_getpdb(ispsoftc_t *isp, int chan, uint16_t id, isp_pdb_t *pdb) chan, id, pdb->portid, un.bill.pdb_flags, un.bill.pdb_curstate, un.bill.pdb_laststate); - if (un.bill.pdb_curstate < PDB2400_STATE_PLOGI_DONE || un.bill.pdb_curstate > PDB2400_STATE_LOGGED_IN) { + /* + * XXX KDM this is broken for NVMe. Need to determine whether this + * is an NVMe target, and if so, check the NVMe status bits. We are + * probably missing more bits for proper NVMe support, though. + */ + if (((un.bill.pdb_curstate & PDB2400_STATE_FCP_MASK) < + PDB2400_STATE_PLOGI_DONE) + || ((un.bill.pdb_curstate & PDB2400_STATE_FCP_MASK) > + PDB2400_STATE_LOGGED_IN)) { mbs.param[0] = MBOX_NOT_LOGGED_IN; return (mbs.param[0]); } diff --git a/sys/dev/isp/ispmbox.h b/sys/dev/isp/ispmbox.h index c6ac9d9ce971..978ed4dc1638 100644 --- a/sys/dev/isp/ispmbox.h +++ b/sys/dev/isp/ispmbox.h @@ -890,6 +890,10 @@ typedef struct { #define PDB2400_CLASS2 0x0010 #define PDB2400_ADDR_VALID 0x0002 +/* + * For NVMe, the state is the high nibble. For FCP, the state is the low + * nibble. This appears to have changed with the 9.x firmware. + */ #define PDB2400_STATE_PLOGI_PEND 0x03 #define PDB2400_STATE_PLOGI_DONE 0x04 #define PDB2400_STATE_PRLI_PEND 0x05 @@ -897,6 +901,8 @@ typedef struct { #define PDB2400_STATE_PORT_UNAVAIL 0x07 #define PDB2400_STATE_PRLO_PEND 0x09 #define PDB2400_STATE_LOGO_PEND 0x0B +#define PDB2400_STATE_FCP_MASK 0x0f +#define PDB2400_STATE_NVME_SHIFT 4 /* * Common elements from the above two structures that are actually useful to us. From nobody Tue Jul 16 20:37:34 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNrV70B7Pz5QC84; Tue, 16 Jul 2024 20:37: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNrV6679Hz4Dw6; Tue, 16 Jul 2024 20:37:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721162254; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ArIdOYL1RhyXC6+IyFIxUdgVIlvqq5+edPNTjJEoFXU=; b=M2lGNB1YrJsXNJDSuuW3CGojivoAQBFTsHfTIvRDAq1qkT07K+3edlVxCe48tmkbu+uJoO odn+1f/dZhZSh1WNeCKP5IDKtIcQjMWkiZWm/dADeI4vGnbhuVKQ91RmtwcmjPf7aObqyN EgALM/YuLSqv/v1g55HiDa24ooPYHrnd4nqHwp9y82w0faEOrequp3NNjA9bjn7wL2Ktbr sb7wSKDzbb5u1oO27a9qwXnIGj38fPXZ6Aa/NjJDhh+4nGIRqs6z7FJOaZcimuMQUG9elz pKpDRJqlVU7JLWxvS0zA9dGA1hCyZydI5ZbZ5Nzvbu4TzZaA4vvQCCXHW+Gp7w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721162254; a=rsa-sha256; cv=none; b=R/c8Y5C5HJ3l0IlCsoa2G7fPdwEg1FudcQ1nXRZYyjKD7YxnzgbAB401GpI3jTaRDaDhv+ zXPPp9sbjuLqxSPETAjMt247YftnljcML/DPvvvD+qVr9TWXcD9lG3gV5eAsGvH7Q5E8dl H55ejXa3zb+nYTLb5vt6+GQMAJQjIdw4jjn1mTADDF1yLQTXfdAY3mN5CBPS1WKB0D7Fcg esOhCgPm95PDFlw3ZYgRHglmf2is5qAsgBcRNM0n/BnS72HPs9zJl09JMd4iKH73lmU8ZF STygkh+TyaRwSeHY6AlL6lhrmViFWEovWbdJdiy26PBRowJesFuQQuXlKlXHkA== 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=1721162254; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ArIdOYL1RhyXC6+IyFIxUdgVIlvqq5+edPNTjJEoFXU=; b=v3kyCFc+Zu2xdyN4DuxXgJMb1sAixtYbJt1+3ji90Wosjeq56k1E0Spjsy6DEU8BcHjOeD 2Yk9IU3PW161eYGCcZCWBTkTCO0LDJXB3gRmc2tztK+bzgCol33qI9l3WhRULxvgZrEXv7 o9p2U/ihsQPQnMmVadn1lm6fkFpdZXabH/3hZHmizPG+3nJBYiEXBh0IVPTSW9SNMitGIb Crpd+A/S/DawNporkXgGuE3a9Ut3Qtlhunkexy2afhAsPZ9MHdETOPuk5XtJ2w0TYON98x L7h+u5fqM/vY6xrPxW9ea1e7K4p/BbMzVBoyQiRtKJBpYA351n4eU/Utt4LM2g== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WNrV65kqczqpr; Tue, 16 Jul 2024 20:37:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46GKbYOJ017857; Tue, 16 Jul 2024 20:37:34 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46GKbYWm017854; Tue, 16 Jul 2024 20:37:34 GMT (envelope-from git) Date: Tue, 16 Jul 2024 20:37:34 GMT Message-Id: <202407162037.46GKbYWm017854@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Kenneth D. Merry" Subject: git: 12f7f57bc07d - stable/13 - Add an isp(4) tunable to default to ispfw(4) firmware. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: ken X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 12f7f57bc07d85158e67c61b83a4269c9d269fdf Auto-Submitted: auto-generated The branch stable/13 has been updated by ken: URL: https://cgit.FreeBSD.org/src/commit/?id=12f7f57bc07d85158e67c61b83a4269c9d269fdf commit 12f7f57bc07d85158e67c61b83a4269c9d269fdf Author: Kenneth D. Merry AuthorDate: 2024-06-24 19:42:41 +0000 Commit: Kenneth D. Merry CommitDate: 2024-07-16 20:36:32 +0000 Add an isp(4) tunable to default to ispfw(4) firmware. ispfw(4) recently gained firmware for Qlogic 27XX and 28XX FC controllers, and isp(4) now selects the newer of firmware in flash or in ispfw(4) to load for those controllers. This differs from the previous behavior (which remains for older controllers), which was to always load the ispfw(4) firmware if it is available. This adds a loader tunable, hint.isp.N.fwload_force to default to loading the ispfw(4) firmware, whether or not it is newer than the firmware in flash. This allows the user to always use the known firmware version included with the kernel. Note that there is an existing fwload_disable tunable that tells the driver to always load the firmware from flash and ignore ispfw(4). If fwload_disable is set, fwload_force will be ignored. So users with existing fwload_disable tunables will have the same behavior. If a user specifies both fwload_force and fwload_disable for the same controller, the isp(4) driver prints a warning message, and fwload_disable will be honored. The user can see which firmware is active through the dev.isp.N.fw_version* sysctl variables. share/man/man4/isp.4: Document the new loader tunable. sys/dev/isp/isp.c: In isp_load_risc_flash(), changet the decision logic to also consider ISP_CFG_FWLOAD_ONLY. Load the flash firmware and get the version, so the user knows what it is, but if the user set fwload_force, honor that. If the user didn't set fwload_force, the behavior remains to select the newer firmware version. sys/dev/isp/isp_pci.c: Add a new fwload_force tunable. Print out a warning if the user sets both fwload_disable and fwload_force. sys/dev/isp/ispvar.h: Add a new ISP_CFG_FWLOAD_FORCE configuration bit. Reviewed by: mav MFC after: 1 week Sponsored by: Spectra Logic Differential Revision: (cherry picked from commit 31354813f3c6e87532189be77c2f10a017c55472) --- share/man/man4/isp.4 | 17 ++++++++++++++++- sys/dev/isp/isp.c | 18 +++++++++++++++++- sys/dev/isp/isp_pci.c | 9 +++++++++ sys/dev/isp/ispvar.h | 1 + 4 files changed, 43 insertions(+), 2 deletions(-) diff --git a/share/man/man4/isp.4 b/share/man/man4/isp.4 index 350a0ea59a64..dc6a6dbd5d2b 100644 --- a/share/man/man4/isp.4 +++ b/share/man/man4/isp.4 @@ -24,7 +24,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.Dd October 27, 2023 +.Dd June 24, 2024 .Dt ISP 4 .Os .Sh NAME @@ -141,6 +141,21 @@ Limit on number of Extended Message Signaled Interrupts (MSI-X) to be used. .It Va hint.isp. Ns Ar N Ns Va .fwload_disable A hint value to disable loading of firmware provided by .Xr ispfw 4 . +.It Va hint.isp. Ns Ar N Ns Va .fwload_force +A hint value to prefer firmware provided by +.Xr ispfw 4 , +even if it is older than the firmware in flash on the board. +If fwload_disable is also specified, fwload_force will be ignored. +.Pp +By default, with 27XX and newer controllers, the +.Xr isp 4 +driver will use the newer +firmware. +For older controllers, the +.Xr isp 4 +driver will use the firmware provided by +.Xr ispfw 4 +if it is available, and otherwise use the firmware in flash on the board. .It Va hint.isp. Ns Ar N Ns Va .ignore_nvram A hint value to ignore board NVRAM settings for. Otherwise use NVRAM settings. diff --git a/sys/dev/isp/isp.c b/sys/dev/isp/isp.c index 7246ea8031ac..14d8147c3562 100644 --- a/sys/dev/isp/isp.c +++ b/sys/dev/isp/isp.c @@ -457,7 +457,10 @@ isp_reset(ispsoftc_t *isp, int do_load_defaults) if (IS_27XX(isp)) { switch (isp_load_risc(isp, 0)) { case ISP_ABORTED: - /* download ispfw(4) as it's newer than flash */ + /* + * download ispfw(4) as it's newer than flash, or + * the user requested it. + */ dodnld = 1; break; case ISP_SUCCESS: @@ -5223,7 +5226,20 @@ isp_load_risc_flash(ispsoftc_t *isp, uint32_t *srisc_addr, uint32_t faddr) /* If ispfw(4) is loaded compare versions and use the newest */ if (isp->isp_osinfo.ispfw != NULL) { + int ispfw_newer = 0; + if (ISP_FW_NEWER_THANX(fcp->fw_ispfwrev, fcp->fw_flashrev)) { + ispfw_newer = 1; + } + + if (isp->isp_confopts & ISP_CFG_FWLOAD_FORCE) { + isp_prt(isp, ISP_LOGCONFIG, + "Loading RISC with %s ispfw(4) firmware %s", + (ispfw_newer == 0) ? "older" : "newer", + "because fwload_force is set"); + return (ISP_ABORTED); + } + if (ispfw_newer != 0) { isp_prt(isp, ISP_LOGCONFIG, "Loading RISC with newer ispfw(4) firmware"); return (ISP_ABORTED); diff --git a/sys/dev/isp/isp_pci.c b/sys/dev/isp/isp_pci.c index f0496bd1fed2..1f3acfdd011d 100644 --- a/sys/dev/isp/isp_pci.c +++ b/sys/dev/isp/isp_pci.c @@ -291,6 +291,15 @@ isp_get_generic_options(device_t dev, ispsoftc_t *isp) isp->isp_confopts |= ISP_CFG_NORELOAD; } tval = 0; + if (resource_int_value(device_get_name(dev), device_get_unit(dev), "fwload_force", &tval) == 0 && tval != 0) { + isp->isp_confopts |= ISP_CFG_FWLOAD_FORCE; + } + if ((isp->isp_confopts & (ISP_CFG_NORELOAD|ISP_CFG_FWLOAD_FORCE)) == + (ISP_CFG_NORELOAD|ISP_CFG_FWLOAD_FORCE)) { + device_printf(dev, "WARNING: both fwload_disable and " + "fwload_force set, ispfw(4) loading disabled\n"); + } + tval = 0; if (resource_int_value(device_get_name(dev), device_get_unit(dev), "ignore_nvram", &tval) == 0 && tval != 0) { isp->isp_confopts |= ISP_CFG_NONVRAM; } diff --git a/sys/dev/isp/ispvar.h b/sys/dev/isp/ispvar.h index 6c3430246b29..abb712a395c1 100644 --- a/sys/dev/isp/ispvar.h +++ b/sys/dev/isp/ispvar.h @@ -612,6 +612,7 @@ struct ispsoftc { #define ISP_CFG_16GB 0x8000 /* force 16Gb connection (26XX only) */ #define ISP_CFG_32GB 0x10000 /* force 32Gb connection (27XX only) */ #define ISP_CFG_64GB 0x20000 /* force 64Gb connection (28XX only) */ +#define ISP_CFG_FWLOAD_FORCE 0x40000 /* Prefer ispfw(4) even if older */ /* * For each channel, the outer layers should know what role that channel From nobody Wed Jul 17 07:31:53 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WP7162kRBz5Ql6S; Wed, 17 Jul 2024 07:31: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WP7160gw2z4H5w; Wed, 17 Jul 2024 07:31:54 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721201514; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=JXxeCMMmsRI8baQr/Xh8X6PYrc2S8pnzUNkh4LEFRjA=; b=kKp43zTSq6zxL8SKoZh8eUZWx7aPL4lQ/0KqvAtMwp948EUpOJkCMZwiAvPCjBAMjMqZyQ K1WJquQrIzOufRZko5XXIZK10L8B+ASRhgm46AlxF3+V6Ff4arIzJvKxOfVBa1XB4uZ6r3 mA8R/xZIB1NvveLNOtofxVIHOhgerWUc+w3loNQ7IkRMLaP+iRytuPwx8vxmaedkmeACbz zmW2DDALruM1neLU3Jb3f1CoDgqVQasxK71Q0bgf2wJ1pwuTK8O2ExbstlL6c4JN7i72Vs g5YORUB7+JBrj0A0UAgj7UI2NHvDWECSfdrZZU9GBAGSnidQ7N1u6EMbHV77LQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721201514; a=rsa-sha256; cv=none; b=Cq3Q/IFrW/5NZYNXv4zfhk9q3wIK/5+4gAD9X4V/oLHw3zzrfcDSmd2DbgRxODJ3yMZ/b7 YDDI3EROCa7PGcUaHN2juNsdIIaEBrNHfjvfXIgIabsmRLoygfJKHlmuZB2lDAlz2oB2Uo hMUSePpczD6PG+ZqyScEsqKuGf9483CqiCe8OdH4Q9wfvANq3lbjv/IltzS6f8e1t+7EyT ahIB6+HHV9S/MLkK19XqnMJ6aqFNu5LVyxmhqmj588bODqqkFBz3LLgsLy0FaNgM4jnXwe O8u99+KWxDQLEf1rk+/kG+LuFscbadMYEWKoKJr7rNrNHPe88n/QepDyNeodXg== 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=1721201514; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=JXxeCMMmsRI8baQr/Xh8X6PYrc2S8pnzUNkh4LEFRjA=; b=ZWw9Dze6J+y8dm3hPCZLY0WtEl96GMIzEpBmPbdueRlusckzcf9aSz3wq1tBERvniX7xUM oHZeaKm8j/eeE6+z2LHSlCo9P3OW3+LRX6w0PRMEubVvRc5UPRX2XAmMTq5sMfWvC6czdo 9/7eHINKWOW4eoqnsGr0yikRW0vzKWRJRzK3wvzGLcH2PIdVInxRCbNO8yKcBxqk/EF8kd fPpzbyKrFGrkURW+CONcrOyYkAiqw0T71c1Mfswj5CXWhgSrDr1jURnM0StRz40icY44mt 2EjZxbfKinamq4z/N8427ed3e3SvhiTc2fLRelJLjzwx2lM19Xrs01xZbR4gcg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WP7160Fxqz19rv; Wed, 17 Jul 2024 07:31:54 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46H7VrE1033318; Wed, 17 Jul 2024 07:31:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46H7Vr03033315; Wed, 17 Jul 2024 07:31:53 GMT (envelope-from git) Date: Wed, 17 Jul 2024 07:31:53 GMT Message-Id: <202407170731.46H7Vr03033315@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: d909f06b907d - main - pf: convert DIOCADDADDR to netlink List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: d909f06b907d53ac4cbf9444ae75ca278900b0f3 Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=d909f06b907d53ac4cbf9444ae75ca278900b0f3 commit d909f06b907d53ac4cbf9444ae75ca278900b0f3 Author: Kristof Provost AuthorDate: 2024-07-16 16:58:59 +0000 Commit: Kristof Provost CommitDate: 2024-07-17 05:52:55 +0000 pf: convert DIOCADDADDR to netlink Sponsored by: Rubicon Communications, LLC ("Netgate") --- lib/libpfctl/libpfctl.c | 52 +++++++++++++++++++++ lib/libpfctl/libpfctl.h | 1 + sbin/pfctl/pfctl.c | 2 +- sys/net/pfvar.h | 1 + sys/netpfil/pf/pf_ioctl.c | 117 ++++++++++++++++++++++++---------------------- sys/netpfil/pf/pf_nl.c | 48 +++++++++++++++++++ sys/netpfil/pf/pf_nl.h | 20 ++++++++ 7 files changed, 185 insertions(+), 56 deletions(-) diff --git a/lib/libpfctl/libpfctl.c b/lib/libpfctl/libpfctl.c index b9fba232b8ca..398595c4715f 100644 --- a/lib/libpfctl/libpfctl.c +++ b/lib/libpfctl/libpfctl.c @@ -1105,6 +1105,19 @@ snl_add_msg_attr_addr_wrap(struct snl_writer *nw, uint32_t type, const struct pf snl_end_attr_nested(nw, off); } +static void +snl_add_msg_attr_pool_addr(struct snl_writer *nw, uint32_t type, const struct pf_pooladdr *pa) +{ + int off; + + off = snl_add_msg_attr_nested(nw, type); + + snl_add_msg_attr_string(nw, PF_PA_IFNAME, pa->ifname); + snl_add_msg_attr_addr_wrap(nw, PF_PA_ADDR, &pa->addr); + + snl_end_attr_nested(nw, off); +} + static void snl_add_msg_attr_rule_addr(struct snl_writer *nw, uint32_t type, const struct pf_rule_addr *addr) { @@ -2737,3 +2750,42 @@ pfctl_begin_addrs(struct pfctl_handle *h, uint32_t *ticket) return (e.error); } +int +pfctl_add_addr(struct pfctl_handle *h, const struct pfioc_pooladdr *pa) +{ + struct snl_writer nw; + struct snl_errmsg_data e = {}; + struct nlmsghdr *hdr; + uint32_t seq_id; + int family_id; + + family_id = snl_get_genl_family(&h->ss, PFNL_FAMILY_NAME); + if (family_id == 0) + return (ENOTSUP); + + snl_init_writer(&h->ss, &nw); + hdr = snl_create_genl_msg_request(&nw, family_id, PFNL_CMD_ADD_ADDR); + + snl_add_msg_attr_u32(&nw, PF_AA_ACTION, pa->action); + snl_add_msg_attr_u32(&nw, PF_AA_TICKET, pa->ticket); + snl_add_msg_attr_u32(&nw, PF_AA_NR, pa->nr); + snl_add_msg_attr_u32(&nw, PF_AA_R_NUM, pa->r_num); + snl_add_msg_attr_u8(&nw, PF_AA_R_ACTION, pa->r_action); + snl_add_msg_attr_u8(&nw, PF_AA_R_LAST, pa->r_last); + snl_add_msg_attr_u8(&nw, PF_AA_AF, pa->af); + snl_add_msg_attr_string(&nw, PF_AA_ANCHOR, pa->anchor); + snl_add_msg_attr_pool_addr(&nw, PF_AA_ADDR, &pa->addr); + + if ((hdr = snl_finalize_msg(&nw)) == NULL) + return (ENXIO); + + seq_id = hdr->nlmsg_seq; + + if (! snl_send_message(&h->ss, hdr)) + return (ENXIO); + + while ((hdr = snl_read_reply_multi(&h->ss, seq_id, &e)) != NULL) { + } + + return (e.error); +} diff --git a/lib/libpfctl/libpfctl.h b/lib/libpfctl/libpfctl.h index eebc97c52565..dd09b061efea 100644 --- a/lib/libpfctl/libpfctl.h +++ b/lib/libpfctl/libpfctl.h @@ -498,5 +498,6 @@ int pfctl_get_timeout(struct pfctl_handle *h, uint32_t timeout, uint32_t *second int pfctl_set_limit(struct pfctl_handle *h, const int index, const uint limit); int pfctl_get_limit(struct pfctl_handle *h, const int index, uint *limit); int pfctl_begin_addrs(struct pfctl_handle *h, uint32_t *ticket); +int pfctl_add_addr(struct pfctl_handle *h, const struct pfioc_pooladdr *pa); #endif diff --git a/sbin/pfctl/pfctl.c b/sbin/pfctl/pfctl.c index 450c64785b9c..a49e82809f9e 100644 --- a/sbin/pfctl/pfctl.c +++ b/sbin/pfctl/pfctl.c @@ -1727,7 +1727,7 @@ pfctl_add_pool(struct pfctl *pf, struct pfctl_pool *p, sa_family_t af) TAILQ_FOREACH(pa, &p->list, entries) { memcpy(&pf->paddr.addr, pa, sizeof(struct pf_pooladdr)); if ((pf->opts & PF_OPT_NOACTION) == 0) { - if (ioctl(pf->dev, DIOCADDADDR, &pf->paddr)) + if (pfctl_add_addr(pf->h, &pf->paddr) != 0) err(1, "DIOCADDADDR"); } } diff --git a/sys/net/pfvar.h b/sys/net/pfvar.h index 0b90600a69ae..aa6dd52a7e69 100644 --- a/sys/net/pfvar.h +++ b/sys/net/pfvar.h @@ -2525,6 +2525,7 @@ int pf_ioctl_set_timeout(int, int, int *); int pf_ioctl_get_limit(int, unsigned int *); int pf_ioctl_set_limit(int, unsigned int, unsigned int *); int pf_ioctl_begin_addrs(uint32_t *); +int pf_ioctl_add_addr(struct pfioc_pooladdr *); void pf_krule_free(struct pf_krule *); void pf_krule_clear_counters(struct pf_krule *); diff --git a/sys/netpfil/pf/pf_ioctl.c b/sys/netpfil/pf/pf_ioctl.c index 2cb6923e1e69..2df6bcd30533 100644 --- a/sys/netpfil/pf/pf_ioctl.c +++ b/sys/netpfil/pf/pf_ioctl.c @@ -2528,6 +2528,67 @@ pf_ioctl_begin_addrs(uint32_t *ticket) return (0); } +int +pf_ioctl_add_addr(struct pfioc_pooladdr *pp) +{ + struct pf_kpooladdr *pa = NULL; + struct pfi_kkif *kif = NULL; + int error; + +#ifndef INET + if (pp->af == AF_INET) + return (EAFNOSUPPORT); +#endif /* INET */ +#ifndef INET6 + if (pp->af == AF_INET6) + return (EAFNOSUPPORT); +#endif /* INET6 */ + + if (pp->addr.addr.type != PF_ADDR_ADDRMASK && + pp->addr.addr.type != PF_ADDR_DYNIFTL && + pp->addr.addr.type != PF_ADDR_TABLE) + return (EINVAL); + + if (pp->addr.addr.p.dyn != NULL) + return (EINVAL); + + pa = malloc(sizeof(*pa), M_PFRULE, M_WAITOK); + error = pf_pooladdr_to_kpooladdr(&pp->addr, pa); + if (error != 0) + goto out; + if (pa->ifname[0]) + kif = pf_kkif_create(M_WAITOK); + PF_RULES_WLOCK(); + if (pp->ticket != V_ticket_pabuf) { + PF_RULES_WUNLOCK(); + if (pa->ifname[0]) + pf_kkif_free(kif); + error = EBUSY; + goto out; + } + if (pa->ifname[0]) { + pa->kif = pfi_kkif_attach(kif, pa->ifname); + kif = NULL; + pfi_kkif_ref(pa->kif); + } else + pa->kif = NULL; + if (pa->addr.type == PF_ADDR_DYNIFTL && ((error = + pfi_dynaddr_setup(&pa->addr, pp->af)) != 0)) { + if (pa->ifname[0]) + pfi_kkif_unref(pa->kif); + PF_RULES_WUNLOCK(); + goto out; + } + TAILQ_INSERT_TAIL(&V_pf_pabuf, pa, entries); + PF_RULES_WUNLOCK(); + + return (0); + +out: + free(pa, M_PFRULE); + return (error); +} + static int pfioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flags, struct thread *td) { @@ -4199,62 +4260,8 @@ DIOCGETSTATESV2_full: case DIOCADDADDR: { struct pfioc_pooladdr *pp = (struct pfioc_pooladdr *)addr; - struct pf_kpooladdr *pa; - struct pfi_kkif *kif = NULL; -#ifndef INET - if (pp->af == AF_INET) { - error = EAFNOSUPPORT; - break; - } -#endif /* INET */ -#ifndef INET6 - if (pp->af == AF_INET6) { - error = EAFNOSUPPORT; - break; - } -#endif /* INET6 */ - if (pp->addr.addr.type != PF_ADDR_ADDRMASK && - pp->addr.addr.type != PF_ADDR_DYNIFTL && - pp->addr.addr.type != PF_ADDR_TABLE) { - error = EINVAL; - break; - } - if (pp->addr.addr.p.dyn != NULL) { - error = EINVAL; - break; - } - pa = malloc(sizeof(*pa), M_PFRULE, M_WAITOK); - error = pf_pooladdr_to_kpooladdr(&pp->addr, pa); - if (error != 0) - break; - if (pa->ifname[0]) - kif = pf_kkif_create(M_WAITOK); - PF_RULES_WLOCK(); - if (pp->ticket != V_ticket_pabuf) { - PF_RULES_WUNLOCK(); - if (pa->ifname[0]) - pf_kkif_free(kif); - free(pa, M_PFRULE); - error = EBUSY; - break; - } - if (pa->ifname[0]) { - pa->kif = pfi_kkif_attach(kif, pa->ifname); - kif = NULL; - pfi_kkif_ref(pa->kif); - } else - pa->kif = NULL; - if (pa->addr.type == PF_ADDR_DYNIFTL && ((error = - pfi_dynaddr_setup(&pa->addr, pp->af)) != 0)) { - if (pa->ifname[0]) - pfi_kkif_unref(pa->kif); - PF_RULES_WUNLOCK(); - free(pa, M_PFRULE); - break; - } - TAILQ_INSERT_TAIL(&V_pf_pabuf, pa, entries); - PF_RULES_WUNLOCK(); + error = pf_ioctl_add_addr(pp); break; } diff --git a/sys/netpfil/pf/pf_nl.c b/sys/netpfil/pf/pf_nl.c index 401baddde948..e855815dd73b 100644 --- a/sys/netpfil/pf/pf_nl.c +++ b/sys/netpfil/pf/pf_nl.c @@ -1509,6 +1509,45 @@ pf_handle_begin_addrs(struct nlmsghdr *hdr, struct nl_pstate *npt) return (0); } +#define _OUT(_field) offsetof(struct pf_pooladdr, _field) +static const struct nlattr_parser nla_p_pool_addr[] = { + { .type = PF_PA_ADDR, .off = _OUT(addr), .arg = &addr_wrap_parser, .cb = nlattr_get_nested }, + { .type = PF_PA_IFNAME, .off = _OUT(ifname), .arg = (void *)IFNAMSIZ, .cb = nlattr_get_chara }, +}; +NL_DECLARE_ATTR_PARSER(pool_addr_parser, nla_p_pool_addr); +#undef _OUT + +#define _OUT(_field) offsetof(struct pfioc_pooladdr, _field) +static const struct nlattr_parser nla_p_add_addr[] = { + { .type = PF_AA_ACTION, .off = _OUT(action), .cb = nlattr_get_uint32 }, + { .type = PF_AA_TICKET, .off = _OUT(ticket), .cb = nlattr_get_uint32 }, + { .type = PF_AA_NR, .off = _OUT(nr), .cb = nlattr_get_uint32 }, + { .type = PF_AA_R_NUM, .off = _OUT(r_num), .cb = nlattr_get_uint32 }, + { .type = PF_AA_R_ACTION, .off = _OUT(r_action), .cb = nlattr_get_uint8 }, + { .type = PF_AA_R_LAST, .off = _OUT(r_last), .cb = nlattr_get_uint8 }, + { .type = PF_AA_AF, .off = _OUT(af), .cb = nlattr_get_uint8 }, + { .type = PF_AA_ANCHOR, .off = _OUT(anchor), .arg = (void *)MAXPATHLEN, .cb = nlattr_get_chara }, + { .type = PF_AA_ADDR, .off = _OUT(addr), .arg = &pool_addr_parser, .cb = nlattr_get_nested }, +}; +static const struct nlfield_parser nlf_p_add_addr[] = {}; +#undef _OUT +NL_DECLARE_PARSER(add_addr_parser, struct genlmsghdr, nlf_p_add_addr, nla_p_add_addr); + +static int +pf_handle_add_addr(struct nlmsghdr *hdr, struct nl_pstate *npt) +{ + struct pfioc_pooladdr attrs = { 0 }; + int error; + + error = nl_parse_nlmsg(hdr, &add_addr_parser, npt, &attrs); + if (error != 0) + return (error); + + error = pf_ioctl_add_addr(&attrs); + + return (error); +} + static const struct nlhdr_parser *all_parsers[] = { &state_parser, &addrule_parser, @@ -1519,6 +1558,8 @@ static const struct nlhdr_parser *all_parsers[] = { &set_debug_parser, &set_timeout_parser, &set_limit_parser, + &pool_addr_parser, + &add_addr_parser, }; static int family_id; @@ -1657,6 +1698,13 @@ static const struct genl_cmd pf_cmds[] = { .cmd_flags = GENL_CMD_CAP_DO | GENL_CMD_CAP_DUMP | GENL_CMD_CAP_HASPOL, .cmd_priv = PRIV_NETINET_PF, }, + { + .cmd_num = PFNL_CMD_ADD_ADDR, + .cmd_name = "ADD_ADDR", + .cmd_cb = pf_handle_add_addr, + .cmd_flags = GENL_CMD_CAP_DO | GENL_CMD_CAP_HASPOL, + .cmd_priv = PRIV_NETINET_PF, + }, }; void diff --git a/sys/netpfil/pf/pf_nl.h b/sys/netpfil/pf/pf_nl.h index d50b5a1e9d43..2459fdc15a63 100644 --- a/sys/netpfil/pf/pf_nl.h +++ b/sys/netpfil/pf/pf_nl.h @@ -55,6 +55,7 @@ enum { PFNL_CMD_SET_LIMIT = 17, PFNL_CMD_GET_LIMIT = 18, PFNL_CMD_BEGIN_ADDRS = 19, + PFNL_CMD_ADD_ADDR = 20, __PFNL_CMD_MAX, }; #define PFNL_CMD_MAX (__PFNL_CMD_MAX -1) @@ -356,6 +357,25 @@ enum pf_begin_addrs_types_t { PF_BA_TICKET = 1, /* u32 */ }; +enum pf_pool_addr_types_t { + PF_PA_UNSPEC, + PF_PA_ADDR = 1, /* nested, pf_addr_wrap */ + PF_PA_IFNAME = 2, /* string */ +}; + +enum pf_add_addr_types_t { + PF_AA_UNSPEC, + PF_AA_ACTION = 1, /* u32 */ + PF_AA_TICKET = 2, /* u32 */ + PF_AA_NR = 3, /* u32 */ + PF_AA_R_NUM = 4, /* u32 */ + PF_AA_R_ACTION = 5, /* u8 */ + PF_AA_R_LAST = 6, /* u8 */ + PF_AA_AF = 7, /* u8 */ + PF_AA_ANCHOR = 8, /* string */ + PF_AA_ADDR = 9, /* nested, pf_pooladdr */ +}; + #ifdef _KERNEL void pf_nl_register(void); From nobody Wed Jul 17 12:43:28 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPFwc2fjZz5RFYx; Wed, 17 Jul 2024 12:43: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPFwc1qF5z4kG8; Wed, 17 Jul 2024 12:43:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721220208; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=IqyN/awVg6nPk85Vcj4NB1/TsYM1eOQzWwYqGYZutO8=; b=hwYbTJyorcyjBbNM/zYNYrlE8AXLYy/dQMnI9UYCNDikwsh5r4DH5Cri3gELAy2lbUJ4HP LnlnxkUnkZjeSNthOY8nwW/4Xnjj5HQllQB6uYED9tKkLVxT//xUhCl7pjQb3chXj34xe1 yhKD7SMFqWZRVTnR5I3TEHNvvCh24gmuSw1znJL+O5McWZNFbWim2pW45GcPxYzrmEfUCy 4qrEYH9CIkWapANuhj0imby57Rlw1Wy00U86Bl6dV3ZkOs1wXb7tRvztul1ajrgFfi2aNe mpG2snP2+wNmxqnpYROPsns6CF0elV8AGlcogRidPluZ7/AXiSVo4Qj+oEjTmg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721220208; a=rsa-sha256; cv=none; b=OLBS7br8y9cuyUom6+4oIFLCkgYfrPOMUBBp4aF6xV1ayCxaZHtslYZ9YM0u+fB8yXuW+K 1/gxG3W+5RzWfcudupr7TCbOQnN0NJgsw9qeIIsTebXSHG++UIMamfpbmUHfM/tgrViWLA X/vAHpAZr0pC865cvUYDlia8kUuVKibvR6iYaSBkBdP21FIOz8ThDQ6lVlCLL1Xe90jHzF eYZVZPyVwbKpfN1amGuqAQotLDiFqHebOpMsKDroOXvbzNMh408bM8/AMnEB8NfYlbmKXF l+VnE9Ul97Y9KV/xy9l+LWUFE/PXSWkX5jZagiqPumNE63rKG9kAGKAk9/57Bw== 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=1721220208; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=IqyN/awVg6nPk85Vcj4NB1/TsYM1eOQzWwYqGYZutO8=; b=jORC7wMh0hOasWaB/ZCPmOHufdh5A9DXex+dU19GGHii3x5FslzgzgReP1RUJRdeMxO8Ad WFjq+iPlmlMmq5nPP5nH25hQEjr0LbvGJV4IS0QxtW/Qo6cscvT9AaZOacHUcxtFUgNZMt vzfnzbHWMVB3r+xBIaBUh7dJ257Sv2lPyfI4gPwBNcSiKlkBfgNC1a+mTa6o8ZK4bQNE/5 BbQkCsBqkvKfvX9RI4/E6TWdH8PvWoTHDv+CVaorjsUOlTwVcZnyHIV6QpRDjv78KOtTmW yg/JemwnLL80up8h9Wn//AAqpd16w7QjBpt3MbXSv6ATopFvNq2QChg9wlYu5w== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPFwc1Qdyz1KZl; Wed, 17 Jul 2024 12:43:28 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HChSnj062425; Wed, 17 Jul 2024 12:43:28 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HChSZQ062422; Wed, 17 Jul 2024 12:43:28 GMT (envelope-from git) Date: Wed, 17 Jul 2024 12:43:28 GMT Message-Id: <202407171243.46HChSZQ062422@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Jessica Clarke Subject: git: e21e8c918086 - main - tools/build: Unbreak cross build by providing stub ssp/ssp.h List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jrtc27 X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e21e8c918086ad130a3caa5116efc64e86f4574f Auto-Submitted: auto-generated The branch main has been updated by jrtc27: URL: https://cgit.FreeBSD.org/src/commit/?id=e21e8c918086ad130a3caa5116efc64e86f4574f commit e21e8c918086ad130a3caa5116efc64e86f4574f Author: Jessica Clarke AuthorDate: 2024-07-17 12:11:25 +0000 Commit: Jessica Clarke CommitDate: 2024-07-17 12:11:25 +0000 tools/build: Unbreak cross build by providing stub ssp/ssp.h We build arc4random.c on non-FreeBSD, which now wants the header for __ssp_real. Fixes: d0b7445904f5 ("include: ssp: fortify ") --- tools/build/cross-build/include/common/ssp/ssp.h | 34 ++++++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/tools/build/cross-build/include/common/ssp/ssp.h b/tools/build/cross-build/include/common/ssp/ssp.h new file mode 100644 index 000000000000..2d8b43235baf --- /dev/null +++ b/tools/build/cross-build/include/common/ssp/ssp.h @@ -0,0 +1,34 @@ +/*- + * SPDX-License-Identifier: BSD-2-Clause + * + * Copyright (c) 2024 Jessica Clarke + * + * 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. + */ + +#ifndef _SSP_SSP_H_ +#define _SSP_SSP_H_ + +#define __ssp_real_(fun) fun +#define __ssp_real(fun) __ssp_real_(fun) + +#endif From nobody Wed Jul 17 13:00:09 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPGHs3mZTz5RHLV; Wed, 17 Jul 2024 13:00: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPGHs38Xyz4lBy; Wed, 17 Jul 2024 13:00:09 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721221209; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=j57qyDQZmzHnZJwbz/d/cwlK9sl0+rmflmhfz466Fn8=; b=BQbC28LsVHxkhHSuvorazyJf01bk+oC1TPJNTyTVRunoFXSwCrqoc3BS5CNE36KesaNIMQ 0zpK5qyNZHFuIVV95LBagUWNPWean3xnm18Mz2RIo2ZhdUeYAALz/kKyAPGkRajx2skSXC qonpO66YTmzmGXSndcPieEnz1mGMzM6R5/od0NsdIl/F1sEy4HnBuFNoyZdJnQ2OEr3Uw7 +ZtjEfijHlmaW6RXYUAFmaUKKk1dBNgqiQAv8/6G6B9nkzfqk5PK8ZTgyQK0mO4qm83vh6 l96WABA55rG5z/XKea5DFnBBDZRQBdcNxXan7ZkUVseJvYcwZV9eDwmZkKwhEw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721221209; a=rsa-sha256; cv=none; b=KuD0R4wKzpHuHiOC5Cy9Dth8D5mDrWegzu8JN+3GZ7aB6tMwyYZ1gICICKeI0i5rO/Vw2G sBMuiYkQBU1z5TipQFT7lASM9TYak0ySQ0MrNrK/l2KNvsajxYAbImTvAFETYJ63ggxDBu j0OKoQ4tSKpZ36kBqmwYOpgMWxFUnkrzGrzs+WJKUJTTatVrsGfF/JZ8JYWy3HbSMQuwqy qflF3RLe+qGNewYFnLBr41RWpm/+XkXf4ol+nBUAVBpLfp94NqvV4nOsfMMHSsz1puljqu jhtEemYz0+gKCvU2scX04miHoH280TZHF2vvco7OJ5xeQZqSmQoTSN0cEee22A== 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=1721221209; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=j57qyDQZmzHnZJwbz/d/cwlK9sl0+rmflmhfz466Fn8=; b=UeeQsl+MtTj8Usabc+b3CvVOud9NhrLEwgufBwNytM4JUuEdMHXD/1voz2L4uh3/ioRt1W PqbQX9T6GQ9MrfTn6x7oETu0xeeLoH2RjHXNQWP/YGAsW0dEb7avT9B1v339SaKsFNsnWJ NFGCa1H4NyuZJ/abxX+1kBiFcPkHQb8OgQnaqplWrTos8SSkFmntVFnynY4SWpqqpK4VEY 1kWo/p0hwAVbw95IDDdPP2sB7TrIhfFiyRlyxdfVY4xWnXlr9IokfYt2wjiVj7N8mf9tBV e6/RND4sX/GzpwJefUbSKfd+5hBsVnT0t7gfk7sSc7VlzqSb4QkEZSxsnfNnww== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPGHs2hvTz1Kb7; Wed, 17 Jul 2024 13:00:09 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HD099J084374; Wed, 17 Jul 2024 13:00:09 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HD09us084362; Wed, 17 Jul 2024 13:00:09 GMT (envelope-from git) Date: Wed, 17 Jul 2024 13:00:09 GMT Message-Id: <202407171300.46HD09us084362@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Jessica Clarke Subject: git: ac0c8c1186f7 - main - dts: Fix arm/qcom-ipq4018-rt-ac58u.dts for recent device-tree versions List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jrtc27 X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: ac0c8c1186f7a45f106b16ef57e303476ce6741a Auto-Submitted: auto-generated The branch main has been updated by jrtc27: URL: https://cgit.FreeBSD.org/src/commit/?id=ac0c8c1186f7a45f106b16ef57e303476ce6741a commit ac0c8c1186f7a45f106b16ef57e303476ce6741a Author: Jessica Clarke AuthorDate: 2024-07-17 12:55:49 +0000 Commit: Jessica Clarke CommitDate: 2024-07-17 12:55:49 +0000 dts: Fix arm/qcom-ipq4018-rt-ac58u.dts for recent device-tree versions The included file has recently moved to a subdirectory. This fixes building arm.armv7 ASUS_AC1300 (marked NO_UNIVERSE). Fixes: f126890ac538 ("Import device-tree files from Linux 6.5") --- sys/dts/arm/qcom-ipq4018-rt-ac58u.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dts/arm/qcom-ipq4018-rt-ac58u.dts b/sys/dts/arm/qcom-ipq4018-rt-ac58u.dts index 7db535b881dc..baaa4c2e9d5f 100644 --- a/sys/dts/arm/qcom-ipq4018-rt-ac58u.dts +++ b/sys/dts/arm/qcom-ipq4018-rt-ac58u.dts @@ -1,6 +1,6 @@ // SPDX-License-Identifier: GPL-2.0-or-later OR MIT -#include "qcom-ipq4019.dtsi" +#include "qcom/qcom-ipq4019.dtsi" #include "qcom-ipq4019-ethernet.dtsi" #include From nobody Wed Jul 17 13:00:10 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPGHt4W1Dz5RHTw; Wed, 17 Jul 2024 13:00: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPGHt3zcLz4lC2; Wed, 17 Jul 2024 13:00:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721221210; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6Vp1b9eKHjBV5Df1wwk41QS/AaV9ycVDMo5EsUrIOmM=; b=s2pl6v5xB9IWsl87o+h1hfCph8OoIhDQQP8Qj/CzLmzkhfnkzak/tejBkBujBAcjMbia3C 5hM/ss9yK9G1wWFsmB4lPPZXRR/XOCGjs+OWPa1LnCpcUH/7GClmr/NHsow3lcnEt/fIt0 jPXtpbcepGpM7Y1TqhJLvQp4byQG9OsOs+6JYz6dEvNOpSGVPo2vV2yejisR4JKBuwNNp2 2m/PjwZtJQRWx0zi1rrqP4BdwoGQjMmukz8QKJaqlI63hAgeOhibuLzgnU4bjJCs3U3ufN CJbHV5YhnRT+cY1Or4XIjdAzNeN6Bh0sp6ACTVswHMhoDLJxenL61vqeRBmBUg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721221210; a=rsa-sha256; cv=none; b=cS1mUdC8o/zSZWyGHgvs3lDO4IpEU2HhbV7HKiWhsfGQP4OwDbRB2m3aL63Y7ss0rrXY1P aBV7NZ6DpqdvUSXaMqKTNWFU1hDoV93Z92ecHa0TNIz2sVJpcilxoJeiiv8VlW3ztkdEQk B/rqolKSVKsqw2WmJ8aJFUS9eA1gKk7we+o7J2KYNVZ6njdCntfKkiiwZhADsx6LTp9Epi xjBcN0uDs4V5vYKs7cq4hQjGzAIrmovkFRTBldSmi/lm0z9oE8M82eVyRso4ZPR/SD59dN 3HDuQGALb/IC6GEOHC3A5gQt45Cm6QXg7A0yQTXEXEQ9C36QUVZ5qIDF29Kdiw== 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=1721221210; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6Vp1b9eKHjBV5Df1wwk41QS/AaV9ycVDMo5EsUrIOmM=; b=LXSP5UPGQqq34+gopmFm1FcqFMQqa8ikqjwqYSYe2vQGfNUkqCUtfX8uegghLg67O9OELy yIdP/tlOr/0Qwgbu7yaUmV4dV4yz9dN9NFxZPBjLxYMQ5cOD+PJ7oua3vDYulBiHeMHqQH +P/5gg1btkj/p2ZY70vlvlfb6P1zB3LVzvREwCVPAmz/3jwklsJBX/xR8qobBzm/6S+gZR xR5q5IyoMmpr/XDwdUqRGrWswhBndtS/vDCeBouMaMlTD0MGilVthDqPAZADj+pvjOTr/4 v/gsM9Cy6jTD4M2xFDqiy4FaAweEYy5UkXNmWJ204++BGp6WflwPsNVnunH32Q== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPGHt3c40z1KhT; Wed, 17 Jul 2024 13:00:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HD0AXT085048; Wed, 17 Jul 2024 13:00:10 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HD0AHq085043; Wed, 17 Jul 2024 13:00:10 GMT (envelope-from git) Date: Wed, 17 Jul 2024 13:00:10 GMT Message-Id: <202407171300.46HD0AHq085043@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Jessica Clarke Subject: git: c24e5fcca9c2 - main - mvs: Fix to use rman_get_rid rather than non-existent rid argument List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jrtc27 X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: c24e5fcca9c2f2cacaf3d7883f0ecb4d5a4747cc Auto-Submitted: auto-generated The branch main has been updated by jrtc27: URL: https://cgit.FreeBSD.org/src/commit/?id=c24e5fcca9c2f2cacaf3d7883f0ecb4d5a4747cc commit c24e5fcca9c2f2cacaf3d7883f0ecb4d5a4747cc Author: Jessica Clarke AuthorDate: 2024-07-17 12:59:13 +0000 Commit: Jessica Clarke CommitDate: 2024-07-17 12:59:13 +0000 mvs: Fix to use rman_get_rid rather than non-existent rid argument This got missed as it's not built in a normal tinderbox build. This fixes building arm.armv7 ARMADAXP (marked NO_UNIVERSE). Fixes: 9dbf5b0e6876 ("new-bus: Remove the 'rid' and 'type' arguments from BUS_RELEASE_RESOURCE") --- sys/dev/mvs/mvs_soc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/mvs/mvs_soc.c b/sys/dev/mvs/mvs_soc.c index 00a868140a0e..b48321b04955 100644 --- a/sys/dev/mvs/mvs_soc.c +++ b/sys/dev/mvs/mvs_soc.c @@ -372,7 +372,7 @@ mvs_release_resource(device_t dev, device_t child, struct resource *r) rman_release_resource(r); return (0); case SYS_RES_IRQ: - if (rid != ATA_IRQ_RID) + if (rman_get_rid(r) != ATA_IRQ_RID) return ENOENT; return (0); } From nobody Wed Jul 17 13:52:12 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPHRx6dcqz5RMbV; Wed, 17 Jul 2024 13:52:13 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPHRx69yPz4qsw; Wed, 17 Jul 2024 13:52:13 +0000 (UTC) (envelope-from jhb@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721224333; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=RALK9G/2qEus3rr0U9iVQh85REoDxY2ijR0AsS/6AcQ=; b=p4Pnl0wVprY1l9A7eps5dNQFwL1+63/I26upCiTjkre+jIFU5J4/8vrEcA5o5cCFPi/QL6 S3RyqyCSmeENKAz5ouWi4mzIcIYh4KxUS5HmZ+VOXLBcnWuujj7rwSmHJL39y6pDA3p5z1 bJyQ1KXzHLupCeROkN003+QosgtOsSqeMBll0nIfpzrM0DjQbiOMbSCUPPP5n7QKTwSP2Z o+uRxAO72HJdkBRX+4700FlKxaweowhTX0ujJUIm2VmMhKhFlERBLSYfr7mILc0JJyhnQ0 bD7WQjKt+5/cbxO0Hl02SprDJd0dwBsJcSI7ra7nZR3fbPiQ9TNcbrxdswS6Xg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721224333; a=rsa-sha256; cv=none; b=jBcA6cVuQzmk+4fxIcBYCWK2M3j9PJjpR08tW62p00zo2KIuHB1RHMn3uilktS5lZY3Xlq lIPZ6RkBYoPEaXKvYozM/Z6X04v9vCIJ7dl/hY0fjKyMyPfhWJYAsKFT2xPPpPLpoS6AKp /Mjt5yN1nUAo1OHpqPuRgq1OM+ZDr7tIZrsQ7eRp7uCd8MLzolYI61Lsn1NVVBeGRDq4H4 gtlPx95bpNKafuipFsWpMEbJM3/pfWHAouNyJpx7WS/tbW8zhFyAIcKH1BJYR5ijPWkyAz i4EJRQqpRP/gA9dfciNmj7Z8xZRi5BHmR+Q+TjeOHCuPMpIP3OQVamLHOMXxbQ== 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=1721224333; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=RALK9G/2qEus3rr0U9iVQh85REoDxY2ijR0AsS/6AcQ=; b=cqfIT3sJf6d38tVg/ojZUmr/5HTeDKMtk32Ec8IvjWkLprs14OqxP8dNKiC5EW8J9AY0tG nYH3t6B/pOHwVEAWhRdhvBNX3g7zZdLv2aTNtDUPyj29JFKhqpwuSLDRD1xWHL2XfqSV1C 0YG2AKbt+iwqil917CDynUH+Yut4KVFwujXl38XevAQmOWGzjciLppYl0a+yXapJ/OTMj+ +MHhqyx2HUd4lA6RY5cVGpnqH6wUwLURNC5OibVULcJeZHKlfR4gRE6qmBviVfzPl7Qtyk FG3+IvFEvQX7uZvDCJWO8ywAVR6sY/MQgglRYE0gvkJjOF32X6Cx78kmzKilTw== Received: from [IPV6:2601:5c0:4200:b830:692e:5caf:134a:ed7b] (unknown [IPv6:2601:5c0:4200:b830:692e:5caf:134a:ed7b]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: jhb) by smtp.freebsd.org (Postfix) with ESMTPSA id 4WPHRx4KlZz1KXg; Wed, 17 Jul 2024 13:52:13 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Message-ID: <692c082f-c6e5-4988-911b-3215838510c3@FreeBSD.org> Date: Wed, 17 Jul 2024 09:52:12 -0400 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: git: 838b6caababb - main - openssl: use getrandom(2) instead of probing for getentropy(2) Content-Language: en-US To: Kyle Evans , src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org References: <202407160512.46G5CjpV056391@gitrepo.freebsd.org> From: John Baldwin In-Reply-To: <202407160512.46G5CjpV056391@gitrepo.freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: base64 T24gNy8xNi8yNCAwMToxMiwgS3lsZSBFdmFucyB3cm90ZToNCj4gVGhlIGJyYW5jaCBtYWlu IGhhcyBiZWVuIHVwZGF0ZWQgYnkga2V2YW5zOg0KPiANCj4gVVJMOiBodHRwczovL2NnaXQu RnJlZUJTRC5vcmcvc3JjL2NvbW1pdC8/aWQ9ODM4YjZjYWFiYWJiYWFhYjY1NjU5ZDQwYTQx YzJkZDQ2YjNhNWZkMg0KPiANCj4gY29tbWl0IDgzOGI2Y2FhYmFiYmFhYWI2NTY1OWQ0MGE0 MWMyZGQ0NmIzYTVmZDINCj4gQXV0aG9yOiAgICAgS3lsZSBFdmFucyA8a2V2YW5zQEZyZWVC U0Qub3JnPg0KPiBBdXRob3JEYXRlOiAyMDI0LTA3LTE2IDA1OjEyOjI3ICswMDAwDQo+IENv bW1pdDogICAgIEt5bGUgRXZhbnMgPGtldmFuc0BGcmVlQlNELm9yZz4NCj4gQ29tbWl0RGF0 ZTogMjAyNC0wNy0xNiAwNToxMjoyNyArMDAwMA0KPiANCj4gICAgICBvcGVuc3NsOiB1c2Ug Z2V0cmFuZG9tKDIpIGluc3RlYWQgb2YgcHJvYmluZyBmb3IgZ2V0ZW50cm9weSgyKQ0KPiAg ICAgIA0KPiAgICAgIFRoZSBwcm9iaW5nIGZvciBnZXRlbnRyb3B5KDIpIHJlbGllcyBvbiBy ZS1kZWNsYXJpbmcgZ2V0ZW50cm9weSgyKQ0KPiAgICAgIGFzIHdlYWsgYW5kIGNoZWNraW5n IHRoZSBhZGRyZXNzLCBidXQgdGhpcyBpcyBpbmNvbXBhdGlibGUgd2l0aA0KPiAgICAgIHRo ZSBfRk9SVElGWV9TT1VSQ0Ugc3ltYm9sIHJlbmFtaW5nIHNjaGVtZS4gIEl0J3MgYWx3YXlz IHByZXNlbnQgb24NCj4gICAgICBhbGwgc3VwcG9ydGVkIEZyZWVCU0QgdmVyc2lvbnMgbm93 IHNvIHdlIGNvdWxkIGN1dCBpdCBkb3duIHRvDQo+ICAgICAgdW5jb25kaXRpb25hbCB1c2Us IGJ1dCB0aGVyZSdzIGFub3RoZXIgc2VnbWVudCBmb3IgZ2V0cmFuZG9tKDIpDQo+ICAgICAg YWxyZWFkeSB0aGF0J3MgY2xlYW5lciB0byBqdXN0IGFkZCB1cyB0by4NCj4gICAgICANCj4g ICAgICBXZSBzaG91bGQgdXBzdHJlYW0gdGhpcy4NCj4gICAgICANCj4gICAgICBSZXZpZXdl ZCBieTogICAga2liIChlYXJsaWVyIHZlcnNpb24pLCBtYXJrag0KPiAgICAgIFNwb25zb3Jl ZCBieTogICBLbGFyYSwgSW5jLg0KPiAgICAgIFNwb25zb3JlZCBieTogICBTdG9ybXNoaWVs ZA0KPiAgICAgIERpZmZlcmVudGlhbCBSZXZpc2lvbjogIGh0dHBzOi8vcmV2aWV3cy5mcmVl YnNkLm9yZy9ENDU5NzYNCg0KQ3VyaW91c2x5LCB3aGlsZSB0aGlzIGJ1aWxkcyBmaW5lIG9u IEdDQyAxMywgaXQgZmFpbHMgZm9yIG1lIG9uIEdDQyAxNCAod2hpY2gNCkkndmUganVzdCBt YWRlIGEgcG9ydCBmb3IgYW5kIHN0YXJ0ZWQgdGVzdGluZyk6DQoNCi91c3IvbG9jYWwvYmlu L3g4Nl82NC11bmtub3duLWZyZWVic2QxNC4xLWdjYzE0IC0tc3lzcm9vdD0vdXNyL29iai9n Y2MxNC91c3IvaG9tZS9qb2huL3dvcmsvZnJlZWJzZC9tYWluL2FtZDY0LmFtZDY0L3RtcCAt Qi91c3IvbG9jYWwveDg2XzY0LXVua25vd24tZnJlZWJzZDE0LjEvYmluLyAgLU8yIC1waXBl IC1mbm8tY29tbW9uICAgLUkvdXNyL2hvbWUvam9obi93b3JrL2ZyZWVic2QvbWFpbi9jcnlw dG8vb3BlbnNzbCAtSS91c3IvaG9tZS9qb2huL3dvcmsvZnJlZWJzZC9tYWluL2NyeXB0by9v cGVuc3NsL2luY2x1ZGUgLUkvdXNyL2hvbWUvam9obi93b3JrL2ZyZWVic2QvbWFpbi9jcnlw dG8vb3BlbnNzbC9wcm92aWRlcnMvY29tbW9uL2luY2x1ZGUgLUkvdXNyL2hvbWUvam9obi93 b3JrL2ZyZWVic2QvbWFpbi9jcnlwdG8vb3BlbnNzbC9wcm92aWRlcnMvaW1wbGVtZW50YXRp b25zL2luY2x1ZGUgLURMX0VORElBTiAtRE9QRU5TU0xfQ1BVSURfT0JKIC1ET1BFTlNTTF9J QTMyX1NTRTIgLURPUEVOU1NMX0JOX0FTTV9NT05UIC1ET1BFTlNTTF9CTl9BU01fTU9OVDUg LURPUEVOU1NMX0JOX0FTTV9HRjJtIC1EU0hBMV9BU00gLURTSEEyNTZfQVNNIC1EU0hBNTEy X0FTTSAtREtFQ0NBSzE2MDBfQVNNIC1EUkM0X0FTTSAtRE1ENV9BU00gLURBRVNfQVNNIC1E QlNBRVNfQVNNIC1EVlBBRVNfQVNNIC1EV0hJUkxQT09MX0FTTSAtREdIQVNIX0FTTSAtRENN TExfQVNNIC1ERUNQX05JU1RaMjU2X0FTTSAtRFgyNTUxOV9BU00gLURQQURMT0NLX0FTTSAt RFBPTFkxMzA1X0FTTSAtRE9QRU5TU0xESVI9IlwiL2V0Yy9zc2xcIiIgLURFTkdJTkVTRElS PSJcIi91c3IvbGliL2VuZ2luZXMtM1wiIiAtRE1PRFVMRVNESVI9IlwiL3Vzci9saWIvb3Nz bC1tb2R1bGVzXCIiIC1ETkRFQlVHIC1JL3Vzci9ob21lL2pvaG4vd29yay9mcmVlYnNkL21h aW4vY3J5cHRvL29wZW5zc2wvY3J5cHRvIC1JL3Vzci9ob21lL2pvaG4vd29yay9mcmVlYnNk L21haW4vY3J5cHRvL29wZW5zc2wvY3J5cHRvL2VjL2N1cnZlNDQ4IC1JL3Vzci9ob21lL2pv aG4vd29yay9mcmVlYnNkL21haW4vY3J5cHRvL29wZW5zc2wvY3J5cHRvL2VjL2N1cnZlNDQ4 L2FyY2hfMzIgLUkvdXNyL2hvbWUvam9obi93b3JrL2ZyZWVic2QvbWFpbi9jcnlwdG8vb3Bl bnNzbC9jcnlwdG8vbW9kZXMgLUkvdXNyL29iai9nY2MxNC91c3IvaG9tZS9qb2huL3dvcmsv ZnJlZWJzZC9tYWluL2FtZDY0LmFtZDY0L3NlY3VyZS9saWIvbGliY3J5cHRvIC1nIC1NRCAg LU1GLmRlcGVuZC5yYW5kX3VuaXgubyAtTVRyYW5kX3VuaXgubyAtc3RkPWdudTk5IC1Xbm8t Zm9ybWF0LXplcm8tbGVuZ3RoIC1mc3RhY2stcHJvdGVjdG9yLXN0cm9uZyAtV25vLXBvaW50 ZXItc2lnbiAtV2RhdGUtdGltZSAtV25vLWVycm9yPWFkZHJlc3MgLVduby1lcnJvcj1hcnJh eS1ib3VuZHMgLVduby1lcnJvcj1hdHRyaWJ1dGVzIC1Xbm8tZXJyb3I9Ym9vbC1jb21wYXJl IC1Xbm8tZXJyb3I9Y2FzdC1hbGlnbiAtV25vLWVycm9yPWNsb2JiZXJlZCAtV25vLWVycm9y PWRlcHJlY2F0ZWQtZGVjbGFyYXRpb25zIC1Xbm8tZXJyb3I9ZW51bS1jb21wYXJlIC1Xbm8t ZXJyb3I9ZXh0cmEgLVduby1lcnJvcj1sb2dpY2FsLW5vdC1wYXJlbnRoZXNlcyAtV25vLWVy cm9yPXN0cmljdC1hbGlhc2luZyAtV25vLWVycm9yPXVuaW5pdGlhbGl6ZWQgLVduby1lcnJv cj11bnVzZWQtZnVuY3Rpb24gLVduby1lcnJvcj11bnVzZWQtdmFsdWUgLVduby1lcnJvcj1l bXB0eS1ib2R5IC1Xbm8tZXJyb3I9bWF5YmUtdW5pbml0aWFsaXplZCAtV25vLWVycm9yPW5v bm51bGwtY29tcGFyZSAtV25vLWVycm9yPXNoaWZ0LW5lZ2F0aXZlLXZhbHVlIC1Xbm8tZXJy b3I9dGF1dG9sb2dpY2FsLWNvbXBhcmUgLVduby1lcnJvcj11bnVzZWQtY29uc3QtdmFyaWFi bGUgLVduby1lcnJvcj1ib29sLW9wZXJhdGlvbiAtV25vLWVycm9yPWRlcHJlY2F0ZWQgLVdu by1lcnJvcj1leHBhbnNpb24tdG8tZGVmaW5lZCAtV25vLWVycm9yPWZvcm1hdC1vdmVyZmxv dyAtV25vLWVycm9yPWZvcm1hdC10cnVuY2F0aW9uIC1Xbm8tZXJyb3I9aW1wbGljaXQtZmFs bHRocm91Z2ggLVduby1lcnJvcj1pbnQtaW4tYm9vbC1jb250ZXh0IC1Xbm8tZXJyb3I9bWVt c2V0LWVsdC1zaXplIC1Xbm8tZXJyb3I9bm9leGNlcHQtdHlwZSAtV25vLWVycm9yPW5vbm51 bGwgLVduby1lcnJvcj1wb2ludGVyLWNvbXBhcmUgLVduby1lcnJvcj1zdHJpbmdvcC1vdmVy ZmxvdyAtV25vLWVycm9yPWFnZ3Jlc3NpdmUtbG9vcC1vcHRpbWl6YXRpb25zIC1Xbm8tZXJy b3I9Y2FzdC1mdW5jdGlvbi10eXBlIC1Xbm8tZXJyb3I9Y2F0Y2gtdmFsdWUgLVduby1lcnJv cj1tdWx0aXN0YXRlbWVudC1tYWNyb3MgLVduby1lcnJvcj1yZXN0cmljdCAtV25vLWVycm9y PXNpemVvZi1wb2ludGVyLW1lbWFjY2VzcyAtV25vLWVycm9yPXN0cmluZ29wLXRydW5jYXRp b24gLVduby1yZXR1cm4tdHlwZSAtV25vLWFkZHJlc3Mtb2YtcGFja2VkLW1lbWJlciAgICAg ICAtYyAvdXNyL2hvbWUvam9obi93b3JrL2ZyZWVic2QvbWFpbi9jcnlwdG8vb3BlbnNzbC9w cm92aWRlcnMvaW1wbGVtZW50YXRpb25zL3JhbmRzL3NlZWRpbmcvcmFuZF91bml4LmMgLW8g cmFuZF91bml4Lm8NCi91c3IvaG9tZS9qb2huL3dvcmsvZnJlZWJzZC9tYWluL2NyeXB0by9v cGVuc3NsL3Byb3ZpZGVycy9pbXBsZW1lbnRhdGlvbnMvcmFuZHMvc2VlZGluZy9yYW5kX3Vu aXguYzogSW4gZnVuY3Rpb24gJ3N5c2NhbGxfcmFuZG9tJzoNCi91c3IvaG9tZS9qb2huL3dv cmsvZnJlZWJzZC9tYWluL2NyeXB0by9vcGVuc3NsL3Byb3ZpZGVycy9pbXBsZW1lbnRhdGlv bnMvcmFuZHMvc2VlZGluZy9yYW5kX3VuaXguYzozOTk6MTI6IGVycm9yOiBpbXBsaWNpdCBk ZWNsYXJhdGlvbiBvZiBmdW5jdGlvbiAnZ2V0cmFuZG9tJzsgZGlkIHlvdSBtZWFuICdzcmFu ZG9tJz8gWy1XaW1wbGljaXQtZnVuY3Rpb24tZGVjbGFyYXRpb25dDQogICAzOTkgfCAgICAg cmV0dXJuIGdldHJhbmRvbShidWYsIGJ1ZmxlbiwgMCk7DQogICAgICAgfCAgICAgICAgICAg IF5+fn5+fn5+fg0KICAgICAgIHwgICAgICAgICAgICBzcmFuZG9tDQoqKiogRXJyb3IgY29k ZSAxDQoNClN0b3AuDQoNCkFuZCBpbiBmYWN0LCBnZXRyYW5kb20oKSBpcyBkZWNsYXJlZCBp biA8c3lzL3JhbmRvbS5oPiB3aGljaCBpc24ndCBpbmNsdWRlZA0KaW4gcmFuZF91bml4LmMg ZXhjZXB0IGZvciBEcmFnb25GbHk6DQoNCiNpZmRlZiBfX2xpbnV4DQojIGluY2x1ZGUgPHN5 cy9zeXNjYWxsLmg+DQojIGlmZGVmIERFVlJBTkRPTV9XQUlUDQojICBpbmNsdWRlIDxzeXMv c2htLmg+DQojICBpbmNsdWRlIDxzeXMvdXRzbmFtZS5oPg0KIyBlbmRpZg0KI2VuZGlmDQoj aWYgKGRlZmluZWQoX19GcmVlQlNEX18pIHx8IGRlZmluZWQoX19OZXRCU0RfXykpICYmICFk ZWZpbmVkKE9QRU5TU0xfU1lTX1VFRkkpDQojIGluY2x1ZGUgPHN5cy90eXBlcy5oPg0KIyBp bmNsdWRlIDxzeXMvc3lzY3RsLmg+DQojIGluY2x1ZGUgPHN5cy9wYXJhbS5oPg0KI2VuZGlm DQojaWYgZGVmaW5lZChfX09wZW5CU0RfXykNCiMgaW5jbHVkZSA8c3lzL3BhcmFtLmg+DQoj ZW5kaWYNCiNpZiBkZWZpbmVkKF9fRHJhZ29uRmx5X18pDQojIGluY2x1ZGUgPHN5cy9wYXJh bS5oPg0KIyBpbmNsdWRlIDxzeXMvcmFuZG9tLmg+DQojZW5kaWYNCg0KSSB0aGluayB3ZSBz aG91bGQgZml4IHRoaXMgaW5zdGVhZCB0byBtb3ZlIHRoZSBGcmVlQlNEIGRvd24gdG8gdGhl IERyYWdvbmZseSBjYXNlPw0KVGhhdCB3b3VsZCBiZXR0ZXIgbWF0Y2ggd2hhdCB5b3UgZGlk IGluIHRoZSBjb2RlIGNoYW5nZXMgYmVsb3cgSSB0aGluay4NCg0KWW91IGFsc28gbGVmdCBz eXNjdGxfcmFuZG9tKCkgZGVmaW5lZCAoYnV0IHVudXNlZCkgb24gRnJlZUJTRC4NCg0KPiAt LS0NCj4gICAuLi4vb3BlbnNzbC9wcm92aWRlcnMvaW1wbGVtZW50YXRpb25zL3JhbmRzL3Nl ZWRpbmcvcmFuZF91bml4LmMgIHwgOSArKysrKy0tLS0NCj4gICAxIGZpbGUgY2hhbmdlZCwg NSBpbnNlcnRpb25zKCspLCA0IGRlbGV0aW9ucygtKQ0KPiANCj4gZGlmZiAtLWdpdCBhL2Ny eXB0by9vcGVuc3NsL3Byb3ZpZGVycy9pbXBsZW1lbnRhdGlvbnMvcmFuZHMvc2VlZGluZy9y YW5kX3VuaXguYyBiL2NyeXB0by9vcGVuc3NsL3Byb3ZpZGVycy9pbXBsZW1lbnRhdGlvbnMv cmFuZHMvc2VlZGluZy9yYW5kX3VuaXguYw0KPiBpbmRleCA3NTBhZmNhNThlZDcuLmVhZGFj ZWRiZTQwYyAxMDA2NDQNCj4gLS0tIGEvY3J5cHRvL29wZW5zc2wvcHJvdmlkZXJzL2ltcGxl bWVudGF0aW9ucy9yYW5kcy9zZWVkaW5nL3JhbmRfdW5peC5jDQo+ICsrKyBiL2NyeXB0by9v cGVuc3NsL3Byb3ZpZGVycy9pbXBsZW1lbnRhdGlvbnMvcmFuZHMvc2VlZGluZy9yYW5kX3Vu aXguYw0KPiBAQCAtMzU2LDcgKzM1Niw3IEBAIHN0YXRpYyBzc2l6ZV90IHN5c2NhbGxfcmFu ZG9tKHZvaWQgKmJ1Ziwgc2l6ZV90IGJ1ZmxlbikNCj4gICAgICAgICogTm90ZTogU29tZXRp bWVzIGdldGVudHJvcHkoKSBjYW4gYmUgcHJvdmlkZWQgYnV0IG5vdCBpbXBsZW1lbnRlZA0K PiAgICAgICAgKiBpbnRlcm5hbGx5LiBTbyB3ZSBuZWVkIHRvIGNoZWNrIGVycm5vIGZvciBF Tk9TWVMNCj4gICAgICAgICovDQo+IC0jICBpZiAhZGVmaW5lZChfX0RyYWdvbkZseV9fKSAm JiAhZGVmaW5lZChfX05ldEJTRF9fKQ0KPiArIyAgaWYgIWRlZmluZWQoX19EcmFnb25GbHlf XykgJiYgIWRlZmluZWQoX19OZXRCU0RfXykgJiYgIWRlZmluZWQoX19GcmVlQlNEX18pDQo+ ICAgIyAgICBpZiBkZWZpbmVkKF9fR05VQ19fKSAmJiBfX0dOVUNfXz49MiAmJiBkZWZpbmVk KF9fRUxGX18pICYmICFkZWZpbmVkKF9faHB1eCkNCj4gICAgICAgZXh0ZXJuIGludCBnZXRl bnRyb3B5KHZvaWQgKmJ1ZmZlciwgc2l6ZV90IGxlbmd0aCkgX19hdHRyaWJ1dGVfXygod2Vh aykpOw0KPiAgIA0KPiBAQCAtMzkzLDExICszOTMsMTIgQEAgc3RhdGljIHNzaXplX3Qgc3lz Y2FsbF9yYW5kb20odm9pZCAqYnVmLCBzaXplX3QgYnVmbGVuKQ0KPiAgICAgICAvKiBMaW51 eCBzdXBwb3J0cyB0aGlzIHNpbmNlIHZlcnNpb24gMy4xNyAqLw0KPiAgICMgIGlmIGRlZmlu ZWQoX19saW51eCkgJiYgZGVmaW5lZChfX05SX2dldHJhbmRvbSkNCj4gICAgICAgcmV0dXJu IHN5c2NhbGwoX19OUl9nZXRyYW5kb20sIGJ1ZiwgYnVmbGVuLCAwKTsNCj4gLSMgIGVsaWYg KGRlZmluZWQoX19GcmVlQlNEX18pIHx8IGRlZmluZWQoX19OZXRCU0RfXykpICYmIGRlZmlu ZWQoS0VSTl9BUk5EKQ0KPiAtICAgIHJldHVybiBzeXNjdGxfcmFuZG9tKGJ1ZiwgYnVmbGVu KTsNCj4gICAjICBlbGlmIChkZWZpbmVkKF9fRHJhZ29uRmx5X18pICAmJiBfX0RyYWdvbkZs eV92ZXJzaW9uID49IDUwMDcwMCkgXA0KPiAtICAgICB8fCAoZGVmaW5lZChfX05ldEJTRF9f KSAmJiBfX05ldEJTRF9WZXJzaW9uID49IDEwMDAwMDAwMDApDQo+ICsgICAgIHx8IChkZWZp bmVkKF9fTmV0QlNEX18pICYmIF9fTmV0QlNEX1ZlcnNpb24gPj0gMTAwMDAwMDAwMCkgXA0K PiArICAgICB8fCBkZWZpbmVkKF9fRnJlZUJTRF9fKQ0KPiAgICAgICByZXR1cm4gZ2V0cmFu ZG9tKGJ1ZiwgYnVmbGVuLCAwKTsNCj4gKyMgIGVsaWYgZGVmaW5lZChfX05ldEJTRF9fKSAm JiBkZWZpbmVkKEtFUk5fQVJORCkNCj4gKyAgICByZXR1cm4gc3lzY3RsX3JhbmRvbShidWYs IGJ1Zmxlbik7DQo+ICAgIyAgZWxzZQ0KPiAgICAgICBlcnJubyA9IEVOT1NZUzsNCj4gICAg ICAgcmV0dXJuIC0xOw0KDQotLSANCkpvaG4gQmFsZHdpbg0KDQo= From nobody Wed Jul 17 14:21:36 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ5r4JHvz5RPR3; Wed, 17 Jul 2024 14:21: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ5r25CMz4shT; Wed, 17 Jul 2024 14:21:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226096; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=I8r9Vf1U81g3SDSYjHJVCVxNFVosu9pwi/piDufBuXY=; b=XjvEy3buWbFag1yb3SclADXZvudzGlyjS1m6m0lsVDy/t/fSVFoU+IRusPDeDoZQYajSpU yHLFRj11io0+3XxGLEpM3sBYsGfFAO1uKYtGwRKYJjDzgb/f8+Y93r3Sk+t6e+EKSLl19O dk7Ilufb3ef/SKhLs92GY0q6XP4JmUwRktfJKOf1lX1UeVQ0N2Iy5FiwIFJjizS2IJAO52 36XOtbfOTN3geSQAO99Hva/mkswykBeMeSVC1uK+T2henMhdt6OC3ElrHFDv4Pw4MZyQ78 tuHnQ5kBg4RuWp502466AvVALs0sKCZNWzqNssNnT8uXh3jKQu3uAN5ARuflww== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226096; a=rsa-sha256; cv=none; b=jT5OVHQiyei/e74T41IkpcPaMX6XYVK85QRY+wK+KWOjod4UmhKvag+vb20FCgzLPuzeJ4 jXpu7ppaGLravHM+JXL7Imml5owJMv0j23XbqfGcrqV9eS388r0u/VMDZXBAr7L4LkJO0X rjyKDq9dr17YzckK1Lo6LJvLV4lozGRHWDC7PIt4CeZBg9xJ5WmXoS7XyDfSFSMadMBXp5 a5TYgm8CcisRgcwC0H8eM5PUXaeNmxfumnU8Q5qnJXgkOKqO2g+cYzBG+5Lm3mBNg7rL04 9LRzxaKTzaJUZ6uy5PMGdgNjWVc4DPsWEC8VTYNdUAPtl2uwb5yrF4KuI1m2LQ== 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=1721226096; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=I8r9Vf1U81g3SDSYjHJVCVxNFVosu9pwi/piDufBuXY=; b=BsueZf7BNmqoLFIduPKLfL2Sm74fc8zT7J/HRntummMmniYBJcywFrKYFqmVDpyoFluHZR vctsq2TKak68T2QVPz7AfNWTpPgDt0wt7ZfIY0hlciZXa7hOXAwWIviVNWsnhqkqPXjvPu D8dKlo3OxW9nuc/V9F58bWv7o/H2kenZYGptmxxR2ijKmgbmPwtZVqzGxvPksePukMurS5 oeL2A2MguFTMWDUREeU+dSzhEZ0BBO/3LRnnFcbCbcbKOTafim5JXnvtqCKMIG0vjbQUd/ 3For5JFmWRuqOQ6fPa9iFpN82l8BbDe4xeuWSu5dLws3s4RKoAmVaMnCIS8GdQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ5r1jHnz1Lnq; Wed, 17 Jul 2024 14:21:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HELa6d026770; Wed, 17 Jul 2024 14:21:36 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HELaIi026767; Wed, 17 Jul 2024 14:21:36 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:21:36 GMT Message-Id: <202407171421.46HELaIi026767@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 1089f5755e11 - stable/14 - cxgbe(4): Remove tx_modq lookup table. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 1089f5755e1131ad13adea0d2c7ac17be024c494 Auto-Submitted: auto-generated The branch stable/14 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=1089f5755e1131ad13adea0d2c7ac17be024c494 commit 1089f5755e1131ad13adea0d2c7ac17be024c494 Author: Navdeep Parhar AuthorDate: 2024-03-29 05:49:32 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 06:27:14 +0000 cxgbe(4): Remove tx_modq lookup table. The driver always uses the same modulation queue as the channel and the table is unnecessary. Sponsored by: Chelsio Communications (cherry picked from commit f76effed14b25bfa0c47b10f6d8a076104c48d94) --- sys/dev/cxgbe/common/common.h | 4 +++- sys/dev/cxgbe/common/t4_hw.c | 5 ----- sys/dev/cxgbe/crypto/t6_kern_tls.c | 4 ++-- sys/dev/cxgbe/tom/t4_tom.c | 2 +- 4 files changed, 6 insertions(+), 9 deletions(-) diff --git a/sys/dev/cxgbe/common/common.h b/sys/dev/cxgbe/common/common.h index 0871ca8c40f1..634474470e17 100644 --- a/sys/dev/cxgbe/common/common.h +++ b/sys/dev/cxgbe/common/common.h @@ -252,7 +252,6 @@ struct tp_params { unsigned int tre; /* log2 of core clocks per TP tick */ unsigned int dack_re; /* DACK timer resolution */ unsigned int la_mask; /* what events are recorded by TP LA */ - unsigned short tx_modq[MAX_NCHAN]; /* channel to modulation queue map */ uint16_t filter_mode; uint16_t filter_mask; /* Used by TOE and hashfilters */ @@ -273,6 +272,9 @@ struct tp_params { int8_t frag_shift; }; +/* Use same modulation queue as the tx channel. */ +#define TX_MODQ(tx_chan) (tx_chan) + struct vpd_params { unsigned int cclk; u8 ec[EC_LEN + 1]; diff --git a/sys/dev/cxgbe/common/t4_hw.c b/sys/dev/cxgbe/common/t4_hw.c index c428fd2720cd..30dedd91262c 100644 --- a/sys/dev/cxgbe/common/t4_hw.c +++ b/sys/dev/cxgbe/common/t4_hw.c @@ -9800,7 +9800,6 @@ read_filter_mode_and_ingress_config(struct adapter *adap) */ int t4_init_tp_params(struct adapter *adap) { - int chan; u32 tx_len, rx_len, r, v; struct tp_params *tpp = &adap->params.tp; @@ -9808,10 +9807,6 @@ int t4_init_tp_params(struct adapter *adap) tpp->tre = G_TIMERRESOLUTION(v); tpp->dack_re = G_DELAYEDACKRESOLUTION(v); - /* MODQ_REQ_MAP defaults to setting queues 0-3 to chan 0-3 */ - for (chan = 0; chan < MAX_NCHAN; chan++) - tpp->tx_modq[chan] = chan; - read_filter_mode_and_ingress_config(adap); if (chip_id(adap) > CHELSIO_T5) { diff --git a/sys/dev/cxgbe/crypto/t6_kern_tls.c b/sys/dev/cxgbe/crypto/t6_kern_tls.c index 6b684c952647..2173cb670874 100644 --- a/sys/dev/cxgbe/crypto/t6_kern_tls.c +++ b/sys/dev/cxgbe/crypto/t6_kern_tls.c @@ -171,7 +171,7 @@ mk_ktls_act_open_req(struct adapter *sc, struct vi_info *vi, struct inpcb *inp, options |= F_NON_OFFLOAD; cpl->opt0 = htobe64(options); - options = V_TX_QUEUE(sc->params.tp.tx_modq[vi->pi->tx_chan]); + options = V_TX_QUEUE(TX_MODQ(vi->pi->tx_chan)); if (tp->t_flags & TF_REQ_TSTMP) options |= F_TSTAMPS_EN; cpl->opt2 = htobe32(options); @@ -206,7 +206,7 @@ mk_ktls_act_open_req6(struct adapter *sc, struct vi_info *vi, options |= F_NON_OFFLOAD; cpl->opt0 = htobe64(options); - options = V_TX_QUEUE(sc->params.tp.tx_modq[vi->pi->tx_chan]); + options = V_TX_QUEUE(TX_MODQ(vi->pi->tx_chan)); if (tp->t_flags & TF_REQ_TSTMP) options |= F_TSTAMPS_EN; cpl->opt2 = htobe32(options); diff --git a/sys/dev/cxgbe/tom/t4_tom.c b/sys/dev/cxgbe/tom/t4_tom.c index 4d4400512ef5..b2d0b85e4832 100644 --- a/sys/dev/cxgbe/tom/t4_tom.c +++ b/sys/dev/cxgbe/tom/t4_tom.c @@ -1202,7 +1202,7 @@ calc_options2(struct vi_info *vi, struct conn_params *cp) /* XXX: F_RX_CHANNEL for multiple rx c-chan support goes here. */ - opt2 |= V_TX_QUEUE(sc->params.tp.tx_modq[pi->tx_chan]); + opt2 |= V_TX_QUEUE(TX_MODQ(pi->tx_chan)); opt2 |= V_PACE(0); opt2 |= F_RSS_QUEUE_VALID; opt2 |= V_RSS_QUEUE(sc->sge.ofld_rxq[cp->rxq_idx].iq.abs_id); From nobody Wed Jul 17 14:21:37 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ5s3qwFz5RPTG; Wed, 17 Jul 2024 14:21: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ5s3B2nz4shV; Wed, 17 Jul 2024 14:21:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226097; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=0rtdp2i1L65BGQKZkzTDV+7wElMOajJKK3SvdR5btms=; b=s6z6619HPg5XfHcCJmrAG7TLQBoXeHi7Xpcx3IzP9ddKGWZ4bkhOrQ06BKx/btZWbN33ys VTyrYmIkU0Hc7oFHfWhwSV3RLqNQGuEtZTk70y5UdL5b+uQZb3JUgZf47Xu6/AecAPwcTc byBbOymJQfqXSdFApw71wNcJAq2Ng/Dfs7ifbNiJQDHtyzvkv03SXa0UQDmvMUzaitBF3p DgBh4Pr+YFRQ0H8ztqtC8Xy/OxaqKEM/CCBu880VO55Q1qkSa734ItdpD36pmxInNPIdGg vmEPMCLuRxAmfmFuQ6gehkX3TtXo+pipTWOp1GGjE3jcaV47pWBT271bKlFc3A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226097; a=rsa-sha256; cv=none; b=ahSYgm6/Xky0ZVoe8DFmErE2NutKyVFt4v44gXhpiIR0VdBhk1Pbk5gVDNU1TeBGv7Fe1g +bkBZovsfd5/fOv1H050OrhiWT1Wy5PFCc3xM31FeG41KIwW+IipMYHiiXQxaDoc9vD+OG /ltUnAEvJ4urSWSZBI7cB2/5cnvd3cIOsH3FMhBmCFdY9nU8E/klqrhC/XGUcxk0iHPs8C H9JGROS8lT0WKpwx1VCmKOAET8sMBfPJdM0EdB+PyrXc2eHvnmWEpdNmdF6DNS8E0iO4j1 eZCoWR2Gm4H4THN1eFvsIvmVwFOUcIIZz/eiWM5nkahunZodCwiltv48VqQb0Q== 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=1721226097; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=0rtdp2i1L65BGQKZkzTDV+7wElMOajJKK3SvdR5btms=; b=fUF8nMpfwqzpBNCfOKL0A6jyK9kt4d2fy8hsDBx0Nka/PYcDi7sAtqoJL5lf8ZTvcZY21C iZ51iU9JWscVsXHQBPCozU7SrSuWK18QxsLx/WKWsBKqq1S2WhcIIZiqHAviar4tTGz4wg jNFkB9HmR56wfFTmfWlfQkuITjn7+2RU17pIQ8MDJMYRHHaySmyccfOCalOSNVA4sGNAqX ex9tTy1HX7zY5tP730nm/Q+OdMMMx7ocgKR2VEBuzLa4N5AxgNS7HYvc7qQQfR+BCQOufe G3+nbhBn6I6N1GZYFn1eWjftqEL67Tbv6Zjp0aJ0wyteBzqIAvyG7Ax1XdniUQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ5s2ngFz1Mcw; Wed, 17 Jul 2024 14:21:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HELbO9026824; Wed, 17 Jul 2024 14:21:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HELbge026821; Wed, 17 Jul 2024 14:21:37 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:21:37 GMT Message-Id: <202407171421.46HELbge026821@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 41309c878de3 - stable/14 - cxgbe(4): Add a helper function to locate MPS/MAC registers. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 41309c878de3ef87fcfefb9326f3cb28bd910a20 Auto-Submitted: auto-generated The branch stable/14 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=41309c878de3ef87fcfefb9326f3cb28bd910a20 commit 41309c878de3ef87fcfefb9326f3cb28bd910a20 Author: Navdeep Parhar AuthorDate: 2024-04-25 05:24:49 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 06:35:30 +0000 cxgbe(4): Add a helper function to locate MPS/MAC registers. These register blocks are at different locations in different chips. Sponsored by: Chelsio Communications (cherry picked from commit b59c5d97edf17525405d95b1f5746c4a79a9c7c4) --- sys/dev/cxgbe/common/common.h | 1 + sys/dev/cxgbe/common/t4_hw.c | 37 +++++++++++++++++-------------------- sys/dev/cxgbe/t4_main.c | 14 +++++--------- 3 files changed, 23 insertions(+), 29 deletions(-) diff --git a/sys/dev/cxgbe/common/common.h b/sys/dev/cxgbe/common/common.h index 634474470e17..3d546c2f976f 100644 --- a/sys/dev/cxgbe/common/common.h +++ b/sys/dev/cxgbe/common/common.h @@ -722,6 +722,7 @@ int t4_set_vf_mac(struct adapter *adapter, unsigned int pf, unsigned int vf, unsigned int t4_get_regs_len(struct adapter *adapter); void t4_get_regs(struct adapter *adap, u8 *buf, size_t buf_size); +u32 t4_port_reg(struct adapter *adap, u8 port, u32 reg); const char *t4_get_port_type_description(enum fw_port_type port_type); void t4_get_port_stats(struct adapter *adap, int idx, struct port_stats *p); void t4_get_port_stats_offset(struct adapter *adap, int idx, diff --git a/sys/dev/cxgbe/common/t4_hw.c b/sys/dev/cxgbe/common/t4_hw.c index 30dedd91262c..cf4f5a65c3e5 100644 --- a/sys/dev/cxgbe/common/t4_hw.c +++ b/sys/dev/cxgbe/common/t4_hw.c @@ -243,18 +243,21 @@ struct port_tx_state { uint64_t tx_frames; }; +u32 +t4_port_reg(struct adapter *adap, u8 port, u32 reg) +{ + if (chip_id(adap) > CHELSIO_T4) + return T5_PORT_REG(port, reg); + return PORT_REG(port, reg); +} + static void read_tx_state_one(struct adapter *sc, int i, struct port_tx_state *tx_state) { uint32_t rx_pause_reg, tx_frames_reg; - if (is_t4(sc)) { - tx_frames_reg = PORT_REG(i, A_MPS_PORT_STAT_TX_PORT_FRAMES_L); - rx_pause_reg = PORT_REG(i, A_MPS_PORT_STAT_RX_PORT_PAUSE_L); - } else { - tx_frames_reg = T5_PORT_REG(i, A_MPS_PORT_STAT_TX_PORT_FRAMES_L); - rx_pause_reg = T5_PORT_REG(i, A_MPS_PORT_STAT_RX_PORT_PAUSE_L); - } + rx_pause_reg = t4_port_reg(sc, i, A_MPS_PORT_STAT_RX_PORT_PAUSE_L); + tx_frames_reg = t4_port_reg(sc, i, A_MPS_PORT_STAT_TX_PORT_FRAMES_L); tx_state->rx_pause = t4_read_reg64(sc, rx_pause_reg); tx_state->tx_frames = t4_read_reg64(sc, tx_frames_reg); @@ -281,10 +284,7 @@ check_tx_state(struct adapter *sc, struct port_tx_state *tx_state) tx_frames = tx_state[i].tx_frames; read_tx_state_one(sc, i, &tx_state[i]); /* update */ - if (is_t4(sc)) - port_ctl_reg = PORT_REG(i, A_MPS_PORT_CTL); - else - port_ctl_reg = T5_PORT_REG(i, A_MPS_PORT_CTL); + port_ctl_reg = t4_port_reg(sc, i, A_MPS_PORT_CTL); if (t4_read_reg(sc, port_ctl_reg) & F_PORTTXEN && rx_pause != tx_state[i].rx_pause && tx_frames == tx_state[i].tx_frames) { @@ -6952,8 +6952,7 @@ void t4_get_port_stats(struct adapter *adap, int idx, struct port_stats *p) #define GET_STAT(name) \ t4_read_reg64(adap, \ - (is_t4(adap) ? PORT_REG(pi->tx_chan, A_MPS_PORT_STAT_##name##_L) : \ - T5_PORT_REG(pi->tx_chan, A_MPS_PORT_STAT_##name##_L))) + t4_port_reg(adap, pi->tx_chan, A_MPS_PORT_STAT_##name##_L)); #define GET_STAT_COM(name) t4_read_reg64(adap, A_MPS_STAT_##name##_L) p->tx_pause = GET_STAT(TX_PORT_PAUSE); @@ -7054,9 +7053,7 @@ void t4_get_lb_stats(struct adapter *adap, int idx, struct lb_port_stats *p) #define GET_STAT(name) \ t4_read_reg64(adap, \ - (is_t4(adap) ? \ - PORT_REG(idx, A_MPS_PORT_STAT_LB_PORT_##name##_L) : \ - T5_PORT_REG(idx, A_MPS_PORT_STAT_LB_PORT_##name##_L))) + t4_port_reg(adap, idx, A_MPS_PORT_STAT_LB_PORT_##name##_L)) #define GET_STAT_COM(name) t4_read_reg64(adap, A_MPS_STAT_##name##_L) p->octets = GET_STAT(BYTES); @@ -9436,16 +9433,16 @@ int t4_shutdown_adapter(struct adapter *adapter) t4_write_reg(adapter, A_DBG_GPIO_EN, 0xffff0000); for_each_port(adapter, port) { u32 a_port_cfg = is_t4(adapter) ? - PORT_REG(port, A_XGMAC_PORT_CFG) : - T5_PORT_REG(port, A_MAC_PORT_CFG); + t4_port_reg(adapter, port, A_XGMAC_PORT_CFG) : + t4_port_reg(adapter, port, A_MAC_PORT_CFG); t4_write_reg(adapter, a_port_cfg, t4_read_reg(adapter, a_port_cfg) & ~V_SIGNAL_DET(1)); if (!bt) { u32 hss_cfg0 = is_t4(adapter) ? - PORT_REG(port, A_XGMAC_PORT_HSS_CFG0) : - T5_PORT_REG(port, A_MAC_PORT_HSS_CFG0); + t4_port_reg(adapter, port, A_XGMAC_PORT_HSS_CFG0) : + t4_port_reg(adapter, port, A_MAC_PORT_HSS_CFG0); t4_set_reg_field(adapter, hss_cfg0, F_HSSPDWNPLLB | F_HSSPDWNPLLA | F_HSSPLLBYPB | F_HSSPLLBYPA, F_HSSPDWNPLLB | F_HSSPDWNPLLA | F_HSSPLLBYPB | diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c index 128d2ae65611..d56a42eee8f4 100644 --- a/sys/dev/cxgbe/t4_main.c +++ b/sys/dev/cxgbe/t4_main.c @@ -1411,13 +1411,10 @@ t4_attach(device_t dev) * depends on the link settings which will be known when the * link comes up. */ - if (is_t6(sc)) { + if (is_t6(sc)) pi->fcs_reg = -1; - } else if (is_t4(sc)) { - pi->fcs_reg = PORT_REG(pi->tx_chan, - A_MPS_PORT_STAT_RX_PORT_CRC_ERROR_L); - } else { - pi->fcs_reg = T5_PORT_REG(pi->tx_chan, + else { + pi->fcs_reg = t4_port_reg(sc, pi->tx_chan, A_MPS_PORT_STAT_RX_PORT_CRC_ERROR_L); } pi->fcs_base = 0; @@ -8025,9 +8022,8 @@ cxgbe_sysctls(struct port_info *pi) #define T4_REGSTAT(name, stat, desc) \ SYSCTL_ADD_OID(ctx, children, OID_AUTO, #name, \ - CTLTYPE_U64 | CTLFLAG_RD | CTLFLAG_MPSAFE, sc, \ - (is_t4(sc) ? PORT_REG(pi->tx_chan, A_MPS_PORT_STAT_##stat##_L) : \ - T5_PORT_REG(pi->tx_chan, A_MPS_PORT_STAT_##stat##_L)), \ + CTLTYPE_U64 | CTLFLAG_RD | CTLFLAG_MPSAFE, sc, \ + t4_port_reg(sc, pi->tx_chan, A_MPS_PORT_STAT_##stat##_L), \ sysctl_handle_t4_reg64, "QU", desc) /* We get these from port_stats and they may be stale by up to 1s */ From nobody Wed Jul 17 14:21:38 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ5t6sVTz5RPg1; Wed, 17 Jul 2024 14:21: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ5t4KKYz4shX; Wed, 17 Jul 2024 14:21:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226098; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=aA1kP5YtXkhT6KKh0EMRPWkJBGyW4+NqGDfXdVlqjjA=; b=bEBKU2+BGMj+cvxhtrenx7Fe+kqoG2Pyn+NaMaoT7x/f7lJzGr0Qll9cvmxjiNlFB1JCYm hP/f3yA/65fAtnjVQ+m38D5zaaVlE8qdd97cr3ZvOmDK+UA2kySA2y8RnZ6vJrxVhE+ubt AxnRwVCJYmOwnj0JMZAFMffQBlfzGfbP+PmRObUv243nYYRUO5EswLbeFE+MlhNk+kY6R6 5voKRIgBkaChjuMmDObPkzC7rlV/fw11LihyQtSP86fDovjcJKDSek66SZPsxe4KLhN0jC Kao3oQgXf++NjRCSopAqRzbFgGaglz1EOjOxSFo3LPfShhLoLKmHPDLEzxIXog== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226098; a=rsa-sha256; cv=none; b=GCzD0EbNS/kJp2ke+YTlztXwnqFQ9veQGdIR41PWp6UFeIoDhMrsTNQBMGlAJb5plJi+Jf mFrGuG8YDpcrW+dE4VcsNFsEyo4gWbe1ckNFoicOB92tzgOdz9pkexlk9di/OjRV2OqSvi Dri7drJt0plZ+q2+ELa2WqsuKZra35vqsfzwBiOPLOKRrXc6+TQOZx7Cp+2HsnzEOlE0xA 1fLD0Ya4FKwxn2H4UVWIify2ndpmbOv6tsp/5wgggxyp2/vNt+/pv+mab9Z2vTZ+nzR6xr ZXcOBVBgDlWiKI2wH8fEq/BvORcw6uAtChDB9OUZ3mVBtL4i4fbsfQoPsW/AcA== 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=1721226098; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=aA1kP5YtXkhT6KKh0EMRPWkJBGyW4+NqGDfXdVlqjjA=; b=rp3ACDqCKtYo0BxbNvICE4NCJfHVyRA9R3lsEJswbFxdzJb5KpgNIcT6Ox6/JspavKwPe1 ZxLwscrTjTzI/TBtzHYrYjZWcibz3tPhy1RRcYpVTEoGi9lf1Gj53kg+aUYYzXVU8zZwrp pn0clDN4+uIH8Q0b9p01KuUfrtdU5jRhTUFsy3r7vSeULxWERmiu3/keaqo7p8LvEoH6Xp psrfESKEov+47GVcv2AYV+hWUHjzOmddkKpQuwzhEUsZWq8LgzUWaKSfde5CFsfikFeEQz y8EUJ3CsCT8p23Gp6ISD/c8Ja5ibIhdPscFORddzLzu9qZvNfFCaLAM7Z7akRw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ5t3r41z1Mmc; Wed, 17 Jul 2024 14:21:38 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HELcNr026863; Wed, 17 Jul 2024 14:21:38 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HELc44026860; Wed, 17 Jul 2024 14:21:38 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:21:38 GMT Message-Id: <202407171421.46HELc44026860@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 6bc34cdd9671 - stable/14 - cxgbe(4): Retire t4_intr_clear. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 6bc34cdd9671bfd3ccfc02d91b8e118482e6e2d3 Auto-Submitted: auto-generated The branch stable/14 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=6bc34cdd9671bfd3ccfc02d91b8e118482e6e2d3 commit 6bc34cdd9671bfd3ccfc02d91b8e118482e6e2d3 Author: Navdeep Parhar AuthorDate: 2024-04-26 00:39:55 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 06:35:55 +0000 cxgbe(4): Retire t4_intr_clear. The firmware clears the interrupts already and it has a better idea of exactly what to clear for which generation of the ASIC. There is no need for the driver to get involved. Sponsored by: Chelsio Communications (cherry picked from commit 1c7f9c8b4673abf3723be09afed4443261e0d186) --- sys/dev/cxgbe/common/common.h | 1 - sys/dev/cxgbe/common/t4_hw.c | 93 ------------------------------------------- sys/dev/cxgbe/t4_main.c | 2 - 3 files changed, 96 deletions(-) diff --git a/sys/dev/cxgbe/common/common.h b/sys/dev/cxgbe/common/common.h index 3d546c2f976f..f43ffc83dff1 100644 --- a/sys/dev/cxgbe/common/common.h +++ b/sys/dev/cxgbe/common/common.h @@ -618,7 +618,6 @@ struct fw_filter_wr; void t4_intr_enable(struct adapter *adapter); void t4_intr_disable(struct adapter *adapter); -void t4_intr_clear(struct adapter *adapter); bool t4_slow_intr_handler(struct adapter *adapter, bool verbose); int t4_hash_mac_addr(const u8 *addr); diff --git a/sys/dev/cxgbe/common/t4_hw.c b/sys/dev/cxgbe/common/t4_hw.c index cf4f5a65c3e5..b58d9f5df0d9 100644 --- a/sys/dev/cxgbe/common/t4_hw.c +++ b/sys/dev/cxgbe/common/t4_hw.c @@ -5454,99 +5454,6 @@ void t4_intr_disable(struct adapter *adap) t4_set_reg_field(adap, A_PL_INT_MAP0, 1 << adap->pf, 0); } -/** - * t4_intr_clear - clear all interrupts - * @adap: the adapter whose interrupts should be cleared - * - * Clears all interrupts. The caller must be a PCI function managing - * global interrupts. - */ -void t4_intr_clear(struct adapter *adap) -{ - static const u32 cause_reg[] = { - A_CIM_HOST_INT_CAUSE, - A_CIM_HOST_UPACC_INT_CAUSE, - MYPF_REG(A_CIM_PF_HOST_INT_CAUSE), - A_CPL_INTR_CAUSE, - EDC_REG(A_EDC_INT_CAUSE, 0), EDC_REG(A_EDC_INT_CAUSE, 1), - A_LE_DB_INT_CAUSE, - A_MA_INT_WRAP_STATUS, - A_MA_PARITY_ERROR_STATUS1, - A_MA_INT_CAUSE, - A_MPS_CLS_INT_CAUSE, - A_MPS_RX_PERR_INT_CAUSE, - A_MPS_STAT_PERR_INT_CAUSE_RX_FIFO, - A_MPS_STAT_PERR_INT_CAUSE_SRAM, - A_MPS_TRC_INT_CAUSE, - A_MPS_TX_INT_CAUSE, - A_MPS_STAT_PERR_INT_CAUSE_TX_FIFO, - A_NCSI_INT_CAUSE, - A_PCIE_INT_CAUSE, - A_PCIE_NONFAT_ERR, - A_PL_PL_INT_CAUSE, - A_PM_RX_INT_CAUSE, - A_PM_TX_INT_CAUSE, - A_SGE_INT_CAUSE1, - A_SGE_INT_CAUSE2, - A_SGE_INT_CAUSE3, - A_SGE_INT_CAUSE4, - A_SMB_INT_CAUSE, - A_TP_INT_CAUSE, - A_ULP_RX_INT_CAUSE, - A_ULP_RX_INT_CAUSE_2, - A_ULP_TX_INT_CAUSE, - A_ULP_TX_INT_CAUSE_2, - - MYPF_REG(A_PL_PF_INT_CAUSE), - }; - int i; - const int nchan = adap->chip_params->nchan; - - for (i = 0; i < ARRAY_SIZE(cause_reg); i++) - t4_write_reg(adap, cause_reg[i], 0xffffffff); - - if (is_t4(adap)) { - t4_write_reg(adap, A_PCIE_CORE_UTL_SYSTEM_BUS_AGENT_STATUS, - 0xffffffff); - t4_write_reg(adap, A_PCIE_CORE_UTL_PCI_EXPRESS_PORT_STATUS, - 0xffffffff); - t4_write_reg(adap, A_MC_INT_CAUSE, 0xffffffff); - for (i = 0; i < nchan; i++) { - t4_write_reg(adap, PORT_REG(i, A_XGMAC_PORT_INT_CAUSE), - 0xffffffff); - } - } - if (chip_id(adap) >= CHELSIO_T5) { - t4_write_reg(adap, A_MA_PARITY_ERROR_STATUS2, 0xffffffff); - t4_write_reg(adap, A_MPS_STAT_PERR_INT_CAUSE_SRAM1, 0xffffffff); - t4_write_reg(adap, A_SGE_INT_CAUSE5, 0xffffffff); - t4_write_reg(adap, A_MC_P_INT_CAUSE, 0xffffffff); - if (is_t5(adap)) { - t4_write_reg(adap, MC_REG(A_MC_P_INT_CAUSE, 1), - 0xffffffff); - } - for (i = 0; i < nchan; i++) { - t4_write_reg(adap, T5_PORT_REG(i, - A_MAC_PORT_PERR_INT_CAUSE), 0xffffffff); - if (chip_id(adap) > CHELSIO_T5) { - t4_write_reg(adap, T5_PORT_REG(i, - A_MAC_PORT_PERR_INT_CAUSE_100G), - 0xffffffff); - } - t4_write_reg(adap, T5_PORT_REG(i, A_MAC_PORT_INT_CAUSE), - 0xffffffff); - } - } - if (chip_id(adap) >= CHELSIO_T6) { - t4_write_reg(adap, A_SGE_INT_CAUSE6, 0xffffffff); - } - - t4_write_reg(adap, A_MPS_INT_CAUSE, is_t4(adap) ? 0 : 0xffffffff); - t4_write_reg(adap, A_PL_PERR_CAUSE, 0xffffffff); - t4_write_reg(adap, A_PL_INT_CAUSE, 0xffffffff); - (void) t4_read_reg(adap, A_PL_INT_CAUSE); /* flush */ -} - /** * hash_mac_addr - return the hash value of a MAC address * @addr: the 48-bit Ethernet MAC address diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c index d56a42eee8f4..04e4427732ac 100644 --- a/sys/dev/cxgbe/t4_main.c +++ b/sys/dev/cxgbe/t4_main.c @@ -1338,7 +1338,6 @@ t4_attach(device_t dev) rc = partition_resources(sc); if (rc != 0) goto done; /* error message displayed already */ - t4_intr_clear(sc); } rc = get_params__post_init(sc); @@ -2298,7 +2297,6 @@ t4_resume(device_t dev) rc = partition_resources(sc); if (rc != 0) goto done; /* error message displayed already */ - t4_intr_clear(sc); } rc = get_params__post_init(sc); From nobody Wed Jul 17 14:21:39 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ5w1y3Zz5RPjZ; Wed, 17 Jul 2024 14:21: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ5v579Lz4shl; Wed, 17 Jul 2024 14:21:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226099; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6bKHTRiIS47yP1TahVd9KAN+LVnHd+/pS1ZnEQ+EXWw=; b=D3DmRWl86TPUMCdXoUESYi4KlXijkmBcwRv2Un+ADYAstkLpQp7GGYiLqeeLu0rYm/HVtf hQ+ASqLu9BpSjECS9WRB57vY4HpgV8c6tu1jAsi+w6IzVv7I+QqcX0fLDv6yeqtRA7AgV/ OHRzHLjwKQAO/78cYpEKTwRWryRKprkbJhW0dg+0WEZG8UxHqgVAc8ddoZKOrSHTknfEfV darsdJ1xvYimyqVskbgBx+zmMOIt8yUkd8iXaHyHWSSfWFi0F+qfU6lM2kXM827nfY19Sa 1ahYAHCXimdJgJfsXOf8g4XbjiH5dlA83YVdNwYuCC8maZlXWa2Sus44uRe2aQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226099; a=rsa-sha256; cv=none; b=aH5szpSOVVuINertt5UYI0TlWclbds3H3YhCkHYoRBodBv+FTaePJkjVWRMOJgdmdc/7Zj c4PM6KP3a2PUa0dtRPuCojj2AMRr3kxGaOOoNUGDZe0ikkiYqoYOajN7Z0trAkQU9r/neJ +jmOaPut/Ti5nwXtQC2NsLNrpRraQWwRkooZXlF4yB0Zo5ljvidsFzPFMiFCVL8Qjpue2c UQb3Ir8EGB8iSQLG0Qp1Ikm40n76NprxViBCh/4u91Xd+X5cUxar0AfGcflj+bmzDsMtw3 3Q/N8tn/oP+6sCOXha/JbEkBshTM0tFhlYZ7hJ7a1GzbmYY09rEI/WgsUDZHeg== 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=1721226099; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6bKHTRiIS47yP1TahVd9KAN+LVnHd+/pS1ZnEQ+EXWw=; b=CEHw/LV0VW20fPYpDHEFQx6nifqnFUjYjEi3hiu/YMrnxuTdtNDs6GxPA4W3XkhEzvCjos NVMSdoZYPIq+rMhQhhz2WtGzjVxa2E6E+s5WcZaZ+7QSyxPllc1r40eYujeuZqHAQK1DaG r23IqCx7pEB1exPRaWdwGNCChNT1UFBQ1Ry+UXypa5peGkjIzEy00HxpwPUUouqKesN45D dnGTsErLK/Mt0JN5GCBfURV0Uj+kYsiAhhpLzLA9tGGufV/RSAcWHwGeAzW90PAq6NSYC/ TmmkM3ZDxsuQSu3qhmvMfDrnc4wjhrCbJjoaYIisGvIsIGvcP3FaPtC9clb6FA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ5v4k5pz1MZg; Wed, 17 Jul 2024 14:21:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HELdc5026920; Wed, 17 Jul 2024 14:21:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HELdvh026917; Wed, 17 Jul 2024 14:21:39 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:21:39 GMT Message-Id: <202407171421.46HELdvh026917@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: d80e7fca010d - stable/14 - cxgbe(4): Add missing description for a port type. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: d80e7fca010d534b6779279feba9c0d49538339b Auto-Submitted: auto-generated The branch stable/14 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=d80e7fca010d534b6779279feba9c0d49538339b commit d80e7fca010d534b6779279feba9c0d49538339b Author: Navdeep Parhar AuthorDate: 2024-04-29 20:27:48 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 06:36:16 +0000 cxgbe(4): Add missing description for a port type. Sponsored by: Chelsio Communications (cherry picked from commit f0ee6112eb61a5130acedd20d9827627c0975fba) --- sys/dev/cxgbe/common/t4_hw.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sys/dev/cxgbe/common/t4_hw.c b/sys/dev/cxgbe/common/t4_hw.c index b58d9f5df0d9..9048884eeb7e 100644 --- a/sys/dev/cxgbe/common/t4_hw.c +++ b/sys/dev/cxgbe/common/t4_hw.c @@ -6814,6 +6814,7 @@ const char *t4_get_port_type_description(enum fw_port_type port_type) "CR2_QSFP", "SFP28", "KR_SFP28", + "KR_XLAUI", }; if (port_type < ARRAY_SIZE(port_type_description)) From nobody Wed Jul 17 14:21:40 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ5x09GFz5RPM7; Wed, 17 Jul 2024 14:21:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ5w69nmz4t0n; Wed, 17 Jul 2024 14:21:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226100; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=q7MBi6f/qWjltuTw5JDDaP4dH0BpxKwIUV1BW9C1XBY=; b=ganYEUWWmLDRfq6djKKyvvjngNqThrOvb87HAIA4AyK3dLNevqUyvJQ4Bm8te9Ki/clC08 eHxq2iRLtcYZnN0FliP9taqqRw62sWwnl15uGtX7GQPPGNant1bff7LAFiPcRQraC1a4D6 AzoLumekN22ie7oCmnjHq+24CabuGVZrC1qPPP6PZ4NZpOPq1zQ2aLvMOL200jXUbqRBQO casrRxA0n96Ean5Suvsx4jZMYLuUhiTeR1rA3aRUYJRDdi+JrFqkLnzUmLtTbC3ntnrSZq Tm9zwhQpyoK65jhUBcoxc6mxL0LLbG+ndRz5wt+oY1yGPdAbj7xQ6oCFxCqL4Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226100; a=rsa-sha256; cv=none; b=vnQ123S2v/blLPj+MjdMtwZcZH2mrrKrv4Yx6wkVDP1I9T6dBGvvhZZ7dh8iUOM4MmIsaU h4G1IFUtMZ9sQedlXLV2lY/ZzDfYaZFKyf3O+ZVrfg5SZLEcLb3ftsJmsU56fugO339RW6 ULI0PmAekGKOkzw6ZHlxr0MsNZCTl7TOw0axKT1dLRPm5MeakPvaOsoiTjgL8luHARIX98 iq///0yaPpWdgTocm6K/U9XDp8RY74QiiEX2gpThFaNbZNgfqIsrIptkQStHJkN8UI4pb3 Fsm4GWqC/AqxvxwGwmqyz/6ti0vrp8EDF7vj2YaN1ZHOxcOtnhKm9wlippcTZA== 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=1721226100; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=q7MBi6f/qWjltuTw5JDDaP4dH0BpxKwIUV1BW9C1XBY=; b=PN12S7n3V9pgXbiUC6XfUrL4If7X9zcJmG/jJb43ocNOUv7bxT9NDQppVrbwZXvG0CYJW4 KGP4Ehlb24Svk8sX7dRLl+Ac8pd1m1B+v75LgqkMmuDcDYy6Jm2yXU7SMBxWlv885l/b7y QSvU+ST/Gk+gbL93dGlaPp8pSumkMvxMxxEpGqEEpeHPcYMBGwaGgQZ58w7sztOYhAu1RA B8qzYVpdlUs/qoun4oteF8qWGt2LCm7+TWlPatrU+0Caf0+x6Hb0EJMa8FB4hAg+VazaMV NL4CTh4UX7rlEVx6ESe2jzD+RLSfVW1qSZbeyy4aSPV2KarS0lPO0Msu0/WBNw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ5w5nlPz1MWv; Wed, 17 Jul 2024 14:21:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HELebW026977; Wed, 17 Jul 2024 14:21:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HELeEE026974; Wed, 17 Jul 2024 14:21:40 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:21:40 GMT Message-Id: <202407171421.46HELeEE026974@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: b67afd194ce9 - stable/14 - cxgbe(4): Reword the comment explaining the atid/cookie split. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: b67afd194ce964309d1033650424a9aeea2acd32 Auto-Submitted: auto-generated The branch stable/14 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=b67afd194ce964309d1033650424a9aeea2acd32 commit b67afd194ce964309d1033650424a9aeea2acd32 Author: Navdeep Parhar AuthorDate: 2023-04-01 23:07:36 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 06:36:39 +0000 cxgbe(4): Reword the comment explaining the atid/cookie split. Avoid a magic constant while here. No functional change intended. Sponsored by: Chelsio Communications (cherry picked from commit 43f6f08488046788b0ad66e9a5119f36e5de71ab) --- sys/dev/cxgbe/offload.h | 6 +++--- sys/dev/cxgbe/t4_main.c | 3 +++ 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/sys/dev/cxgbe/offload.h b/sys/dev/cxgbe/offload.h index 688c4b592180..a8b243b764c8 100644 --- a/sys/dev/cxgbe/offload.h +++ b/sys/dev/cxgbe/offload.h @@ -67,10 +67,10 @@ struct stid_region { }; /* - * Max # of ATIDs. The absolute HW max is 14b (enough for 16K) but we reserve - * the upper 3b for use as a cookie to demux the reply. + * Max # of ATIDs. The absolute HW max is larger than this but we reserve a few + * of the upper bits for use as a cookie to demux the reply. */ -#define MAX_ATIDS 2048U +#define MAX_ATIDS (M_TID_TID + 1) union aopen_entry { void *data; diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c index 04e4427732ac..2da399839ce5 100644 --- a/sys/dev/cxgbe/t4_main.c +++ b/sys/dev/cxgbe/t4_main.c @@ -3911,6 +3911,9 @@ rw_via_memwin(struct adapter *sc, int idx, uint32_t addr, uint32_t *val, return (0); } +CTASSERT(M_TID_COOKIE == M_COOKIE); +CTASSERT(MAX_ATIDS <= (M_TID_TID + 1)); + static void t4_init_atid_table(struct adapter *sc) { From nobody Wed Jul 17 14:21:41 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ5y1nH1z5RP1k; Wed, 17 Jul 2024 14:21: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ5y08M0z4sjS; Wed, 17 Jul 2024 14:21:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226102; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=zmWMJjfqiw77rlj/7awc7NKSw1ZnMAz2krwmbZnY2Tw=; b=lZvM3t22qc45uhtyVHWpdSBJt48AbDH13k2lyRrtDjVuX34ZveE+EJ9L7ZZ5AG6zOKfDlY WubfUc1Zj1dC8xu1kkziw92VumGLC6lVEVUEPBmKNgWql5QqdixPHfZSm2qOWdkLyPl2a1 Ak9CEaFhB2DVagkrD0h88DDIE9jezBS1f+25Lh1KQkVNbdWno7ti6dpvOKam2gNBar0H6W Np2S4YViDJWS2EdUOBi0fJB8BbHOmW3n8BefzG0HMUL2EAxQ9kq7LWJpPnhoncv0zbZ1hA tFqzNCwhFSbyeF2EbtsIpLWCyZ2x5glK8uXIbeQS7HdfTkblGu94Mred1knuaA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226102; a=rsa-sha256; cv=none; b=vmAjDonsLUXzpzZSTahAHz3qJ14XEYRTg9bsYvxZSHVKZqPBmIIE5nyv60vcdyG8zLKnmP 5eFyYIcufRsZzA1bEWB4/qfQQ+eAVRVXPEGU1biQ/8a0YQLCm6ZFlHNC+vMOAKFPkQ0ZkC YvtDhZwHWyNfdvEYQzLezpNfh3ySpuWzdLkMyfzFZRZ4qHv2bSqXi2ORPqk08oHbjPu0CN Vgl60mKg8g/DIC2BBNl2iepS7iGrWGGTqOUq8EF00lUK2+ed9h856DRCikSWJXd67H2OGf TvilfqqW4Ix+gs+wvnGRN0hRp9ZSv0hVgX78VMWTBYABj8se0vZ4OwEPqy8gow== 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=1721226102; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=zmWMJjfqiw77rlj/7awc7NKSw1ZnMAz2krwmbZnY2Tw=; b=ZBfeELRX3iT1HEHzQ5oF0IjPlmEGosF9WCh6ylowStzkhsheToW5ql3lviNpguMurKfUgt 16RLgcGrwQ7PfOR88JA7zIUGpuqFM9UK4uyfhduZg5vO5iylOvPM4AtJiw4K9iH9tf9FWP vVqBjzkD3bRHWRbk8rdB6fd9V5VqYU+ASYYufLRh+eWdfQb1+AIq4a7+uYHb1phB0R0SvT 45bbaHRqMwwRaeVUjBogjLDKJMKCtM5QWk/eKFLluQKH4WsaYdRvWLKJyIyTOiarJwdAt4 lrPClhyYCHDew72CLf1tPdhLT6dgbu0AOadL924oXaI/n50eIe+qp9RS+tBTjg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ5x6qSXz1Mp9; Wed, 17 Jul 2024 14:21:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HELf4F027038; Wed, 17 Jul 2024 14:21:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HELfvI027035; Wed, 17 Jul 2024 14:21:41 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:21:41 GMT Message-Id: <202407171421.46HELfvI027035@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: a238d1b04522 - stable/14 - cxgbe(4): Shared code update to deal with partial failure in query_params. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: a238d1b04522565d6ce20cea69b7c26e23266595 Auto-Submitted: auto-generated The branch stable/14 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=a238d1b04522565d6ce20cea69b7c26e23266595 commit a238d1b04522565d6ce20cea69b7c26e23266595 Author: Navdeep Parhar AuthorDate: 2024-02-14 01:28:53 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 06:37:03 +0000 cxgbe(4): Shared code update to deal with partial failure in query_params. Obtained from: Chelsio Communications Sponsored by: Chelsio Communications (cherry picked from commit 2965ae59144177eb3570721295da9cbc447f1105) --- sys/dev/cxgbe/common/t4_hw.c | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/sys/dev/cxgbe/common/t4_hw.c b/sys/dev/cxgbe/common/t4_hw.c index 9048884eeb7e..8a225849930d 100644 --- a/sys/dev/cxgbe/common/t4_hw.c +++ b/sys/dev/cxgbe/common/t4_hw.c @@ -7740,9 +7740,18 @@ int t4_query_params_rw(struct adapter *adap, unsigned int mbox, unsigned int pf, } ret = t4_wr_mbox(adap, mbox, &c, sizeof(c), &c); - if (ret == 0) - for (i = 0, p = &c.param[0].val; i < nparams; i++, p += 2) - *val++ = be32_to_cpu(*p); + + /* + * We always copy back the results, even if there's an error. We'll + * get an error if any of the parameters was unknown to the Firmware, + * but there will be results for the others ... (Older Firmware + * stopped at the first unknown parameter; newer Firmware processes + * them all and flags the unknown parameters with a return value of + * ~0UL.) + */ + for (i = 0, p = &c.param[0].val; i < nparams; i++, p += 2) + *val++ = be32_to_cpu(*p); + return ret; } From nobody Wed Jul 17 14:21:44 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ604PqVz5RPR6; Wed, 17 Jul 2024 14:21: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ601tDHz4sxq; Wed, 17 Jul 2024 14:21:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226104; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=AtLvaHBS5sG3e1bZk1EN8xe++p8P5NEyhGgZCUOj/Jk=; b=WiUJ3bkjWoYyZWcx4iDFcQx/+XxCSMFSr2xpY8Vidu6ae+hv4NMRZ1gLDbOiWc8qX2BFE8 Hqfbpnvuk1az33gt1cR1qFl0++syiOK/9gJtnJ57uZEFzJ16r18P9HO1kOP85pUjsGoNCR JJCPKNqJO2bw9bSv5Ogt7QF/0VoPjpUd5BRR1Lwx7pIWy6U2SRxB0T30xiL8L+TwZ//Zvz F8p+DNta0JOi7Xdtrh+sq4vN0vIKtLEshVz4u3W5CW5mOpT+WoNizg/lxyMw5ou8PJEQ1O sq9wtVWipMeR6quBnMtG6DeFjLBrL44NBJTzpc/1fUMOA8Ji0b6+gvqbcXPmog== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226104; a=rsa-sha256; cv=none; b=GaOGUYyk4sF5N++5XnqFsTe5w7i0qKaE6XRgKa9b1uGswb0N/EY4QPSTTjwObdMrzADhXy ivfPtnG5Oj4/UpyLhZ8IelZpgJ7421lPY37etyLPfpZJK1kPPJTnNH3mLcC6qmJ9jY4hmL OIu5ovdItZox9ETZjiG/RFrlLVocPKQEXHWeHDbnne0cHQCq2kZg6OXgnMDb51iDCiVQIE yP86+WW8FjdvnTEwLKa1l9NBdj7kiKox0zmq4/z3vqfT/o4tzAfM9KNN2w9YhqsmuMpYMk Nh7Mbv99W+yKdOs8+KCT8sc/CHLLBwpUJJY2Rb/L4ozwXmzApA34b/3Hj8AJ/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=1721226104; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=AtLvaHBS5sG3e1bZk1EN8xe++p8P5NEyhGgZCUOj/Jk=; b=gINpFyPHhd9PV+x8ifrQp4U2XEmMMg88HTG9krNSB3P0EPIgTo8ASVXhp/VqE2jdRP86MP 1qIdn7ha+NhFWrnPVPVu4uwaMZXSpHCtgT+PF3bn0hqR9QpelVSw4/L5vyKj2a73wisaz1 nNY9Xfcwa/n/5js28hPgYX5kU4zgqYbisrisbqc7oWka4uLduDdq2sjHugzAty9A7b3Ez5 yDdYLOb40rQUNdX8h1XbYMtY5rsmMh96HxXdqhctBh8RlgODlQC7/bLOC6nJlCD8qkGHXi 2wbi8fpZ6b8UC6GjSyKAbJN0zd71SCn6EUGvabdI4Dd+2613qlTkOY99xDeM9g== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ601RGjz1Md8; Wed, 17 Jul 2024 14:21:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HELiDA028127; Wed, 17 Jul 2024 14:21:44 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HELiri028109; Wed, 17 Jul 2024 14:21:44 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:21:44 GMT Message-Id: <202407171421.46HELiri028109@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 92383a2c844b - stable/14 - cxgbe(4): Do not read hardware registers to determine the number of ports. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 92383a2c844b102f6d65efbc2755ae21c656163b Auto-Submitted: auto-generated The branch stable/14 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=92383a2c844b102f6d65efbc2755ae21c656163b commit 92383a2c844b102f6d65efbc2755ae21c656163b Author: Navdeep Parhar AuthorDate: 2024-04-30 19:42:14 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 06:37:39 +0000 cxgbe(4): Do not read hardware registers to determine the number of ports. PORTVEC obtained from the firmware is the authoritative source of this information, and nports (calculated from PORTVEC) is available by the time t4_port_init runs. Sponsored by: Chelsio Communications (cherry picked from commit 4d1362cdc7375984a48f5f0048b1fe909524d21d) --- sys/dev/cxgbe/common/t4_hw.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/sys/dev/cxgbe/common/t4_hw.c b/sys/dev/cxgbe/common/t4_hw.c index 8a225849930d..8d109b389f0d 100644 --- a/sys/dev/cxgbe/common/t4_hw.c +++ b/sys/dev/cxgbe/common/t4_hw.c @@ -6745,10 +6745,11 @@ static unsigned int t4_get_mps_bg_map(struct adapter *adap, int idx) if (adap->params.mps_bg_map) return ((adap->params.mps_bg_map >> (idx << 3)) & 0xff); - n = G_NUMPORTS(t4_read_reg(adap, A_MPS_CMN_CTL)); - if (n == 0) + n = adap->params.nports; + MPASS(n > 0 && n <= MAX_NPORTS); + if (n == 1) return idx == 0 ? 0xf : 0; - if (n == 1 && chip_id(adap) <= CHELSIO_T5) + if (n == 2 && chip_id(adap) <= CHELSIO_T5) return idx < 2 ? (3 << (2 * idx)) : 0; return 1 << idx; } @@ -6758,12 +6759,12 @@ static unsigned int t4_get_mps_bg_map(struct adapter *adap, int idx) */ static unsigned int t4_get_rx_e_chan_map(struct adapter *adap, int idx) { - u32 n = G_NUMPORTS(t4_read_reg(adap, A_MPS_CMN_CTL)); + const u32 n = adap->params.nports; const u32 all_chan = (1 << adap->chip_params->nchan) - 1; - if (n == 0) + if (n == 1) return idx == 0 ? all_chan : 0; - if (n == 1 && chip_id(adap) <= CHELSIO_T5) + if (n == 2 && chip_id(adap) <= CHELSIO_T5) return idx < 2 ? (3 << (2 * idx)) : 0; return 1 << idx; } From nobody Wed Jul 17 14:21:42 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ5z3BpFz5RPg5; Wed, 17 Jul 2024 14:21: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ5z1WL0z4t3B; Wed, 17 Jul 2024 14:21:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226103; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=iG2sFY1DDAidIVwXjVKU0rADcP/+gGA8VreWtTxbL3U=; b=uguy8T7nNHOLL2GWAHEX/O1xxWyekj/zlfrtRzc2U+pA683YnUUKgFqfxUbSscpyYa9QbE ejsvM9ERbBE4F+Fc5H2gjrRnOIILJJuCqFS+WvOMmtqQjWmresSo5pZzuznYQadpFJ4Ryg Z2OalFEASDqz21N6VbTCQzzs/rrZAQBn0bjJ1KNUdejcFiFaMEQx5l5aTXOO+7XT/6zKVG 5fBzffUJfUn33FDnCgHdliLRonmW1ibUWWkNSzD5vshec2E/IdvUTPQxb+1eo+bnBxo9ai baV1YFf2eLgK0k7Fj+41pZr7vSk8cMTFjNyVZbZaN5VNpj3m258gHn3E24oyPg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226103; a=rsa-sha256; cv=none; b=Y07ZXvt5I37ngkwNPTT/RaoFgaqxzdaS8Tj7cqzriOSSSStPxRrxKGsonzu/o4wr92w6k+ qvbUVW6gDP2lU/b8a6jN8jyelRoHoQOqeuCHefaLwUNmctAqyFPAwXyjsA0ZjnPUwk3GZd NvAnREhUMmVcZRnXC6WNVtPFzJh06sNlluXnvfnBCA5uYRj1FcTAknhIY+fazTPml7vKs3 AxeZNdiC2wSpttr2shummzu9RzUjtduHAo71Dqj8fBNdD47i4l2YkN3NZJq89ivdaWQSi6 xUV1hy/qbgZF4fKKaOiU7bm3dKuQ5LK1t+dkcmfhdlNfqCrdcIiNGvUpqmuApQ== 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=1721226103; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=iG2sFY1DDAidIVwXjVKU0rADcP/+gGA8VreWtTxbL3U=; b=IYcML678AfuOmxEu0ULGduZvOPn5iz4F7W2dLGuFmF4oxM3PfmXNavJ1d8knlIMswfwpEh gCIouXU5h2tlyOuJFhLfpGjkm0ea1AFydAge4Xp8W8L6QSZcMeSRQC4tYHXUVw6fh96jqD QAzyj7041o6LnRqMlasqobaMck+CkfncutwTHDf3cfzSB9OHYa7ioDiDrMTZE4MTOpuaDv Ho3y3z6f0n58gb9QfhNp21Gt94sN9IGhe/Sxrh8dYUZrBErJutvS/r6gwS8z+/oXaJYqdb vA10+M5Ier9AFyd9wqIQoRWcikVmi6gIi8a9oJTJ8DGficMVhGkCE2fmzsY1ag== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ5z0qHFz1Md1; Wed, 17 Jul 2024 14:21:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HELhvh027095; Wed, 17 Jul 2024 14:21:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HELgGZ027092; Wed, 17 Jul 2024 14:21:42 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:21:42 GMT Message-Id: <202407171421.46HELgGZ027092@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: e5efc8cf5d7d - stable/14 - cxgbe(4): Allocate a taskqueue per port instead of per channel. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: e5efc8cf5d7d7082d3528b3d658a24ad23a8d18a Auto-Submitted: auto-generated The branch stable/14 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=e5efc8cf5d7d7082d3528b3d658a24ad23a8d18a commit e5efc8cf5d7d7082d3528b3d658a24ad23a8d18a Author: Navdeep Parhar AuthorDate: 2024-04-30 17:51:45 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 06:37:25 +0000 cxgbe(4): Allocate a taskqueue per port instead of per channel. All the channels are not used on all boards and there's no point allocating taskqueues that will never be used. Sponsored by: Chelsio Communications (cherry picked from commit 857d74b6340e418396d79a46b264ce0eedd760e4) --- sys/dev/cxgbe/adapter.h | 3 ++- sys/dev/cxgbe/t4_main.c | 7 +++++-- sys/dev/cxgbe/t4_sge.c | 19 ++++++++++--------- 3 files changed, 17 insertions(+), 12 deletions(-) diff --git a/sys/dev/cxgbe/adapter.h b/sys/dev/cxgbe/adapter.h index 335b1be57b8b..36d67d062e67 100644 --- a/sys/dev/cxgbe/adapter.h +++ b/sys/dev/cxgbe/adapter.h @@ -471,6 +471,7 @@ struct sge_eq { unsigned int abs_id; /* absolute SGE id for the eq */ uint8_t type; /* EQ_CTRL/EQ_ETH/EQ_OFLD */ uint8_t doorbells; + uint8_t port_id; /* port_id of the port associated with the eq */ uint8_t tx_chan; /* tx channel used by the eq */ struct mtx eq_lock; @@ -930,7 +931,7 @@ struct adapter { int nrawf; u_int vlan_id; - struct taskqueue *tq[MAX_NCHAN]; /* General purpose taskqueues */ + struct taskqueue *tq[MAX_NPORTS]; /* General purpose taskqueues */ struct port_info *port[MAX_NPORTS]; uint8_t chan_map[MAX_NCHAN]; /* channel -> port */ diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c index 2da399839ce5..b41746828e9e 100644 --- a/sys/dev/cxgbe/t4_main.c +++ b/sys/dev/cxgbe/t4_main.c @@ -6665,7 +6665,8 @@ adapter_full_init(struct adapter *sc) if (rc != 0) return (rc); - for (i = 0; i < nitems(sc->tq); i++) { + MPASS(sc->params.nports <= nitems(sc->tq)); + for (i = 0; i < sc->params.nports; i++) { if (sc->tq[i] != NULL) continue; sc->tq[i] = taskqueue_create("t4 taskq", M_NOWAIT, @@ -6714,7 +6715,9 @@ adapter_full_uninit(struct adapter *sc) t4_teardown_adapter_queues(sc); - for (i = 0; i < nitems(sc->tq) && sc->tq[i]; i++) { + for (i = 0; i < nitems(sc->tq); i++) { + if (sc->tq[i] == NULL) + continue; taskqueue_free(sc->tq[i]); sc->tq[i] = NULL; } diff --git a/sys/dev/cxgbe/t4_sge.c b/sys/dev/cxgbe/t4_sge.c index 7008c3c65e02..614aa1f7508c 100644 --- a/sys/dev/cxgbe/t4_sge.c +++ b/sys/dev/cxgbe/t4_sge.c @@ -3391,13 +3391,14 @@ init_fl(struct adapter *sc, struct sge_fl *fl, int qsize, int maxp, char *name) static inline void init_eq(struct adapter *sc, struct sge_eq *eq, int eqtype, int qsize, - uint8_t tx_chan, struct sge_iq *iq, char *name) + uint8_t port_id, struct sge_iq *iq, char *name) { KASSERT(eqtype >= EQ_CTRL && eqtype <= EQ_OFLD, ("%s: bad qtype %d", __func__, eqtype)); eq->type = eqtype; - eq->tx_chan = tx_chan; + eq->port_id = port_id; + eq->tx_chan = sc->port[port_id]->tx_chan; eq->iq = iq; eq->sidx = qsize - sc->params.sge.spg_len / EQ_ESIZE; strlcpy(eq->lockname, name, sizeof(eq->lockname)); @@ -3838,8 +3839,8 @@ alloc_ctrlq(struct adapter *sc, int idx) snprintf(name, sizeof(name), "%s ctrlq%d", device_get_nameunit(sc->dev), idx); - init_eq(sc, &ctrlq->eq, EQ_CTRL, CTRL_EQ_QSIZE, - sc->port[idx]->tx_chan, &sc->sge.fwq, name); + init_eq(sc, &ctrlq->eq, EQ_CTRL, CTRL_EQ_QSIZE, idx, + &sc->sge.fwq, name); rc = alloc_wrq(sc, NULL, ctrlq, &sc->ctx, oid); if (rc != 0) { CH_ERR(sc, "failed to allocate ctrlq%d: %d\n", idx, rc); @@ -4603,7 +4604,7 @@ alloc_txq(struct vi_info *vi, struct sge_txq *txq, int idx) iqidx = vi->first_rxq + (idx % vi->nrxq); snprintf(name, sizeof(name), "%s txq%d", device_get_nameunit(vi->dev), idx); - init_eq(sc, &txq->eq, EQ_ETH, vi->qsize_txq, pi->tx_chan, + init_eq(sc, &txq->eq, EQ_ETH, vi->qsize_txq, pi->port_id, &sc->sge.rxq[iqidx].iq, name); rc = mp_ring_alloc(&txq->r, eq->sidx, txq, eth_tx, @@ -4820,11 +4821,11 @@ alloc_ofld_txq(struct vi_info *vi, struct sge_ofld_txq *ofld_txq, int idx) device_get_nameunit(vi->dev), idx); if (vi->nofldrxq > 0) { iqidx = vi->first_ofld_rxq + (idx % vi->nofldrxq); - init_eq(sc, eq, EQ_OFLD, vi->qsize_txq, pi->tx_chan, + init_eq(sc, eq, EQ_OFLD, vi->qsize_txq, pi->port_id, &sc->sge.ofld_rxq[iqidx].iq, name); } else { iqidx = vi->first_rxq + (idx % vi->nrxq); - init_eq(sc, eq, EQ_OFLD, vi->qsize_txq, pi->tx_chan, + init_eq(sc, eq, EQ_OFLD, vi->qsize_txq, pi->port_id, &sc->sge.rxq[iqidx].iq, name); } @@ -6339,7 +6340,7 @@ handle_wrq_egr_update(struct adapter *sc, struct sge_eq *eq) struct sge_wrq *wrq = (void *)eq; atomic_readandclear_int(&eq->equiq); - taskqueue_enqueue(sc->tq[eq->tx_chan], &wrq->wrq_tx_task); + taskqueue_enqueue(sc->tq[eq->port_id], &wrq->wrq_tx_task); } static void @@ -6351,7 +6352,7 @@ handle_eth_egr_update(struct adapter *sc, struct sge_eq *eq) atomic_readandclear_int(&eq->equiq); if (mp_ring_is_idle(txq->r)) - taskqueue_enqueue(sc->tq[eq->tx_chan], &txq->tx_reclaim_task); + taskqueue_enqueue(sc->tq[eq->port_id], &txq->tx_reclaim_task); else mp_ring_check_drainage(txq->r, 64); } From nobody Wed Jul 17 14:21:45 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ615BZPz5RPjf; Wed, 17 Jul 2024 14:21: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ612brFz4syG; Wed, 17 Jul 2024 14:21:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226105; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=iYrgvQNyTilJJeAa1wTGLSExIdRclx/AgFYOQ2wFtzo=; b=w7SJ/4S9eG00C3ZkgFt9UItAVQU+aJRtkiG/UdjkeaWAUYyf0aCKKW/SAdyZE0DL2RYtu+ FWXmzoeGnHLaoQsAD4jlxBhiPszZOCSJ/VOpfwMlCHSNjxNZ5+vhqpBmN9AJMJmAQDMKhU SBJGzmaMaO2u+u/zF0tSzcgc3Kw7Jn+zNsyPHf+yRr3TE7I4o7sW1I1fNgOCBsxLV+dll+ tBdglhhx8zra/2hd1kHYquzzKbJ3CHMV3rlHjWQBUezOgwKXYZvlbzwAu3EsBJrEy74eOo QFcnvPVxnMxAu4cX6Zgm5+c0aYrSX3YnGVzWNPFaB9Gzh7AU8sawrJ7d90I7ag== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226105; a=rsa-sha256; cv=none; b=uG350LCct1ToL6YvekeCingA8Vu7IGZcurovc6bnyE9NAaZ0+VN4O21oocAFU0dtXe2kcD AoBGPDq2otCynRqUmvmSEfENr0ZS1PMTM13lSrfsdCOQ/COBrb7RK410tsprEhi2DNLXrF HeznNi//I2YdFmvF3qQyGqUJnBHPLzUwMQIxeKdD7veGSmi3FFdxNNixYUmTQXznKXK5es Ir6lXeoADM0po2SGNy7PgrbXSRzPhYQW0NMIy/ilNQ/XEddQmzfULlgqrvzNuX+V3O0b8o 4ZVEDfTKrm/ljtYPcFCvURaXO8MXV+LgZPao+8DVdGhlEzmXIgnd6bdkFt8iBQ== 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=1721226105; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=iYrgvQNyTilJJeAa1wTGLSExIdRclx/AgFYOQ2wFtzo=; b=oUt8bYXnrQyXOAQbLWetHrOZMYOr2QkBlOhUHlMe8rRXq7qoyCWbZs6L91gQfp/4ypKFZI h59J5QWvU4jV6Viag5BrffUuAK+XXDh6eCdpPtBOkVLaZnEPHZnKpxGznm91TKd0RHGi5J VKsjY6cwj/kIvVeuurduSA7CH5AnquLmoEENVQf09zHBBJdKEzMrvePYckLJmvXcVOUjrv 3epzveZ6K7aQE6KaYH1hWjp4wzAsfCz3y4QWs973YE+EDvwLZZRluLiQkdA7F8dSqHqC3I JlcwTuS/8hRmMevxAUo3Ut95cUXJaJsQ8xeBcAiJnfPJSP40S+fnGZtKO7cwzA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ612CVLz1Mms; Wed, 17 Jul 2024 14:21:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HELjom029619; Wed, 17 Jul 2024 14:21:45 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HELjNd029601; Wed, 17 Jul 2024 14:21:45 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:21:45 GMT Message-Id: <202407171421.46HELjNd029601@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 67faf45be5d6 - stable/14 - cxgbe(4): Initialize mps_bg_map to an invalid value if it's not known. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 67faf45be5d67830497914ef807f536ba98d4e32 Auto-Submitted: auto-generated The branch stable/14 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=67faf45be5d67830497914ef807f536ba98d4e32 commit 67faf45be5d67830497914ef807f536ba98d4e32 Author: Navdeep Parhar AuthorDate: 2024-04-30 19:51:29 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 06:38:00 +0000 cxgbe(4): Initialize mps_bg_map to an invalid value if it's not known. Sponsored by: Chelsio Communications (cherry picked from commit 9de0036b55dcdabc54fa69ea6e583b22d739818c) --- sys/dev/cxgbe/common/t4_hw.c | 2 +- sys/dev/cxgbe/t4_main.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/dev/cxgbe/common/t4_hw.c b/sys/dev/cxgbe/common/t4_hw.c index 8d109b389f0d..755062909e14 100644 --- a/sys/dev/cxgbe/common/t4_hw.c +++ b/sys/dev/cxgbe/common/t4_hw.c @@ -6742,7 +6742,7 @@ static unsigned int t4_get_mps_bg_map(struct adapter *adap, int idx) { u32 n; - if (adap->params.mps_bg_map) + if (adap->params.mps_bg_map != UINT32_MAX) return ((adap->params.mps_bg_map >> (idx << 3)) & 0xff); n = adap->params.nports; diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c index b41746828e9e..4834a4fc2873 100644 --- a/sys/dev/cxgbe/t4_main.c +++ b/sys/dev/cxgbe/t4_main.c @@ -5333,7 +5333,7 @@ get_params__post_init(struct adapter *sc) if (rc == 0) sc->params.mps_bg_map = val[0]; else - sc->params.mps_bg_map = 0; + sc->params.mps_bg_map = UINT32_MAX; /* Not a legal value. */ /* * Determine whether the firmware supports the filter2 work request. From nobody Wed Jul 17 14:21:46 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ624tpnz5RP1q; Wed, 17 Jul 2024 14:21: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ62378Fz4t1w; Wed, 17 Jul 2024 14:21:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226106; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=h/MKk+m0+biIieN+R4AuyzWtnVb0WBDxpNoDP6QosNA=; b=yWam9dmFIMwIL0c3RxzuE1AnoYDvfIIPrMfgpya5enLbhFvGdIn+eLGh4tMvmUyVfG/iwU fEetWnhXqqC+eO6z/3cp57r3fIjFxbNzzXUnky/9gxcscExD543xKX+JwRgLiJ2W/GTBRk 13csjtGfDm7pTuNqeT5ZKEC3OnpZwSZ7MYRr/wNSkQdUQOV/U7BjA/FCQCY4aKCNac7UD+ Nreevp52nc+a+GDmg26VdHuMChmcLxEkDOpNAOIjcCKUJrHn+poKYov8IqTWowkujQr+28 aWSgqIG+mZ2mJDYFHAWM1JdnAo4qrG5bhsm2W6eFc1pZAgEkRaDb/gA6K0UEgg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226106; a=rsa-sha256; cv=none; b=u8pmiuBx0Wa7/IUF+PIDEetLstobLhCNlEEjfIKXkLrLfMEGp7aHJ5g57gwPbNJY+oIGPY ds6C/j/92eXvb/Fqdakh5J68o6+PGEZ/4k0afye2lbAkk2lQwuSxzb6AnU6/9qvDyc7XlT e5C8wvHHWsiYMYb679ybv1rNxYtO/AZ6yv/Ta588Z4y8oCbhR9Vm2bXK98FSSZvxAy52/8 DgcBxHqmwtp7v3E4ZPixzv1qESA2DHmOBfp00z0qsUv2iia1CsSXdtGg5KzPiJOPuyG5s/ USIp/cpdDs9kw1VKIpi7d5OKW9nApyHfZm47eht0sD7tx/RpGs5pSIiko+WJDw== 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=1721226106; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=h/MKk+m0+biIieN+R4AuyzWtnVb0WBDxpNoDP6QosNA=; b=TVo9PK5i1Iq5MqD4pFy0eDems54VgqpfwPCLt6J4r/F47njpSkyxGqX1oxegyKfbo7EAEi Fczmp11q7pFmQNCPpA288eRB+5MltPcQEs42LqxBELRhySBydY0G6kHJHDhp2oZoxsZgw7 qdDPfloDcXFSIVV7zBAg39BBJHkvN8t7Nwe3NwQcvjJkpC3SsNGx71TsIscFmp/25myvMa pmsK3Aj+BbyKze9xm2Oy6nGFXCyS80UEgImYUOzDXdm788kq1mV+QaUrsgVvrhNi4yQwk+ Y90zNZrkXCl+qDk+b+tRzIksRnnmVpN6xWRwq3h6BKQa8yOdft0Uas1SeycoKw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ622lKrz1Mmt; Wed, 17 Jul 2024 14:21:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HELk8L029921; Wed, 17 Jul 2024 14:21:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HELkYY029900; Wed, 17 Jul 2024 14:21:46 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:21:46 GMT Message-Id: <202407171421.46HELkYY029900@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 5af25b6e4d55 - stable/14 - cxgbe(4): Minor tweaks to comments. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 5af25b6e4d5514c10028c6bce89d123a6162a2de Auto-Submitted: auto-generated The branch stable/14 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=5af25b6e4d5514c10028c6bce89d123a6162a2de commit 5af25b6e4d5514c10028c6bce89d123a6162a2de Author: Navdeep Parhar AuthorDate: 2024-04-30 20:01:07 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 06:38:18 +0000 cxgbe(4): Minor tweaks to comments. No functional change intended. Sponsored by: Chelsio Communications (cherry picked from commit 21aba396551e29808fa56a6d4fab17e871c3524f) --- sys/dev/cxgbe/t4_main.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c index 4834a4fc2873..04f564124356 100644 --- a/sys/dev/cxgbe/t4_main.c +++ b/sys/dev/cxgbe/t4_main.c @@ -5323,9 +5323,13 @@ get_params__post_init(struct adapter *sc) } /* - * MPSBGMAP is queried separately because only recent firmwares support - * it as a parameter and we don't want the compound query above to fail - * on older firmwares. + * The parameters that follow may not be available on all firmwares. We + * query them individually rather than in a compound query because old + * firmwares fail the entire query if an unknown parameter is queried. + */ + + /* + * MPS buffer group configuration. */ param[0] = FW_PARAM_DEV(MPSBGMAP); val[0] = 0; @@ -5337,7 +5341,6 @@ get_params__post_init(struct adapter *sc) /* * Determine whether the firmware supports the filter2 work request. - * This is queried separately for the same reason as MPSBGMAP above. */ param[0] = FW_PARAM_DEV(FILTER2_WR); val[0] = 0; @@ -5349,7 +5352,6 @@ get_params__post_init(struct adapter *sc) /* * Find out whether we're allowed to use the ULPTX MEMWRITE DSGL. - * This is queried separately for the same reason as other params above. */ param[0] = FW_PARAM_DEV(ULPTX_MEMWRITE_DSGL); val[0] = 0; From nobody Wed Jul 17 14:21:47 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ635d7Pz5RPgJ; Wed, 17 Jul 2024 14:21: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ634BQxz4tBL; Wed, 17 Jul 2024 14:21:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226107; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=XkF7XlobHgziUWb1fk0za1bbrJb375gn285NdSzSy7k=; b=IkpsjW0P5Edi4qgzw4OSB2P9t5QC5VxRwGo0rLbn8OSd0NCMf01rWNZeUyjpU4967FIa50 ByKwSv9rzKd2XUWTvrGK/ZUsBid9U1zwyoxrET+HmMKMPNGvjYe97QnEKBKzXLSDt3wXBu cq+Vr966KZ9UFS783CTVFuUyCdwxRJL5qb2/P7VofSgwgUKE13JId1fus5iOVWZ18S7imi cZPZwZ/WCUjSdt7R3aJoDSc7xJIdZ7ssRUSUhV793ojCPqNSF01iv6ynSMbqQTgeQ6jcD/ ioLMUa9X/ziNzBrIBPNhOEhxSUEiQSV5bxVDch+LXXpCrjqk0eFKwKEjFEWl9A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226107; a=rsa-sha256; cv=none; b=hrfG2PLt9mcREvs+tt6PAGupBy50yhW9X6enJL+ra+2xlcBMEp6ptwa74KWNvcWZEBsGkB xc2iwcb3IxH4ESIwJgKReRsgIMeBafae4uptALdSMrh3PSksy17btIJCXDKx+XUzlRXEk3 ClqIThMbqS90hqWmNfTZlR390GEp0PHx4v4g91nQycfIruBR9A4Z5UzZETiI2Chfbte5Vf M1oy9KaQNbSD/3XYDieTCfD5kXHMO700T50/2fi4SYkRklAqqYOGWfLfoEhIQfQVfbdK5o KhH3nPRcUUF0qNWQcPomP/CRlT1qHRgIFAXi1yS8PiLPT+yn+0zeUKOFM7LjCw== 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=1721226107; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=XkF7XlobHgziUWb1fk0za1bbrJb375gn285NdSzSy7k=; b=UQF/y7Ew6syJMhlpDHqX+aLS0TiXAHObbouN2AS9Z6Rkrn8OD3ER3g7pjieYY6X186ts64 ZyBr6HpRgfI0P5lxBmTDRYP7Csyz1D10b50GZ72dP3uIrw+p2Qkv+foEjrp7gwB1ltt1uF AXwOGaAdSipeN5nuhyFavnoe0c9eO51JMEQbHIrA3dBOq/pBSDfB9IGDdZ9wyQRXOLF5lP Q1aE3CTNWYhsoTzokodpL0mPG0XvC7+G+llWDghvr/bch6XZ+puxU0YfQoPL20qBs9sPED 8tWscx5XSpyO8VeJXYvXa6g8hyTbdiyYUQ/c61g8fjeYGmAX5mcdntz5Iz+wbQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ633q29z1MdC; Wed, 17 Jul 2024 14:21:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HELlOI030902; Wed, 17 Jul 2024 14:21:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HELldj030899; Wed, 17 Jul 2024 14:21:47 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:21:47 GMT Message-Id: <202407171421.46HELldj030899@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 0ca32f02defd - stable/14 - cxgbe(4): Rename rx_c_chan to rx_chan. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 0ca32f02defd99b02d29e629f857baff9c456272 Auto-Submitted: auto-generated The branch stable/14 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=0ca32f02defd99b02d29e629f857baff9c456272 commit 0ca32f02defd99b02d29e629f857baff9c456272 Author: Navdeep Parhar AuthorDate: 2024-04-30 23:07:24 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 06:38:40 +0000 cxgbe(4): Rename rx_c_chan to rx_chan. It is the equivalent of tx_chan but for receive so rx_chan is a better name. Initialize both using helper functions and make sure both are displayed in the sysctl MIB. Sponsored by: Chelsio Communications (cherry picked from commit 480ff89c67b25113515018cdcd13179229b4a0d3) --- sys/dev/cxgbe/adapter.h | 4 ++-- sys/dev/cxgbe/common/t4_hw.c | 12 ++++++++++-- sys/dev/cxgbe/crypto/t4_crypto.c | 2 +- sys/dev/cxgbe/t4_main.c | 6 ++++-- 4 files changed, 17 insertions(+), 7 deletions(-) diff --git a/sys/dev/cxgbe/adapter.h b/sys/dev/cxgbe/adapter.h index 36d67d062e67..36529601dffa 100644 --- a/sys/dev/cxgbe/adapter.h +++ b/sys/dev/cxgbe/adapter.h @@ -320,10 +320,10 @@ struct port_info { uint8_t port_type; uint8_t mod_type; uint8_t port_id; - uint8_t tx_chan; + uint8_t tx_chan; /* tx TP c-channel */ + uint8_t rx_chan; /* rx TP c-channel */ uint8_t mps_bg_map; /* rx MPS buffer group bitmap */ uint8_t rx_e_chan_map; /* rx TP e-channel bitmap */ - uint8_t rx_c_chan; /* rx TP c-channel */ struct link_config link_cfg; struct ifmedia media; diff --git a/sys/dev/cxgbe/common/t4_hw.c b/sys/dev/cxgbe/common/t4_hw.c index 755062909e14..3e04995eec3b 100644 --- a/sys/dev/cxgbe/common/t4_hw.c +++ b/sys/dev/cxgbe/common/t4_hw.c @@ -6786,6 +6786,14 @@ static unsigned int t4_get_rx_c_chan(struct adapter *adap, int idx) return 0; } +/* + * TP TX c-channel associated with the port. + */ +static unsigned int t4_get_tx_c_chan(struct adapter *adap, int idx) +{ + return idx; +} + /** * t4_get_port_type_description - return Port Type string description * @port_type: firmware Port Type enumeration @@ -9817,10 +9825,10 @@ int t4_port_init(struct adapter *adap, int mbox, int pf, int vf, int port_id) } while ((adap->params.portvec & (1 << j)) == 0); } - p->tx_chan = j; + p->tx_chan = t4_get_tx_c_chan(adap, j); + p->rx_chan = t4_get_rx_c_chan(adap, j); p->mps_bg_map = t4_get_mps_bg_map(adap, j); p->rx_e_chan_map = t4_get_rx_e_chan_map(adap, j); - p->rx_c_chan = t4_get_rx_c_chan(adap, j); p->lport = j; if (!(adap->flags & IS_VF) || diff --git a/sys/dev/cxgbe/crypto/t4_crypto.c b/sys/dev/cxgbe/crypto/t4_crypto.c index 50f6c9526a85..2348acb2064c 100644 --- a/sys/dev/cxgbe/crypto/t4_crypto.c +++ b/sys/dev/cxgbe/crypto/t4_crypto.c @@ -1925,7 +1925,7 @@ ccr_init_port(struct ccr_softc *sc, int port) pi = sc->adapter->port[port]; sc->ports[port].txq = &sc->adapter->sge.ctrlq[port]; sc->ports[port].rxq = &sc->adapter->sge.rxq[pi->vi->first_rxq]; - sc->ports[port].rx_channel_id = pi->rx_c_chan; + sc->ports[port].rx_channel_id = pi->rx_chan; sc->ports[port].tx_channel_id = pi->tx_chan; sc->ports[port].stats_queued = counter_u64_alloc(M_WAITOK); sc->ports[port].stats_completed = counter_u64_alloc(M_WAITOK); diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c index 04f564124356..1c4fe4b4d0cf 100644 --- a/sys/dev/cxgbe/t4_main.c +++ b/sys/dev/cxgbe/t4_main.c @@ -7977,8 +7977,10 @@ cxgbe_sysctls(struct port_info *pi) pi->mps_bg_map, "MPS buffer group map"); SYSCTL_ADD_INT(ctx, children, OID_AUTO, "rx_e_chan_map", CTLFLAG_RD, NULL, pi->rx_e_chan_map, "TP rx e-channel map"); - SYSCTL_ADD_INT(ctx, children, OID_AUTO, "rx_c_chan", CTLFLAG_RD, NULL, - pi->rx_c_chan, "TP rx c-channel"); + SYSCTL_ADD_INT(ctx, children, OID_AUTO, "tx_chan", CTLFLAG_RD, NULL, + pi->tx_chan, "TP tx c-channel"); + SYSCTL_ADD_INT(ctx, children, OID_AUTO, "rx_chan", CTLFLAG_RD, NULL, + pi->rx_chan, "TP rx c-channel"); if (sc->flags & IS_VF) return; From nobody Wed Jul 17 14:21:48 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ651lWtz5RPgP; Wed, 17 Jul 2024 14:21: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ645HDDz4t9F; Wed, 17 Jul 2024 14:21:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226108; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=wI9EAmhI7TCrAam/oygGqj4Z87hc5YzMfTeVYmYk3WI=; b=Bf5U5GBsuorL9P9zbiIJ38SCeuMbZ6g4OZAr3xWO+D9rJirYaBf4lCKizqgU8VRsZDLyZR PfpsEFOQBbbxl/IInHvI7445fekLPUaZXje13pqMOHSx1/Qj25ptcIYij8RKP5FhcH28d7 TRA1DMjzWpatno+C9fCVDOxhzBDri63EOnXHIfMPhJMvCf7L9ZdNuYsaZwO+DwUGdwh0i5 zRTTFGv0dFTIz/Ct0WH/vJELwbI/aBG8yX4whxfMP3vTbSzbcMQxVrakMskWEyLzGK9Rz7 183L3v52/HL9XEKD9F8S4GD2WEI/m1G59GUjOTFY1Ia9ngjq7PDPRtHa6CLEuw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226108; a=rsa-sha256; cv=none; b=QGbzsdoKwBHlbw2AMNqQP2pQeZAy648GNBU1t0DCa8PFCHCC+d7iwXagMGiPYeoIIWBiQh qzx64sbGJDSfdfoDvAf9D327eHDcIZUJGKAxsKdKAj6FEVtEJ2bjE4cLxbL0+hzY3iD301 W36R6bTEw4+oMzqqme2qQGYNetTG18dDp1JH95vsyHKwte7qjyoSdvRu2x7K/WNk2gs1VF T2UacUkCUwOSC/Uys+X+5FB99yUBKrZDU0AjxF6JKn7BHabVHv/Q2+uUU3VX15JnkPJmDk LUG6UPaEvpoXUwUR9hH5QUYZF6U3Qn43cpKZ8z+g/bcUlidBM1oEqcHR0PqdWQ== 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=1721226108; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=wI9EAmhI7TCrAam/oygGqj4Z87hc5YzMfTeVYmYk3WI=; b=Z9qddDOW2ah0QqxKPmYweCWZ1m53GbCjb6Y+wDEG7jIKS2wZ1qVshAR1q8+f2Ii/srxwuN zL2v0of9qvi3wOTnSzLz2Lf8TUOUwcUGLCiKBVB45TWWzfRfU+Uk+WotibdpD/vV/ptIjk AK9j53W+dJu6h7m/UGn7DK6UhQ8ETvI1LlKCIqte4a5gFbMDuzFOqPdNBJCw+VbOV4HXnI Y2v3/UEm1zveiPPLmUNi/5T/icW88ypGfLUFTwM0xL76w/Ne+pspbaofAqgN2/zeUyj7Xg Bk8QsHYsq1sDG4pe4MPLp6QOKa2QzGeWrbDMliQ4tTjAh4/UX+4+SdtocuP2fg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ644vdqz1N0f; Wed, 17 Jul 2024 14:21:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HELmV2030960; Wed, 17 Jul 2024 14:21:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HELmlM030957; Wed, 17 Jul 2024 14:21:48 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:21:48 GMT Message-Id: <202407171421.46HELmlM030957@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: c0b69999b1b3 - stable/14 - cxgbe(4): Query TPCHMAP once and not once per port. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: c0b69999b1b34cc02b02222a63e0cd918c522e88 Auto-Submitted: auto-generated The branch stable/14 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=c0b69999b1b34cc02b02222a63e0cd918c522e88 commit c0b69999b1b34cc02b02222a63e0cd918c522e88 Author: Navdeep Parhar AuthorDate: 2024-04-30 23:32:55 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 06:38:57 +0000 cxgbe(4): Query TPCHMAP once and not once per port. Sponsored by: Chelsio Communications (cherry picked from commit 7f10048f983a31c09587b436e7fb073f7cbb76e4) --- sys/dev/cxgbe/common/common.h | 4 +++- sys/dev/cxgbe/common/t4_hw.c | 11 ++--------- sys/dev/cxgbe/t4_main.c | 8 ++++++++ 3 files changed, 13 insertions(+), 10 deletions(-) diff --git a/sys/dev/cxgbe/common/common.h b/sys/dev/cxgbe/common/common.h index f43ffc83dff1..67bbf5e43b79 100644 --- a/sys/dev/cxgbe/common/common.h +++ b/sys/dev/cxgbe/common/common.h @@ -402,7 +402,9 @@ struct adapter_params { unsigned int max_ordird_qp; unsigned int max_ird_adapter; - uint32_t mps_bg_map; /* rx buffer group map for all ports (upto 4) */ + /* These values are for all ports (8b/port, upto 4 ports) */ + uint32_t mps_bg_map; /* MPS rx buffer group map */ + uint32_t tp_ch_map; /* TPCHMAP from firmware */ bool ulptx_memwrite_dsgl; /* use of T5 DSGL allowed */ bool fr_nsmr_tpte_wr_support; /* FW support for FR_NSMR_TPTE_WR */ diff --git a/sys/dev/cxgbe/common/t4_hw.c b/sys/dev/cxgbe/common/t4_hw.c index 3e04995eec3b..07940a44f66e 100644 --- a/sys/dev/cxgbe/common/t4_hw.c +++ b/sys/dev/cxgbe/common/t4_hw.c @@ -6774,15 +6774,8 @@ static unsigned int t4_get_rx_e_chan_map(struct adapter *adap, int idx) */ static unsigned int t4_get_rx_c_chan(struct adapter *adap, int idx) { - u32 param, val; - int ret; - - param = (V_FW_PARAMS_MNEM(FW_PARAMS_MNEM_DEV) | - V_FW_PARAMS_PARAM_X(FW_PARAMS_PARAM_DEV_TPCHMAP)); - ret = t4_query_params(adap, adap->mbox, adap->pf, 0, 1, ¶m, &val); - if (!ret) - return (val >> (8 * idx)) & 0xff; - + if (adap->params.tp_ch_map != UINT32_MAX) + return (adap->params.tp_ch_map >> (8 * idx)) & 0xff; return 0; } diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c index 1c4fe4b4d0cf..2e885b9c3ffe 100644 --- a/sys/dev/cxgbe/t4_main.c +++ b/sys/dev/cxgbe/t4_main.c @@ -5339,6 +5339,14 @@ get_params__post_init(struct adapter *sc) else sc->params.mps_bg_map = UINT32_MAX; /* Not a legal value. */ + param[0] = FW_PARAM_DEV(TPCHMAP); + val[0] = 0; + rc = -t4_query_params(sc, sc->mbox, sc->pf, 0, 1, param, val); + if (rc == 0) + sc->params.tp_ch_map = val[0]; + else + sc->params.tp_ch_map = UINT32_MAX; /* Not a legal value. */ + /* * Determine whether the firmware supports the filter2 work request. */ From nobody Wed Jul 17 14:21:49 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ662jVyz5RPgQ; Wed, 17 Jul 2024 14:21: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ656N0mz4t75; Wed, 17 Jul 2024 14:21:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226109; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Vx6TALkrbug4EAr+FpNzbAue+JzZ9dqaCOMLMF7stdI=; b=El5/wq6fzsPBJx9GlwH4nfEzFUwChfTWCM045cnlc9bPZlUVU++xX6Tu+J+iu4R1OwJRdC 5CfuV8gni6E6E74rnwx3vok0QbAgeb5S+bs+BbsyOJHR8c0TbZnsLUNvj3SBv7BesOgVhb zjBD1lGz1x0VQuFZuwVQOi2fotEZAxcKN4WnpycwdKoe6znZv2i5ULJTSKURBXf3EY09dT 7ltxUNEnopm6b+AVCKT0WVvRSW1PxtLcv4WQmWoY+4WRQO4i3BerdOhPKYGkL7M/ZZmSxk gBU46RqP6GS21MHASEunKqR4SkPWsekm5ZnbeyvN+wyPFW4Os+ngZE/+WchGbw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226109; a=rsa-sha256; cv=none; b=xWLWUnS+qlmZJb7lgpjZYq7PatnLCdy73fgZNWPY7DfGGYrgpBUCdv8GcESFCIb5NhXsAv 5+ygihm06kmrsvxmYWrMfCkdyIgdG0pT1y13bkYRBbnkwQBSCs22ayr8UmIqvn/ZyyMHm+ uc5DsyjBC7BjvY5zh0dQTIrTIjkLU1LevwbwmQs/Hqy3fm2JWjlrjAKEPkniKXRDpKf+zB XXS9T8ZGRCiy83YCe08kk4NYzlzDH/Pd3rYSpxYqRbn6DYJJV+T9zV1fuh9xWeKsN0V/Vm 1I2vCloQoo/jAdKQVcy/y7y260QMhXRPjdCSfTJDgqOXiYY5mdQl9nHREOUtIw== 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=1721226109; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Vx6TALkrbug4EAr+FpNzbAue+JzZ9dqaCOMLMF7stdI=; b=RNt7XsDeYXJWbg+78Wh5aea0nhNwC/ottW/gY/lGDuOjrxvFEo3PGlCy35AWqhZP6n91uY YqlFbHw3VL3jjbw/97wYAVcJ24q0u7S9+5YQ+nwu7mXtV+xFPP0e13R/lasxSMbRBbTW3y 3TwVI4sT3DKofF72jdL4/ew/o1+KM2KiyStsRRAYWbYc73O4YYSF3hsk7+V/66pjjx0pP4 qtSYBiQwJGTVs5qg867CMCJSN4mQUCOQ8DqOLrlxhs6nDF4yA3uM3LLTHQi/SruKrIJmGj AdnXtIUjXSnefaiJnIlRylSBkYqiSZbTXOdfRZEz9eyN8qxRuibbyGt6CQDkNw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ6560CXz1Mmv; Wed, 17 Jul 2024 14:21:49 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HELn2W031015; Wed, 17 Jul 2024 14:21:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HELnwx031012; Wed, 17 Jul 2024 14:21:49 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:21:49 GMT Message-Id: <202407171421.46HELnwx031012@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 29791662e974 - stable/14 - cxgbe/tom: Fix the rx channel selection in options2. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 29791662e9748ff82dc0daaefab9183e49d74099 Auto-Submitted: auto-generated The branch stable/14 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=29791662e9748ff82dc0daaefab9183e49d74099 commit 29791662e9748ff82dc0daaefab9183e49d74099 Author: Navdeep Parhar AuthorDate: 2024-04-15 20:04:49 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 06:39:13 +0000 cxgbe/tom: Fix the rx channel selection in options2. This affects TOE operation when multiple rx c-channels are in use for offload, which is an unusual configuration. Sponsored by: Chelsio Communications (cherry picked from commit c6c6d4aff90da83a292b4c2bbbe1f4d6e01cd82e) --- sys/dev/cxgbe/tom/t4_tom.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sys/dev/cxgbe/tom/t4_tom.c b/sys/dev/cxgbe/tom/t4_tom.c index b2d0b85e4832..ac5bba75f904 100644 --- a/sys/dev/cxgbe/tom/t4_tom.c +++ b/sys/dev/cxgbe/tom/t4_tom.c @@ -1200,12 +1200,14 @@ calc_options2(struct vi_info *vi, struct conn_params *cp) MPASS(cp->ecn == 0 || cp->ecn == 1); opt2 |= V_CCTRL_ECN(cp->ecn); - /* XXX: F_RX_CHANNEL for multiple rx c-chan support goes here. */ - opt2 |= V_TX_QUEUE(TX_MODQ(pi->tx_chan)); opt2 |= V_PACE(0); opt2 |= F_RSS_QUEUE_VALID; opt2 |= V_RSS_QUEUE(sc->sge.ofld_rxq[cp->rxq_idx].iq.abs_id); + if (chip_id(sc) <= CHELSIO_T6) { + MPASS(pi->rx_chan == 0 || pi->rx_chan == 1); + opt2 |= V_RX_CHANNEL(pi->rx_chan); + } MPASS(cp->cong_algo >= 0 && cp->cong_algo <= M_CONG_CNTRL); opt2 |= V_CONG_CNTRL(cp->cong_algo); From nobody Wed Jul 17 14:21:50 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ672lkCz5RPjw; Wed, 17 Jul 2024 14:21: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ670GNLz4tNP; Wed, 17 Jul 2024 14:21:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226111; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=L3TGYhFoPgj+3cKHEe4IkX8r6Xi7nqya3rUGuF4yG6Y=; b=lt4wZctCTLtEY2fxxVX+SFxKw+SQA+XxNeTgmMIDHR+VhNHJmGKsfltnnrhFUQvr9B4aj9 0kA4+VtUIpTBpR0ZhyxD1JzmJ8KP4IS6UkjDgRugwbHDYoT559Lc2V1iH/o9BSTsMHjtnJ htOryma3J8ew1OMCBj+oqYCxrgpMBOaVstacgpKc11qdmJvXY3hZUuxDx3pWvJ2ljdLikr IrHeLbjMGe4jol1BRk8HZwLOxruDmSYWkEnmeAcG9nWIHHRAWI4doJpyKFBrTGSimpnbM8 7cu3HNdQ8eIElaIfA62h3pNdc1FSqlx4E6dP3BuKxEyi8ts3/mwVIh1F7v010A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226111; a=rsa-sha256; cv=none; b=LFgMQGqYp3Zon7+1t0HeWWDu35bQ3mis6DgJD6qQgaalZHjaNSpGjAe75PA1LutpR0/TTk 58DVvxnrot0O66CBOrh241xUuHGZhrEp7J/5XhevW0MrZPcI/0OivwK/cvT6jw1rzCHF0Z cEs9p3gfslxoDb0/iP5dhoeIWHiDrhn38ur8iwf03thYc6Oj2RzEvxRRlGvlnUWHhVR9CB PFhltW+Nrp1CvGVBvxOKpquhldYguwhKET/hRCqvSVbK3app1+Dxdm2HYKMFfYL1DkCQGd XdMN9MASymCUQ/VqWjLasVTaq+dw8mHnQWzkm8DHV8vKMeKcjbDQv8gHNLE+dA== 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=1721226111; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=L3TGYhFoPgj+3cKHEe4IkX8r6Xi7nqya3rUGuF4yG6Y=; b=UezFtCpUqgcygbHVHJxFq7f5d5FgWhssrQ32AhRnAAk9NA1ONZG8X+wEBAp5JlTyd/+0gu IIfdlhSeIabVNGHgtCGGDs+agO1yGSBSOAhFLfw+iAfkfWbRVCJO0Va4+TcH0E4gHm9dGQ MtBDLASYGw+i2/QfbEeyCYsPcPqkkoWpy+z0wGwBiQK1AjZqofKG1tnyHmn+SWlCy3mIc6 DiLrdTps08VxIv44F1MT5l35SBl3bZ25enM8YfZ39XX5ioS0tVfe2xT5UEe04blEs+2Aoq +88LWUGOG0Q140Dm7vUOtsHFWZI5OHXq9EQW1knSHyxi/Sb3BDXYNmrsPxgavA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ6670Zpz1Mmw; Wed, 17 Jul 2024 14:21:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HELoZ5031069; Wed, 17 Jul 2024 14:21:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HELopG031066; Wed, 17 Jul 2024 14:21:50 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:21:50 GMT Message-Id: <202407171421.46HELopG031066@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 307639c1e93f - stable/14 - cxgbe(4): sc->port is indexed by port_id and not tx_chan. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 307639c1e93f7948359f157cfd47c6aeadf77719 Auto-Submitted: auto-generated The branch stable/14 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=307639c1e93f7948359f157cfd47c6aeadf77719 commit 307639c1e93f7948359f157cfd47c6aeadf77719 Author: Navdeep Parhar AuthorDate: 2024-05-02 23:47:18 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 06:39:32 +0000 cxgbe(4): sc->port is indexed by port_id and not tx_chan. Sponsored by: Chelsio Communications (cherry picked from commit cca3506dc15464baf9b09b143879ed13fb5684c7) --- sys/dev/cxgbe/t4_sched.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/cxgbe/t4_sched.c b/sys/dev/cxgbe/t4_sched.c index 46638a086a0d..2186c8aa2ac0 100644 --- a/sys/dev/cxgbe/t4_sched.c +++ b/sys/dev/cxgbe/t4_sched.c @@ -334,7 +334,7 @@ bind_txq_to_traffic_class(struct adapter *sc, struct sge_txq *txq, int idx) goto done; } - tc0 = &sc->port[txq->eq.tx_chan]->sched_params->cl_rl[0]; + tc0 = &sc->port[txq->eq.port_id]->sched_params->cl_rl[0]; if (idx != -1) { /* * Bind to a different class at index idx. From nobody Wed Jul 17 14:21:52 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ685J3vz5RPRJ; Wed, 17 Jul 2024 14:21: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ680yvzz4tNd; Wed, 17 Jul 2024 14:21:52 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226112; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=f1WpAQLt/FbI719gM08cMTLAMDOjVfPsWjrJ4+Gmx+s=; b=TZ7GWdR/FfahaGCLwD7W+/hVU4toINup8dsXyXK2Fd3QKym6xTqr7lZBtQ1Vhx7DDMDugX SPvcrGpyeHGey0j61NdECUt3kT5nZTm+E1UPZU9dQSUTDi/eN1qGIdw5m7KaSGVmL+J9zt ZPA5vHQu4j7fjFDlcHqA492g3v3Nvyc+DZmdykJNB1DTiUXuVMsB3o59hjRjW/FIXWMUHa HqYOrs2Ziom4h86Y/E3KopsZ8aLvs5UgsZis6hqxm18gGpI+W+TskiGr+N0cZi8nEZgXGg +0bU3wxWBnDlgeFRDqQRH1kpWa3sgo3v44ytAQUbrwkq1CU3+qw/GV7abZzp6A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226112; a=rsa-sha256; cv=none; b=W4EnmN3Fb5jd0HR8KPwAxNzV7i25BSAkEItBqoLgngDocOJcgMj4i5Mrx6iIMNCs50J5Nx RQasMc3No0cjrKS7ldH084BMjnQWLu+EGfS8wDYjw7Wo8qNGNIHpuq8rDw3ca3Qbs6BA78 nGGQQNLi84gX70fiXI9jt11uojWHbb9PYUm9Qqj16TGCiPBB5rSqSpFAFtomDcMEm6b0Pp q0OvB0CAt9dzM57CF4cLOlPHnqpbrK+iZcPAsdARqTyodJWvOX5qgkZB8Aehl3puNia4XF Cl27gDxJqhsEM9cyEdY8eSMBpAGunGO1VXFdoX+latqW/8pgZHBXRkj1b4mpkA== 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=1721226112; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=f1WpAQLt/FbI719gM08cMTLAMDOjVfPsWjrJ4+Gmx+s=; b=xl5QUYXenyjGWw1gJF9UP7I4+R5i8+capsyJSiMPCN824+auquZ578I7DWT2x+M1+/4Lfv Rb7AcCLJbVpzhJNGwmrhXK/CCgbkVZJhCmCsAtgvf1ZK3Kv0Qt6S4FQccYqbxnvLZTnosI OQb5xr0CVKmKabGEJehUpgBOzTQIiRdwhfb6xwVPhtXQxDHokP+6PjstYO1/39XpuAh7oI JFhj0Q/OHXrd0o9Hxbtj8v3gsiPlkRqIkZY+jYQ29p+sVop6iEFd8WZsOqU94RXwp7WLbu 8P+maIz+Zs1q2+Wi8k8blQZQrQygU+8nB25b4IlRq7GtqlYOQxqasSkvB+R7xQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ680b6jz1N0g; Wed, 17 Jul 2024 14:21:52 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HELqHu031119; Wed, 17 Jul 2024 14:21:52 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HELqAY031116; Wed, 17 Jul 2024 14:21:52 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:21:52 GMT Message-Id: <202407171421.46HELqAY031116@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 8d214aa2c189 - stable/14 - cxgbe(4): Consolidate all mk_set_tcb_field_ulp in one place. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 8d214aa2c18925c630495a66990d4e77c256a805 Auto-Submitted: auto-generated The branch stable/14 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=8d214aa2c18925c630495a66990d4e77c256a805 commit 8d214aa2c18925c630495a66990d4e77c256a805 Author: Navdeep Parhar AuthorDate: 2023-04-01 00:23:38 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 06:39:43 +0000 cxgbe(4): Consolidate all mk_set_tcb_field_ulp in one place. Sponsored by: Chelsio Communications (cherry picked from commit 64a00f877fc23d904d5f4ca00471e09954eb9381) --- sys/dev/cxgbe/common/common.h | 42 ++++++++++++++++++++++++++++++++++ sys/dev/cxgbe/t4_filter.c | 43 +++++------------------------------ sys/dev/cxgbe/tom/t4_ddp.c | 52 +++++++++---------------------------------- sys/dev/cxgbe/tom/t4_tls.c | 50 ++++++----------------------------------- sys/dev/cxgbe/tom/t4_tom.c | 42 ++++------------------------------ 5 files changed, 68 insertions(+), 161 deletions(-) diff --git a/sys/dev/cxgbe/common/common.h b/sys/dev/cxgbe/common/common.h index 67bbf5e43b79..6e80ce40648b 100644 --- a/sys/dev/cxgbe/common/common.h +++ b/sys/dev/cxgbe/common/common.h @@ -964,4 +964,46 @@ port_top_speed(const struct port_info *pi) return (fwcap_to_speed(pi->link_cfg.pcaps) / 1000); } +/* SET_TCB_FIELD sent as a ULP command looks like this */ +#define LEN__SET_TCB_FIELD_ULP (sizeof(struct ulp_txpkt) + \ + sizeof(struct ulptx_idata) + sizeof(struct cpl_set_tcb_field_core)) + +static inline void * +mk_set_tcb_field_ulp(struct adapter *sc, void *cur, int tid, uint16_t word, + uint64_t mask, uint64_t val) +{ + struct ulp_txpkt *ulpmc; + struct ulptx_idata *ulpsc; + struct cpl_set_tcb_field_core *req; + + MPASS(((uintptr_t)cur & 7) == 0); + + ulpmc = cur; + ulpmc->cmd_dest = htobe32(V_ULPTX_CMD(ULP_TX_PKT) | + V_ULP_TXPKT_DEST(ULP_TXPKT_DEST_TP)); + ulpmc->len = htobe32(howmany(LEN__SET_TCB_FIELD_ULP, 16)); + + ulpsc = (struct ulptx_idata *)(ulpmc + 1); + ulpsc->cmd_more = htobe32(V_ULPTX_CMD(ULP_TX_SC_IMM)); + ulpsc->len = htobe32(sizeof(*req)); + + req = (struct cpl_set_tcb_field_core *)(ulpsc + 1); + OPCODE_TID(req) = htobe32(MK_OPCODE_TID(CPL_SET_TCB_FIELD, tid)); + req->reply_ctrl = htobe16(F_NO_REPLY); + req->word_cookie = htobe16(V_WORD(word) | V_COOKIE(0)); + req->mask = htobe64(mask); + req->val = htobe64(val); + + /* + * ULP_TX is an 8B processor but the firmware transfers WRs in 16B + * chunks. The master command for set_tcb_field does not end at a 16B + * boundary so it needs to be padded with a no-op. + */ + MPASS((LEN__SET_TCB_FIELD_ULP & 0xf) != 0); + ulpsc = (struct ulptx_idata *)(req + 1); + ulpsc->cmd_more = htobe32(V_ULPTX_CMD(ULP_TX_SC_NOOP)); + ulpsc->len = htobe32(0); + + return (ulpsc + 1); +} #endif /* __CHELSIO_COMMON_H */ diff --git a/sys/dev/cxgbe/t4_filter.c b/sys/dev/cxgbe/t4_filter.c index 18fa1093800f..359aae6df24e 100644 --- a/sys/dev/cxgbe/t4_filter.c +++ b/sys/dev/cxgbe/t4_filter.c @@ -1698,40 +1698,6 @@ done: return (rc); } -/* SET_TCB_FIELD sent as a ULP command looks like this */ -#define LEN__SET_TCB_FIELD_ULP (sizeof(struct ulp_txpkt) + \ - sizeof(struct ulptx_idata) + sizeof(struct cpl_set_tcb_field_core)) - -static void * -mk_set_tcb_field_ulp(struct ulp_txpkt *ulpmc, uint64_t word, uint64_t mask, - uint64_t val, uint32_t tid, uint32_t qid) -{ - struct ulptx_idata *ulpsc; - struct cpl_set_tcb_field_core *req; - - ulpmc->cmd_dest = htonl(V_ULPTX_CMD(ULP_TX_PKT) | V_ULP_TXPKT_DEST(0)); - ulpmc->len = htobe32(howmany(LEN__SET_TCB_FIELD_ULP, 16)); - - ulpsc = (struct ulptx_idata *)(ulpmc + 1); - ulpsc->cmd_more = htobe32(V_ULPTX_CMD(ULP_TX_SC_IMM)); - ulpsc->len = htobe32(sizeof(*req)); - - req = (struct cpl_set_tcb_field_core *)(ulpsc + 1); - OPCODE_TID(req) = htobe32(MK_OPCODE_TID(CPL_SET_TCB_FIELD, tid)); - req->reply_ctrl = htobe16(V_NO_REPLY(1) | V_QUEUENO(qid)); - req->word_cookie = htobe16(V_WORD(word) | V_COOKIE(0)); - req->mask = htobe64(mask); - req->val = htobe64(val); - - ulpsc = (struct ulptx_idata *)(req + 1); - if (LEN__SET_TCB_FIELD_ULP % 16) { - ulpsc->cmd_more = htobe32(V_ULPTX_CMD(ULP_TX_SC_NOOP)); - ulpsc->len = htobe32(0); - return (ulpsc + 1); - } - return (ulpsc); -} - /* ABORT_REQ sent as a ULP command looks like this */ #define LEN__ABORT_REQ_ULP (sizeof(struct ulp_txpkt) + \ sizeof(struct ulptx_idata) + sizeof(struct cpl_abort_req_core)) @@ -1807,14 +1773,15 @@ del_hashfilter_wrlen(void) } static void -mk_del_hashfilter_wr(int tid, struct work_request_hdr *wrh, int wrlen, int qid) +mk_del_hashfilter_wr(struct adapter *sc, int tid, struct work_request_hdr *wrh, + int wrlen, int qid) { struct ulp_txpkt *ulpmc; INIT_ULPTX_WRH(wrh, wrlen, 0, 0); ulpmc = (struct ulp_txpkt *)(wrh + 1); - ulpmc = mk_set_tcb_field_ulp(ulpmc, W_TCB_RSS_INFO, - V_TCB_RSS_INFO(M_TCB_RSS_INFO), V_TCB_RSS_INFO(qid), tid, 0); + ulpmc = mk_set_tcb_field_ulp(sc, ulpmc, tid, W_TCB_RSS_INFO, + V_TCB_RSS_INFO(M_TCB_RSS_INFO), V_TCB_RSS_INFO(qid)); ulpmc = mk_abort_req_ulp(ulpmc, tid); ulpmc = mk_abort_rpl_ulp(ulpmc, tid); } @@ -1857,7 +1824,7 @@ del_hashfilter(struct adapter *sc, struct t4_filter *t) goto done; } - mk_del_hashfilter_wr(t->idx, wr, wrlen, sc->sge.fwq.abs_id); + mk_del_hashfilter_wr(sc, t->idx, wr, wrlen, sc->sge.fwq.abs_id); f->locked = 1; f->pending = 1; commit_wrq_wr(&sc->sge.ctrlq[0], wr, &cookie); diff --git a/sys/dev/cxgbe/tom/t4_ddp.c b/sys/dev/cxgbe/tom/t4_ddp.c index c1d4af45fd70..a08ddea00d05 100644 --- a/sys/dev/cxgbe/tom/t4_ddp.c +++ b/sys/dev/cxgbe/tom/t4_ddp.c @@ -545,37 +545,6 @@ insert_ddp_data(struct toepcb *toep, uint32_t n) #define LEN__RX_DATA_ACK_ULP (sizeof(struct ulp_txpkt) + \ sizeof(struct ulptx_idata) + sizeof(struct cpl_rx_data_ack_core)) -static inline void * -mk_set_tcb_field_ulp(struct ulp_txpkt *ulpmc, struct toepcb *toep, - uint64_t word, uint64_t mask, uint64_t val) -{ - struct ulptx_idata *ulpsc; - struct cpl_set_tcb_field_core *req; - - ulpmc->cmd_dest = htonl(V_ULPTX_CMD(ULP_TX_PKT) | V_ULP_TXPKT_DEST(0)); - ulpmc->len = htobe32(howmany(LEN__SET_TCB_FIELD_ULP, 16)); - - ulpsc = (struct ulptx_idata *)(ulpmc + 1); - ulpsc->cmd_more = htobe32(V_ULPTX_CMD(ULP_TX_SC_IMM)); - ulpsc->len = htobe32(sizeof(*req)); - - req = (struct cpl_set_tcb_field_core *)(ulpsc + 1); - OPCODE_TID(req) = htobe32(MK_OPCODE_TID(CPL_SET_TCB_FIELD, toep->tid)); - req->reply_ctrl = htobe16(V_NO_REPLY(1) | - V_QUEUENO(toep->ofld_rxq->iq.abs_id)); - req->word_cookie = htobe16(V_WORD(word) | V_COOKIE(0)); - req->mask = htobe64(mask); - req->val = htobe64(val); - - ulpsc = (struct ulptx_idata *)(req + 1); - if (LEN__SET_TCB_FIELD_ULP % 16) { - ulpsc->cmd_more = htobe32(V_ULPTX_CMD(ULP_TX_SC_NOOP)); - ulpsc->len = htobe32(0); - return (ulpsc + 1); - } - return (ulpsc); -} - static inline void * mk_rx_data_ack_ulp(struct ulp_txpkt *ulpmc, struct toepcb *toep) { @@ -634,21 +603,21 @@ mk_update_tcb_for_ddp(struct adapter *sc, struct toepcb *toep, int db_idx, ulpmc = (struct ulp_txpkt *)(wrh + 1); /* Write the buffer's tag */ - ulpmc = mk_set_tcb_field_ulp(ulpmc, toep, + ulpmc = mk_set_tcb_field_ulp(sc, ulpmc, toep->tid, W_TCB_RX_DDP_BUF0_TAG + db_idx, V_TCB_RX_DDP_BUF0_TAG(M_TCB_RX_DDP_BUF0_TAG), V_TCB_RX_DDP_BUF0_TAG(prsv->prsv_tag)); /* Update the current offset in the DDP buffer and its total length */ if (db_idx == 0) - ulpmc = mk_set_tcb_field_ulp(ulpmc, toep, + ulpmc = mk_set_tcb_field_ulp(sc, ulpmc, toep->tid, W_TCB_RX_DDP_BUF0_OFFSET, V_TCB_RX_DDP_BUF0_OFFSET(M_TCB_RX_DDP_BUF0_OFFSET) | V_TCB_RX_DDP_BUF0_LEN(M_TCB_RX_DDP_BUF0_LEN), V_TCB_RX_DDP_BUF0_OFFSET(offset) | V_TCB_RX_DDP_BUF0_LEN(len)); else - ulpmc = mk_set_tcb_field_ulp(ulpmc, toep, + ulpmc = mk_set_tcb_field_ulp(sc, ulpmc, toep->tid, W_TCB_RX_DDP_BUF1_OFFSET, V_TCB_RX_DDP_BUF1_OFFSET(M_TCB_RX_DDP_BUF1_OFFSET) | V_TCB_RX_DDP_BUF1_LEN((u64)M_TCB_RX_DDP_BUF1_LEN << 32), @@ -656,7 +625,7 @@ mk_update_tcb_for_ddp(struct adapter *sc, struct toepcb *toep, int db_idx, V_TCB_RX_DDP_BUF1_LEN((u64)len << 32)); /* Update DDP flags */ - ulpmc = mk_set_tcb_field_ulp(ulpmc, toep, W_TCB_RX_DDP_FLAGS, + ulpmc = mk_set_tcb_field_ulp(sc, ulpmc, toep->tid, W_TCB_RX_DDP_FLAGS, ddp_flags_mask, ddp_flags); /* Gratuitous RX_DATA_ACK with RX_MODULATE set to speed up delivery. */ @@ -1295,26 +1264,25 @@ set_ddp_ulp_mode(struct toepcb *toep) * Words 26/27 are zero except for the DDP_OFF flag in * W_TCB_RX_DDP_FLAGS (27). */ - ulpmc = mk_set_tcb_field_ulp(ulpmc, toep, 26, + ulpmc = mk_set_tcb_field_ulp(sc, ulpmc, toep->tid, 26, 0xffffffffffffffff, (uint64_t)V_TF_DDP_OFF(1) << 32); /* Words 28/29 are zero. */ - ulpmc = mk_set_tcb_field_ulp(ulpmc, toep, 28, + ulpmc = mk_set_tcb_field_ulp(sc, ulpmc, toep->tid, 28, 0xffffffffffffffff, 0); /* Words 30/31 are zero. */ - ulpmc = mk_set_tcb_field_ulp(ulpmc, toep, 30, + ulpmc = mk_set_tcb_field_ulp(sc, ulpmc, toep->tid, 30, 0xffffffffffffffff, 0); /* Set the ULP mode to ULP_MODE_TCPDDP. */ toep->params.ulp_mode = ULP_MODE_TCPDDP; - ulpmc = mk_set_tcb_field_ulp(ulpmc, toep, W_TCB_ULP_TYPE, - V_TCB_ULP_TYPE(M_TCB_ULP_TYPE), - V_TCB_ULP_TYPE(ULP_MODE_TCPDDP)); + ulpmc = mk_set_tcb_field_ulp(sc, ulpmc, toep->tid, W_TCB_ULP_TYPE, + V_TCB_ULP_TYPE(M_TCB_ULP_TYPE), V_TCB_ULP_TYPE(ULP_MODE_TCPDDP)); #ifdef USE_DDP_RX_FLOW_CONTROL /* Set TF_RX_FLOW_CONTROL_DDP. */ - ulpmc = mk_set_tcb_field_ulp(ulpmc, toep, W_TCB_T_FLAGS, + ulpmc = mk_set_tcb_field_ulp(sc, ulpmc, toep->tid, W_TCB_T_FLAGS, V_TF_RX_FLOW_CONTROL_DDP(1), V_TF_RX_FLOW_CONTROL_DDP(1)); #endif diff --git a/sys/dev/cxgbe/tom/t4_tls.c b/sys/dev/cxgbe/tom/t4_tls.c index bdd03edd3a6f..c6377980fca9 100644 --- a/sys/dev/cxgbe/tom/t4_tls.c +++ b/sys/dev/cxgbe/tom/t4_tls.c @@ -1075,41 +1075,6 @@ out: m_freem(m); } -/* SET_TCB_FIELD sent as a ULP command looks like this */ -#define LEN__SET_TCB_FIELD_ULP (sizeof(struct ulp_txpkt) + \ - sizeof(struct ulptx_idata) + sizeof(struct cpl_set_tcb_field_core)) - -static inline void * -mk_set_tcb_field_ulp(struct ulp_txpkt *ulpmc, struct toepcb *toep, - uint64_t word, uint64_t mask, uint64_t val) -{ - struct ulptx_idata *ulpsc; - struct cpl_set_tcb_field_core *req; - - ulpmc->cmd_dest = htonl(V_ULPTX_CMD(ULP_TX_PKT) | V_ULP_TXPKT_DEST(0)); - ulpmc->len = htobe32(howmany(LEN__SET_TCB_FIELD_ULP, 16)); - - ulpsc = (struct ulptx_idata *)(ulpmc + 1); - ulpsc->cmd_more = htobe32(V_ULPTX_CMD(ULP_TX_SC_IMM)); - ulpsc->len = htobe32(sizeof(*req)); - - req = (struct cpl_set_tcb_field_core *)(ulpsc + 1); - OPCODE_TID(req) = htobe32(MK_OPCODE_TID(CPL_SET_TCB_FIELD, toep->tid)); - req->reply_ctrl = htobe16(V_NO_REPLY(1) | - V_QUEUENO(toep->ofld_rxq->iq.abs_id)); - req->word_cookie = htobe16(V_WORD(word) | V_COOKIE(0)); - req->mask = htobe64(mask); - req->val = htobe64(val); - - ulpsc = (struct ulptx_idata *)(req + 1); - if (LEN__SET_TCB_FIELD_ULP % 16) { - ulpsc->cmd_more = htobe32(V_ULPTX_CMD(ULP_TX_SC_NOOP)); - ulpsc->len = htobe32(0); - return (ulpsc + 1); - } - return (ulpsc); -} - /* * Send a work request setting multiple TCB fields to enable * ULP_MODE_TLS. @@ -1164,7 +1129,7 @@ tls_update_tcb(struct adapter *sc, struct toepcb *toep, uint64_t seqno) * decryption. Word 30 is zero and Word 31 contains * the keyid. */ - ulpmc = mk_set_tcb_field_ulp(ulpmc, toep, 26, + ulpmc = mk_set_tcb_field_ulp(sc, ulpmc, toep->tid, 26, 0xffffffffffffffff, 0); /* @@ -1173,15 +1138,15 @@ tls_update_tcb(struct adapter *sc, struct toepcb *toep, uint64_t seqno) * units of 64 bytes. */ key_offset = toep->tls.rx_key_addr - sc->vres.key.start; - ulpmc = mk_set_tcb_field_ulp(ulpmc, toep, 30, + ulpmc = mk_set_tcb_field_ulp(sc, ulpmc, toep->tid, 30, 0xffffffffffffffff, (uint64_t)V_TCB_RX_TLS_KEY_TAG(key_offset / 64) << 32); CTR3(KTR_CXGBE, "%s: tid %d enable TLS seqno %lu", __func__, toep->tid, seqno); - ulpmc = mk_set_tcb_field_ulp(ulpmc, toep, W_TCB_TLS_SEQ, + ulpmc = mk_set_tcb_field_ulp(sc, ulpmc, toep->tid, W_TCB_TLS_SEQ, V_TCB_TLS_SEQ(M_TCB_TLS_SEQ), V_TCB_TLS_SEQ(seqno)); - ulpmc = mk_set_tcb_field_ulp(ulpmc, toep, W_TCB_ULP_RAW, + ulpmc = mk_set_tcb_field_ulp(sc, ulpmc, toep->tid, W_TCB_ULP_RAW, V_TCB_ULP_RAW(M_TCB_ULP_RAW), V_TCB_ULP_RAW((V_TF_TLS_KEY_SIZE(3) | V_TF_TLS_CONTROL(1) | V_TF_TLS_ACTIVE(1) | V_TF_TLS_ENABLE(1)))); @@ -1191,12 +1156,11 @@ tls_update_tcb(struct adapter *sc, struct toepcb *toep, uint64_t seqno) /* Set the ULP mode to ULP_MODE_TLS. */ toep->params.ulp_mode = ULP_MODE_TLS; - ulpmc = mk_set_tcb_field_ulp(ulpmc, toep, W_TCB_ULP_TYPE, - V_TCB_ULP_TYPE(M_TCB_ULP_TYPE), - V_TCB_ULP_TYPE(ULP_MODE_TLS)); + ulpmc = mk_set_tcb_field_ulp(sc, ulpmc, toep->tid, W_TCB_ULP_TYPE, + V_TCB_ULP_TYPE(M_TCB_ULP_TYPE), V_TCB_ULP_TYPE(ULP_MODE_TLS)); /* Clear TF_RX_QUIESCE. */ - ulpmc = mk_set_tcb_field_ulp(ulpmc, toep, W_TCB_T_FLAGS, + ulpmc = mk_set_tcb_field_ulp(sc, ulpmc, toep->tid, W_TCB_T_FLAGS, V_TF_RX_QUIESCE(1), 0); t4_wrq_tx(sc, wr); diff --git a/sys/dev/cxgbe/tom/t4_tom.c b/sys/dev/cxgbe/tom/t4_tom.c index ac5bba75f904..3fe34c7c01a3 100644 --- a/sys/dev/cxgbe/tom/t4_tom.c +++ b/sys/dev/cxgbe/tom/t4_tom.c @@ -838,40 +838,6 @@ t4_alloc_tls_session(struct toedev *tod, struct tcpcb *tp, } #endif -/* SET_TCB_FIELD sent as a ULP command looks like this */ -#define LEN__SET_TCB_FIELD_ULP (sizeof(struct ulp_txpkt) + \ - sizeof(struct ulptx_idata) + sizeof(struct cpl_set_tcb_field_core)) - -static void * -mk_set_tcb_field_ulp(struct ulp_txpkt *ulpmc, uint64_t word, uint64_t mask, - uint64_t val, uint32_t tid) -{ - struct ulptx_idata *ulpsc; - struct cpl_set_tcb_field_core *req; - - ulpmc->cmd_dest = htonl(V_ULPTX_CMD(ULP_TX_PKT) | V_ULP_TXPKT_DEST(0)); - ulpmc->len = htobe32(howmany(LEN__SET_TCB_FIELD_ULP, 16)); - - ulpsc = (struct ulptx_idata *)(ulpmc + 1); - ulpsc->cmd_more = htobe32(V_ULPTX_CMD(ULP_TX_SC_IMM)); - ulpsc->len = htobe32(sizeof(*req)); - - req = (struct cpl_set_tcb_field_core *)(ulpsc + 1); - OPCODE_TID(req) = htobe32(MK_OPCODE_TID(CPL_SET_TCB_FIELD, tid)); - req->reply_ctrl = htobe16(V_NO_REPLY(1)); - req->word_cookie = htobe16(V_WORD(word) | V_COOKIE(0)); - req->mask = htobe64(mask); - req->val = htobe64(val); - - ulpsc = (struct ulptx_idata *)(req + 1); - if (LEN__SET_TCB_FIELD_ULP % 16) { - ulpsc->cmd_more = htobe32(V_ULPTX_CMD(ULP_TX_SC_NOOP)); - ulpsc->len = htobe32(0); - return (ulpsc + 1); - } - return (ulpsc); -} - static void send_mss_flowc_wr(struct adapter *sc, struct toepcb *toep) { @@ -958,10 +924,10 @@ t4_pmtu_update(struct toedev *tod, struct tcpcb *tp, tcp_seq seq, int mtu) } INIT_ULPTX_WRH(wrh, len, 1, 0); /* atomic */ ulpmc = (struct ulp_txpkt *)(wrh + 1); - ulpmc = mk_set_tcb_field_ulp(ulpmc, W_TCB_T_MAXSEG, - V_TCB_T_MAXSEG(M_TCB_T_MAXSEG), V_TCB_T_MAXSEG(idx), toep->tid); - ulpmc = mk_set_tcb_field_ulp(ulpmc, W_TCB_TIMESTAMP, - V_TCB_TIMESTAMP(0x7FFFFULL << 11), 0, toep->tid); + ulpmc = mk_set_tcb_field_ulp(sc, ulpmc, toep->tid, W_TCB_T_MAXSEG, + V_TCB_T_MAXSEG(M_TCB_T_MAXSEG), V_TCB_T_MAXSEG(idx)); + ulpmc = mk_set_tcb_field_ulp(sc, ulpmc, toep->tid, W_TCB_TIMESTAMP, + V_TCB_TIMESTAMP(0x7FFFFULL << 11), 0); commit_wrq_wr(toep->ctrlq, wrh, &cookie); /* Update the software toepcb and tcpcb. */ From nobody Wed Jul 17 14:21:53 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ695SMHz5RPRM; Wed, 17 Jul 2024 14:21: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ691hfSz4tCT; Wed, 17 Jul 2024 14:21:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226113; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=565ICV/1Fh9x7iv4Xk2XokLafToZI45PStrsOFfuxgI=; b=lcETQenUEsLOnvr1/STuSsQMCJGvyll2OC93TCg9KnBhKb6Glb2YT951a3mKKEgEHFoMnX TipI7ykU3bwFfaNZfnv+doh2qCIFvGkIVu/Mv7TE9EeWNbA/LRKWRmCibJslkcYyr+HRBW CSwMDcTIxG8aceJqxwUmEbtpnfI6LR7S24mLbfymXpnls0iED+1b1YGbN9Jipy8lFC8jJL Y32vRFlfe2jC/zZ9k6rDs0q0LzlPcrZ55qhKwU6LCiSXyUdvW/bwWR5xGwARjZJSQkCZTd CpNPziSojy+ZLgCXVtb/1uoOErEzuMhIGCIzJauQTHUgIHy1YGuZW05HKCMllw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226113; a=rsa-sha256; cv=none; b=Vb7nlNC2FiZqAWyQ/UlujP5FJK2YXm7ZaU4bEYpJBNzxWl7ayCBY0kiqHqkKJQHKVqlHgU NUkdLsGFQi6sbNwITGXVnZDJ81kC8XpECAZtTISEvy0v8wNsqbwKqwr+bHR6vzYGggRMeK xnMyI+Db+XIyup0M+vxFwGIJWiJ8H8TGkGBcb+Gs+3ieipRsvVBHQv2TGidAubMor7NYUQ sURZrj0NLa/4S7+7TBrltDdG1H9X5QEMilLkRCmzaBp6d0TGXmQu9EDU1lUzCD040odlWt qdQsiNPJNlzubhIwet4JZS6I3EkeS/z4jXMZk4qNmf2y0g3mDgLoe2RTrVrAJA== 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=1721226113; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=565ICV/1Fh9x7iv4Xk2XokLafToZI45PStrsOFfuxgI=; b=j5PKMmeQbT3R3MzDnWGFU4vcnjTWtyFiL4mZ4NHCYHSW0EeYlepCBrxGvRCrajw4WQCQUl rVbWNZ2r5vCXbchA3lBtp/+VLBif5GGGS876PEGadIEd5SBmsCq2qsz6+dBb8sF9OM7fbh uk+fG120yXmuls4fd3D7VmSjRaSyBW0iYpni0ZAUoZ2ynC0p0RoBFpvuAD//aRwaT46RVs GgAbStQMrNGjjAfkti+uQR7t5KZIfxrOQEaq5dL2iKyAZH5MbPDDwnGQDNKStsiNgtT/IH L9ou0aHvrY/KDihtXcBfOIcQyGeQh1FYz6nllN/74fNQYFjStB5neE7BZdv64w== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ691Flkz1MZp; Wed, 17 Jul 2024 14:21:53 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HELrDe031171; Wed, 17 Jul 2024 14:21:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HELra9031168; Wed, 17 Jul 2024 14:21:53 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:21:53 GMT Message-Id: <202407171421.46HELra9031168@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 0d7e2e14ba79 - stable/14 - cxgbetool(8): Be flexible about the nexus name. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 0d7e2e14ba79cac306959abc6d35b119ee1a38e8 Auto-Submitted: auto-generated The branch stable/14 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=0d7e2e14ba79cac306959abc6d35b119ee1a38e8 commit 0d7e2e14ba79cac306959abc6d35b119ee1a38e8 Author: Navdeep Parhar AuthorDate: 2024-06-13 20:17:55 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 06:39:56 +0000 cxgbetool(8): Be flexible about the nexus name. Use the name as-is but perform cxgbe specific ioctls on the device to make sure that it is a Terminator device nexus. Determine the chip type, pf/vf, etc. from the device registers rather than the nexus name. This allows cxgbetool to work with the VF driver. Sponsored by: Chelsio Communications (cherry picked from commit e827b61cacddd4bc9a2f1657ad8c6d2bcd70d52e) --- usr.sbin/cxgbetool/cxgbetool.c | 116 +++++++++++++++++++++++++++-------------- 1 file changed, 76 insertions(+), 40 deletions(-) diff --git a/usr.sbin/cxgbetool/cxgbetool.c b/usr.sbin/cxgbetool/cxgbetool.c index c02bc7fdc054..7b2b495a0292 100644 --- a/usr.sbin/cxgbetool/cxgbetool.c +++ b/usr.sbin/cxgbetool/cxgbetool.c @@ -43,6 +43,7 @@ #include #include #include +#include #include #include #include @@ -56,9 +57,16 @@ #define in_range(val, lo, hi) ( val < 0 || (val <= hi && val >= lo)) #define max(x, y) ((x) > (y) ? (x) : (y)) -static const char *progname, *nexus; -static int chip_id; /* 4 for T4, 5 for T5, and so on. */ -static int inst; /* instance of nexus device */ +static struct { + const char *progname, *nexus; + int chip_id; /* 4 for T4, 5 for T5, and so on. */ + int inst; /* instance of nexus device */ + int pf; /* PF# of the nexus (if not VF). */ + bool vf; /* Nexus is a VF. */ + + int fd; + bool warn_on_ioctl_err; +} g; struct reg_info { const char *name; @@ -88,7 +96,7 @@ struct field_desc { static void usage(FILE *fp) { - fprintf(fp, "Usage: %s [operation]\n", progname); + fprintf(fp, "Usage: %s [operation]\n", g.progname); fprintf(fp, "\tclearstats clear port statistics\n" "\tclip hold|release hold/release an address\n" @@ -137,27 +145,12 @@ get_card_vers(unsigned int version) static int real_doit(unsigned long cmd, void *data, const char *cmdstr) { - static int fd = -1; - int rc = 0; - - if (fd == -1) { - char buf[64]; - - snprintf(buf, sizeof(buf), "/dev/%s", nexus); - if ((fd = open(buf, O_RDWR)) < 0) { - warn("open(%s)", nexus); - rc = errno; - return (rc); - } - } - - rc = ioctl(fd, cmd, data); - if (rc < 0) { - warn("%s", cmdstr); - rc = errno; + if (ioctl(g.fd, cmd, data) < 0) { + if (g.warn_on_ioctl_err) + warn("%s", cmdstr); + return (errno); } - - return (rc); + return (0); } #define doit(x, y) real_doit(x, y, #x) @@ -523,7 +516,7 @@ dump_regs(int argc, const char *argv[]) rc = dump_regs_t6(argc, argv, regs.data); } else { warnx("%s (type %d, rev %d) is not a known card.", - nexus, vers, revision); + g.nexus, vers, revision); return (ENOTSUP); } @@ -915,7 +908,7 @@ do_show_one_filter_info(struct t4_filter *t, uint32_t mode) printf("(hash)"); } } - if (chip_id <= 5 && t->fs.prio) + if (g.chip_id <= 5 && t->fs.prio) printf(" Prio"); if (t->fs.rpttid) printf(" RptTID"); @@ -934,7 +927,7 @@ show_filters(int hash) if (rc != 0) return (rc); - if (!hash && chip_id >= 6) { + if (!hash && g.chip_id >= 6) { header = 0; bzero(&t, sizeof (t)); t.idx = 0; @@ -1925,10 +1918,10 @@ get_sge_context(int argc, const char *argv[]) if (rc != 0) return (rc); - if (chip_id == 4) + if (g.chip_id == 4) show_t4_ctxt(&cntxt); else - show_t5t6_ctxt(&cntxt, chip_id); + show_t5t6_ctxt(&cntxt, g.chip_id); return (0); } @@ -2244,7 +2237,7 @@ show_tcb(uint32_t *buf, uint32_t len) } printf("\n"); } - set_tcb_info(TIDTYPE_TCB, chip_id); + set_tcb_info(TIDTYPE_TCB, g.chip_id); set_print_style(PRNTSTYL_COMP); swizzle_tcb(tcb); parse_n_display_xcb(tcb); @@ -2448,7 +2441,7 @@ static void create_tracing_ifnet() { char *cmd[] = { - "/sbin/ifconfig", __DECONST(char *, nexus), "create", NULL + "/sbin/ifconfig", __DECONST(char *, g.nexus), "create", NULL }; char *env[] = {NULL}; @@ -3495,7 +3488,7 @@ display_clip(void) return (errno); } - snprintf(name, sizeof(name), "dev.t%unex.%u.misc.clip", chip_id, inst); + snprintf(name, sizeof(name), "dev.t%unex.%u.misc.clip", g.chip_id, g.inst); rc = sysctlbyname(name, buf, &clip_buf_size, NULL, 0); if (rc != 0) { warn("sysctl %s", name); @@ -3650,14 +3643,57 @@ run_cmd_loop(void) return (rc); } +#define A_PL_WHOAMI 0x19400 +#define A_PL_REV 0x1943c +#define A_PL_VF_WHOAMI 0x200 +#define A_PL_VF_REV 0x204 + static void -parse_nexus_name(const char *s) +open_nexus_device(const char *s) { - char junk; - - if (sscanf(s, "t%unex%u%c", &chip_id, &inst, &junk) != 2) - errx(EINVAL, "invalid nexus \"%s\"", s); - nexus = s; + const int len = strlen(s); + long long val; + const char *num; + int rc; + u_int chip_id, whoami; + char buf[128]; + + if (len < 2 || isdigit(s[0]) || !isdigit(s[len - 1])) + errx(1, "invalid nexus name \"%s\"", s); + for (num = s + len - 1; isdigit(*num); num--) + continue; + g.inst = strtoll(num, NULL, 0); + g.nexus = s; + snprintf(buf, sizeof(buf), "/dev/%s", g.nexus); + if ((g.fd = open(buf, O_RDWR)) < 0) + err(1, "open(%s)", buf); + + g.warn_on_ioctl_err = false; + rc = read_reg(A_PL_REV, 4, &val); + if (rc == 0) { + /* PF */ + g.vf = false; + whoami = A_PL_WHOAMI; + } else { + rc = read_reg(A_PL_VF_REV, 4, &val); + if (rc != 0) + errx(1, "%s is not a Terminator device.", s); + /* VF */ + g.vf = true; + whoami = A_PL_VF_WHOAMI; + } + chip_id = (val >> 4) & 0xf; + if (chip_id == 0) + chip_id = 4; + if (chip_id < 4 || chip_id > 7) + warnx("%s reports chip_id %d.", s, chip_id); + g.chip_id = chip_id; + + rc = read_reg(whoami, 4, &val); + if (rc != 0) + errx(rc, "failed to read whoami(0x%x): %d", whoami, rc); + g.pf = g.chip_id > 5 ? (val >> 9) & 7 : (val >> 8) & 7; + g.warn_on_ioctl_err = true; } int @@ -3665,7 +3701,7 @@ main(int argc, const char *argv[]) { int rc = -1; - progname = argv[0]; + g.progname = argv[0]; if (argc == 2) { if (!strcmp(argv[1], "-h") || !strcmp(argv[1], "--help")) { @@ -3679,7 +3715,7 @@ main(int argc, const char *argv[]) exit(EINVAL); } - parse_nexus_name(argv[1]); + open_nexus_device(argv[1]); /* progname and nexus */ argc -= 2; From nobody Wed Jul 17 14:21:54 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ6B5Ljvz5RPMM; Wed, 17 Jul 2024 14:21: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ6B2y4pz4tRL; Wed, 17 Jul 2024 14:21:54 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226114; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=yFklu6tLEujCmjIBhyRt+ccU4Dr0rOZ36os8ducPmG4=; b=i2jR252IWz5DiGWiYwT8CeedZzQPk85g4Bjh/8Nzoc5GGCKhXZMokuGQ92dzkK5MBbHni9 N8FAozq+/1PO7sSYudyuD3PAu6JLtH3swcpX2eTJ2u5BHPA6jVBO9gBVTDpHLFBeBOHcVY NIUL2BqX4+Sdx4suxM+GItag5cdjCw2ptCvyllXO3uk8I54lo5sDaxYLL/aYER24y6TvWR 06bQ4rSoX4NjVwiX/Zz9nhOLgFjqJuSp3W8RltKpn331/SUHWquqTcLpESpo9BLNzL66ZR Cl739TPyIoEOd7FJOgyioF2ncy4GSDbgEBM8BhI0LM9liwilAo6nssYydXCSEA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226114; a=rsa-sha256; cv=none; b=GUA2LN2Oebj/nmHCfAfImJtRpt10iYZjqevrdhPHYOIKO9Y0RMto+zO6FvrxwTy+9plJJJ vVrbclZJohV9aJV6EdTpEAlDt4TCxeWAPE31IGA8JawC96/lQ5UFdSWP34RZMpSVq/rFDn FT62pGwTDXd7uWzBkrYJMm/yFeQSzz8nW2VSKGYAffZ72fTK7KodoQ2tYHIv6iHwVtPjoS unAdv7s0z/wnYKUwGGZpyf602z6ZgMAiCGR4OglHSZOE2f1XnnbBB5XnqBFSP7XxdUFNP/ TDNxU1CA2++b5p1LVJC5VFbftfqWFA1c282XmGzJ0i5Sxxxd2y6o1A29nUpiqQ== 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=1721226114; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=yFklu6tLEujCmjIBhyRt+ccU4Dr0rOZ36os8ducPmG4=; b=GlAC2HqK1k/q62aQShUxVLBMJswQyaenwkPUJsMJ9LVe+WgzaLMV6KpdzdWwBOq0+4khsA moXi5yN6rMNipQ7snNZZTP2D+emTI/RgqbUp4sgAeklF3pjMamlfXTi1lGV3Vc8c+n11IP VctljaxmI69gR5l+gLLWqKqjK9MUzOKJ5YHqtWb2xYKHuXtv5oNKMM8llbUG2HlBVRzEwa sTXK/pisk/KG7nPFQHNdPPKQCaZQHxtnMGh++05icWyL5fjigIScA3eKSVZX7ijPlBBT2c nPOA5oMaLprYtXPyxLKF5rawMKRDDrEeOWsZGUwfWbQ322UJYyuVkknyLbATmw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ6B2V23z1MpQ; Wed, 17 Jul 2024 14:21:54 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HELsLV031228; Wed, 17 Jul 2024 14:21:54 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HELs56031225; Wed, 17 Jul 2024 14:21:54 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:21:54 GMT Message-Id: <202407171421.46HELs56031225@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 60bf442ee273 - stable/14 - cxgbe(4): Do not report link state change during interface detach. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 60bf442ee273e06b56b59698778d1569a3a55e30 Auto-Submitted: auto-generated The branch stable/14 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=60bf442ee273e06b56b59698778d1569a3a55e30 commit 60bf442ee273e06b56b59698778d1569a3a55e30 Author: Navdeep Parhar AuthorDate: 2024-07-03 19:01:33 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 06:40:13 +0000 cxgbe(4): Do not report link state change during interface detach. This fixes a panic when multiple VIs are configured on an interface and only the non-primary VI is up at the time of driver detach. The problem was that the driver would queue a link state change notification for an interface about to be freed. To reproduce the panic, add "hw.cxgbe.num_vis=2" to loader.conf and # kldload if_cxgbe # ifconfig vcc0 up # devctl detach t6nex0 trap 0x9, rip = 0xffffffff8107db70, rsp = 0xfffffe0055263d60, rbp = 0xfffffe0055263dd0 taskqueue_run_locked() at taskqueue_run_locked+0x2a0/frame 0xfffffe0055263dd0 taskqueue_run() at taskqueue_run+0x72/frame 0xfffffe0055263df0 taskqueue_swi_run() at taskqueue_swi_run+0x18/frame 0xfffffe0055263e10 intr_event_execute_handlers() at intr_event_execute_handlers+0x249/frame 0xfffffe0055263e50 ithread_execute_handlers() at ithread_execute_handlers+0x9e/frame 0xfffffe0055263e70 Reviewed by: jhb Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D45864 (cherry picked from commit dc20d49aa939caea365cbdf0341b00de69253be4) --- sys/dev/cxgbe/t4_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c index 2e885b9c3ffe..b60eda504b6b 100644 --- a/sys/dev/cxgbe/t4_main.c +++ b/sys/dev/cxgbe/t4_main.c @@ -12227,7 +12227,7 @@ t4_os_link_changed(struct port_info *pi) for_each_vi(pi, v, vi) { ifp = vi->ifp; - if (ifp == NULL) + if (ifp == NULL || IS_DETACHING(vi)) continue; if (lc->link_ok) { From nobody Wed Jul 17 14:24:31 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ9C4kvCz5RQ46; Wed, 17 Jul 2024 14:24: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ9C3tZNz40tt; Wed, 17 Jul 2024 14:24:31 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226271; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=JbvFFmehyFUCBsbRLarJ9RpANeeOId+X51KneEifa/k=; b=r3Eso8X8bQta6BjnodNZInLX3waxlfEhSjwMo90AmEM/m4ELRmZG7Aky66Bl0fQljVxlK/ 202rwIvs4P83SQXrRkZ/0l8C0HT209QIolgbvS55OfscVqxGcOSNTx5gkyZDGtizMgk/PQ dvPwyAHYDyt2nhUk2L1NCzVc5Rm44LpeGmB2XkxCRDyoK/AOhDlpK86CVBRlW08l7XeZis wDRFW2Zde8HR+lMvw8jWr6IGPTCxKCOxwAwTr7JZXOCvkovKeMYu9OArTXi9JCj+8nT3rx Mp+bJU0OOb1DhVsdejdZOw8GpTCnQ3hd/4np8flvOV6u/NxVU9Bm0xiVQ8PmMA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226271; a=rsa-sha256; cv=none; b=OEknwkWXoEEImDsWL4N0emOQoGmwGXftl/GaRaAWXMwytOryQd1req9CwX1AUaxxXuu1hL TbTAz++nmfcAnfNT/afUIISv6y1Qf4o+bBo5DOHQYnHTU8Jqs+p81k1ZZuIK65cTp/9L9y b/UI+PpxSJlJGTwOJIakLnyABhQXeDBqqNQfThI98kBgapxxUyaUcuxYUePH/P4LrX3u6b SFRHI62EiucArUzJehtKLP4NGwDabD2T725HKfBut23EVALzOnCgyJ++asfEAu79LQ3lS9 UOWHpTocmyhVNxTbbxAfIbmm4Wk/zGxMOAOzIpvwHSu6Ktj6894X4nsemcSNoA== 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=1721226271; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=JbvFFmehyFUCBsbRLarJ9RpANeeOId+X51KneEifa/k=; b=ya6XhYmYXuuFXUoRjb3bm2U7PL2RwZGhFqgkyDDs/PplCGbeD2Imff73PXW6TZvaPKyJSN KcofduwE+myIrMD3cpKGOcxh3thYSNhhkfXghpM0NEw+/BV+/chbkf7438TX330QIkFXgK 6xArQMhfzmzN8WMbbdiVEMw6tHPZ5g53LQcW6+5xPP8/U2pYq1aqmAKNsMSNOpbGnYji8A Vb6SN5L/tBDg040s3BNOyIqCQvnfSrd1H40zSriews8ZIfb+GEwlLEfF7JNOlkwFpHQlaU hUbF0SuJchi8fiTF8PsU5Vk46aeRWQ9sfE+SN4yEzR8CidE2rCAAUskYtp61Qw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ9C33bKz1MdK; Wed, 17 Jul 2024 14:24:31 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HEOVbO032797; Wed, 17 Jul 2024 14:24:31 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HEOVp2032794; Wed, 17 Jul 2024 14:24:31 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:24:31 GMT Message-Id: <202407171424.46HEOVp2032794@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 66527188a4ed - stable/13 - cxgbe(4): Remove tx_modq lookup table. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 66527188a4edbf56ab7afd12929c3844c8bcb843 Auto-Submitted: auto-generated The branch stable/13 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=66527188a4edbf56ab7afd12929c3844c8bcb843 commit 66527188a4edbf56ab7afd12929c3844c8bcb843 Author: Navdeep Parhar AuthorDate: 2024-03-29 05:49:32 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 07:12:42 +0000 cxgbe(4): Remove tx_modq lookup table. The driver always uses the same modulation queue as the channel and the table is unnecessary. Sponsored by: Chelsio Communications (cherry picked from commit f76effed14b25bfa0c47b10f6d8a076104c48d94) --- sys/dev/cxgbe/common/common.h | 4 +++- sys/dev/cxgbe/common/t4_hw.c | 5 ----- sys/dev/cxgbe/crypto/t6_kern_tls.c | 4 ++-- sys/dev/cxgbe/tom/t4_tom.c | 2 +- 4 files changed, 6 insertions(+), 9 deletions(-) diff --git a/sys/dev/cxgbe/common/common.h b/sys/dev/cxgbe/common/common.h index 0871ca8c40f1..634474470e17 100644 --- a/sys/dev/cxgbe/common/common.h +++ b/sys/dev/cxgbe/common/common.h @@ -252,7 +252,6 @@ struct tp_params { unsigned int tre; /* log2 of core clocks per TP tick */ unsigned int dack_re; /* DACK timer resolution */ unsigned int la_mask; /* what events are recorded by TP LA */ - unsigned short tx_modq[MAX_NCHAN]; /* channel to modulation queue map */ uint16_t filter_mode; uint16_t filter_mask; /* Used by TOE and hashfilters */ @@ -273,6 +272,9 @@ struct tp_params { int8_t frag_shift; }; +/* Use same modulation queue as the tx channel. */ +#define TX_MODQ(tx_chan) (tx_chan) + struct vpd_params { unsigned int cclk; u8 ec[EC_LEN + 1]; diff --git a/sys/dev/cxgbe/common/t4_hw.c b/sys/dev/cxgbe/common/t4_hw.c index c428fd2720cd..30dedd91262c 100644 --- a/sys/dev/cxgbe/common/t4_hw.c +++ b/sys/dev/cxgbe/common/t4_hw.c @@ -9800,7 +9800,6 @@ read_filter_mode_and_ingress_config(struct adapter *adap) */ int t4_init_tp_params(struct adapter *adap) { - int chan; u32 tx_len, rx_len, r, v; struct tp_params *tpp = &adap->params.tp; @@ -9808,10 +9807,6 @@ int t4_init_tp_params(struct adapter *adap) tpp->tre = G_TIMERRESOLUTION(v); tpp->dack_re = G_DELAYEDACKRESOLUTION(v); - /* MODQ_REQ_MAP defaults to setting queues 0-3 to chan 0-3 */ - for (chan = 0; chan < MAX_NCHAN; chan++) - tpp->tx_modq[chan] = chan; - read_filter_mode_and_ingress_config(adap); if (chip_id(adap) > CHELSIO_T5) { diff --git a/sys/dev/cxgbe/crypto/t6_kern_tls.c b/sys/dev/cxgbe/crypto/t6_kern_tls.c index a717b1212532..a1548cc9b81f 100644 --- a/sys/dev/cxgbe/crypto/t6_kern_tls.c +++ b/sys/dev/cxgbe/crypto/t6_kern_tls.c @@ -165,7 +165,7 @@ mk_ktls_act_open_req(struct adapter *sc, struct vi_info *vi, struct inpcb *inp, options |= F_NON_OFFLOAD; cpl->opt0 = htobe64(options); - options = V_TX_QUEUE(sc->params.tp.tx_modq[vi->pi->tx_chan]); + options = V_TX_QUEUE(TX_MODQ(vi->pi->tx_chan)); if (tp->t_flags & TF_REQ_TSTMP) options |= F_TSTAMPS_EN; cpl->opt2 = htobe32(options); @@ -200,7 +200,7 @@ mk_ktls_act_open_req6(struct adapter *sc, struct vi_info *vi, options |= F_NON_OFFLOAD; cpl->opt0 = htobe64(options); - options = V_TX_QUEUE(sc->params.tp.tx_modq[vi->pi->tx_chan]); + options = V_TX_QUEUE(TX_MODQ(vi->pi->tx_chan)); if (tp->t_flags & TF_REQ_TSTMP) options |= F_TSTAMPS_EN; cpl->opt2 = htobe32(options); diff --git a/sys/dev/cxgbe/tom/t4_tom.c b/sys/dev/cxgbe/tom/t4_tom.c index 22c34c4d217c..1600325ca42f 100644 --- a/sys/dev/cxgbe/tom/t4_tom.c +++ b/sys/dev/cxgbe/tom/t4_tom.c @@ -1053,7 +1053,7 @@ calc_options2(struct vi_info *vi, struct conn_params *cp) /* XXX: F_RX_CHANNEL for multiple rx c-chan support goes here. */ - opt2 |= V_TX_QUEUE(sc->params.tp.tx_modq[pi->tx_chan]); + opt2 |= V_TX_QUEUE(TX_MODQ(pi->tx_chan)); opt2 |= V_PACE(0); opt2 |= F_RSS_QUEUE_VALID; opt2 |= V_RSS_QUEUE(sc->sge.ofld_rxq[cp->rxq_idx].iq.abs_id); From nobody Wed Jul 17 14:24:32 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ9D5hRcz5RPr4; Wed, 17 Jul 2024 14:24: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ9D4J83z40cD; Wed, 17 Jul 2024 14:24:32 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226272; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=/KqqZkVZHPWW1h+DGVPi337UmAEgWOfJIu+c1G26PBw=; b=QiQyLTjALhLdazpOUrrdJpMhwSFT7ylzWiggsCCQ07rH8MYbeIV1GVkEEyeE6i6j2zfVJo Yiq8nE3Sp4I1pQqOBQ1CNx9BKBsbMORcWFu+GPLtHlqk65Lvz6d963hDSNeGRBCROlO+qf UF2P9Fi9QK9yPzcPc3/bbjH3orMbfWGRibkAN6wu47ShpiiIWuFU3h1hxik0NVT/RvSpQC M1Q+ZIndlrUGS+zyk7WYa5/kqnWVbSd8l2eXkYr+sHUr+iW8PGTH+hRpF9ZIrxK6T8D5J9 dlMIxYVMc/kkA7SAqnSwgIOPWdB8/rmxY62Cakf8Z7JywEptR6Tok260wbtWaw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226272; a=rsa-sha256; cv=none; b=XylpbRuFBqlahFIlFx6Hjn46kWU+fcvB3b9eIMkeEzmWYnDwHZuWKNXpgueDQuc5oFrS+A C7nVAbI+TAdhAinUoWyGCf5ZkXiltl/WnpCYj4H78vmPC+/d54C/qsUjyIymMpMIzuyFOV Ssg88JBgiiFcWxG4ssfJ53A9nyDchQKb31k6sjbLDhorQ2zVD+VIy0iJF627Fjj80urE/m Sag2Ren+vup5hsAg2V1DjbPwWcr7Z39WDVEXXXbADUT4+fLAWbsmyG2WHoOXi+IK2IX3v4 oWy5dgbs2vZjuOuoiMz3KmkTkDFB3Z02XNC9GvmqeMRBsn4J+MtUkCbPHzRZeQ== 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=1721226272; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=/KqqZkVZHPWW1h+DGVPi337UmAEgWOfJIu+c1G26PBw=; b=ZudZeSR9bqKGyHfTOUvkPFs+9A2t9pHMerzuHUb/Tt4xedlBSphuXVe7L76sf8P2CRnofH mvKLBn0fFfHLw4QXXSHzErj+XBbo8fUxFu2eiIOqI28+jZvMU5+tRGmtjohXqtxiYN5O0d xRO9qTEvEulUg8cRurw7crxRPKwvZXag00QRbgmRp1H2uPOLNSM4HYHLd+ZkFEH0NlDkAF /qtov70g3Ze5Qx36EbueAeH+tW7014Wjh8PMNzbYcnKjdV8/IITvKfLUmA7E50kfpoX2y4 JjmUx8+9/t/mdO4dSh9+KLZJA9Cv1F0HwTfC/SXvLIbAZ8ZcdOiQTIIK2GUvsQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ9D3wRBz1MXM; Wed, 17 Jul 2024 14:24:32 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HEOW4r032851; Wed, 17 Jul 2024 14:24:32 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HEOWSc032848; Wed, 17 Jul 2024 14:24:32 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:24:32 GMT Message-Id: <202407171424.46HEOWSc032848@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 803c082fd263 - stable/13 - cxgbe(4): Add a helper function to locate MPS/MAC registers. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 803c082fd2638432468ba8036bf9def0cdea17c2 Auto-Submitted: auto-generated The branch stable/13 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=803c082fd2638432468ba8036bf9def0cdea17c2 commit 803c082fd2638432468ba8036bf9def0cdea17c2 Author: Navdeep Parhar AuthorDate: 2024-04-25 05:24:49 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 07:12:58 +0000 cxgbe(4): Add a helper function to locate MPS/MAC registers. These register blocks are at different locations in different chips. Sponsored by: Chelsio Communications (cherry picked from commit b59c5d97edf17525405d95b1f5746c4a79a9c7c4) --- sys/dev/cxgbe/common/common.h | 1 + sys/dev/cxgbe/common/t4_hw.c | 37 +++++++++++++++++-------------------- sys/dev/cxgbe/t4_main.c | 14 +++++--------- 3 files changed, 23 insertions(+), 29 deletions(-) diff --git a/sys/dev/cxgbe/common/common.h b/sys/dev/cxgbe/common/common.h index 634474470e17..3d546c2f976f 100644 --- a/sys/dev/cxgbe/common/common.h +++ b/sys/dev/cxgbe/common/common.h @@ -722,6 +722,7 @@ int t4_set_vf_mac(struct adapter *adapter, unsigned int pf, unsigned int vf, unsigned int t4_get_regs_len(struct adapter *adapter); void t4_get_regs(struct adapter *adap, u8 *buf, size_t buf_size); +u32 t4_port_reg(struct adapter *adap, u8 port, u32 reg); const char *t4_get_port_type_description(enum fw_port_type port_type); void t4_get_port_stats(struct adapter *adap, int idx, struct port_stats *p); void t4_get_port_stats_offset(struct adapter *adap, int idx, diff --git a/sys/dev/cxgbe/common/t4_hw.c b/sys/dev/cxgbe/common/t4_hw.c index 30dedd91262c..cf4f5a65c3e5 100644 --- a/sys/dev/cxgbe/common/t4_hw.c +++ b/sys/dev/cxgbe/common/t4_hw.c @@ -243,18 +243,21 @@ struct port_tx_state { uint64_t tx_frames; }; +u32 +t4_port_reg(struct adapter *adap, u8 port, u32 reg) +{ + if (chip_id(adap) > CHELSIO_T4) + return T5_PORT_REG(port, reg); + return PORT_REG(port, reg); +} + static void read_tx_state_one(struct adapter *sc, int i, struct port_tx_state *tx_state) { uint32_t rx_pause_reg, tx_frames_reg; - if (is_t4(sc)) { - tx_frames_reg = PORT_REG(i, A_MPS_PORT_STAT_TX_PORT_FRAMES_L); - rx_pause_reg = PORT_REG(i, A_MPS_PORT_STAT_RX_PORT_PAUSE_L); - } else { - tx_frames_reg = T5_PORT_REG(i, A_MPS_PORT_STAT_TX_PORT_FRAMES_L); - rx_pause_reg = T5_PORT_REG(i, A_MPS_PORT_STAT_RX_PORT_PAUSE_L); - } + rx_pause_reg = t4_port_reg(sc, i, A_MPS_PORT_STAT_RX_PORT_PAUSE_L); + tx_frames_reg = t4_port_reg(sc, i, A_MPS_PORT_STAT_TX_PORT_FRAMES_L); tx_state->rx_pause = t4_read_reg64(sc, rx_pause_reg); tx_state->tx_frames = t4_read_reg64(sc, tx_frames_reg); @@ -281,10 +284,7 @@ check_tx_state(struct adapter *sc, struct port_tx_state *tx_state) tx_frames = tx_state[i].tx_frames; read_tx_state_one(sc, i, &tx_state[i]); /* update */ - if (is_t4(sc)) - port_ctl_reg = PORT_REG(i, A_MPS_PORT_CTL); - else - port_ctl_reg = T5_PORT_REG(i, A_MPS_PORT_CTL); + port_ctl_reg = t4_port_reg(sc, i, A_MPS_PORT_CTL); if (t4_read_reg(sc, port_ctl_reg) & F_PORTTXEN && rx_pause != tx_state[i].rx_pause && tx_frames == tx_state[i].tx_frames) { @@ -6952,8 +6952,7 @@ void t4_get_port_stats(struct adapter *adap, int idx, struct port_stats *p) #define GET_STAT(name) \ t4_read_reg64(adap, \ - (is_t4(adap) ? PORT_REG(pi->tx_chan, A_MPS_PORT_STAT_##name##_L) : \ - T5_PORT_REG(pi->tx_chan, A_MPS_PORT_STAT_##name##_L))) + t4_port_reg(adap, pi->tx_chan, A_MPS_PORT_STAT_##name##_L)); #define GET_STAT_COM(name) t4_read_reg64(adap, A_MPS_STAT_##name##_L) p->tx_pause = GET_STAT(TX_PORT_PAUSE); @@ -7054,9 +7053,7 @@ void t4_get_lb_stats(struct adapter *adap, int idx, struct lb_port_stats *p) #define GET_STAT(name) \ t4_read_reg64(adap, \ - (is_t4(adap) ? \ - PORT_REG(idx, A_MPS_PORT_STAT_LB_PORT_##name##_L) : \ - T5_PORT_REG(idx, A_MPS_PORT_STAT_LB_PORT_##name##_L))) + t4_port_reg(adap, idx, A_MPS_PORT_STAT_LB_PORT_##name##_L)) #define GET_STAT_COM(name) t4_read_reg64(adap, A_MPS_STAT_##name##_L) p->octets = GET_STAT(BYTES); @@ -9436,16 +9433,16 @@ int t4_shutdown_adapter(struct adapter *adapter) t4_write_reg(adapter, A_DBG_GPIO_EN, 0xffff0000); for_each_port(adapter, port) { u32 a_port_cfg = is_t4(adapter) ? - PORT_REG(port, A_XGMAC_PORT_CFG) : - T5_PORT_REG(port, A_MAC_PORT_CFG); + t4_port_reg(adapter, port, A_XGMAC_PORT_CFG) : + t4_port_reg(adapter, port, A_MAC_PORT_CFG); t4_write_reg(adapter, a_port_cfg, t4_read_reg(adapter, a_port_cfg) & ~V_SIGNAL_DET(1)); if (!bt) { u32 hss_cfg0 = is_t4(adapter) ? - PORT_REG(port, A_XGMAC_PORT_HSS_CFG0) : - T5_PORT_REG(port, A_MAC_PORT_HSS_CFG0); + t4_port_reg(adapter, port, A_XGMAC_PORT_HSS_CFG0) : + t4_port_reg(adapter, port, A_MAC_PORT_HSS_CFG0); t4_set_reg_field(adapter, hss_cfg0, F_HSSPDWNPLLB | F_HSSPDWNPLLA | F_HSSPLLBYPB | F_HSSPLLBYPA, F_HSSPDWNPLLB | F_HSSPDWNPLLA | F_HSSPLLBYPB | diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c index a47b4609e8f1..9a637767c9a6 100644 --- a/sys/dev/cxgbe/t4_main.c +++ b/sys/dev/cxgbe/t4_main.c @@ -1414,13 +1414,10 @@ t4_attach(device_t dev) * depends on the link settings which will be known when the * link comes up. */ - if (is_t6(sc)) { + if (is_t6(sc)) pi->fcs_reg = -1; - } else if (is_t4(sc)) { - pi->fcs_reg = PORT_REG(pi->tx_chan, - A_MPS_PORT_STAT_RX_PORT_CRC_ERROR_L); - } else { - pi->fcs_reg = T5_PORT_REG(pi->tx_chan, + else { + pi->fcs_reg = t4_port_reg(sc, pi->tx_chan, A_MPS_PORT_STAT_RX_PORT_CRC_ERROR_L); } pi->fcs_base = 0; @@ -8110,9 +8107,8 @@ cxgbe_sysctls(struct port_info *pi) #define T4_REGSTAT(name, stat, desc) \ SYSCTL_ADD_OID(ctx, children, OID_AUTO, #name, \ - CTLTYPE_U64 | CTLFLAG_RD | CTLFLAG_MPSAFE, sc, \ - (is_t4(sc) ? PORT_REG(pi->tx_chan, A_MPS_PORT_STAT_##stat##_L) : \ - T5_PORT_REG(pi->tx_chan, A_MPS_PORT_STAT_##stat##_L)), \ + CTLTYPE_U64 | CTLFLAG_RD | CTLFLAG_MPSAFE, sc, \ + t4_port_reg(sc, pi->tx_chan, A_MPS_PORT_STAT_##stat##_L), \ sysctl_handle_t4_reg64, "QU", desc) /* We get these from port_stats and they may be stale by up to 1s */ From nobody Wed Jul 17 14:24:33 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ9G0psJz5RPr7; Wed, 17 Jul 2024 14:24: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ9F5Mtwz40lf; Wed, 17 Jul 2024 14:24:33 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226273; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=sOjo/cbUnFo548wXensA+goDSXeumfaUnLs/vC1ca5g=; b=MNKzTFJSFVUxQ+S27w59EzFKpSsssPW/sMaTMynHvZHsAEhFyy+zop5PF+9R9bW0NzB50C uF9IdNdczU7ffKxqWq9nVE3TjasyeVDYnlLCc0QxRvHvE8Ov8HWJGO9T1ic02BAjIKyzMo NQXq9SS8HX+zKjAOPr05GIX+NWIDLFNgr5Nmphj4MKHNZxBiHA0Lc30KiHxG9m78+Zty5p yvpO+hOSqHw30gpqvJQbXKJcbSgvuSH/sHstZdtSYZ7mKvAQWYiel8RS5gCrzOFqLna35r NSgSUNXXW02qYaQ8LE2e9kzSIAO0rd0Il4kzf1y8Bem5bQSMqVuVCNvPYqA7wA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226273; a=rsa-sha256; cv=none; b=XlVQIXnJmT6LUSvEdhXC9VfPKNalB0xw4fWWEvYR79sIIRMlXbz70jwc3B9FYlhrgqyFxi dbfLiCrRvjxK7D6jPt1fY81hHDWXSjS5gQzpyxqRn1wmvb5RSfZjC/mzLkM+dwMfBS5mjv t3synF5eFPiExAovQXzYe1f8056aoWc1Y4NY1y1rWuzket4vr+JYWGlB3EWYTsb99RvPIy TR7zfD7HFnBZNtX9Lo6nO4ZWBNPJnklq0OO6hTxwHabEYdPDsaWP+k1cIrHrJHuE8O5cN4 ic7SR1kTX1CwhZ7ljpFhNiwvRaaplLpM9QVs6KofsnKRPHQ3NpRwzuqudoxFiA== 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=1721226273; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=sOjo/cbUnFo548wXensA+goDSXeumfaUnLs/vC1ca5g=; b=wE2bToiWjQ53/vHfkpGJiT+2OMI/5Ue8lncFmfR64Esp5wqfUen0mN4lAmbR0Tv5095XDR IydZA+LxEfSFA8G8U118WFAZhP8jYO702uRhRqh0QGdcJQxCtSnHGbr8EMM3WDFaffg6t9 UBElmuyb7/fp+TvyapGc7cjPc68HAE0hOyG0ym5gwsoxolPkGmwVlysAeJ73WuqWk/+M+8 MXIfV6KfZhqOZK9jXenthsIko662MgX9p0NSRDSaAq4aUppHd6RGgS65o5a3vBdeDVxvfm x5VR5Zricfh8Azs1wEAis6/bJQbjowI3SrUlAyehl3//q5DrOLrNzUNSyq3hgA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ9F50FCz1MnH; Wed, 17 Jul 2024 14:24:33 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HEOXnE032894; Wed, 17 Jul 2024 14:24:33 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HEOXvf032891; Wed, 17 Jul 2024 14:24:33 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:24:33 GMT Message-Id: <202407171424.46HEOXvf032891@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: fd90e164109f - stable/13 - cxgbe(4): Retire t4_intr_clear. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: fd90e164109f9ccd7e0d94e38226403880526034 Auto-Submitted: auto-generated The branch stable/13 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=fd90e164109f9ccd7e0d94e38226403880526034 commit fd90e164109f9ccd7e0d94e38226403880526034 Author: Navdeep Parhar AuthorDate: 2024-04-26 00:39:55 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 07:13:19 +0000 cxgbe(4): Retire t4_intr_clear. The firmware clears the interrupts already and it has a better idea of exactly what to clear for which generation of the ASIC. There is no need for the driver to get involved. Sponsored by: Chelsio Communications (cherry picked from commit 1c7f9c8b4673abf3723be09afed4443261e0d186) --- sys/dev/cxgbe/common/common.h | 1 - sys/dev/cxgbe/common/t4_hw.c | 93 ------------------------------------------- sys/dev/cxgbe/t4_main.c | 2 - 3 files changed, 96 deletions(-) diff --git a/sys/dev/cxgbe/common/common.h b/sys/dev/cxgbe/common/common.h index 3d546c2f976f..f43ffc83dff1 100644 --- a/sys/dev/cxgbe/common/common.h +++ b/sys/dev/cxgbe/common/common.h @@ -618,7 +618,6 @@ struct fw_filter_wr; void t4_intr_enable(struct adapter *adapter); void t4_intr_disable(struct adapter *adapter); -void t4_intr_clear(struct adapter *adapter); bool t4_slow_intr_handler(struct adapter *adapter, bool verbose); int t4_hash_mac_addr(const u8 *addr); diff --git a/sys/dev/cxgbe/common/t4_hw.c b/sys/dev/cxgbe/common/t4_hw.c index cf4f5a65c3e5..b58d9f5df0d9 100644 --- a/sys/dev/cxgbe/common/t4_hw.c +++ b/sys/dev/cxgbe/common/t4_hw.c @@ -5454,99 +5454,6 @@ void t4_intr_disable(struct adapter *adap) t4_set_reg_field(adap, A_PL_INT_MAP0, 1 << adap->pf, 0); } -/** - * t4_intr_clear - clear all interrupts - * @adap: the adapter whose interrupts should be cleared - * - * Clears all interrupts. The caller must be a PCI function managing - * global interrupts. - */ -void t4_intr_clear(struct adapter *adap) -{ - static const u32 cause_reg[] = { - A_CIM_HOST_INT_CAUSE, - A_CIM_HOST_UPACC_INT_CAUSE, - MYPF_REG(A_CIM_PF_HOST_INT_CAUSE), - A_CPL_INTR_CAUSE, - EDC_REG(A_EDC_INT_CAUSE, 0), EDC_REG(A_EDC_INT_CAUSE, 1), - A_LE_DB_INT_CAUSE, - A_MA_INT_WRAP_STATUS, - A_MA_PARITY_ERROR_STATUS1, - A_MA_INT_CAUSE, - A_MPS_CLS_INT_CAUSE, - A_MPS_RX_PERR_INT_CAUSE, - A_MPS_STAT_PERR_INT_CAUSE_RX_FIFO, - A_MPS_STAT_PERR_INT_CAUSE_SRAM, - A_MPS_TRC_INT_CAUSE, - A_MPS_TX_INT_CAUSE, - A_MPS_STAT_PERR_INT_CAUSE_TX_FIFO, - A_NCSI_INT_CAUSE, - A_PCIE_INT_CAUSE, - A_PCIE_NONFAT_ERR, - A_PL_PL_INT_CAUSE, - A_PM_RX_INT_CAUSE, - A_PM_TX_INT_CAUSE, - A_SGE_INT_CAUSE1, - A_SGE_INT_CAUSE2, - A_SGE_INT_CAUSE3, - A_SGE_INT_CAUSE4, - A_SMB_INT_CAUSE, - A_TP_INT_CAUSE, - A_ULP_RX_INT_CAUSE, - A_ULP_RX_INT_CAUSE_2, - A_ULP_TX_INT_CAUSE, - A_ULP_TX_INT_CAUSE_2, - - MYPF_REG(A_PL_PF_INT_CAUSE), - }; - int i; - const int nchan = adap->chip_params->nchan; - - for (i = 0; i < ARRAY_SIZE(cause_reg); i++) - t4_write_reg(adap, cause_reg[i], 0xffffffff); - - if (is_t4(adap)) { - t4_write_reg(adap, A_PCIE_CORE_UTL_SYSTEM_BUS_AGENT_STATUS, - 0xffffffff); - t4_write_reg(adap, A_PCIE_CORE_UTL_PCI_EXPRESS_PORT_STATUS, - 0xffffffff); - t4_write_reg(adap, A_MC_INT_CAUSE, 0xffffffff); - for (i = 0; i < nchan; i++) { - t4_write_reg(adap, PORT_REG(i, A_XGMAC_PORT_INT_CAUSE), - 0xffffffff); - } - } - if (chip_id(adap) >= CHELSIO_T5) { - t4_write_reg(adap, A_MA_PARITY_ERROR_STATUS2, 0xffffffff); - t4_write_reg(adap, A_MPS_STAT_PERR_INT_CAUSE_SRAM1, 0xffffffff); - t4_write_reg(adap, A_SGE_INT_CAUSE5, 0xffffffff); - t4_write_reg(adap, A_MC_P_INT_CAUSE, 0xffffffff); - if (is_t5(adap)) { - t4_write_reg(adap, MC_REG(A_MC_P_INT_CAUSE, 1), - 0xffffffff); - } - for (i = 0; i < nchan; i++) { - t4_write_reg(adap, T5_PORT_REG(i, - A_MAC_PORT_PERR_INT_CAUSE), 0xffffffff); - if (chip_id(adap) > CHELSIO_T5) { - t4_write_reg(adap, T5_PORT_REG(i, - A_MAC_PORT_PERR_INT_CAUSE_100G), - 0xffffffff); - } - t4_write_reg(adap, T5_PORT_REG(i, A_MAC_PORT_INT_CAUSE), - 0xffffffff); - } - } - if (chip_id(adap) >= CHELSIO_T6) { - t4_write_reg(adap, A_SGE_INT_CAUSE6, 0xffffffff); - } - - t4_write_reg(adap, A_MPS_INT_CAUSE, is_t4(adap) ? 0 : 0xffffffff); - t4_write_reg(adap, A_PL_PERR_CAUSE, 0xffffffff); - t4_write_reg(adap, A_PL_INT_CAUSE, 0xffffffff); - (void) t4_read_reg(adap, A_PL_INT_CAUSE); /* flush */ -} - /** * hash_mac_addr - return the hash value of a MAC address * @addr: the 48-bit Ethernet MAC address diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c index 9a637767c9a6..b9b9b3150caf 100644 --- a/sys/dev/cxgbe/t4_main.c +++ b/sys/dev/cxgbe/t4_main.c @@ -1341,7 +1341,6 @@ t4_attach(device_t dev) rc = partition_resources(sc); if (rc != 0) goto done; /* error message displayed already */ - t4_intr_clear(sc); } rc = get_params__post_init(sc); @@ -2303,7 +2302,6 @@ t4_resume(device_t dev) rc = partition_resources(sc); if (rc != 0) goto done; /* error message displayed already */ - t4_intr_clear(sc); } rc = get_params__post_init(sc); From nobody Wed Jul 17 14:24:34 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ9H0PChz5RPr8; Wed, 17 Jul 2024 14:24: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ9G6PNSz40xq; Wed, 17 Jul 2024 14:24:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226274; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Tr03MbJO57eS3P6z/AOtYQcaqFjk7vJgmOcOONPd1F8=; b=gwG1CPj8WRgq0mQ4rIl9Jm34rzKjfu20ZREKG+JCIZXqBI9KS6dZ3sYAr0QlQTkKYBGO5E vm/YN3H4mf7nB88D5eotDH32E7kfzqEDIX4S2n9aSsDl6tv3wPIXavK4XKNhCeH4DB3+Ej QEsV2wW4/pc6VsdLWNeLwrHB1lFPBsdmmoMbFvCUzn3QvB/yG0DN3L0LDcjKCZDu00/3QD vJ2O8QYZe6egutz3XcepvrwRK0PJzM6j8aO7IYobUILpHoOIdhZ2rI77atkfhq4kPCs0YV TuvqeKsVFOczZeALabcDuKLRwGak8MCctpJckvoHvIp645pJD/K9tCSTMHjAhA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226274; a=rsa-sha256; cv=none; b=QXZw895iHOh2B+lmYVmXT8sH2N6pJewRB/5TwyCOg2kcycPQEPwNdRWxEJoDwQ9Rw1pY8b AfBMolvjcI8Q3mnmyxjESIu3ea2CuoEu8QzFqU/ml4W/agVbyZo+/MBq0M8I/mpam4Lg0d 7IZl6mZUg4VB0KEFf4yWuB4wbf4gewwCYpxWG39HEYErSnzpwALMwuFbJDdxEdpOVDgO3y K07j2wsR8n4gBGZopkLR+L0pQzlc2MB8jK3c0xYW/4IXNyW5HUBvYxYhA9jaN7qAz87j5l BDl9zwpDiwD5h4t6BogKJRDdCKVhthFZkUR+t04A1LL5Zut/2w83qK8njPz0Rg== 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=1721226274; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Tr03MbJO57eS3P6z/AOtYQcaqFjk7vJgmOcOONPd1F8=; b=asQZy8ScFpHftNlvfNfBWaBqv8YfDTPCe6RM7DzBOQMKPeSK9nB/jSZY32YmeMf2rqYe7G 4WatosIFY+PJadQ00nswk+rDAIFnT6CLlhza98DB+KzL22Fv5cU0KA93eBcdyZ7W+VNXwp 3riD6ChixwJV8+BSFZpMDva0PWt+G3ETvZuOEcV1v7fPkH5B6BnJZgg8YOgRYVOPFfd4EM cPesQv3Ovv5uegLb38DRH8Ch8S+13jgYJys1px6y+S45TQ/7NQdC4yoo9eNzphlMVyqdL+ vpsdBmjsNlxq43YClEEnElAJ63uWMM04vJsnVbucAZ9QTbWfddDOJJKx3tV7nQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ9G5zMPz1Mb1; Wed, 17 Jul 2024 14:24:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HEOYf3032947; Wed, 17 Jul 2024 14:24:34 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HEOYNq032944; Wed, 17 Jul 2024 14:24:34 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:24:34 GMT Message-Id: <202407171424.46HEOYNq032944@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 3cd0460e7bf7 - stable/13 - cxgbe(4): Add missing description for a port type. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 3cd0460e7bf749882401a6bf5714d4e26d4a4d67 Auto-Submitted: auto-generated The branch stable/13 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=3cd0460e7bf749882401a6bf5714d4e26d4a4d67 commit 3cd0460e7bf749882401a6bf5714d4e26d4a4d67 Author: Navdeep Parhar AuthorDate: 2024-04-29 20:27:48 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 07:13:42 +0000 cxgbe(4): Add missing description for a port type. Sponsored by: Chelsio Communications (cherry picked from commit f0ee6112eb61a5130acedd20d9827627c0975fba) --- sys/dev/cxgbe/common/t4_hw.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sys/dev/cxgbe/common/t4_hw.c b/sys/dev/cxgbe/common/t4_hw.c index b58d9f5df0d9..9048884eeb7e 100644 --- a/sys/dev/cxgbe/common/t4_hw.c +++ b/sys/dev/cxgbe/common/t4_hw.c @@ -6814,6 +6814,7 @@ const char *t4_get_port_type_description(enum fw_port_type port_type) "CR2_QSFP", "SFP28", "KR_SFP28", + "KR_XLAUI", }; if (port_type < ARRAY_SIZE(port_type_description)) From nobody Wed Jul 17 14:24:35 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ9J2Qncz5RQ1d; Wed, 17 Jul 2024 14:24: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ9J0f0yz40ct; Wed, 17 Jul 2024 14:24:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226276; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=nJ1kazdEVXNf2XMqe5F7w9jGeBBJJmN+lnHnALgTigs=; b=fEhEGtIAJd8OP8K2bc4835JB0VQ8Q1jlLk3YOaQn4gIJ96UWosOiBW25pO7hSpveMIocKH GeiFddzXfbdQw3qC556b7robQoqwZkxqh1EHUq3kvwaKv3/zdNCzhsa1vFOWHhrJ9SUiQT DAfimNdh15sy4Ob4Vjc1uco5yxvMFrWQyUkXwXKZ/3v63R5BfyMmwVwVvF8fh1TLfouNAZ KRXT2C/oIUtEfNlDCQqgFfEDwcdS0v3oeLoKcDWEP9sn20nEJJsDGtf9UkzMl6Fxtv3juD rWgAHKpuLmfUpXgG1lwXw1TPsqD9YMs6TX8hYtewMsVXN08e8HIA2gJHoda1Cg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226276; a=rsa-sha256; cv=none; b=L/eZ164F8dcHFJwQ3F4LBxK9ITKWbAawFGxNB0Okakr/my1HI7i5rvZcd33wqhzpthFFSV Vlcl+CSC2FApxZE50Gu3b/WVaKAQ3pNCShJgG+uDvlJOylQqxTe9GhvDdk8PtNqKrHWSuv STew8wMkD4xSuGUKlgGe4UpziK0wm54bm/t/iz6IZDn6GkVPuUzO7Nien8AQjzzchD6eam eW7srDpx6TRDhmCfwWSTrKeTB7Z490Gov46CGL7NFDl6yy2DpmyunbTu9zP8+qjgcILSOV TDXTo3uKWHtBJQ6aBNLFdHG561cjX+slPBTjpsu/du996bELpv4r8RFLL9HfWw== 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=1721226276; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=nJ1kazdEVXNf2XMqe5F7w9jGeBBJJmN+lnHnALgTigs=; b=Vbi0Vo4BsOiy041LSQl5j1xXC6ckw/519kMUC6GF9g9robL2URsUoikTtbol36ZVI/FfLK 4dghvDHoYp1Bm/ri2EckMTnjdmE+ZUeCQLnRTp2yWN/YSUIwMPEuyQWEMlRkgNilLVYsD1 k+Yu7uvtxb43cgM2Jlb3dLkmY7Dj/Xtd5ePC8Oy7kJdfV9RvWh9fviOzUjJ3beTj9vCZA0 tce+Y7zlbvn+kXnU9ZP/qf6ESHSYz1q85V3wYmVpIfgDiVqDwlQA3FNVkOhSncWRP4iwfc oDSgHouoPlIdwGC1GIifSW26quG6eGQ1UbJTRbiJE1nktNCzE8u3I3aGogZbMQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ9H75m4z1MnJ; Wed, 17 Jul 2024 14:24:35 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HEOZw8033001; Wed, 17 Jul 2024 14:24:35 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HEOZ3I032998; Wed, 17 Jul 2024 14:24:35 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:24:35 GMT Message-Id: <202407171424.46HEOZ3I032998@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 4c07c994d4ef - stable/13 - cxgbe(4): Reword the comment explaining the atid/cookie split. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 4c07c994d4ef65c83ccf257207873a3925a8c089 Auto-Submitted: auto-generated The branch stable/13 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=4c07c994d4ef65c83ccf257207873a3925a8c089 commit 4c07c994d4ef65c83ccf257207873a3925a8c089 Author: Navdeep Parhar AuthorDate: 2023-04-01 23:07:36 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 07:14:00 +0000 cxgbe(4): Reword the comment explaining the atid/cookie split. Avoid a magic constant while here. No functional change intended. Sponsored by: Chelsio Communications (cherry picked from commit 43f6f08488046788b0ad66e9a5119f36e5de71ab) --- sys/dev/cxgbe/offload.h | 6 +++--- sys/dev/cxgbe/t4_main.c | 3 +++ 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/sys/dev/cxgbe/offload.h b/sys/dev/cxgbe/offload.h index 04bf3995a7b8..e600314ea503 100644 --- a/sys/dev/cxgbe/offload.h +++ b/sys/dev/cxgbe/offload.h @@ -67,10 +67,10 @@ struct stid_region { }; /* - * Max # of ATIDs. The absolute HW max is 14b (enough for 16K) but we reserve - * the upper 3b for use as a cookie to demux the reply. + * Max # of ATIDs. The absolute HW max is larger than this but we reserve a few + * of the upper bits for use as a cookie to demux the reply. */ -#define MAX_ATIDS 2048U +#define MAX_ATIDS (M_TID_TID + 1) union aopen_entry { void *data; diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c index b9b9b3150caf..dd7552a50e4f 100644 --- a/sys/dev/cxgbe/t4_main.c +++ b/sys/dev/cxgbe/t4_main.c @@ -3984,6 +3984,9 @@ rw_via_memwin(struct adapter *sc, int idx, uint32_t addr, uint32_t *val, return (0); } +CTASSERT(M_TID_COOKIE == M_COOKIE); +CTASSERT(MAX_ATIDS <= (M_TID_TID + 1)); + static void t4_init_atid_table(struct adapter *sc) { From nobody Wed Jul 17 14:24:37 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ9K4G1Sz5RQ1j; Wed, 17 Jul 2024 14:24: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ9K1TXdz40yP; Wed, 17 Jul 2024 14:24:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226277; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=kWfMHeqbm9Ois5RqxlPJfdpM29zTiPLROKuBq9RBCFE=; b=gkx1S7OCAwqHL7doHxHFE0EAiO5k+O8eJdtahx8OHIP7YDOTH+m82dxWaPKA4H0BnS4U9Q 5PeYCKklrJF5IiVgla3fn7o3x9nYwOs67UftxS0Uf7N0PJThxgy0z6oPitxEq3rUvzq36L dnqEtMKWyNJP/JVQuFBAxezDdSNJRBzqwSiweIpE9jThs+wXhnyg21TeKVz35fVF/tHZxl hjPhvtPHaJbV+svM39TEF7lFbG7yYnNNUsjQ4XpVsDXkrYGER+vKkEHKL4Ygu4/avuI3LZ fMmXOWVyfn8vraIYnLUzqfBqseBJjUdsTBA9sww68E1ev6XRrmvBGVDhW5Z8vA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226277; a=rsa-sha256; cv=none; b=vKDo5zSNoimeUdYlPirhkzs/d2BDN9nlvlUG/ta9/T1VZS56R31Q4OJJRgQ8YiXNFgcYoB vafGEIHoiEZlCQFGW4vl9Nso4RKbZihhUaOzBPKMA1+J/w50/gpNU6Ks2MDKdqo6IUu6r0 7eScfSTL9z+YHiCQIyg45ScbjUwTn9gYyDu03xcYSUx5afnyjXyPQqyOCl9nX80uuwtNiS hVN5Ly5xw4BRejPt/RWfRlv+GXtxyEyUukPfNFZ0nP5OR2bFz87C/mEdLXWIzA6jpHUkic DV1Jtc9FVX2k6dEIGQxQGhxvkWWZm1YZJTmIb72gk7sc5aT1Hc62uLiAWopp1A== 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=1721226277; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=kWfMHeqbm9Ois5RqxlPJfdpM29zTiPLROKuBq9RBCFE=; b=saaCK+dLGFat3n3vTmhF75hiIVcyAg2aVi4en0Pf+X78l5OjPiXQ92pOQyWxj5ZY/pKsZU e/Or37rK7jchDK0YJUMI0mnbZ8kPk4P/Its8DiGoVLb7TLBM/gtdcfe/Ar3VFqIoM4HjlE gb474pZK7sXAtLZVzDEDnFXn+vlLnWi5HhvTDQbHs3fYCP9g/CPTnGJ0V7AE0Qlzp9Qna3 CYOgZ7ke0TBgxK8m+5Btwxjxc9YFY5a1hwtO098Ode1DXUGJ0jxhFq4JRxmUBomi1Y8FPY KSfZgEuKvzJRz0eEM1eahVqJqw9UIvI0xQw2XAH1w8btdZ2ucv98RlIuKiH1AQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ9K106jz1Mpd; Wed, 17 Jul 2024 14:24:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HEObnT033061; Wed, 17 Jul 2024 14:24:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HEObM3033058; Wed, 17 Jul 2024 14:24:37 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:24:37 GMT Message-Id: <202407171424.46HEObM3033058@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 0109a527607c - stable/13 - cxgbe(4): Shared code update to deal with partial failure in query_params. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 0109a527607ce0390ed5dfe59e9e3bf868ce08fa Auto-Submitted: auto-generated The branch stable/13 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=0109a527607ce0390ed5dfe59e9e3bf868ce08fa commit 0109a527607ce0390ed5dfe59e9e3bf868ce08fa Author: Navdeep Parhar AuthorDate: 2024-02-14 01:28:53 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 07:14:14 +0000 cxgbe(4): Shared code update to deal with partial failure in query_params. Obtained from: Chelsio Communications Sponsored by: Chelsio Communications (cherry picked from commit 2965ae59144177eb3570721295da9cbc447f1105) --- sys/dev/cxgbe/common/t4_hw.c | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/sys/dev/cxgbe/common/t4_hw.c b/sys/dev/cxgbe/common/t4_hw.c index 9048884eeb7e..8a225849930d 100644 --- a/sys/dev/cxgbe/common/t4_hw.c +++ b/sys/dev/cxgbe/common/t4_hw.c @@ -7740,9 +7740,18 @@ int t4_query_params_rw(struct adapter *adap, unsigned int mbox, unsigned int pf, } ret = t4_wr_mbox(adap, mbox, &c, sizeof(c), &c); - if (ret == 0) - for (i = 0, p = &c.param[0].val; i < nparams; i++, p += 2) - *val++ = be32_to_cpu(*p); + + /* + * We always copy back the results, even if there's an error. We'll + * get an error if any of the parameters was unknown to the Firmware, + * but there will be results for the others ... (Older Firmware + * stopped at the first unknown parameter; newer Firmware processes + * them all and flags the unknown parameters with a return value of + * ~0UL.) + */ + for (i = 0, p = &c.param[0].val; i < nparams; i++, p += 2) + *val++ = be32_to_cpu(*p); + return ret; } From nobody Wed Jul 17 14:24:39 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ9M49fXz5RPwv; Wed, 17 Jul 2024 14:24: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ9M2wqqz40dt; Wed, 17 Jul 2024 14:24:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226279; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Q0rqt/ZhUkf854yMhiAG9krmUTxygz8FGPSK9mCXnsQ=; b=ed7GRS1t+SmH54bMc6o9Wuy1TzPaga8FfS4z+CGVbpRjrZedv+ERx2NRBMgJn/fa38n6lA Tc1GSsL9gY58orL7FXdPiRKONvE5Gj+XGlHuIafwj0aqyPcFyvC61M/OdnBSPC6aWIRwOG 1adbwxBmGx0crBiXLd2JHFLrAxpQ6MGz05IVllk+v+tE6brFROew8TRJrRfew/ukHp2ErD 1mxs+NZhJH2Xck6xfAdQuX2TwJUUR0rscmdoQGtXhCsjtgxTjZOKZLLNe78H/AfvOqvkZT Nxua0D/hgmlIvgNxr3stYmd/upu9sUCQv69xGNaiC91RsrDeiRci5ivSHCmKnw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226279; a=rsa-sha256; cv=none; b=oiHbIxzFgNmfa9ltdscpZscynq8dj+wk7Jfz8X6csOSDKA/JJk5XgIp1PmJsmZ90N24GNA EbSAeUh8rJQC/7025K6K+34XdKk/UZQ09jLPcBzPSfMsE8gg0aLDHptP+02NCye1/Av1Bv LQRbt+4STfiY+2q2zlX16lMofIQu4fxnyfpIl/NZIxDuoygLIEmhaFWH1FvwdLdi7DLIwu xXpi36hvE5occy7s/yYkhxKGUadVR3nFuV9lm5qOcioZoGTDyPvUr+RaXVY5tCzla7P1Mo Qs4thHJBrR0Mii0AoD7e/khg1NN1vAbjE9BLrBGdX/tMZuu1yBqAoYqvHYlytg== 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=1721226279; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Q0rqt/ZhUkf854yMhiAG9krmUTxygz8FGPSK9mCXnsQ=; b=AIaUycRcVFiLOHbLpqKJ/wFz0999uUotCGWW3M+8ES/sd4vjOKdXauTF4uv820EGt09obg HegJZ25ROyAsiciMAXP2apBGD0vfCPrKsogbvTOXEvo5IKTCjRF8qzWQd6VBv/XjSMnnYT agGh7q9eQydipi78DzGCPRTpGCjocKMGsP4AnLPjx99Dpuf9LP1L2dRryR7hR8932vzNvq qkxIzPSaAK8K9cROilowlNPxyKOIqlTVkB8QQkfbB/QPeAg6H4o2Qa12qoHjVviMhQ6uvF RVrHL2Xfn1cMc2PvF0atJ9hYGaSZl/IET2qBo4mPGZs0PqzMZZutML4JhvqdJA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ9M2V60z1MHn; Wed, 17 Jul 2024 14:24:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HEOdlI033193; Wed, 17 Jul 2024 14:24:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HEOdPe033190; Wed, 17 Jul 2024 14:24:39 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:24:39 GMT Message-Id: <202407171424.46HEOdPe033190@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 8a499f92d472 - stable/13 - cxgbe(4): Do not read hardware registers to determine the number of ports. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 8a499f92d472393564bd9a87d4fe82aa113d894f Auto-Submitted: auto-generated The branch stable/13 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=8a499f92d472393564bd9a87d4fe82aa113d894f commit 8a499f92d472393564bd9a87d4fe82aa113d894f Author: Navdeep Parhar AuthorDate: 2024-04-30 19:42:14 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 07:14:42 +0000 cxgbe(4): Do not read hardware registers to determine the number of ports. PORTVEC obtained from the firmware is the authoritative source of this information, and nports (calculated from PORTVEC) is available by the time t4_port_init runs. Sponsored by: Chelsio Communications (cherry picked from commit 4d1362cdc7375984a48f5f0048b1fe909524d21d) --- sys/dev/cxgbe/common/t4_hw.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/sys/dev/cxgbe/common/t4_hw.c b/sys/dev/cxgbe/common/t4_hw.c index 8a225849930d..8d109b389f0d 100644 --- a/sys/dev/cxgbe/common/t4_hw.c +++ b/sys/dev/cxgbe/common/t4_hw.c @@ -6745,10 +6745,11 @@ static unsigned int t4_get_mps_bg_map(struct adapter *adap, int idx) if (adap->params.mps_bg_map) return ((adap->params.mps_bg_map >> (idx << 3)) & 0xff); - n = G_NUMPORTS(t4_read_reg(adap, A_MPS_CMN_CTL)); - if (n == 0) + n = adap->params.nports; + MPASS(n > 0 && n <= MAX_NPORTS); + if (n == 1) return idx == 0 ? 0xf : 0; - if (n == 1 && chip_id(adap) <= CHELSIO_T5) + if (n == 2 && chip_id(adap) <= CHELSIO_T5) return idx < 2 ? (3 << (2 * idx)) : 0; return 1 << idx; } @@ -6758,12 +6759,12 @@ static unsigned int t4_get_mps_bg_map(struct adapter *adap, int idx) */ static unsigned int t4_get_rx_e_chan_map(struct adapter *adap, int idx) { - u32 n = G_NUMPORTS(t4_read_reg(adap, A_MPS_CMN_CTL)); + const u32 n = adap->params.nports; const u32 all_chan = (1 << adap->chip_params->nchan) - 1; - if (n == 0) + if (n == 1) return idx == 0 ? all_chan : 0; - if (n == 1 && chip_id(adap) <= CHELSIO_T5) + if (n == 2 && chip_id(adap) <= CHELSIO_T5) return idx < 2 ? (3 << (2 * idx)) : 0; return 1 << idx; } From nobody Wed Jul 17 14:24:38 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ9L4KYPz5RPwt; Wed, 17 Jul 2024 14:24: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ9L2X86z40yb; Wed, 17 Jul 2024 14:24:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226278; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=kQb2fh1rDixI96Zg9GGlbYLEeQlLM4ePw4op492qCDo=; b=ZV1XHDrT/4FRLfeLx8Ho49dV4pYzwbyXjgpRFWWJF2mhZy7l2hB9wPn5y4TIC0uFz8EPJo ujZIpCpSW/SPU7SqVQpLtVaHTcbtqwqqLkFLztejr1jVt8y19bfm7cNDPx0Zol+X9tsHMu mUhivxkIzJzGccnFeTiWjpJJZgdY+aENtlLqRduNsLHLgmqp2bsqPwm9b0bpiqcJ6UFH/c 92CYuVCBEP71sk2DoxWK5gVa/m3taUHeVgsFeSiq1T3n5ZlMzQUHVL4qJUToZxFzkuksHj t3pBbeusECzwHpiYVsE2hlfUH2HdqkBnsOj8mzBaZa+UhCXSd5QtVm1XPaQ45A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226278; a=rsa-sha256; cv=none; b=tC/mmuaopL6JjeD99ftz1L0xPW7nCCuiHhckuKWvAIEKoSaysQFRTPfj+kJWD9lw0RY9UM AGrm7lEvtzoPcOTbrHJEsUIrf8z8bdlvlGReVmFkBzki8KX7p3jdSRngt0GkITWQ/FPtvE Cuen0v0grnC8JRcIS7mhJpY4rjwA1frtbbXUPefWzP8PZoR8AcJH/jCZx23MQdmbCalin0 N9rKmYJFWQs1GdIyDpkHwkMwMNkm1rjciNiT1URjwRAW1mZkD5cmI4B8rj88KcvlrQGkuV x/Twho9Rk7awZHsVV/2Y9q98Sl9Vhsk8JF9+ZypFYMaPa0kf5IHUFbAHqFwg9w== 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=1721226278; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=kQb2fh1rDixI96Zg9GGlbYLEeQlLM4ePw4op492qCDo=; b=aABORgNjLN3+s7hfV/fTc6mwbIH5Z2MUblUB+kZiQrf5SuWzVLtuTDKIfjRCwXO8LeKkbn fcsgRkjYA5gKBfYxSQHXLauPWhHxuXo6KPcfYLk0oxp7FyjSSh9pJqelfvE2m8Zq/lCCsp HqxAN+AnNQmt8B5QcqHIbkrgh68oK3fktfiyRLj6WAmBcKiLJn6ao5LXFLpNyCRIa8s7fj wFefYcwX495uSua0Vy+DTqfQyi1vkyxmQyupjKz5cJKqXZ9+qGEc6OjmJBs/QlNCs4U+MU 0m+GIPjj7YyQRGbkX7St7trEUdKcfsqunVwNzAhK1mTyU4QZxA0XAPwPe1wLyw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ9L27lJz1MHm; Wed, 17 Jul 2024 14:24:38 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HEOc5s033118; Wed, 17 Jul 2024 14:24:38 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HEOcH9033115; Wed, 17 Jul 2024 14:24:38 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:24:38 GMT Message-Id: <202407171424.46HEOcH9033115@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: b52a25051796 - stable/13 - cxgbe(4): Allocate a taskqueue per port instead of per channel. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: b52a25051796a930b2eb8985180744bb676df928 Auto-Submitted: auto-generated The branch stable/13 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=b52a25051796a930b2eb8985180744bb676df928 commit b52a25051796a930b2eb8985180744bb676df928 Author: Navdeep Parhar AuthorDate: 2024-04-30 17:51:45 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 07:14:27 +0000 cxgbe(4): Allocate a taskqueue per port instead of per channel. All the channels are not used on all boards and there's no point allocating taskqueues that will never be used. Sponsored by: Chelsio Communications (cherry picked from commit 857d74b6340e418396d79a46b264ce0eedd760e4) --- sys/dev/cxgbe/adapter.h | 3 ++- sys/dev/cxgbe/t4_main.c | 7 +++++-- sys/dev/cxgbe/t4_sge.c | 19 ++++++++++--------- 3 files changed, 17 insertions(+), 12 deletions(-) diff --git a/sys/dev/cxgbe/adapter.h b/sys/dev/cxgbe/adapter.h index 648182fe31c4..8d70e840d3f2 100644 --- a/sys/dev/cxgbe/adapter.h +++ b/sys/dev/cxgbe/adapter.h @@ -475,6 +475,7 @@ struct sge_eq { unsigned int abs_id; /* absolute SGE id for the eq */ uint8_t type; /* EQ_CTRL/EQ_ETH/EQ_OFLD */ uint8_t doorbells; + uint8_t port_id; /* port_id of the port associated with the eq */ uint8_t tx_chan; /* tx channel used by the eq */ struct mtx eq_lock; @@ -930,7 +931,7 @@ struct adapter { int nrawf; u_int vlan_id; - struct taskqueue *tq[MAX_NCHAN]; /* General purpose taskqueues */ + struct taskqueue *tq[MAX_NPORTS]; /* General purpose taskqueues */ struct port_info *port[MAX_NPORTS]; uint8_t chan_map[MAX_NCHAN]; /* channel -> port */ diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c index dd7552a50e4f..8895e22d18ac 100644 --- a/sys/dev/cxgbe/t4_main.c +++ b/sys/dev/cxgbe/t4_main.c @@ -6745,7 +6745,8 @@ adapter_full_init(struct adapter *sc) if (rc != 0) return (rc); - for (i = 0; i < nitems(sc->tq); i++) { + MPASS(sc->params.nports <= nitems(sc->tq)); + for (i = 0; i < sc->params.nports; i++) { if (sc->tq[i] != NULL) continue; sc->tq[i] = taskqueue_create("t4 taskq", M_NOWAIT, @@ -6794,7 +6795,9 @@ adapter_full_uninit(struct adapter *sc) t4_teardown_adapter_queues(sc); - for (i = 0; i < nitems(sc->tq) && sc->tq[i]; i++) { + for (i = 0; i < nitems(sc->tq); i++) { + if (sc->tq[i] == NULL) + continue; taskqueue_free(sc->tq[i]); sc->tq[i] = NULL; } diff --git a/sys/dev/cxgbe/t4_sge.c b/sys/dev/cxgbe/t4_sge.c index 93f914c3e2c5..cc8a0cc652b2 100644 --- a/sys/dev/cxgbe/t4_sge.c +++ b/sys/dev/cxgbe/t4_sge.c @@ -3462,13 +3462,14 @@ init_fl(struct adapter *sc, struct sge_fl *fl, int qsize, int maxp, char *name) static inline void init_eq(struct adapter *sc, struct sge_eq *eq, int eqtype, int qsize, - uint8_t tx_chan, struct sge_iq *iq, char *name) + uint8_t port_id, struct sge_iq *iq, char *name) { KASSERT(eqtype >= EQ_CTRL && eqtype <= EQ_OFLD, ("%s: bad qtype %d", __func__, eqtype)); eq->type = eqtype; - eq->tx_chan = tx_chan; + eq->port_id = port_id; + eq->tx_chan = sc->port[port_id]->tx_chan; eq->iq = iq; eq->sidx = qsize - sc->params.sge.spg_len / EQ_ESIZE; strlcpy(eq->lockname, name, sizeof(eq->lockname)); @@ -3909,8 +3910,8 @@ alloc_ctrlq(struct adapter *sc, int idx) snprintf(name, sizeof(name), "%s ctrlq%d", device_get_nameunit(sc->dev), idx); - init_eq(sc, &ctrlq->eq, EQ_CTRL, CTRL_EQ_QSIZE, - sc->port[idx]->tx_chan, &sc->sge.fwq, name); + init_eq(sc, &ctrlq->eq, EQ_CTRL, CTRL_EQ_QSIZE, idx, + &sc->sge.fwq, name); rc = alloc_wrq(sc, NULL, ctrlq, &sc->ctx, oid); if (rc != 0) { CH_ERR(sc, "failed to allocate ctrlq%d: %d\n", idx, rc); @@ -4656,7 +4657,7 @@ alloc_txq(struct vi_info *vi, struct sge_txq *txq, int idx) iqidx = vi->first_rxq + (idx % vi->nrxq); snprintf(name, sizeof(name), "%s txq%d", device_get_nameunit(vi->dev), idx); - init_eq(sc, &txq->eq, EQ_ETH, vi->qsize_txq, pi->tx_chan, + init_eq(sc, &txq->eq, EQ_ETH, vi->qsize_txq, pi->port_id, &sc->sge.rxq[iqidx].iq, name); rc = mp_ring_alloc(&txq->r, eq->sidx, txq, eth_tx, @@ -4873,11 +4874,11 @@ alloc_ofld_txq(struct vi_info *vi, struct sge_ofld_txq *ofld_txq, int idx) device_get_nameunit(vi->dev), idx); if (vi->nofldrxq > 0) { iqidx = vi->first_ofld_rxq + (idx % vi->nofldrxq); - init_eq(sc, eq, EQ_OFLD, vi->qsize_txq, pi->tx_chan, + init_eq(sc, eq, EQ_OFLD, vi->qsize_txq, pi->port_id, &sc->sge.ofld_rxq[iqidx].iq, name); } else { iqidx = vi->first_rxq + (idx % vi->nrxq); - init_eq(sc, eq, EQ_OFLD, vi->qsize_txq, pi->tx_chan, + init_eq(sc, eq, EQ_OFLD, vi->qsize_txq, pi->port_id, &sc->sge.rxq[iqidx].iq, name); } @@ -6392,7 +6393,7 @@ handle_wrq_egr_update(struct adapter *sc, struct sge_eq *eq) struct sge_wrq *wrq = (void *)eq; atomic_readandclear_int(&eq->equiq); - taskqueue_enqueue(sc->tq[eq->tx_chan], &wrq->wrq_tx_task); + taskqueue_enqueue(sc->tq[eq->port_id], &wrq->wrq_tx_task); } static void @@ -6404,7 +6405,7 @@ handle_eth_egr_update(struct adapter *sc, struct sge_eq *eq) atomic_readandclear_int(&eq->equiq); if (mp_ring_is_idle(txq->r)) - taskqueue_enqueue(sc->tq[eq->tx_chan], &txq->tx_reclaim_task); + taskqueue_enqueue(sc->tq[eq->port_id], &txq->tx_reclaim_task); else mp_ring_check_drainage(txq->r, 64); } From nobody Wed Jul 17 14:24:40 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ9N5Wf0z5RPtX; Wed, 17 Jul 2024 14:24: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ9N4JqTz40wg; Wed, 17 Jul 2024 14:24:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226280; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ILd+R/KFK9VGrgwBvm7dUb1F9cs6S7Mnbh8NdTOtZro=; b=YYI/2l+ODUCwKEa3AWOgudmo4y9akZ6+38Ax3cnRAksHwtSYAdVnOUSRnro4v6STnQrmvl zM5dWaTVgsdYv7Qb5A2IwY3Po5ZrIDnrB3ZNIa/HvxdNZRaRrnF0GMq8xLiD2kPOeVCHNV HnEg/iDkDNkpKoZRKnEnNQ2yMsffBjoTqLUoB6qB4hdLRZK/gr2fv6tMB8+38hwkVyuWJ7 ssSa0YzIsozMpFlZJ/7qHcXOu7ho9j/b7TrQtkIrv6x1hY9BbT3q8O4NetSgCuZx6nROzj R7WJ1r8shswazFd41NNwDV1FTr55hOzKTS271laSS1pFObflanf2/oBpg3VUvg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226280; a=rsa-sha256; cv=none; b=mYmad0YiUUM+HYwvxgrbjuxRj/ys/SyQKz12OLRnZBAiHD1p7qaDAPz4g3wEcmUYlZKkWO Ok0jxnJeiw5o6sqt8UKdjIx4QGl8FvvElZRAmxw5HGAybfws2gHvwR8y9d/T12rwBNNzC6 d7cT8VCByH1SB+xvx+ymxeOQgeg0U0/l+ph4/TRqwIedBUE7GuTHvuwkgVOXMf3TeodLaU LggQHX37cYkuwnAZRiW2UG/SELX35RZRBt7p3Kp1W6gOPb3nwjaPYKbvg1vLPyPlQdXBne 6q48QkRvX1mHFrqJ5Cetr4/0eNHayTEDaegXAxwSw+sukZDwT2YLj8F+Ru4IMw== 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=1721226280; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ILd+R/KFK9VGrgwBvm7dUb1F9cs6S7Mnbh8NdTOtZro=; b=JyRldUvHFxVCa/1laSYr0qA7Gm+Le1eU7nOsxu/aX5kwBPNh+t0/FnO7y2InsObqUEcfu8 jO00xCWzqXezjMdo957mK5Nagm9UVYIHw/RGT8eVdEeE7JTcHVKmtdVEcn44Ymls902cBB 95DCWRVn9sjX8fINUGZDUG5tZ8PjIEqsc0pwsPx2AVfQscJvKC7NXOCav59qShxj/nbIWN xS0rfleK6Hhmb19cr3y2+ZpNF0VncGIWuh2lpfaqgAWg7es3WjpeTnBjygh1zhRY83wGcM Uc33Lcl9C1M5q3sDnNAb0lySAQHhmJBp4AqKyeMcsmv697S37e6yO7cjhhANlw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ9N3vKJz1MdL; Wed, 17 Jul 2024 14:24:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HEOek5033253; Wed, 17 Jul 2024 14:24:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HEOeQT033250; Wed, 17 Jul 2024 14:24:40 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:24:40 GMT Message-Id: <202407171424.46HEOeQT033250@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 89d87c1864b8 - stable/13 - cxgbe(4): Initialize mps_bg_map to an invalid value if it's not known. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 89d87c1864b8982e9a2b3244086ed438a602bb0b Auto-Submitted: auto-generated The branch stable/13 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=89d87c1864b8982e9a2b3244086ed438a602bb0b commit 89d87c1864b8982e9a2b3244086ed438a602bb0b Author: Navdeep Parhar AuthorDate: 2024-04-30 19:51:29 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 07:15:24 +0000 cxgbe(4): Initialize mps_bg_map to an invalid value if it's not known. Sponsored by: Chelsio Communications (cherry picked from commit 9de0036b55dcdabc54fa69ea6e583b22d739818c) --- sys/dev/cxgbe/common/t4_hw.c | 2 +- sys/dev/cxgbe/t4_main.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/dev/cxgbe/common/t4_hw.c b/sys/dev/cxgbe/common/t4_hw.c index 8d109b389f0d..755062909e14 100644 --- a/sys/dev/cxgbe/common/t4_hw.c +++ b/sys/dev/cxgbe/common/t4_hw.c @@ -6742,7 +6742,7 @@ static unsigned int t4_get_mps_bg_map(struct adapter *adap, int idx) { u32 n; - if (adap->params.mps_bg_map) + if (adap->params.mps_bg_map != UINT32_MAX) return ((adap->params.mps_bg_map >> (idx << 3)) & 0xff); n = adap->params.nports; diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c index 8895e22d18ac..80e798049aa4 100644 --- a/sys/dev/cxgbe/t4_main.c +++ b/sys/dev/cxgbe/t4_main.c @@ -5406,7 +5406,7 @@ get_params__post_init(struct adapter *sc) if (rc == 0) sc->params.mps_bg_map = val[0]; else - sc->params.mps_bg_map = 0; + sc->params.mps_bg_map = UINT32_MAX; /* Not a legal value. */ /* * Determine whether the firmware supports the filter2 work request. From nobody Wed Jul 17 14:24:41 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ9Q0KSBz5RPx0; Wed, 17 Jul 2024 14:24: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ9P5M6Zz40hl; Wed, 17 Jul 2024 14:24:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226281; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=32Cmaj8pBKubAnZMeerytF4RNANpn4XCyWd1UEXUEtQ=; b=mcdEq71HWJVO9M47wdLEo8pQf1UdUYJpHYR90/w/Sp1v03P+YSgnXzLkg1om817Y0bmcQn 9ar7/1uJrMpckwozgO5rqYKqCmjSjrrPrVRQJ9om8nwbMQtCsWvig3Db6pnHDnO1XDHk9P QTbhcdasieFf7r6KY22AIOs/Jx5JAxUC78yWjeBxjtDiTxW6RL1gCOjvFlW6tSx6LVihXp M5HADSrs9cCYP+Jald3SaFXG1fl332Xb6Y8IlVWT9+MGn/s1hnNURBbrI2kfOUshPYNT3+ unYb1KZ1RuB4P3x/CRxuwMuVeKeWOQ2gAtM5jXPzNWPrITuAlli5iT56InPZIQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226281; a=rsa-sha256; cv=none; b=u5UgmR7xm3K+Ut4MpUwMDUbCxVcDewk9U1izFooCvExoQlEXJmObVcR86vEzhYxN5y5K24 onrwgN8uE21No1HsFB/rhMdPxUwT9SkIFkwOR4LmQidWIo1Yftvu+/o5DRWdDuSX+UHtEO qctIqQ3leLJRtVOI46h+xDZTIUMBny6FqmHY2ZFYFx2dZ+beBBOskSMZPfzu7yH9pwhbs4 JBW7QLRkHXhi5YMmJnKgujWsB5WeSegxvpK9Fwmvx7XdVVFRdqbYWDyU9EqsWUbnyJG7qD ceJtv8Ts4mgRjX9peN69QIG7bjz52u0GaTiuYZVrXQ3Xt+vHl9W8KFMUtuGpxA== 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=1721226281; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=32Cmaj8pBKubAnZMeerytF4RNANpn4XCyWd1UEXUEtQ=; b=HQVN1yi5s2GFPBySxghNc+62JUiWyDd5agoDWBg+8kc8M/eAuFM3k0PyADzITbHFm8D9gY FvytXqERdRP4fgI6wB1A6i6s5nHeiTSIQLnduf2uR+FvsA7EFVXCS8sYmbgrTVMNlQB57/ vS2raVNM/6Fg3esqmMS1lY6bd3YtmMpZ69yYKagQNH44zjiNsw87XM5+gswg7FKX571jru 2bRl16GCCpc3jKAlb5/pwXQwg3286qFm6KjHvvq4kYhjad5K3xxTXlbu+QYjc8GNRh/cMe DXeGawVREyAD7RwyLEG4zslx84VTJl3KM0POjG29AvbmK3xHkS6fNULdE+rpow== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ9P4yq1z1MdM; Wed, 17 Jul 2024 14:24:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HEOf9w033295; Wed, 17 Jul 2024 14:24:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HEOfNK033292; Wed, 17 Jul 2024 14:24:41 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:24:41 GMT Message-Id: <202407171424.46HEOfNK033292@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 352bef734c4d - stable/13 - cxgbe(4): Minor tweaks to comments. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 352bef734c4d7460eb65ad2b1a9a263d58f18e09 Auto-Submitted: auto-generated The branch stable/13 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=352bef734c4d7460eb65ad2b1a9a263d58f18e09 commit 352bef734c4d7460eb65ad2b1a9a263d58f18e09 Author: Navdeep Parhar AuthorDate: 2024-04-30 20:01:07 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 07:15:43 +0000 cxgbe(4): Minor tweaks to comments. No functional change intended. Sponsored by: Chelsio Communications (cherry picked from commit 21aba396551e29808fa56a6d4fab17e871c3524f) --- sys/dev/cxgbe/t4_main.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c index 80e798049aa4..6db64dc53440 100644 --- a/sys/dev/cxgbe/t4_main.c +++ b/sys/dev/cxgbe/t4_main.c @@ -5396,9 +5396,13 @@ get_params__post_init(struct adapter *sc) } /* - * MPSBGMAP is queried separately because only recent firmwares support - * it as a parameter and we don't want the compound query above to fail - * on older firmwares. + * The parameters that follow may not be available on all firmwares. We + * query them individually rather than in a compound query because old + * firmwares fail the entire query if an unknown parameter is queried. + */ + + /* + * MPS buffer group configuration. */ param[0] = FW_PARAM_DEV(MPSBGMAP); val[0] = 0; @@ -5410,7 +5414,6 @@ get_params__post_init(struct adapter *sc) /* * Determine whether the firmware supports the filter2 work request. - * This is queried separately for the same reason as MPSBGMAP above. */ param[0] = FW_PARAM_DEV(FILTER2_WR); val[0] = 0; @@ -5422,7 +5425,6 @@ get_params__post_init(struct adapter *sc) /* * Find out whether we're allowed to use the ULPTX MEMWRITE DSGL. - * This is queried separately for the same reason as other params above. */ param[0] = FW_PARAM_DEV(ULPTX_MEMWRITE_DSGL); val[0] = 0; From nobody Wed Jul 17 14:24:43 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ9S1dXlz5RPyp; Wed, 17 Jul 2024 14:24:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ9S0QpLz418N; Wed, 17 Jul 2024 14:24:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226284; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=11DpPC1HMOS9GH7uGSo3nOCC4THw7M9VH0nEbtmM1m4=; b=BJd/nEUhNtQohmQtgm95E3ptklgWd97zB8BOatok8skIlixpDG7xuQ+Xh/tvQTA94lWaDT ygXf3iPe+LCI5GZ6bVYV3bgsDAzSPRzqE8r7wPj6ACUKUP3SYOtr4Zu8FDNeBTIe2AMXf7 mBH5IzEfhqoKwW11NMjt0KI7FRYc8Y9x9EpE0Vntn9uOqT70R9WK93D3KB87A6WAj2sZMB xJ9ru3UjmQXE2lK0wQmrWiSHAM6oE6VIGsI6rPZXbi0xFBSpvNB99KTZECe+cY8KtrPipo /4pDUDmoSj8p2w7s52NqjCzq5c2ETW3sjY4wM1CwgQu3sI/ntV4Ia53bTWs8MA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226284; a=rsa-sha256; cv=none; b=g2TBSG3ReapKmyeK1oaVw8lgGAXsqRYe41fBDtWOPLcesYw23lJndb8fhE9Z3e8g97bxl1 yODgsKnvTHdcYoCfG5djTsx3suAOWw1p8CNek+cEPEKXdERNoxNSW7QvksNjg3qGvjHUW9 a80AwweFRyAmbulD8aLGDJ2KRmo7i98pdm7ztI42RQEo+eQlUcKKsE3NPrHHCwP8BQXBxn ZSe1Am28p5j5zBIRhXx1BRThc14VSkY155K3YwOXZacrQSx/EbTAQKU2fuFZJaxnI9aFTZ XkqRpuGteM8hLblxiA/BJ1oKwvZSBYgG7gZmwSp8kqPumvVZI+NC0IJnp6Rdyg== 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=1721226284; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=11DpPC1HMOS9GH7uGSo3nOCC4THw7M9VH0nEbtmM1m4=; b=cc1x8lCQ+McrFHam67RCm8vbQ5FjO6gvGReS5Qvr+FjW4fLFbkoVqL9f1o8r/ALio+juYX kMsqlSNVJRKmeBF/FMmGClNv3t+U5PW0ckZUWkd+JZUjV1rL2ohsWykDZQFQ3H4lXcO+Pf a+jW+njOFP9/50h9FsuELCf/owsmtPHwfpLg/2i91SbCyDmEVh7uQSFX/W1vx/gy5eYej1 I16mVKNd33uw90OD3Bh2l4nFlzdtfN+q1PmRa2IJdjqSbyM9SGTMQ2hWOKe7HkVMb7U4ml OAQN4PGKGB829w9OCw8H/qsVtEuIWzKkGC6JoPXCt19qtiIcjaGw3VpxmHJKcQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ9S03Hgz1Mb2; Wed, 17 Jul 2024 14:24:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HEOhiK033396; Wed, 17 Jul 2024 14:24:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HEOhGe033393; Wed, 17 Jul 2024 14:24:43 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:24:43 GMT Message-Id: <202407171424.46HEOhGe033393@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: ab374f82d9f1 - stable/13 - cxgbe(4): Query TPCHMAP once and not once per port. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: ab374f82d9f1060154938117946a2953ac8926c9 Auto-Submitted: auto-generated The branch stable/13 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=ab374f82d9f1060154938117946a2953ac8926c9 commit ab374f82d9f1060154938117946a2953ac8926c9 Author: Navdeep Parhar AuthorDate: 2024-04-30 23:32:55 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 07:16:20 +0000 cxgbe(4): Query TPCHMAP once and not once per port. Sponsored by: Chelsio Communications (cherry picked from commit 7f10048f983a31c09587b436e7fb073f7cbb76e4) --- sys/dev/cxgbe/common/common.h | 4 +++- sys/dev/cxgbe/common/t4_hw.c | 11 ++--------- sys/dev/cxgbe/t4_main.c | 8 ++++++++ 3 files changed, 13 insertions(+), 10 deletions(-) diff --git a/sys/dev/cxgbe/common/common.h b/sys/dev/cxgbe/common/common.h index f43ffc83dff1..67bbf5e43b79 100644 --- a/sys/dev/cxgbe/common/common.h +++ b/sys/dev/cxgbe/common/common.h @@ -402,7 +402,9 @@ struct adapter_params { unsigned int max_ordird_qp; unsigned int max_ird_adapter; - uint32_t mps_bg_map; /* rx buffer group map for all ports (upto 4) */ + /* These values are for all ports (8b/port, upto 4 ports) */ + uint32_t mps_bg_map; /* MPS rx buffer group map */ + uint32_t tp_ch_map; /* TPCHMAP from firmware */ bool ulptx_memwrite_dsgl; /* use of T5 DSGL allowed */ bool fr_nsmr_tpte_wr_support; /* FW support for FR_NSMR_TPTE_WR */ diff --git a/sys/dev/cxgbe/common/t4_hw.c b/sys/dev/cxgbe/common/t4_hw.c index 3e04995eec3b..07940a44f66e 100644 --- a/sys/dev/cxgbe/common/t4_hw.c +++ b/sys/dev/cxgbe/common/t4_hw.c @@ -6774,15 +6774,8 @@ static unsigned int t4_get_rx_e_chan_map(struct adapter *adap, int idx) */ static unsigned int t4_get_rx_c_chan(struct adapter *adap, int idx) { - u32 param, val; - int ret; - - param = (V_FW_PARAMS_MNEM(FW_PARAMS_MNEM_DEV) | - V_FW_PARAMS_PARAM_X(FW_PARAMS_PARAM_DEV_TPCHMAP)); - ret = t4_query_params(adap, adap->mbox, adap->pf, 0, 1, ¶m, &val); - if (!ret) - return (val >> (8 * idx)) & 0xff; - + if (adap->params.tp_ch_map != UINT32_MAX) + return (adap->params.tp_ch_map >> (8 * idx)) & 0xff; return 0; } diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c index ae6e25e47a15..842eb87e9126 100644 --- a/sys/dev/cxgbe/t4_main.c +++ b/sys/dev/cxgbe/t4_main.c @@ -5412,6 +5412,14 @@ get_params__post_init(struct adapter *sc) else sc->params.mps_bg_map = UINT32_MAX; /* Not a legal value. */ + param[0] = FW_PARAM_DEV(TPCHMAP); + val[0] = 0; + rc = -t4_query_params(sc, sc->mbox, sc->pf, 0, 1, param, val); + if (rc == 0) + sc->params.tp_ch_map = val[0]; + else + sc->params.tp_ch_map = UINT32_MAX; /* Not a legal value. */ + /* * Determine whether the firmware supports the filter2 work request. */ From nobody Wed Jul 17 14:24:42 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ9R4DwFz5RPnc; Wed, 17 Jul 2024 14:24: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ9R1WyZz40kl; Wed, 17 Jul 2024 14:24:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226283; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=yap5wbeXLPTJrZK13RTZKYCnGA3ImYajX1VwlnMh6Ho=; b=rw00SMA24tHfi22UIcc2Ddp9tmOVIo/ED6tofmf0tK0hI2mN8yhDbVHqc0kEcyY3ZenXFA SyHaqMpz+WtbGUlK+HDGx0/ul+ObSTo97/K/V0vGGO/AYGTv8fAeMqIfhcVkVEA0LePv4a I4/dYh6qbPJq9rNjiN5LoX1ndwHzWCzjKc54a3W+qCdGUSirS0c+b9mH6KAyRSfO/0jYg3 SYdrStv21T5BvDdlsxLPfrSNloNKwbU40djWproy+akdDy9xOg/YpfJLXtiQTDeOxoc88U vGfLtI8j9InmxfRUnKYjWSsm0dVtlnhm9lV9JTN9l7BTfXPyhobyF0/SIQVXqA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226283; a=rsa-sha256; cv=none; b=jLT1tpX9PimopOiauINHYaJ2yBxy7REsqgZ2DNucp+LtFCv8Lc/YXoMN2b+bEOZHLeWadL ++HRxaURB1qPDoUZ2aXZ0B6K4JyD9/ld7SetOVrUGKkIFk16VPeuaPwdyoohk7eK/STdyg N87L+JJBX34kyDIYAQd9p028Vx6rPkXphrTwxLxMmKmXRU9k71MuS1nShM9A6AQt31m9A1 h/rdiGDuZMotUYjL42UsYKMCHFyiwVr/bc4qnTdZahJVWJTCryuO5OCIKMnw9WG28l7uVA wnNj7/hRAQ/VBcFxNkzQPaavOA1MpU3gL5bfgC9A2XqxFxA0t57BBu0/1JCiPg== 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=1721226283; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=yap5wbeXLPTJrZK13RTZKYCnGA3ImYajX1VwlnMh6Ho=; b=H2q6Lm3R3MJYDK9xB8fUbtbaDTVWSluzO/8FXOjfMiNlq/PVySGnjRmb23hy37RRt+ZLnu fMlXRFpdcvGmwwjAxmDlSpw7KQhSwPVvnH5p/Rs7JQuSpCPYN5Oq5sbt/SjZxTvWQ53k7f vZjfRBSE96xiK04xahcw+hqJX/VSDsEgqhx73wr+0CSzH3NnW6ZIZn5LksoCHi4tMGkU6q Ot5Ec7c/or82OWYiorFX2MsF72fjiVl4B82ZTWXfwUoAFAMELBfiL5gpMP3NjaOeMpyiQE rcdZT36D3ujwuECxmfb+ldu6t0rbZ25FaMcU/oVVUYWSEj7PuZ9c5ZzEkTzaLw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ9Q62X4z1Mpf; Wed, 17 Jul 2024 14:24:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HEOghk033337; Wed, 17 Jul 2024 14:24:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HEOgCI033334; Wed, 17 Jul 2024 14:24:42 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:24:42 GMT Message-Id: <202407171424.46HEOgCI033334@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 8b6adcb3c768 - stable/13 - cxgbe(4): Rename rx_c_chan to rx_chan. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 8b6adcb3c76858accbe445eb9414064856477ce1 Auto-Submitted: auto-generated The branch stable/13 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=8b6adcb3c76858accbe445eb9414064856477ce1 commit 8b6adcb3c76858accbe445eb9414064856477ce1 Author: Navdeep Parhar AuthorDate: 2024-04-30 23:07:24 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 07:16:05 +0000 cxgbe(4): Rename rx_c_chan to rx_chan. It is the equivalent of tx_chan but for receive so rx_chan is a better name. Initialize both using helper functions and make sure both are displayed in the sysctl MIB. Sponsored by: Chelsio Communications (cherry picked from commit 480ff89c67b25113515018cdcd13179229b4a0d3) --- sys/dev/cxgbe/adapter.h | 4 ++-- sys/dev/cxgbe/common/t4_hw.c | 12 ++++++++++-- sys/dev/cxgbe/crypto/t4_crypto.c | 2 +- sys/dev/cxgbe/t4_main.c | 6 ++++-- 4 files changed, 17 insertions(+), 7 deletions(-) diff --git a/sys/dev/cxgbe/adapter.h b/sys/dev/cxgbe/adapter.h index 8d70e840d3f2..17e4e682bdc2 100644 --- a/sys/dev/cxgbe/adapter.h +++ b/sys/dev/cxgbe/adapter.h @@ -324,10 +324,10 @@ struct port_info { uint8_t port_type; uint8_t mod_type; uint8_t port_id; - uint8_t tx_chan; + uint8_t tx_chan; /* tx TP c-channel */ + uint8_t rx_chan; /* rx TP c-channel */ uint8_t mps_bg_map; /* rx MPS buffer group bitmap */ uint8_t rx_e_chan_map; /* rx TP e-channel bitmap */ - uint8_t rx_c_chan; /* rx TP c-channel */ struct link_config link_cfg; struct ifmedia media; diff --git a/sys/dev/cxgbe/common/t4_hw.c b/sys/dev/cxgbe/common/t4_hw.c index 755062909e14..3e04995eec3b 100644 --- a/sys/dev/cxgbe/common/t4_hw.c +++ b/sys/dev/cxgbe/common/t4_hw.c @@ -6786,6 +6786,14 @@ static unsigned int t4_get_rx_c_chan(struct adapter *adap, int idx) return 0; } +/* + * TP TX c-channel associated with the port. + */ +static unsigned int t4_get_tx_c_chan(struct adapter *adap, int idx) +{ + return idx; +} + /** * t4_get_port_type_description - return Port Type string description * @port_type: firmware Port Type enumeration @@ -9817,10 +9825,10 @@ int t4_port_init(struct adapter *adap, int mbox, int pf, int vf, int port_id) } while ((adap->params.portvec & (1 << j)) == 0); } - p->tx_chan = j; + p->tx_chan = t4_get_tx_c_chan(adap, j); + p->rx_chan = t4_get_rx_c_chan(adap, j); p->mps_bg_map = t4_get_mps_bg_map(adap, j); p->rx_e_chan_map = t4_get_rx_e_chan_map(adap, j); - p->rx_c_chan = t4_get_rx_c_chan(adap, j); p->lport = j; if (!(adap->flags & IS_VF) || diff --git a/sys/dev/cxgbe/crypto/t4_crypto.c b/sys/dev/cxgbe/crypto/t4_crypto.c index 7301174614d2..6e925103ba74 100644 --- a/sys/dev/cxgbe/crypto/t4_crypto.c +++ b/sys/dev/cxgbe/crypto/t4_crypto.c @@ -1919,7 +1919,7 @@ ccr_init_port(struct ccr_softc *sc, int port) pi = sc->adapter->port[port]; sc->ports[port].txq = &sc->adapter->sge.ctrlq[port]; sc->ports[port].rxq = &sc->adapter->sge.rxq[pi->vi->first_rxq]; - sc->ports[port].rx_channel_id = pi->rx_c_chan; + sc->ports[port].rx_channel_id = pi->rx_chan; sc->ports[port].tx_channel_id = pi->tx_chan; sc->ports[port].stats_queued = counter_u64_alloc(M_WAITOK); sc->ports[port].stats_completed = counter_u64_alloc(M_WAITOK); diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c index 6db64dc53440..ae6e25e47a15 100644 --- a/sys/dev/cxgbe/t4_main.c +++ b/sys/dev/cxgbe/t4_main.c @@ -8062,8 +8062,10 @@ cxgbe_sysctls(struct port_info *pi) pi->mps_bg_map, "MPS buffer group map"); SYSCTL_ADD_INT(ctx, children, OID_AUTO, "rx_e_chan_map", CTLFLAG_RD, NULL, pi->rx_e_chan_map, "TP rx e-channel map"); - SYSCTL_ADD_INT(ctx, children, OID_AUTO, "rx_c_chan", CTLFLAG_RD, NULL, - pi->rx_c_chan, "TP rx c-channel"); + SYSCTL_ADD_INT(ctx, children, OID_AUTO, "tx_chan", CTLFLAG_RD, NULL, + pi->tx_chan, "TP tx c-channel"); + SYSCTL_ADD_INT(ctx, children, OID_AUTO, "rx_chan", CTLFLAG_RD, NULL, + pi->rx_chan, "TP rx c-channel"); if (sc->flags & IS_VF) return; From nobody Wed Jul 17 14:24:45 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ9T2XVbz5RPx7; Wed, 17 Jul 2024 14:24: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ9T1TGbz416J; Wed, 17 Jul 2024 14:24:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226285; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=LY08AchYZqLSvS0zXoNLB47U1E4Fj1LKGJpU6Nhz6zQ=; b=c5GzfdxIzVuIBTYtljKeC/TqWSSFSgo2QSdSoGJcIbyywgLl9jjFqU38pjj1u3Ipj1LQm0 KzdLFIL38AJD1g/gNKrRKhOpr4le3NN6CbWrNWUoVXtgDrrDeiK54L2Nb13FlO6/mmojzi hnbbS6UP2EvPHHLfUZwuWpMNJE1PC36Ccjrp00VAKMmZ3eG4iPJbjYzb4UYQUk+7GFuLNF FxDNb3Qq6iDq/HEx42MqGZIpKeex5BMRF5a+q04S255nuXCX7BUVy5Llbm/u5fmgtap/Wb bCZKHfXYUNK373xmT7Bf73oVaAxA1Gx3loULIdt/kpGFL2YTZCjzjd7NjhE1mg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226285; a=rsa-sha256; cv=none; b=MCZ9DFTS4C0WlG4V2saFAO+YmTOWJtQeKwvrCRHTWAImMBCVMWlS46E8/Slld8AIIzX8lu t2hzAIee0XVJcbfjM6b8VfKH76LR4lD0o+1vONm4Et8lnoVMD6tqPVlhR3Pr0MVAQyODmw hzhY+sHt/2LZVs0fNt4PwVmz1aeztVIpgsQ6yyLPnaFy1CKgU/h+xkCs2IMWAjVY7/jLon Fc1I31XkpneYaH1jrrQhFC5T8Vn/+5eUs0/QudzuK2hlsSqkcsh1/jEWJ01jXPNTylfy7U WozUjtiSj6eaaDPKpsu+mVZommBvEpXl9MUEmCCakSb++3EdRm54alwFBPloHw== 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=1721226285; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=LY08AchYZqLSvS0zXoNLB47U1E4Fj1LKGJpU6Nhz6zQ=; b=D3xY0wjGfqHDqH8iVQtMk+V+MCN+XeUlx0Bv40ICMZCdH8WoOn9cdIfN4ohBvBte2UXRXI A/HXc8W2N95WzjOePXhKmhW8hxpU/DEQij7AYUzWC0T5B5ikh4FAP9DnG7KsZJ/zvOCOBS yAO+rQtFyhlw314zJz5/hvEfiDa27oT0i+gSteoWYr33OP6cvDpNLiQclr5vijBEWzT8+R BKJLpPk7/2rYsgD4PAMsrXqtNdDUxTq1ksO250l9NJ7EB7FYfmvLGB7UpK39WcfoM4hf7V jEk75Lavp6gWXWv7AwIeZKdFyLxZuGoJgKDKSeAGErjEwXCnAgULanj6uktUkQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ9T12ySz1N0l; Wed, 17 Jul 2024 14:24:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HEOjKN033453; Wed, 17 Jul 2024 14:24:45 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HEOjZd033450; Wed, 17 Jul 2024 14:24:45 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:24:45 GMT Message-Id: <202407171424.46HEOjZd033450@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 7f864af3e648 - stable/13 - cxgbe/tom: Fix the rx channel selection in options2. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 7f864af3e648fc3fcc27d3f2b840f111deac1600 Auto-Submitted: auto-generated The branch stable/13 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=7f864af3e648fc3fcc27d3f2b840f111deac1600 commit 7f864af3e648fc3fcc27d3f2b840f111deac1600 Author: Navdeep Parhar AuthorDate: 2024-04-15 20:04:49 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 07:16:36 +0000 cxgbe/tom: Fix the rx channel selection in options2. This affects TOE operation when multiple rx c-channels are in use for offload, which is an unusual configuration. Sponsored by: Chelsio Communications (cherry picked from commit c6c6d4aff90da83a292b4c2bbbe1f4d6e01cd82e) --- sys/dev/cxgbe/tom/t4_tom.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sys/dev/cxgbe/tom/t4_tom.c b/sys/dev/cxgbe/tom/t4_tom.c index 1600325ca42f..7456a2d4051b 100644 --- a/sys/dev/cxgbe/tom/t4_tom.c +++ b/sys/dev/cxgbe/tom/t4_tom.c @@ -1051,12 +1051,14 @@ calc_options2(struct vi_info *vi, struct conn_params *cp) MPASS(cp->ecn == 0 || cp->ecn == 1); opt2 |= V_CCTRL_ECN(cp->ecn); - /* XXX: F_RX_CHANNEL for multiple rx c-chan support goes here. */ - opt2 |= V_TX_QUEUE(TX_MODQ(pi->tx_chan)); opt2 |= V_PACE(0); opt2 |= F_RSS_QUEUE_VALID; opt2 |= V_RSS_QUEUE(sc->sge.ofld_rxq[cp->rxq_idx].iq.abs_id); + if (chip_id(sc) <= CHELSIO_T6) { + MPASS(pi->rx_chan == 0 || pi->rx_chan == 1); + opt2 |= V_RX_CHANNEL(pi->rx_chan); + } MPASS(cp->cong_algo >= 0 && cp->cong_algo <= M_CONG_CNTRL); opt2 |= V_CONG_CNTRL(cp->cong_algo); From nobody Wed Jul 17 14:24:46 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ9V6ZVdz5RPyv; Wed, 17 Jul 2024 14:24: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ9V2W8yz41J4; Wed, 17 Jul 2024 14:24:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226286; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Paz66P1y77/nwOZN6nuiLFa6qEG7vEFwQdyniS1k8Fo=; b=ph1Xo1Dh0/Uh/1pnGZ1EazdXuaVeV3y9ELkjTz+u1A7Ovpnrx3zj2Ekc4TIDYA5puDvs1q 03P1dpTB3FH+1Q8izr+zDCDVvgh+POnkueuFgMzLEUiPoegRmVpHsA2wKzmpnm/Db5wBvj LrdQiRBhzh8SClkFtjUgEefqu2fyX4UrceJzbW69JYdKBbUY/PmbilC9AZgHlX3QRcEQHy PprUt4sTwbwgRZw1Verw4UYPSe8fs1eIw77+E7E4UOwci56BZktJN1r/ao7NPS9FXVsxui kDRgnlcWEUwzPPmoSEboUrHXiDbHb5xrK5mLRPbh9omEqNbITZOSHgaT6kLPMg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226286; a=rsa-sha256; cv=none; b=AxIpgzOChLIRQHyUWSo1RXGMSdzYdCgMcr1rD5Ykk41ooQEljQrj+fHf5BHJr5SiHJsAOt ++W2VSOEwJNjl7USwicakxvlaYiTbbTlNtKZ6irWwpmpHZr+35Hgq875m3haGEq/iBBz3s gZ2i5VeliOVfH0Qr3L07nfR3BjHN+i7rXfJLfz7CrRn8GkrwTtYhbHarMvpbsGrRVM1GRR 3x2YzmSXoRS1n3QzC19NKz5aAEHkov0pnIvzE3QiqT/pJkW05B4ANBRs/kBpWtfEFEjIwV ujBJERkj2EXhwvLlfAh3FRRFqo0KSVYRQi37sdtrV8D5lwIbkSAaehKCdsUf8A== 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=1721226286; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Paz66P1y77/nwOZN6nuiLFa6qEG7vEFwQdyniS1k8Fo=; b=GZmEOChQXgxAhI1/tk03yH1DTbF8qAM1nbHeNQcz9vpwtSmcQP5AP0RNVEECm75L5pkoTG lbjir6ValqK0EhOS7fHZ5QaiR+Y9DcqYOn9eyRnpxXX3FXJNYrSa/5hzEKAKWMDPEz3qRw 0Y3s0iquTsQq+YYOujWDd4zaDhOvWfj7V0/5ZgpziE55A9XW98+X51CxtvWVarxciXIyM0 hQSOqCv+r29xntJgvVf3BCqMXrKbx8gkTU8D6GUPLexZJ+kT5dSS1wqRPtGCWksbGzjbC7 9rD5TFtRPYTN2R1fiXKHSeSwRTUp0stiAaqa8NBkelVrtj7QCy7ub4B3wvqklg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ9V250qz1N0m; Wed, 17 Jul 2024 14:24:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HEOkaI033514; Wed, 17 Jul 2024 14:24:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HEOkda033511; Wed, 17 Jul 2024 14:24:46 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:24:46 GMT Message-Id: <202407171424.46HEOkda033511@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 9cdafb024d3e - stable/13 - cxgbe(4): sc->port is indexed by port_id and not tx_chan. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 9cdafb024d3ea8dbc169a556863ef7c1e516719f Auto-Submitted: auto-generated The branch stable/13 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=9cdafb024d3ea8dbc169a556863ef7c1e516719f commit 9cdafb024d3ea8dbc169a556863ef7c1e516719f Author: Navdeep Parhar AuthorDate: 2024-05-02 23:47:18 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 07:16:55 +0000 cxgbe(4): sc->port is indexed by port_id and not tx_chan. Sponsored by: Chelsio Communications (cherry picked from commit cca3506dc15464baf9b09b143879ed13fb5684c7) --- sys/dev/cxgbe/t4_sched.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/cxgbe/t4_sched.c b/sys/dev/cxgbe/t4_sched.c index f7e2e168880a..d343b75a614f 100644 --- a/sys/dev/cxgbe/t4_sched.c +++ b/sys/dev/cxgbe/t4_sched.c @@ -335,7 +335,7 @@ bind_txq_to_traffic_class(struct adapter *sc, struct sge_txq *txq, int idx) goto done; } - tc0 = &sc->port[txq->eq.tx_chan]->sched_params->cl_rl[0]; + tc0 = &sc->port[txq->eq.port_id]->sched_params->cl_rl[0]; if (idx != -1) { /* * Bind to a different class at index idx. From nobody Wed Jul 17 14:24:47 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ9W686Vz5RQ00; Wed, 17 Jul 2024 14:24:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ9W43rTz41G4; Wed, 17 Jul 2024 14:24:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226287; h=from:from:reply-to:subject:subject: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+PfeL5VQ2ACFh5fMwo24PLf8iaI0bqT+xuv+Xu+M2s=; b=Pa7uu0hPS8nDQs3Dr5L6bx5vmYFSQjOQpC0To22f3hMgxGZEAj3X+gvgWWpAvP6WmjS+To gcu7lwhLXrwvrdvif3QckW8yIHG/1Jrq/QI0v0oD5Ka7qGu7VBEugSAKjGtdUHAS6aVq4D i0z1BQxoW3MCCfA6trdeHYBz8FooD/sN/r6zQDr/jJwU9iB7JQzylBd5nKwv/d/5aBGXwu XYiPOdBdsweMVmvuPyQQfSqfWj0Ulg4bFZ301gXJ4qnGcHkLC5e1Uzmkz4xQym7aY3Z626 FnsoLTraBUOHjKHOlExEu8qvtU/U1q+2esKZYC9FSQmzXD1Q383QDFnh2GViLQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226287; a=rsa-sha256; cv=none; b=WhcUEZud0VUSLP3kESY+3X2k8BanZIcJOJU+NTyww8GEHrs5GIvhznD/dA+xJyBshNMBzT Qp2/cr/4hHd1Viua4jht6kJXBK79bpe+VWu7pWluRMUtv5ODBBZfsveZNEshGjeQokLkJz H8PcYOe1gxD0dLNmKGhxxCRlXjJc0MmBrjiltd6MeTRi2J+kQGFrc+R1emxHW95276mHu4 Ssa+2o6jFWtfx0Usjbzhgqrwps7AwZlEKm5Hs9ZOcf4FHjaGn/RI27fLWnrFMzJdXQr9dU FXswIY2gZXh6wZhRO5ITlR68wn3rNTFCJk15ZNdNxDHHTK5sRTeZzZlIQ4kOiw== 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=1721226287; h=from:from:reply-to:subject:subject: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+PfeL5VQ2ACFh5fMwo24PLf8iaI0bqT+xuv+Xu+M2s=; b=j/TeH/hxDw7ym0DyRLlvOwbE6HkIeu6ROqn19+5KRQ6uX0IFXuNKcZ3HqDcrYdfWs0Mr4k F+wIl9RH/PCI+lE0Xl2ycd6IcixJyz0OpzJX76qu3VorlRf6lALVZklhZQaDnG+zfCGWVh Olg6r2INRHfOpqLsYiDh/qOGu6ThQMQdvY3xEwGZ/DsX7px0fbfFRJIRUOQCbHpJI9xG5Z As55Oxfilwf/2V+vpYKdFsHIyG6/xvx/gm9OLZSOcuqSATF8nKHVGv+ikO31T+cruoLD5f bBJJ2U4yzCUFIEU4g2WNcyC1pa6kYFOs/tMf96Zs64h+ONcl89jN+yyvCS/Puw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ9W38r3z1N0n; Wed, 17 Jul 2024 14:24:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HEOlsL033562; Wed, 17 Jul 2024 14:24:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HEOlKZ033559; Wed, 17 Jul 2024 14:24:47 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:24:47 GMT Message-Id: <202407171424.46HEOlKZ033559@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 1d0abfccc47f - stable/13 - cxgbetool(8): Be flexible about the nexus name. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 1d0abfccc47f7f70c6dfd12dc96768259babf1f6 Auto-Submitted: auto-generated The branch stable/13 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=1d0abfccc47f7f70c6dfd12dc96768259babf1f6 commit 1d0abfccc47f7f70c6dfd12dc96768259babf1f6 Author: Navdeep Parhar AuthorDate: 2024-06-13 20:17:55 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 07:18:12 +0000 cxgbetool(8): Be flexible about the nexus name. Use the name as-is but perform cxgbe specific ioctls on the device to make sure that it is a Terminator device nexus. Determine the chip type, pf/vf, etc. from the device registers rather than the nexus name. This allows cxgbetool to work with the VF driver. Sponsored by: Chelsio Communications (cherry picked from commit e827b61cacddd4bc9a2f1657ad8c6d2bcd70d52e) --- usr.sbin/cxgbetool/cxgbetool.c | 116 +++++++++++++++++++++++++++-------------- 1 file changed, 76 insertions(+), 40 deletions(-) diff --git a/usr.sbin/cxgbetool/cxgbetool.c b/usr.sbin/cxgbetool/cxgbetool.c index c02bc7fdc054..7b2b495a0292 100644 --- a/usr.sbin/cxgbetool/cxgbetool.c +++ b/usr.sbin/cxgbetool/cxgbetool.c @@ -43,6 +43,7 @@ #include #include #include +#include #include #include #include @@ -56,9 +57,16 @@ #define in_range(val, lo, hi) ( val < 0 || (val <= hi && val >= lo)) #define max(x, y) ((x) > (y) ? (x) : (y)) -static const char *progname, *nexus; -static int chip_id; /* 4 for T4, 5 for T5, and so on. */ -static int inst; /* instance of nexus device */ +static struct { + const char *progname, *nexus; + int chip_id; /* 4 for T4, 5 for T5, and so on. */ + int inst; /* instance of nexus device */ + int pf; /* PF# of the nexus (if not VF). */ + bool vf; /* Nexus is a VF. */ + + int fd; + bool warn_on_ioctl_err; +} g; struct reg_info { const char *name; @@ -88,7 +96,7 @@ struct field_desc { static void usage(FILE *fp) { - fprintf(fp, "Usage: %s [operation]\n", progname); + fprintf(fp, "Usage: %s [operation]\n", g.progname); fprintf(fp, "\tclearstats clear port statistics\n" "\tclip hold|release hold/release an address\n" @@ -137,27 +145,12 @@ get_card_vers(unsigned int version) static int real_doit(unsigned long cmd, void *data, const char *cmdstr) { - static int fd = -1; - int rc = 0; - - if (fd == -1) { - char buf[64]; - - snprintf(buf, sizeof(buf), "/dev/%s", nexus); - if ((fd = open(buf, O_RDWR)) < 0) { - warn("open(%s)", nexus); - rc = errno; - return (rc); - } - } - - rc = ioctl(fd, cmd, data); - if (rc < 0) { - warn("%s", cmdstr); - rc = errno; + if (ioctl(g.fd, cmd, data) < 0) { + if (g.warn_on_ioctl_err) + warn("%s", cmdstr); + return (errno); } - - return (rc); + return (0); } #define doit(x, y) real_doit(x, y, #x) @@ -523,7 +516,7 @@ dump_regs(int argc, const char *argv[]) rc = dump_regs_t6(argc, argv, regs.data); } else { warnx("%s (type %d, rev %d) is not a known card.", - nexus, vers, revision); + g.nexus, vers, revision); return (ENOTSUP); } @@ -915,7 +908,7 @@ do_show_one_filter_info(struct t4_filter *t, uint32_t mode) printf("(hash)"); } } - if (chip_id <= 5 && t->fs.prio) + if (g.chip_id <= 5 && t->fs.prio) printf(" Prio"); if (t->fs.rpttid) printf(" RptTID"); @@ -934,7 +927,7 @@ show_filters(int hash) if (rc != 0) return (rc); - if (!hash && chip_id >= 6) { + if (!hash && g.chip_id >= 6) { header = 0; bzero(&t, sizeof (t)); t.idx = 0; @@ -1925,10 +1918,10 @@ get_sge_context(int argc, const char *argv[]) if (rc != 0) return (rc); - if (chip_id == 4) + if (g.chip_id == 4) show_t4_ctxt(&cntxt); else - show_t5t6_ctxt(&cntxt, chip_id); + show_t5t6_ctxt(&cntxt, g.chip_id); return (0); } @@ -2244,7 +2237,7 @@ show_tcb(uint32_t *buf, uint32_t len) } printf("\n"); } - set_tcb_info(TIDTYPE_TCB, chip_id); + set_tcb_info(TIDTYPE_TCB, g.chip_id); set_print_style(PRNTSTYL_COMP); swizzle_tcb(tcb); parse_n_display_xcb(tcb); @@ -2448,7 +2441,7 @@ static void create_tracing_ifnet() { char *cmd[] = { - "/sbin/ifconfig", __DECONST(char *, nexus), "create", NULL + "/sbin/ifconfig", __DECONST(char *, g.nexus), "create", NULL }; char *env[] = {NULL}; @@ -3495,7 +3488,7 @@ display_clip(void) return (errno); } - snprintf(name, sizeof(name), "dev.t%unex.%u.misc.clip", chip_id, inst); + snprintf(name, sizeof(name), "dev.t%unex.%u.misc.clip", g.chip_id, g.inst); rc = sysctlbyname(name, buf, &clip_buf_size, NULL, 0); if (rc != 0) { warn("sysctl %s", name); @@ -3650,14 +3643,57 @@ run_cmd_loop(void) return (rc); } +#define A_PL_WHOAMI 0x19400 +#define A_PL_REV 0x1943c +#define A_PL_VF_WHOAMI 0x200 +#define A_PL_VF_REV 0x204 + static void -parse_nexus_name(const char *s) +open_nexus_device(const char *s) { - char junk; - - if (sscanf(s, "t%unex%u%c", &chip_id, &inst, &junk) != 2) - errx(EINVAL, "invalid nexus \"%s\"", s); - nexus = s; + const int len = strlen(s); + long long val; + const char *num; + int rc; + u_int chip_id, whoami; + char buf[128]; + + if (len < 2 || isdigit(s[0]) || !isdigit(s[len - 1])) + errx(1, "invalid nexus name \"%s\"", s); + for (num = s + len - 1; isdigit(*num); num--) + continue; + g.inst = strtoll(num, NULL, 0); + g.nexus = s; + snprintf(buf, sizeof(buf), "/dev/%s", g.nexus); + if ((g.fd = open(buf, O_RDWR)) < 0) + err(1, "open(%s)", buf); + + g.warn_on_ioctl_err = false; + rc = read_reg(A_PL_REV, 4, &val); + if (rc == 0) { + /* PF */ + g.vf = false; + whoami = A_PL_WHOAMI; + } else { + rc = read_reg(A_PL_VF_REV, 4, &val); + if (rc != 0) + errx(1, "%s is not a Terminator device.", s); + /* VF */ + g.vf = true; + whoami = A_PL_VF_WHOAMI; + } + chip_id = (val >> 4) & 0xf; + if (chip_id == 0) + chip_id = 4; + if (chip_id < 4 || chip_id > 7) + warnx("%s reports chip_id %d.", s, chip_id); + g.chip_id = chip_id; + + rc = read_reg(whoami, 4, &val); + if (rc != 0) + errx(rc, "failed to read whoami(0x%x): %d", whoami, rc); + g.pf = g.chip_id > 5 ? (val >> 9) & 7 : (val >> 8) & 7; + g.warn_on_ioctl_err = true; } int @@ -3665,7 +3701,7 @@ main(int argc, const char *argv[]) { int rc = -1; - progname = argv[0]; + g.progname = argv[0]; if (argc == 2) { if (!strcmp(argv[1], "-h") || !strcmp(argv[1], "--help")) { @@ -3679,7 +3715,7 @@ main(int argc, const char *argv[]) exit(EINVAL); } - parse_nexus_name(argv[1]); + open_nexus_device(argv[1]); /* progname and nexus */ argc -= 2; From nobody Wed Jul 17 14:24:48 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJ9X6tNDz5RPxH; Wed, 17 Jul 2024 14:24:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJ9X4Q0mz412Z; Wed, 17 Jul 2024 14:24:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226288; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=CZ77FX1vSx9gn/TpvIHvQZ6MSj7PNBzB7owXjhc44Ss=; b=GjgJEuA3Hf2wRb2vOBzmWpxy6xlUDRZoEAyW3XaUvxytYeUd2qztVpgxq67G+8lEFB6Ffq qAmTHQoXSp8lp2s3qDeljsdb4DGqeFOSyzAK7Ve5oYv9OklKsMQXI99uBEbWZTRPfolvFZ Z9PBTJhyFI6ve7CaVg20EkrUQnplHNXmUht1nTo/AbAK7ewotdWVk0noZL9i6eeqZtAL0t LdCFuVEyXCtq/cRYdIUkL0mgo198eqXqWaO9fk48cCh3yDRBTWALV5FWuEaPvb7MU6QYdu f9eWlmXm1K4VkkYhZqmw39ZQ1IpLh1AmBwwj28CV7AWWDRzTl2hxwYKTYEJZsg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226288; a=rsa-sha256; cv=none; b=gVrMvtCoSeRvdEjmvwKHtvd0ErOp8ZT67A6OvZ5whOPaCvh7GZUvlQEKuOKhTKpArJdZTj 5TMuHgKiK75txYK+DjSS7Vn9Vv0ctqBw05PtH4mXx3qhY7EQ+L2qVmKN1a9r1yy+o/QST8 9oaGB4k5GaMrzl0xIxsnwfiV6U6nmPhi86KiBmoGkE+ANfeT8G9XtvIhcKf/ms/TrVLQHM a6q3e9Ev2wBqprNZfedmSlFmuiX/OCxADn2seOv04Fbl/+BQ3oY5sIPhYKwYaHK9aTzUro tF3w3ISVYqK+Rcs3gOxzc7f314wKthGVhCmLN8V/6ZrRCLxZavr9UlCGpZeFkw== 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=1721226288; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=CZ77FX1vSx9gn/TpvIHvQZ6MSj7PNBzB7owXjhc44Ss=; b=rApdG0ZDhU/xQpIjR0N2wDDAhWPeTz+lp7AiDh+9LvqU2EDJ34RW4fUT6Eh7vhBtltsSK7 JbFrH4+KV3EY5qnzCHFoPOom6Z+y3bgwfmHasB0MbRDDyUdhps8r1CGlXEWZO5xi/+RzVU Zc5t2S6SFl4lRJfok2fGjE4HzobqDXE384OS9ybc6nfN9xNJGKTC3GOzub7HmafcTE+OCG Kpfh3CsDmkLC2R05jcfI3w8ihw9RNG6RErp7XKJ8rXyUtxt+fWSP6soYFSgUGNGJo/xR5u kkSsDJclYHo5x2ZE/Zr5Fkz2A/z3KFoXrTYaofNTwbq5HQK1uvHxUYCTH/hu1g== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPJ9X42NTz1Mb3; Wed, 17 Jul 2024 14:24:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HEOmiG033619; Wed, 17 Jul 2024 14:24:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HEOmaq033616; Wed, 17 Jul 2024 14:24:48 GMT (envelope-from git) Date: Wed, 17 Jul 2024 14:24:48 GMT Message-Id: <202407171424.46HEOmaq033616@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: dd0bb5ba4257 - stable/13 - cxgbe(4): Do not report link state change during interface detach. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: dd0bb5ba4257e814ff39b9d7e0321af4b0f82fc5 Auto-Submitted: auto-generated The branch stable/13 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=dd0bb5ba4257e814ff39b9d7e0321af4b0f82fc5 commit dd0bb5ba4257e814ff39b9d7e0321af4b0f82fc5 Author: Navdeep Parhar AuthorDate: 2024-07-03 19:01:33 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 07:18:27 +0000 cxgbe(4): Do not report link state change during interface detach. This fixes a panic when multiple VIs are configured on an interface and only the non-primary VI is up at the time of driver detach. The problem was that the driver would queue a link state change notification for an interface about to be freed. To reproduce the panic, add "hw.cxgbe.num_vis=2" to loader.conf and # kldload if_cxgbe # ifconfig vcc0 up # devctl detach t6nex0 trap 0x9, rip = 0xffffffff8107db70, rsp = 0xfffffe0055263d60, rbp = 0xfffffe0055263dd0 taskqueue_run_locked() at taskqueue_run_locked+0x2a0/frame 0xfffffe0055263dd0 taskqueue_run() at taskqueue_run+0x72/frame 0xfffffe0055263df0 taskqueue_swi_run() at taskqueue_swi_run+0x18/frame 0xfffffe0055263e10 intr_event_execute_handlers() at intr_event_execute_handlers+0x249/frame 0xfffffe0055263e50 ithread_execute_handlers() at ithread_execute_handlers+0x9e/frame 0xfffffe0055263e70 Reviewed by: jhb Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D45864 (cherry picked from commit dc20d49aa939caea365cbdf0341b00de69253be4) --- sys/dev/cxgbe/t4_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c index 842eb87e9126..7f949ad8e66c 100644 --- a/sys/dev/cxgbe/t4_main.c +++ b/sys/dev/cxgbe/t4_main.c @@ -12399,7 +12399,7 @@ t4_os_link_changed(struct port_info *pi) for_each_vi(pi, v, vi) { ifp = vi->ifp; - if (ifp == NULL) + if (ifp == NULL || IS_DETACHING(vi)) continue; if (lc->link_ok) { From nobody Wed Jul 17 14:25:41 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPJBZ6cThz5RQ07; Wed, 17 Jul 2024 14:25:42 +0000 (UTC) (envelope-from jhb@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 "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPJBZ18lQz4447; Wed, 17 Jul 2024 14:25:42 +0000 (UTC) (envelope-from jhb@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721226342; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=fBcb49d5Xj1ak5M/BXSteHM/q5CWJonmj5Sk7GvFsDk=; b=SsZFYwNoM9bCxMmKMySAqb+Jsh9j5l1oUfCtKZ+/5V2gYlqPZJLjP/Jk3AW7icJJxqNDsQ SrPkn87QdZtRJTZnybNOUtR4g67FPROWhFDTYnQqnPOc5SzggCfJjamf8M2QpLz28oeXLD XCTAKZCIUqBQL264Oxo+NwS1sgAc/+kgJhnAdgxIfxCTR34cRHKbxxtd2yUtkMa7J/iY/V fTkLDOf37hapOMRqfhPBRxwv/7mAq7eZ0OHoXo0gm6tAa6tPwoCWdxRStBhvtd4yg20jj2 71DaJjNPgBXPpbtWj7NQkNWHoUXrQoB0Qo0o/++6r03pNa9rlvkmO/J+bEGfxg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721226342; a=rsa-sha256; cv=none; b=QS6b8JjUT9dAGbRQlHYk03JnEZi4CaE6NN5GynYb3PXv69L/dDHrK0o4dn4D1GGsqpPmnb AwGvnPQ+Obrl/Md7mL4wWuAYdGUJlC6ioYLIL78P+1CP0hcTjWSC8s119Vz1ECvTVQ9ZgJ TQHI968RZI9mBjgLnlP8m8zoqmrEeUAFX+CxRRq5EHVZ6xgqxPIqCP+soSooha5YYjDe9P TUJdVPh97AwRDpUaqNtZYCoI73J1xax1aMxr02rU+Wqy2L9fPaenvJEC1dtBi9Q2BBJmZL DARSlyAqxgEz08GTSnEyYopPuNxOPDjm7+wacthnw9ZaxiWp7CBz4kuq8GFZ4Q== 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=1721226342; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=fBcb49d5Xj1ak5M/BXSteHM/q5CWJonmj5Sk7GvFsDk=; b=j6178l/jgGqIxvItvIN9WdRP0G6OY+U9mUCyQwB10ruEDwtcubE+r+x2WXErmApiJJ9Btw LjQ/wWZG5tUM2D3bXuIwtNEuWhrG0Ox41oNh+o34XN6YFptm6hahM6S5MhkaL4USXj/SSR 9K4CcZCe6boEIeb/ceAu0It92XLrGO52berpScMtEp3ulhsSl6+vWm1fxxefF+9Ehmg09g aeUb5cnNT69gEwhDr6oTRL7zJ1YCuHGUraKqBD8Bb2kto7SctjvemrRLlYLWIIn9jo/YLr ui8+wiaK2p8H1fMLXclQeruJn9yLkDNAYg/NitU2zrgeaPBf3zOs0iCR+sIOEg== Received: from [IPV6:2601:5c0:4200:b830:692e:5caf:134a:ed7b] (unknown [IPv6:2601:5c0:4200:b830:692e:5caf:134a:ed7b]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: jhb) by smtp.freebsd.org (Postfix) with ESMTPSA id 4WPJBY6LBRz1Kbh; Wed, 17 Jul 2024 14:25:41 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Message-ID: <4daa2b3e-3d6e-4e85-aa28-72d99271b70a@FreeBSD.org> Date: Wed, 17 Jul 2024 10:25:41 -0400 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: git: c24e5fcca9c2 - main - mvs: Fix to use rman_get_rid rather than non-existent rid argument Content-Language: en-US To: Jessica Clarke , src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org References: <202407171300.46HD0AHq085043@gitrepo.freebsd.org> From: John Baldwin In-Reply-To: <202407171300.46HD0AHq085043@gitrepo.freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 7/17/24 09:00, Jessica Clarke wrote: > The branch main has been updated by jrtc27: > > URL: https://cgit.FreeBSD.org/src/commit/?id=c24e5fcca9c2f2cacaf3d7883f0ecb4d5a4747cc > > commit c24e5fcca9c2f2cacaf3d7883f0ecb4d5a4747cc > Author: Jessica Clarke > AuthorDate: 2024-07-17 12:59:13 +0000 > Commit: Jessica Clarke > CommitDate: 2024-07-17 12:59:13 +0000 > > mvs: Fix to use rman_get_rid rather than non-existent rid argument > > This got missed as it's not built in a normal tinderbox build. > > This fixes building arm.armv7 ARMADAXP (marked NO_UNIVERSE). > > Fixes: 9dbf5b0e6876 ("new-bus: Remove the 'rid' and 'type' arguments from BUS_RELEASE_RESOURCE") Oops, thanks -- John Baldwin From nobody Wed Jul 17 15:35:13 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPKkp0fH4z5RWHp; Wed, 17 Jul 2024 15:35: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPKkp0MQSz49th; Wed, 17 Jul 2024 15:35:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721230514; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Z6j0I/HRyaSrjeOHbagUJjjksfIZ60cNCQ1JbJHhl/E=; b=v5n/lUD5i/K/pk2DuhrVu7qKFgx6VW3tdpbbiNTu7LZG1efFPJrS986z90W3urDmFGFvXG kwo3C+EKv65PRcC5zYv3tNz0uYRtUssuhgM+aeCNGRI3Gmf/WxCZ0YWr/CQfkRS9g0861l +t8rnAiFcfsz8CtE9vzsPdAzhWof5p0Q8TNRuhmPztCPXQybcPD3C+p8zSqCnHoF8Jxtpu sNUcLfaCXkfNjeWardAVWPJfK1zb2ZaBFaMnwPtAx71aNi+q72LrX9qRSpeUTNrxQcAyH5 DZNo9wMtze65k/3XJJ5/cBYCFdPMawMZdZLpDoZSYQbSfg75WHQWXNk3/Aj+og== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721230514; a=rsa-sha256; cv=none; b=bvVOZmm2kQaii6/ikNbpDqpaWn+JHHan5VZ6FMZAV0HUK32gvBxPw7jl7RHcSuDs0hdVuG 2e9u2cTLc4tAreD3hJrDOsTX3HBHgno2uVJmY+9lmTVDqPz44Ge8Y+Dsr9PRUAaiM166SZ ZCdXhYx1tKAzCPEdBSCSp0lWKcsM1ir/Ox+NlNy4FgPRzL/LNXnI83R9v3Jpw4jO9YcRpl bHyOPAEpyF2mWh3RWVM9Ja2Oickq4aNpIubJhSH5+rk5gu884m+DKc2NL2tUaUnTPYMRiJ 6iGt3oNgpXhvBucsLB1IuD409earCorqvzpolJcSxn9vavGXNczG+e3Y8EF2Zg== 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=1721230514; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Z6j0I/HRyaSrjeOHbagUJjjksfIZ60cNCQ1JbJHhl/E=; b=DSgIUd2LKKi9tZk/Q4uGu2wzHbHNYTgYX573gN8wp1KjZy2guJd6btzCu+JQKp6u/+HSUc Fef+naO0cPXyJXZFxLQBw/HjCF6rcxPCnBjza+lF6CykssY/I5zUmeYasPhjFX7PX+BIqQ jIZm+0Tu3ekpw8+06p4p+FiXJV6gP0o0wgBrudJ3nfwmwTNLdagPpx8oRHpZrueBFXEeVP x4d6Vo9nFV9sn6wGbW6VYN9ylum7eP5sZtGmCVEDeM1+voc4z8JPUtEj3gysoKZZXxtoc6 dVq9FlkI+8MVTAJxheCszcZa4s4/neWplBZM8h6qYb7ABRC67K0N3Lbwg6CyHw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPKkn74Pfz1P6y; Wed, 17 Jul 2024 15:35:13 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HFZDqv052716; Wed, 17 Jul 2024 15:35:13 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HFZD1J052713; Wed, 17 Jul 2024 15:35:13 GMT (envelope-from git) Date: Wed, 17 Jul 2024 15:35:13 GMT Message-Id: <202407171535.46HFZD1J052713@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: 271f14695564 - main - pf: vnet-ify pf_hashsize, pf_hashmask, pf_srchashsize and V_pf_srchashmask List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 271f146955641857c93705b5b1916b8004e5623c Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=271f146955641857c93705b5b1916b8004e5623c commit 271f146955641857c93705b5b1916b8004e5623c Author: Kristof Provost AuthorDate: 2024-07-17 13:52:13 +0000 Commit: Kristof Provost CommitDate: 2024-07-17 14:00:49 +0000 pf: vnet-ify pf_hashsize, pf_hashmask, pf_srchashsize and V_pf_srchashmask These variables are tunables, so in principle they never change at runtime. That would mean they don't need to be tracked per-vnet. However, they both can be decreased (back to their default values) if the memory allocations for their respective tables fail, and these allocations are per-vnet. That is, it's possible for a few vnets to be started and have the tuned size for the hash and srchash tables only to have later vnets fail the initial allocation and fall back to smaller allocations. That would confuse the previously created vnets (because their actual table size and size/mask variables would no longer match). Avoid this by turning these into per-vnet variables. MFC after: 1 week Sponsored by: Rubicon Communications, LLC ("Netgate") --- sys/net/pfvar.h | 8 +++-- sys/netpfil/pf/if_pfsync.c | 12 +++++--- sys/netpfil/pf/pf.c | 74 ++++++++++++++++++++++++---------------------- sys/netpfil/pf/pf_ioctl.c | 22 +++++++------- sys/netpfil/pf/pf_nl.c | 4 +-- 5 files changed, 64 insertions(+), 56 deletions(-) diff --git a/sys/net/pfvar.h b/sys/net/pfvar.h index aa6dd52a7e69..b38a1bebcc1f 100644 --- a/sys/net/pfvar.h +++ b/sys/net/pfvar.h @@ -2125,8 +2125,10 @@ struct pf_idhash { }; extern u_long pf_ioctl_maxcount; -extern u_long pf_hashmask; -extern u_long pf_srchashmask; +VNET_DECLARE(u_long, pf_hashmask); +#define V_pf_hashmask VNET(pf_hashmask) +VNET_DECLARE(u_long, pf_srchashmask); +#define V_pf_srchashmask VNET(pf_srchashmask) #define PF_HASHSIZ (131072) #define PF_SRCHASHSIZ (PF_HASHSIZ/4) VNET_DECLARE(struct pf_keyhash *, pf_keyhash); @@ -2136,7 +2138,7 @@ VNET_DECLARE(struct pf_idhash *, pf_idhash); VNET_DECLARE(struct pf_srchash *, pf_srchash); #define V_pf_srchash VNET(pf_srchash) -#define PF_IDHASH(s) (be64toh((s)->id) % (pf_hashmask + 1)) +#define PF_IDHASH(s) (be64toh((s)->id) % (V_pf_hashmask + 1)) VNET_DECLARE(void *, pf_swi_cookie); #define V_pf_swi_cookie VNET(pf_swi_cookie) diff --git a/sys/netpfil/pf/if_pfsync.c b/sys/netpfil/pf/if_pfsync.c index 67011d16c788..82a42c874a8f 100644 --- a/sys/netpfil/pf/if_pfsync.c +++ b/sys/netpfil/pf/if_pfsync.c @@ -979,7 +979,7 @@ pfsync_in_clr(struct mbuf *m, int offset, int count, int flags, int action) pfi_kkif_find(clr[i].ifname) == NULL) continue; - for (int i = 0; i <= pf_hashmask; i++) { + for (int i = 0; i <= V_pf_hashmask; i++) { struct pf_idhash *ih = &V_pf_idhash[i]; struct pf_kstate *s; relock: @@ -2080,7 +2080,11 @@ pfsync_defer_tmo(void *arg) struct pfsync_softc *sc = pd->pd_sc; struct mbuf *m = pd->pd_m; struct pf_kstate *st = pd->pd_st; - struct pfsync_bucket *b = pfsync_get_bucket(sc, st); + struct pfsync_bucket *b; + + CURVNET_SET(sc->sc_ifp->if_vnet); + + b = pfsync_get_bucket(sc, st); PFSYNC_BUCKET_LOCK_ASSERT(b); @@ -2093,11 +2097,11 @@ pfsync_defer_tmo(void *arg) if (sc->sc_sync_if == NULL) { pf_release_state(st); m_freem(m); + CURVNET_RESTORE(); return; } NET_EPOCH_ENTER(et); - CURVNET_SET(sc->sc_sync_if->if_vnet); pfsync_tx(sc, m); @@ -2483,7 +2487,7 @@ pfsync_bulk_update(void *arg) else i = sc->sc_bulk_hashid; - for (; i <= pf_hashmask; i++) { + for (; i <= V_pf_hashmask; i++) { struct pf_idhash *ih = &V_pf_idhash[i]; if (s != NULL) diff --git a/sys/netpfil/pf/pf.c b/sys/netpfil/pf/pf.c index 764d2fa54179..dfa87b515cd1 100644 --- a/sys/netpfil/pf/pf.c +++ b/sys/netpfil/pf/pf.c @@ -486,16 +486,18 @@ VNET_DEFINE(struct pf_srchash *, pf_srchash); SYSCTL_NODE(_net, OID_AUTO, pf, CTLFLAG_RW | CTLFLAG_MPSAFE, 0, "pf(4)"); -u_long pf_hashmask; -u_long pf_srchashmask; -static u_long pf_hashsize; -static u_long pf_srchashsize; +VNET_DEFINE(u_long, pf_hashmask); +VNET_DEFINE(u_long, pf_srchashmask); +VNET_DEFINE_STATIC(u_long, pf_hashsize); +#define V_pf_hashsize VNET(pf_hashsize) +VNET_DEFINE_STATIC(u_long, pf_srchashsize); +#define V_pf_srchashsize VNET(pf_srchashsize) u_long pf_ioctl_maxcount = 65535; -SYSCTL_ULONG(_net_pf, OID_AUTO, states_hashsize, CTLFLAG_RDTUN, - &pf_hashsize, 0, "Size of pf(4) states hashtable"); -SYSCTL_ULONG(_net_pf, OID_AUTO, source_nodes_hashsize, CTLFLAG_RDTUN, - &pf_srchashsize, 0, "Size of pf(4) source nodes hashtable"); +SYSCTL_ULONG(_net_pf, OID_AUTO, states_hashsize, CTLFLAG_VNET | CTLFLAG_RDTUN, + &VNET_NAME(pf_hashsize), 0, "Size of pf(4) states hashtable"); +SYSCTL_ULONG(_net_pf, OID_AUTO, source_nodes_hashsize, CTLFLAG_VNET | CTLFLAG_RDTUN, + &VNET_NAME(pf_srchashsize), 0, "Size of pf(4) source nodes hashtable"); SYSCTL_ULONG(_net_pf, OID_AUTO, request_maxcount, CTLFLAG_RWTUN, &pf_ioctl_maxcount, 0, "Maximum number of tables, addresses, ... in a single ioctl() call"); @@ -662,7 +664,7 @@ pf_hashkey(const struct pf_state_key *sk) sizeof(struct pf_state_key_cmp)/sizeof(uint32_t), V_pf_hashseed); - return (h & pf_hashmask); + return (h & V_pf_hashmask); } static __inline uint32_t @@ -683,7 +685,7 @@ pf_hashsrc(struct pf_addr *addr, sa_family_t af) panic("%s: unknown address family %u", __func__, af); } - return (h & pf_srchashmask); + return (h & V_pf_srchashmask); } #ifdef ALTQ @@ -885,7 +887,7 @@ pf_overload_task(void *v, int pending) return; } - for (int i = 0; i <= pf_hashmask; i++) { + for (int i = 0; i <= V_pf_hashmask; i++) { struct pf_idhash *ih = &V_pf_idhash[i]; struct pf_state_key *sk; struct pf_kstate *s; @@ -1075,10 +1077,10 @@ pf_initialize(void) struct pf_srchash *sh; u_int i; - if (pf_hashsize == 0 || !powerof2(pf_hashsize)) - pf_hashsize = PF_HASHSIZ; - if (pf_srchashsize == 0 || !powerof2(pf_srchashsize)) - pf_srchashsize = PF_SRCHASHSIZ; + if (V_pf_hashsize == 0 || !powerof2(V_pf_hashsize)) + V_pf_hashsize = PF_HASHSIZ; + if (V_pf_srchashsize == 0 || !powerof2(V_pf_srchashsize)) + V_pf_srchashsize = PF_SRCHASHSIZ; V_pf_hashseed = arc4random(); @@ -1093,26 +1095,26 @@ pf_initialize(void) sizeof(struct pf_state_key), pf_state_key_ctor, NULL, NULL, NULL, UMA_ALIGN_PTR, 0); - V_pf_keyhash = mallocarray(pf_hashsize, sizeof(struct pf_keyhash), + V_pf_keyhash = mallocarray(V_pf_hashsize, sizeof(struct pf_keyhash), M_PFHASH, M_NOWAIT | M_ZERO); - V_pf_idhash = mallocarray(pf_hashsize, sizeof(struct pf_idhash), + V_pf_idhash = mallocarray(V_pf_hashsize, sizeof(struct pf_idhash), M_PFHASH, M_NOWAIT | M_ZERO); if (V_pf_keyhash == NULL || V_pf_idhash == NULL) { printf("pf: Unable to allocate memory for " - "state_hashsize %lu.\n", pf_hashsize); + "state_hashsize %lu.\n", V_pf_hashsize); free(V_pf_keyhash, M_PFHASH); free(V_pf_idhash, M_PFHASH); - pf_hashsize = PF_HASHSIZ; - V_pf_keyhash = mallocarray(pf_hashsize, + V_pf_hashsize = PF_HASHSIZ; + V_pf_keyhash = mallocarray(V_pf_hashsize, sizeof(struct pf_keyhash), M_PFHASH, M_WAITOK | M_ZERO); - V_pf_idhash = mallocarray(pf_hashsize, + V_pf_idhash = mallocarray(V_pf_hashsize, sizeof(struct pf_idhash), M_PFHASH, M_WAITOK | M_ZERO); } - pf_hashmask = pf_hashsize - 1; - for (i = 0, kh = V_pf_keyhash, ih = V_pf_idhash; i <= pf_hashmask; + V_pf_hashmask = V_pf_hashsize - 1; + for (i = 0, kh = V_pf_keyhash, ih = V_pf_idhash; i <= V_pf_hashmask; i++, kh++, ih++) { mtx_init(&kh->lock, "pf_keyhash", NULL, MTX_DEF | MTX_DUPOK); mtx_init(&ih->lock, "pf_idhash", NULL, MTX_DEF); @@ -1126,19 +1128,19 @@ pf_initialize(void) uma_zone_set_max(V_pf_sources_z, PFSNODE_HIWAT); uma_zone_set_warning(V_pf_sources_z, "PF source nodes limit reached"); - V_pf_srchash = mallocarray(pf_srchashsize, + V_pf_srchash = mallocarray(V_pf_srchashsize, sizeof(struct pf_srchash), M_PFHASH, M_NOWAIT | M_ZERO); if (V_pf_srchash == NULL) { printf("pf: Unable to allocate memory for " - "source_hashsize %lu.\n", pf_srchashsize); + "source_hashsize %lu.\n", V_pf_srchashsize); - pf_srchashsize = PF_SRCHASHSIZ; - V_pf_srchash = mallocarray(pf_srchashsize, + V_pf_srchashsize = PF_SRCHASHSIZ; + V_pf_srchash = mallocarray(V_pf_srchashsize, sizeof(struct pf_srchash), M_PFHASH, M_WAITOK | M_ZERO); } - pf_srchashmask = pf_srchashsize - 1; - for (i = 0, sh = V_pf_srchash; i <= pf_srchashmask; i++, sh++) + V_pf_srchashmask = V_pf_srchashsize - 1; + for (i = 0, sh = V_pf_srchash; i <= V_pf_srchashmask; i++, sh++) mtx_init(&sh->lock, "pf_srchash", NULL, MTX_DEF); /* ALTQ */ @@ -1177,7 +1179,7 @@ pf_cleanup(void) struct pf_send_entry *pfse, *next; u_int i; - for (i = 0, kh = V_pf_keyhash, ih = V_pf_idhash; i <= pf_hashmask; + for (i = 0, kh = V_pf_keyhash, ih = V_pf_idhash; i <= V_pf_hashmask; i++, kh++, ih++) { KASSERT(LIST_EMPTY(&kh->keys), ("%s: key hash not empty", __func__)); @@ -1189,7 +1191,7 @@ pf_cleanup(void) free(V_pf_keyhash, M_PFHASH); free(V_pf_idhash, M_PFHASH); - for (i = 0, sh = V_pf_srchash; i <= pf_srchashmask; i++, sh++) { + for (i = 0, sh = V_pf_srchash; i <= V_pf_srchashmask; i++, sh++) { KASSERT(LIST_EMPTY(&sh->nodes), ("%s: source node hash not empty", __func__)); mtx_destroy(&sh->lock); @@ -1589,7 +1591,7 @@ pf_find_state_byid(uint64_t id, uint32_t creatorid) pf_counter_u64_add(&V_pf_status.fcounters[FCNT_STATE_SEARCH], 1); - ih = &V_pf_idhash[(be64toh(id) % (pf_hashmask + 1))]; + ih = &V_pf_idhash[(be64toh(id) % (V_pf_hashmask + 1))]; PF_HASHROW_LOCK(ih); LIST_FOREACH(s, &ih->states, entry) @@ -1981,7 +1983,7 @@ pf_purge_thread(void *unused __unused) * table every run. */ V_pf_purge_idx = - pf_purge_expired_states(V_pf_purge_idx, pf_hashmask / + pf_purge_expired_states(V_pf_purge_idx, V_pf_hashmask / (V_pf_default_rule.timeout[PFTM_INTERVAL] * 10)); /* @@ -2026,7 +2028,7 @@ pf_unload_vnet_purge(void) /* * Now purge everything. */ - pf_purge_expired_states(0, pf_hashmask); + pf_purge_expired_states(0, V_pf_hashmask); pf_purge_fragments(UINT_MAX); pf_purge_expired_src_nodes(); @@ -2086,7 +2088,7 @@ pf_purge_expired_src_nodes(void) int i; LIST_INIT(&freelist); - for (i = 0, sh = V_pf_srchash; i <= pf_srchashmask; i++, sh++) { + for (i = 0, sh = V_pf_srchash; i <= V_pf_srchashmask; i++, sh++) { PF_HASHROW_LOCK(sh); LIST_FOREACH_SAFE(cur, &sh->nodes, entry, next) if (cur->states == 0 && cur->expire <= time_uptime) { @@ -2261,7 +2263,7 @@ relock: SDT_PROBE2(pf, purge, state, rowcount, i, count); /* Return when we hit end of hash. */ - if (++i > pf_hashmask) { + if (++i > V_pf_hashmask) { V_pf_status.states = uma_zone_get_cur(V_pf_state_z); return (0); } diff --git a/sys/netpfil/pf/pf_ioctl.c b/sys/netpfil/pf/pf_ioctl.c index 2df6bcd30533..f5a216666076 100644 --- a/sys/netpfil/pf/pf_ioctl.c +++ b/sys/netpfil/pf/pf_ioctl.c @@ -3778,7 +3778,7 @@ DIOCCHANGERULE_error: sizeof(struct pfsync_state_1301), M_TEMP, M_WAITOK | M_ZERO); nr = 0; - for (i = 0; i <= pf_hashmask; i++) { + for (i = 0; i <= V_pf_hashmask; i++) { struct pf_idhash *ih = &V_pf_idhash[i]; DIOCGETSTATES_retry: @@ -3857,7 +3857,7 @@ DIOCGETSTATES_full: sizeof(struct pf_state_export), M_TEMP, M_WAITOK | M_ZERO); nr = 0; - for (i = 0; i <= pf_hashmask; i++) { + for (i = 0; i <= V_pf_hashmask; i++) { struct pf_idhash *ih = &V_pf_idhash[i]; DIOCGETSTATESV2_retry: @@ -5363,7 +5363,7 @@ DIOCCHANGEADDR_error: struct pf_src_node *p, *pstore; uint32_t i, nr = 0; - for (i = 0, sh = V_pf_srchash; i <= pf_srchashmask; + for (i = 0, sh = V_pf_srchash; i <= V_pf_srchashmask; i++, sh++) { PF_HASHROW_LOCK(sh); LIST_FOREACH(n, &sh->nodes, entry) @@ -5382,7 +5382,7 @@ DIOCCHANGEADDR_error: nr = 0; p = pstore = malloc(psn->psn_len, M_TEMP, M_WAITOK | M_ZERO); - for (i = 0, sh = V_pf_srchash; i <= pf_srchashmask; + for (i = 0, sh = V_pf_srchash; i <= V_pf_srchashmask; i++, sh++) { PF_HASHROW_LOCK(sh); LIST_FOREACH(n, &sh->nodes, entry) { @@ -5854,7 +5854,7 @@ pf_clear_all_states(void) u_int i; NET_EPOCH_ENTER(et); - for (i = 0; i <= pf_hashmask; i++) { + for (i = 0; i <= V_pf_hashmask; i++) { struct pf_idhash *ih = &V_pf_idhash[i]; relock: PF_HASHROW_LOCK(ih); @@ -5891,7 +5891,7 @@ pf_clear_srcnodes(struct pf_ksrc_node *n) struct pf_kstate *s; int i; - for (i = 0; i <= pf_hashmask; i++) { + for (i = 0; i <= V_pf_hashmask; i++) { struct pf_idhash *ih = &V_pf_idhash[i]; PF_HASHROW_LOCK(ih); @@ -5907,7 +5907,7 @@ pf_clear_srcnodes(struct pf_ksrc_node *n) if (n == NULL) { struct pf_srchash *sh; - for (i = 0, sh = V_pf_srchash; i <= pf_srchashmask; + for (i = 0, sh = V_pf_srchash; i <= V_pf_srchashmask; i++, sh++) { PF_HASHROW_LOCK(sh); LIST_FOREACH(n, &sh->nodes, entry) { @@ -5929,7 +5929,7 @@ pf_kill_srcnodes(struct pfioc_src_node_kill *psnk) struct pf_ksrc_node_list kill; LIST_INIT(&kill); - for (int i = 0; i <= pf_srchashmask; i++) { + for (int i = 0; i <= V_pf_srchashmask; i++) { struct pf_srchash *sh = &V_pf_srchash[i]; struct pf_ksrc_node *sn, *tmp; @@ -5950,7 +5950,7 @@ pf_kill_srcnodes(struct pfioc_src_node_kill *psnk) PF_HASHROW_UNLOCK(sh); } - for (int i = 0; i <= pf_hashmask; i++) { + for (int i = 0; i <= V_pf_hashmask; i++) { struct pf_idhash *ih = &V_pf_idhash[i]; struct pf_kstate *s; @@ -6013,7 +6013,7 @@ pf_clear_states(const struct pf_kstate_kill *kill) NET_EPOCH_ASSERT(); - for (unsigned int i = 0; i <= pf_hashmask; i++) { + for (unsigned int i = 0; i <= V_pf_hashmask; i++) { struct pf_idhash *ih = &V_pf_idhash[i]; relock_DIOCCLRSTATES: @@ -6088,7 +6088,7 @@ pf_killstates(struct pf_kstate_kill *kill, unsigned int *killed) return; } - for (unsigned int i = 0; i <= pf_hashmask; i++) + for (unsigned int i = 0; i <= V_pf_hashmask; i++) *killed += pf_killstates_row(kill, &V_pf_idhash[i]); } diff --git a/sys/netpfil/pf/pf_nl.c b/sys/netpfil/pf/pf_nl.c index e855815dd73b..6c98a50d8e06 100644 --- a/sys/netpfil/pf/pf_nl.c +++ b/sys/netpfil/pf/pf_nl.c @@ -231,7 +231,7 @@ handle_dumpstates(struct nlpcb *nlp, struct nl_parsed_state *attrs, hdr->nlmsg_flags |= NLM_F_MULTI; - for (int i = 0; i <= pf_hashmask; i++) { + for (int i = 0; i <= V_pf_hashmask; i++) { struct pf_idhash *ih = &V_pf_idhash[i]; struct pf_kstate *s; @@ -346,7 +346,7 @@ pf_handle_getcreators(struct nlmsghdr *hdr, struct nl_pstate *npt) bzero(creators, sizeof(creators)); - for (int i = 0; i < pf_hashmask; i++) { + for (int i = 0; i < V_pf_hashmask; i++) { struct pf_idhash *ih = &V_pf_idhash[i]; struct pf_kstate *s; From nobody Wed Jul 17 15:35:15 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPKkq26lFz5RWCZ; Wed, 17 Jul 2024 15:35: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPKkq13q7z4C8c; Wed, 17 Jul 2024 15:35:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721230515; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=mRmBJ4J/X1XzpMHF3ao/NoYI7Ewvm0mD4cbHYMP2Y4Y=; b=cvLFBEit5wALm5vfh1JtLvN0I1+iJl2ukkoeZA9eLJFdab8TwxjdKorCgOGuR7OyAWx41W 2DRMCbJd/dBpPFWIJfFr7gKXPfV9EmMkxXlmQ47q5KWtyVoFQeLbHG5eoIrmnaY6oIpCBG RP45Fur2Iaq5IEcIhGrP09KJ7Aq8IVBNl7BIcngKiAFZv835vUvMvJfQgn4Vdg5zqz4sCG MflxyqpAql3Z15unOxBaBfOjEBh3yi97GZ8N4hzR5UHPhD5FrZrXIyrtyQuipm4+d8Ndbv q3Jx6Leqgr5ahUf/I76vQxdX6qzExYVwSdUfD9k2FyQEPqTJ2X85LNPdej0z2Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721230515; a=rsa-sha256; cv=none; b=FMLNLBJOnQj6ozph8LolFL4CcnZYK/AFimi8QDQSgWhnuKuTwNkjYW8zEMqMNRQ+7r2f4j 5BZNPgmxvEGoP+rz7AJpqnTnsmNwWZgJHF3FN1IEdALAXknWBOszUn9h0N3stqUaogxKQM DjOa/X0LYTfZFHZg9D1UBBJCn38+TDligKv7UL82UV6SoxGV5WEiAEN+FeTbx3OsNiF0y3 VIeLe7zKQ8zM2761HJcgLOuqhuzZiloQeRNlJyxhdBTmJRYOIlGQbe90mPImE0n+3cBK9J l7uwTlLNe4vkdSxF8Qo+biDmMMncJW/9o7zv9yXtHFZh/dfET19WcQ3VJ4nG0A== 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=1721230515; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=mRmBJ4J/X1XzpMHF3ao/NoYI7Ewvm0mD4cbHYMP2Y4Y=; b=uFIpo91oiZJX9PxFdwstmRkl5W8hYAJLIphifb65tQ2z9GKtFXoOmdrmZhs7wRJAu8Hpq3 Iorr76Ws9eoGFfvOBRg2Vf8rllkfGlUEJSjIXzYDBEQGZTIBnc7NBiHOhdYv9zgREn5uC4 +xrUyfRVyTbbEvZpBd05Ac7W/tIAQ8vfbrD1CzYmLq2MN6zEWTEgXwe0gT1JUH6vmntQmK 1x4HqEvhtU03LwF1SG3+nYd8vGWeHpg7SrQGdnRJE4Xjmh5db/3eF/Eo0JK3V5Zv6N9wDt t3//Ps8hXcVnBwhLdm1f94SFUn9aFQBqXhVEWgJDBwF/hRKlvL5jU/NmHGh4sg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPKkq0dc1z1Phw; Wed, 17 Jul 2024 15:35:15 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HFZFF2052765; Wed, 17 Jul 2024 15:35:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HFZFoC052762; Wed, 17 Jul 2024 15:35:15 GMT (envelope-from git) Date: Wed, 17 Jul 2024 15:35:15 GMT Message-Id: <202407171535.46HFZFoC052762@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: fe0c82a603ce - main - pf tests: fix sctp:timeout test List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: fe0c82a603ce069786ee81604315f499fd965546 Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=fe0c82a603ce069786ee81604315f499fd965546 commit fe0c82a603ce069786ee81604315f499fd965546 Author: Kristof Provost AuthorDate: 2024-07-17 13:56:49 +0000 Commit: Kristof Provost CommitDate: 2024-07-17 14:01:24 +0000 pf tests: fix sctp:timeout test The test body somehow wound up in the cleanup function. MFC after: 1 week Sponsored by: Rubicon Communications, LLC ("Netgate") --- tests/sys/netpfil/pf/sctp.sh | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/tests/sys/netpfil/pf/sctp.sh b/tests/sys/netpfil/pf/sctp.sh index c3e1301238b0..d07d1122048b 100644 --- a/tests/sys/netpfil/pf/sctp.sh +++ b/tests/sys/netpfil/pf/sctp.sh @@ -666,11 +666,6 @@ timeout_head() timeout_body() { sctp_init -} - -timeout_cleanup() -{ - pft_cleanup vnet_mkjail timeout @@ -687,6 +682,11 @@ timeout_cleanup() jexec timeout pfctl -st } +timeout_cleanup() +{ + pft_cleanup +} + atf_init_test_cases() { atf_add_test_case "basic_v4" From nobody Wed Jul 17 18:19:49 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPPNj4JRLz5Rr9s; Wed, 17 Jul 2024 18:19: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPPNj3bqBz4SrR; Wed, 17 Jul 2024 18:19:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721240389; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=EjX9c4CIg6X0eNfHA8mLLUVoYZd7H0073lcRJkBD/NI=; b=U9Lfo+hjm3hTr8P2KUhJ2vq4dEEnSZoLZqLUCvUB53TV7p4PS7aOS2wpu5ZV955/xprr3l VoTw9xvwVJsA5XzKCz40dBsTILuNLfQr3xvO2mS2UZyKR6u0LrHXq0vAbt3C7SZYxF/qqR d0A04IMnlriD6vkLf9+TRbBt6g30YB8NbRyLs1DferH6uV1H5qMf3IgFJjgatk4yJhB1dM 0bmJcPg/mMzLjcNUHZs5VbEMqrqcabacQb8UvkPONg1VGSow3h0V8P5l/HiX3LmY46ehcX +XKwO2eeMXCoLoKF97NrVor+e0RURaKav5ug0mCKsROrMXRuKcQBYFn7W8rgpQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721240389; a=rsa-sha256; cv=none; b=QiXrXUzlnklwBYR0/rs4R9oF+S1qHd+ain5i4PSiv7gB+rAFDOLCvp2Czn9dPBJMxMuFX4 5TW90bWAHdFsczdS4JnodSwEl+QJ56q6DRmyVNZKbH0sEKa6Nc/wVnFA53tmJJdykQw83r /8WYAt4iY8uUKc4z4rr+/nmbdVelokUV7PxIoeIcjszmJZwa+lzYBQcHq1B8dymzucg0Xn rIjCXrFMJgUjfo9IgYDxj4DbIjy6iUqhf/z0aswlymONCmDwCLq0dYvsoZodqKXAvPCi/t KBL2IyCn28QVtjUD5nvCjR9Ca4fa0VAetgVdvOtWy6QNguXI7MuFnOfASXexyw== 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=1721240389; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=EjX9c4CIg6X0eNfHA8mLLUVoYZd7H0073lcRJkBD/NI=; b=x2amFi8ekDT+PlmGwIxyjfbybLCbOnDG+dbBQnkL7jSSeSEYNT6eXGbEOjf4aAB/VYssIX +83O59P8tYC7yWKh4MG3I7nCGI9yivuESK/v3kbZV9FFcQpus7HJjTh+f3p+29AmTnSzPe 9p1U73Tj7V3TGW3wonwRH2zrN9EXO3UBVqHAtsrnS9gvQ+wUmXTlTKcGjuVj3ztW6227Uk XLZh6Z55c1bFFUWzs4K/mQ5AEh7hk/tgTBM5ufPg7J/Q/BnC+9jRL0HaXCiIeXTzepQfwq i05REmhXpTD1gIhZmdv26UJHJ1skzprZU/J/tmL7njZI8tmTW2lXwpvkFGiYaA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPPNj35p9zFg8; Wed, 17 Jul 2024 18:19:49 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HIJnkv023299; Wed, 17 Jul 2024 18:19:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HIJnLL023296; Wed, 17 Jul 2024 18:19:49 GMT (envelope-from git) Date: Wed, 17 Jul 2024 18:19:49 GMT Message-Id: <202407171819.46HIJnLL023296@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Navdeep Parhar Subject: git: b3bbc6cc79a3 - main - cxgbe(4): Tidy up t4_l2t.h List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: b3bbc6cc79a3b76d342b2a8fd68e5266eb50ff11 Auto-Submitted: auto-generated The branch main has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=b3bbc6cc79a3b76d342b2a8fd68e5266eb50ff11 commit b3bbc6cc79a3b76d342b2a8fd68e5266eb50ff11 Author: Navdeep Parhar AuthorDate: 2024-07-17 17:41:37 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-17 17:53:16 +0000 cxgbe(4): Tidy up t4_l2t.h Align the comment for if_t with the rest and remove the declaration of t4_l2t_set_switching, which was removed in 061bbaf7e7fe. No functional change. MFC after: 3 days Sponsored by: Chelsio Communications --- sys/dev/cxgbe/t4_l2t.h | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/sys/dev/cxgbe/t4_l2t.h b/sys/dev/cxgbe/t4_l2t.h index be6337a60eab..36a41e459a5d 100644 --- a/sys/dev/cxgbe/t4_l2t.h +++ b/sys/dev/cxgbe/t4_l2t.h @@ -64,7 +64,7 @@ struct l2t_entry { uint32_t addr[4]; /* next hop IP or IPv6 address */ uint32_t iqid; /* iqid for reply to write_l2e */ struct sge_wrq *wrq; /* queue to use for write_l2e */ - if_t ifp; /* outgoing interface */ + if_t ifp; /* outgoing interface */ uint16_t smt_idx; /* SMT index */ uint16_t vlan; /* VLAN TCI (id: 0-11, prio: 13-15) */ struct l2t_entry *first; /* start of hash chain */ @@ -94,8 +94,6 @@ struct l2t_entry *t4_l2t_alloc_switching(struct adapter *, uint16_t, uint8_t, uint8_t *); struct l2t_entry *t4_l2t_alloc_tls(struct adapter *, struct sge_txq *, void *, int *, uint16_t, uint8_t, uint8_t *); -int t4_l2t_set_switching(struct adapter *, struct l2t_entry *, uint16_t, - uint8_t, uint8_t *); int t4_write_l2e(struct l2t_entry *, int); int do_l2t_write_rpl(struct sge_iq *, const struct rss_header *, struct mbuf *); From nobody Wed Jul 17 21:45:38 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPTyC1FHrz5QSRr; Wed, 17 Jul 2024 21:45: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPTyC0lMMz4nFf; Wed, 17 Jul 2024 21:45:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721252739; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Mr0fTzNS7e8gT5Krj5FxrzEX2JbldNFp81I95DejKHs=; b=LSrvJH2DENDt+fRlo6uplka0j5DhFg/6o46aIKhkP7qDVRL3pdc+1rJknKj2Iu1CMInreu EdtzRWTzVBvZL7qiFCKtTdy43JHTXorWEBcda85aUv23bT8QYcqkwznZCfp/nLde27+sww MZyAeccaCiJOk/HQ7geQC/wsS7l+lvBv9pKGALXORIMw1ZurWQ9w9Rgyl9gyQ4/ewepwXw cDTQpySVMNd3nvGp3ooO7mB0aaoMnG78KGBpyk0vtcgyPfTrjEzNA196CcsPIP/bttCcwu nN/iDBGa0mptymWk9K8ic22x4Vmv6hJFpUo6aHPBbQEvcmezAOfggPamBo24jg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721252739; a=rsa-sha256; cv=none; b=AkaubuawqmmIV8bZYyvrEGjbFfRhkwFPO9VARiZmRY2jCr8YNfF5N8EiLf0k9k5QSoSqzU yt3Oq27AOYggSDotKiRMHAbHmWatWSG9ziIydPo3vuQc5/1Y32L7qHAsfILS8OS6IcEqXy +liThmnrkmqihKLKMrq1mBu58Cd709fFPyfLJUqtdv7yT/2nM55hamoMWjoZvgtnOf41wE cDUrV2ZqLixEFL3Wvu2TNquFGHWuJ4KRCDiqUuQk6M7iAksopZA0TR8JHs3Pi040ZrzFKu sm/9jlOj2xgGPIzJduSvAIg3QW0OPDEUb7oj+k9I6/hERS1lqN6SJ94yTYchAg== 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=1721252739; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Mr0fTzNS7e8gT5Krj5FxrzEX2JbldNFp81I95DejKHs=; b=CFzRvUTWnPvDe+a4gFc6JfqodS2NbQyuP4yjIKh8SMPzwB0KaBofPh7rJSIFSZOjsYlyP5 jQ9AJy9OT7I5dQopyMPlA7gbCd6sBVJnuQ55gjN4MSg+KyiynPtKHJwaYt8SiJ1NUpsPtW KGnEs0GCDelcruppLcHnozBdr9Xrc1YLOi3uThF3ZjgZAcsQeVy8MVuFtjuyCr4uiZemmP mPPegDbf78+Njy08ZZzUV60IGejtMYUX4n4sPg/1aDfL5Ghwpj1xEXzI64f3/P/AGM0Jsh jPBxf8DOQY44gUQLOCmHb/44s3buc2aRACbkk4NHf6hK+yRtrXhiTNZ4GMSBAA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPTyC0LVpzL9g; Wed, 17 Jul 2024 21:45:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HLjcxL079915; Wed, 17 Jul 2024 21:45:38 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HLjcJp079912; Wed, 17 Jul 2024 21:45:38 GMT (envelope-from git) Date: Wed, 17 Jul 2024 21:45:38 GMT Message-Id: <202407172145.46HLjcJp079912@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mateusz Guzik Subject: git: a4469a0d19b6 - main - pipe: convert pipelock flag argument to bool List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mjg X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: a4469a0d19b64bf518c12e8c24c81ec513a45e7d Auto-Submitted: auto-generated The branch main has been updated by mjg: URL: https://cgit.FreeBSD.org/src/commit/?id=a4469a0d19b64bf518c12e8c24c81ec513a45e7d commit a4469a0d19b64bf518c12e8c24c81ec513a45e7d Author: Mateusz Guzik AuthorDate: 2024-07-17 19:07:07 +0000 Commit: Mateusz Guzik CommitDate: 2024-07-17 21:45:32 +0000 pipe: convert pipelock flag argument to bool No functional changes, preparatory cleanup. Sponsored by: Rubicon Communications, LLC ("Netgate") --- sys/kern/sys_pipe.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/sys/kern/sys_pipe.c b/sys/kern/sys_pipe.c index 1d48728139c2..70b2a03e0140 100644 --- a/sys/kern/sys_pipe.c +++ b/sys/kern/sys_pipe.c @@ -225,7 +225,7 @@ static void pipeclose(struct pipe *cpipe); static void pipe_free_kmem(struct pipe *cpipe); static int pipe_create(struct pipe *pipe, bool backing); static int pipe_paircreate(struct thread *td, struct pipepair **p_pp); -static __inline int pipelock(struct pipe *cpipe, int catch); +static __inline int pipelock(struct pipe *cpipe, bool catch); static __inline void pipeunlock(struct pipe *cpipe); static void pipe_timestamp(struct timespec *tsp); #ifndef PIPE_NODIRECT @@ -633,7 +633,7 @@ pipespace(struct pipe *cpipe, int size) * lock a pipe for I/O, blocking other access */ static __inline int -pipelock(struct pipe *cpipe, int catch) +pipelock(struct pipe *cpipe, bool catch) { int error, prio; @@ -738,7 +738,7 @@ pipe_read(struct file *fp, struct uio *uio, struct ucred *active_cred, PIPE_LOCK(rpipe); ++rpipe->pipe_busy; - error = pipelock(rpipe, 1); + error = pipelock(rpipe, true); if (error) goto unlocked_error; @@ -854,7 +854,7 @@ pipe_read(struct file *fp, struct uio *uio, struct ucred *active_cred, if ((error = msleep(rpipe, PIPE_MTX(rpipe), PRIBIO | PCATCH, "piperd", 0)) == 0) - error = pipelock(rpipe, 1); + error = pipelock(rpipe, true); } if (error) goto unlocked_error; @@ -1034,7 +1034,7 @@ retry: pipeunlock(wpipe); error = msleep(wpipe, PIPE_MTX(wpipe), PRIBIO | PCATCH, "pipdww", 0); - pipelock(wpipe, 0); + pipelock(wpipe, false); if (error != 0) goto error1; goto retry; @@ -1049,7 +1049,7 @@ retry: pipeunlock(wpipe); error = msleep(wpipe, PIPE_MTX(wpipe), PRIBIO | PCATCH, "pipdwc", 0); - pipelock(wpipe, 0); + pipelock(wpipe, false); if (error != 0) goto error1; goto retry; @@ -1071,7 +1071,7 @@ retry: pipeunlock(wpipe); error = msleep(wpipe, PIPE_MTX(wpipe), PRIBIO | PCATCH, "pipdwt", 0); - pipelock(wpipe, 0); + pipelock(wpipe, false); if (error != 0) break; } @@ -1107,7 +1107,7 @@ pipe_write(struct file *fp, struct uio *uio, struct ucred *active_cred, rpipe = fp->f_data; wpipe = PIPE_PEER(rpipe); PIPE_LOCK(rpipe); - error = pipelock(wpipe, 1); + error = pipelock(wpipe, true); if (error) { PIPE_UNLOCK(rpipe); return (error); @@ -1206,7 +1206,7 @@ pipe_write(struct file *fp, struct uio *uio, struct ucred *active_cred, pipeunlock(wpipe); error = msleep(wpipe, PIPE_MTX(rpipe), PRIBIO | PCATCH, "pipbww", 0); - pipelock(wpipe, 0); + pipelock(wpipe, false); if (error != 0) break; continue; @@ -1311,7 +1311,7 @@ pipe_write(struct file *fp, struct uio *uio, struct ucred *active_cred, pipeunlock(wpipe); error = msleep(wpipe, PIPE_MTX(rpipe), PRIBIO | PCATCH, "pipewr", 0); - pipelock(wpipe, 0); + pipelock(wpipe, false); if (error != 0) break; continue; @@ -1671,7 +1671,7 @@ pipeclose(struct pipe *cpipe) KASSERT(cpipe != NULL, ("pipeclose: cpipe == NULL")); PIPE_LOCK(cpipe); - pipelock(cpipe, 0); + pipelock(cpipe, false); #ifdef MAC pp = cpipe->pipe_pair; #endif @@ -1686,7 +1686,7 @@ pipeclose(struct pipe *cpipe) cpipe->pipe_state |= PIPE_WANT; pipeunlock(cpipe); msleep(cpipe, PIPE_MTX(cpipe), PRIBIO, "pipecl", 0); - pipelock(cpipe, 0); + pipelock(cpipe, false); } pipeselwakeup(cpipe); From nobody Wed Jul 17 21:55:26 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPV9V3RrMz5QT7j; Wed, 17 Jul 2024 21:55: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPV9V2j0Wz4p80; Wed, 17 Jul 2024 21:55:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721253326; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=quwV52xgmB9RPu0Tfq4kLyanuROsiaulqzrauYPdKDM=; b=r8YMpcnMrCDMc+Px+37ajaB1T/+9vEO8iUtKvGFAcSZqrdqeEH3OQiXAUZ3bSJkCutYIf7 rKNVO6DRxGz7buKg7vXrEEM5TTubeicvxFJer80+hOpdevHSkr2irdA+yQBKfX9J5nm9Q+ wSEj0rCGaMyM1hYczLOy6UKDg3BF1PTosAcKaZB3cDKCkDnTZcKp9Q06CwZJwHmg413GnJ ocX3vbKsGS439PAIPQr7DHZ/4+ysfzJI7EpN7BIUlyEfswlmfMMQhKsMwFy4lyQmu0M3DP 8rcwxjuXpDOsku/dA7VkrZFfvEKrhTySEUM1OLtSq3WU7gjG3yjGAASyigCjeQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721253326; a=rsa-sha256; cv=none; b=v9HPvnNhO2kzVEWuZjyGLPOKFYltTwQ6THK4QQB4sTDLVieo3AtsvgKRCatIiqTNCqg+mz ee1LhH3CdnEDa3vofW5pLWtrgWTZZ3bF/MAUTzjsZ9lFsf7vrbgPHIWpfCytrlGKeuRNjx AGRnmi8+SlWjFSuMoeIlAM8emFKv/0MrCkEi1gnDVSPqZCrMYFjDhsiALc/esoN3/M55J5 ZMl+taZqQxUrb8zwHhxzAqZSVGTGHP+4SDFu9Jli1u3cjQEUWj6PzS3AoCVko5jgnBg2O1 qqa5Ql3ntM5Ez/BA8EqYyIk4wYIh7iswXN1pg/G/Fp5jIIZTsgPg7yc3mvR6Cw== 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=1721253326; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=quwV52xgmB9RPu0Tfq4kLyanuROsiaulqzrauYPdKDM=; b=igd8Lh/e8L37yRYq81jVXTmS/Kv10/6HYSW2qoxLsxL8FXDMf1Kn3zEG5mZB29nVB/XU8P AX405+ZkrHXpfm1p051FXNyo2ppzP9vlokaV1ld4q/hutRst/BMsqkjUZxeS1mGPvKVJbS gg5WMvodZ9bbfIEeJhj9qUaf4x5Fc443kCFrEVAVHxvfEij8qE0na36S37m1M7fHILLfZ3 sK/DCAiCoW4Zeph6BQRE2rP2EdUmmV60yi73LEt+qQ0HPFMSmQ9qJALW5xXBhHHRIEo7Pb DNvVq+ZxLJ6Mf3DNGXKsCd8RmYZH49zs30nv8egamd/AP5x66ZuI/RqXoCgIQQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPV9V20MkzMB8; Wed, 17 Jul 2024 21:55:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HLtQaC096684; Wed, 17 Jul 2024 21:55:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HLtQaY096681; Wed, 17 Jul 2024 21:55:26 GMT (envelope-from git) Date: Wed, 17 Jul 2024 21:55:26 GMT Message-Id: <202407172155.46HLtQaY096681@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: a69d075e96a6 - stable/13 - if_pfsync: lock buckets during pfsync_drop() List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: a69d075e96a60273a9b39005b3e765e6476a8b53 Auto-Submitted: auto-generated The branch stable/13 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=a69d075e96a60273a9b39005b3e765e6476a8b53 commit a69d075e96a60273a9b39005b3e765e6476a8b53 Author: Kristof Provost AuthorDate: 2024-07-07 14:42:48 +0000 Commit: Kristof Provost CommitDate: 2024-07-17 21:54:35 +0000 if_pfsync: lock buckets during pfsync_drop() We failed to lock buckets while dropping messages, which could potentially lead to crashes, and is the likely cause of panics like: > pfsync_drop: st->sync_state == q > # pfsync_drop > # pfsync_q_ins > # pfsync_insert_state > # pf_state_insert > ... Handle this by only handling the currently relevant (and this locked) bucket. This ensures that the bucket is locked while we manipulate it. While here also log slightly more information in the KASSERT(). MFC after: 2 weeks Sponsored by: Orange Business Services (cherry picked from commit 5f75cd390a67cbec06993c4c66f784f0f777c854) --- sys/netpfil/pf/if_pfsync.c | 70 ++++++++++++++++++++++++++++------------------ 1 file changed, 43 insertions(+), 27 deletions(-) diff --git a/sys/netpfil/pf/if_pfsync.c b/sys/netpfil/pf/if_pfsync.c index 1dde4e52e3f8..b8632e1fd61b 100644 --- a/sys/netpfil/pf/if_pfsync.c +++ b/sys/netpfil/pf/if_pfsync.c @@ -300,7 +300,8 @@ static void pfsync_defer_tmo(void *); static void pfsync_request_update(u_int32_t, u_int64_t); static bool pfsync_update_state_req(struct pf_kstate *); -static void pfsync_drop(struct pfsync_softc *); +static void pfsync_drop_all(struct pfsync_softc *); +static void pfsync_drop(struct pfsync_softc *, int); static void pfsync_sendout(int, int); static void pfsync_send_plus(void *, size_t); @@ -434,7 +435,7 @@ pfsync_clone_destroy(struct ifnet *ifp) bpfdetach(ifp); if_detach(ifp); - pfsync_drop(sc); + pfsync_drop_all(sc); if_free(ifp); pfsync_multicast_cleanup(sc); @@ -1532,39 +1533,54 @@ pfsync_out_del(struct pf_kstate *st, void *buf) } static void -pfsync_drop(struct pfsync_softc *sc) +pfsync_drop_all(struct pfsync_softc *sc) { - struct pf_kstate *st, *next; - struct pfsync_upd_req_item *ur; struct pfsync_bucket *b; - int c, q; + int c; for (c = 0; c < pfsync_buckets; c++) { b = &sc->sc_buckets[c]; - for (q = 0; q < PFSYNC_S_COUNT; q++) { - if (TAILQ_EMPTY(&b->b_qs[q])) - continue; - TAILQ_FOREACH_SAFE(st, &b->b_qs[q], sync_list, next) { - KASSERT(st->sync_state == q, - ("%s: st->sync_state == q", - __func__)); - st->sync_state = PFSYNC_S_NONE; - pf_release_state(st); - } - TAILQ_INIT(&b->b_qs[q]); - } + PFSYNC_BUCKET_LOCK(b); + pfsync_drop(sc, c); + PFSYNC_BUCKET_UNLOCK(b); + } +} - while ((ur = TAILQ_FIRST(&b->b_upd_req_list)) != NULL) { - TAILQ_REMOVE(&b->b_upd_req_list, ur, ur_entry); - free(ur, M_PFSYNC); +static void +pfsync_drop(struct pfsync_softc *sc, int c) +{ + struct pf_kstate *st, *next; + struct pfsync_upd_req_item *ur; + struct pfsync_bucket *b; + int q; + + b = &sc->sc_buckets[c]; + PFSYNC_BUCKET_LOCK_ASSERT(b); + + for (q = 0; q < PFSYNC_S_COUNT; q++) { + if (TAILQ_EMPTY(&b->b_qs[q])) + continue; + + TAILQ_FOREACH_SAFE(st, &b->b_qs[q], sync_list, next) { + KASSERT(st->sync_state == q, + ("%s: st->sync_state %d == q %d", + __func__, st->sync_state, q)); + st->sync_state = PFSYNC_S_NONE; + pf_release_state(st); } + TAILQ_INIT(&b->b_qs[q]); + } - b->b_len = PFSYNC_MINPKT; - free(b->b_plus, M_PFSYNC); - b->b_plus = NULL; - b->b_pluslen = 0; + while ((ur = TAILQ_FIRST(&b->b_upd_req_list)) != NULL) { + TAILQ_REMOVE(&b->b_upd_req_list, ur, ur_entry); + free(ur, M_PFSYNC); } + + b->b_len = PFSYNC_MINPKT; + free(b->b_plus, M_PFSYNC); + b->b_plus = NULL; + b->b_pluslen = 0; } static void @@ -1588,7 +1604,7 @@ pfsync_sendout(int schedswi, int c) PFSYNC_BUCKET_LOCK_ASSERT(b); if (!bpf_peers_present(ifp->if_bpf) && sc->sc_sync_if == NULL) { - pfsync_drop(sc); + pfsync_drop(sc, c); return; } @@ -2130,8 +2146,8 @@ pfsync_q_ins(struct pf_kstate *st, int q, bool ref) } b->b_len += nlen; - TAILQ_INSERT_TAIL(&b->b_qs[q], st, sync_list); st->sync_state = q; + TAILQ_INSERT_TAIL(&b->b_qs[q], st, sync_list); if (ref) pf_ref_state(st); } From nobody Wed Jul 17 21:55:26 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPV9W0kshz5QTDP; Wed, 17 Jul 2024 21: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPV9V6kgfz4pW4; Wed, 17 Jul 2024 21:55:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721253326; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Ts72YOqV5zNudTs78j5L60Uhs6u46SHfSXpt+ux98Ls=; b=grmJYbsuM5o0G2r9B+rnxWavG/MT772l+t0sKBmDXdRyvOCfqzTR6wXJ8W7vd07Wejp3xn jn50t61nIYaKLVBVnDN21keJy9auzFYWu7REPQDYEMYN6+JERLxoI6PCuP7E7r23NzdYLj 4yu12VyYzWuVZ9tmpMAvZLfu9yNKjeCOe6/iVGCjis7lISRyzZ/DSdJDy8w8iuHqQdsPie Bt5YxzxCndS+4xZaYUdQZntOTCqoWjwYtfYVKYkLTzoir0olwRdvcu1vsmbNmmnokbsEEe 8gfjZ/0LiO8oHmtXlVvRethXZAhdAb3rFdMJg2VUVSGK15/x13NJssJVE2sndg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721253326; a=rsa-sha256; cv=none; b=n8GFz/hX7DmMIx0W+aR/JkSC9oFWTzy/QfB8VUncmQrKkhdeuP37L4D3Fi7QcuXAyd/Kvz B9yS0TY8CrH7hBYsjuxXgOKeub0ooAnYN1NxDyNV33caPosPntbq9r0VD3t3SYQJLYLjsL af/3YEPvzUdSJ6cKLILCYpUF1G6YM4wG1NaqWvqOHSxQ7Hw/qVyPjaDg3I02iV9Riwulkn RBcz1LP0SYDP120UNAkCo/1AW6RhhYF6bKxkQpQivARzWc6nQszKPZSTiWJ2gTCYyfLxm9 JxQCWbH3Pef6fSuWVizODrtytBGnH0bC2ciyjiztCIbkaL5tgL1K55ho1+onMg== 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=1721253326; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Ts72YOqV5zNudTs78j5L60Uhs6u46SHfSXpt+ux98Ls=; b=GtaVy5Ygk2V38r3Tlwt6VfQpEkwHAyJeDpii+ASXGiqPOQBtERSpA4kh4mpyeMtb7ZPWXi mzKQqTfClZ8leEeSFle7NKRYPXgtjsrgKc/jeRQU40yCzP1JfibNn+Jk6yoJ/wMpgvcGgv z1FEkOyF2DwJRhtLNdAEUPd9OKlu8xbzXR9eTOP5HhBP2BLcwBJkAbltRjetf1RaoUl5Uh HXeMFcSEW6NA4XX3kR3ksN2xjfKR6oDiWgQdKrkYDBOwZx4yhiYAq/UCcDB6SRg1GBtBcf 8CuNBue5iWweM2D6rjExxj+YXn+6YTEmxjJEwVfWk0EWjGbsnnE36F5JsABhgQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPV9V6LJ9zMB9; Wed, 17 Jul 2024 21:55:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HLtQtD096790; Wed, 17 Jul 2024 21:55:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HLtQr4096787; Wed, 17 Jul 2024 21:55:26 GMT (envelope-from git) Date: Wed, 17 Jul 2024 21:55:26 GMT Message-Id: <202407172155.46HLtQr4096787@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: e99c76951e10 - stable/14 - if_pfsync: lock buckets during pfsync_drop() List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: e99c76951e1092464037cd4bcbce1e05a3589acc Auto-Submitted: auto-generated The branch stable/14 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=e99c76951e1092464037cd4bcbce1e05a3589acc commit e99c76951e1092464037cd4bcbce1e05a3589acc Author: Kristof Provost AuthorDate: 2024-07-07 14:42:48 +0000 Commit: Kristof Provost CommitDate: 2024-07-17 15:23:48 +0000 if_pfsync: lock buckets during pfsync_drop() We failed to lock buckets while dropping messages, which could potentially lead to crashes, and is the likely cause of panics like: > pfsync_drop: st->sync_state == q > # pfsync_drop > # pfsync_q_ins > # pfsync_insert_state > # pf_state_insert > ... Handle this by only handling the currently relevant (and this locked) bucket. This ensures that the bucket is locked while we manipulate it. While here also log slightly more information in the KASSERT(). MFC after: 2 weeks Sponsored by: Orange Business Services (cherry picked from commit 5f75cd390a67cbec06993c4c66f784f0f777c854) --- sys/netpfil/pf/if_pfsync.c | 70 ++++++++++++++++++++++++++++------------------ 1 file changed, 43 insertions(+), 27 deletions(-) diff --git a/sys/netpfil/pf/if_pfsync.c b/sys/netpfil/pf/if_pfsync.c index 9aad44ccaf99..7af9ce8f468d 100644 --- a/sys/netpfil/pf/if_pfsync.c +++ b/sys/netpfil/pf/if_pfsync.c @@ -345,7 +345,8 @@ static void pfsync_defer_tmo(void *); static void pfsync_request_update(u_int32_t, u_int64_t); static bool pfsync_update_state_req(struct pf_kstate *); -static void pfsync_drop(struct pfsync_softc *); +static void pfsync_drop_all(struct pfsync_softc *); +static void pfsync_drop(struct pfsync_softc *, int); static void pfsync_sendout(int, int); static void pfsync_send_plus(void *, size_t); @@ -485,7 +486,7 @@ pfsync_clone_destroy(struct ifnet *ifp) bpfdetach(ifp); if_detach(ifp); - pfsync_drop(sc); + pfsync_drop_all(sc); if_free(ifp); pfsync_multicast_cleanup(sc); @@ -1736,40 +1737,54 @@ pfsync_out_del_c(struct pf_kstate *st, void *buf) } static void -pfsync_drop(struct pfsync_softc *sc) +pfsync_drop_all(struct pfsync_softc *sc) { - struct pf_kstate *st, *next; - struct pfsync_upd_req_item *ur; struct pfsync_bucket *b; int c; - enum pfsync_q_id q; for (c = 0; c < pfsync_buckets; c++) { b = &sc->sc_buckets[c]; - for (q = 0; q < PFSYNC_Q_COUNT; q++) { - if (TAILQ_EMPTY(&b->b_qs[q])) - continue; - TAILQ_FOREACH_SAFE(st, &b->b_qs[q], sync_list, next) { - KASSERT(st->sync_state == pfsync_qid_sstate[q], - ("%s: st->sync_state == q", - __func__)); - st->sync_state = PFSYNC_S_NONE; - pf_release_state(st); - } - TAILQ_INIT(&b->b_qs[q]); - } + PFSYNC_BUCKET_LOCK(b); + pfsync_drop(sc, c); + PFSYNC_BUCKET_UNLOCK(b); + } +} - while ((ur = TAILQ_FIRST(&b->b_upd_req_list)) != NULL) { - TAILQ_REMOVE(&b->b_upd_req_list, ur, ur_entry); - free(ur, M_PFSYNC); +static void +pfsync_drop(struct pfsync_softc *sc, int c) +{ + struct pf_kstate *st, *next; + struct pfsync_upd_req_item *ur; + struct pfsync_bucket *b; + enum pfsync_q_id q; + + b = &sc->sc_buckets[c]; + PFSYNC_BUCKET_LOCK_ASSERT(b); + + for (q = 0; q < PFSYNC_Q_COUNT; q++) { + if (TAILQ_EMPTY(&b->b_qs[q])) + continue; + + TAILQ_FOREACH_SAFE(st, &b->b_qs[q], sync_list, next) { + KASSERT(st->sync_state == pfsync_qid_sstate[q], + ("%s: st->sync_state %d == q %d", + __func__, st->sync_state, q)); + st->sync_state = PFSYNC_S_NONE; + pf_release_state(st); } + TAILQ_INIT(&b->b_qs[q]); + } - b->b_len = PFSYNC_MINPKT; - free(b->b_plus, M_PFSYNC); - b->b_plus = NULL; - b->b_pluslen = 0; + while ((ur = TAILQ_FIRST(&b->b_upd_req_list)) != NULL) { + TAILQ_REMOVE(&b->b_upd_req_list, ur, ur_entry); + free(ur, M_PFSYNC); } + + b->b_len = PFSYNC_MINPKT; + free(b->b_plus, M_PFSYNC); + b->b_plus = NULL; + b->b_pluslen = 0; } static void @@ -1793,7 +1808,7 @@ pfsync_sendout(int schedswi, int c) PFSYNC_BUCKET_LOCK_ASSERT(b); if (!bpf_peers_present(ifp->if_bpf) && sc->sc_sync_if == NULL) { - pfsync_drop(sc); + pfsync_drop(sc, c); return; } @@ -1841,6 +1856,7 @@ pfsync_sendout(int schedswi, int c) #endif default: m_freem(m); + pfsync_drop(sc, c); return; } m->m_len = m->m_pkthdr.len = len; @@ -2401,8 +2417,8 @@ pfsync_q_ins(struct pf_kstate *st, int sync_state, bool ref) } b->b_len += nlen; - TAILQ_INSERT_TAIL(&b->b_qs[q], st, sync_list); st->sync_state = pfsync_qid_sstate[q]; + TAILQ_INSERT_TAIL(&b->b_qs[q], st, sync_list); if (ref) pf_ref_state(st); } From nobody Wed Jul 17 21:55:27 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPV9W5GRkz5QT5s; Wed, 17 Jul 2024 21: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPV9W3FvDz4pF2; Wed, 17 Jul 2024 21: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=1721253327; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=wdG9NvxAAS/IuWsnIUX5kXOpfP9zaAmssrIVZU0TY0U=; b=nBW/z/UGofo7874Z81QMp6NDbc0hcU3svZ8+B4iBm1zAc6dom4lUjsm8OYMimK6fKLJNGx wXQ4M+r/y3VEmAtARjpD7/sj/0ePPpyu0YqufM1nnBzioqcJfKKcQ7+/KpKzeEUXm5FCF/ o851d/FnxmNausg2NvAJoasss+Bqz+kEbRCJ239u9UpXZgQnJm+3lAcKSsi2EH0q7GZCZz 9eC+GG2K01tvPcYxP+azkNUjwNFk8CWVOuhReZt1meGIC6NS2tx5U7rZGGOD/VGgsGvlOU qxMhMlG4L0MU9xNB9IDVlsM9qO3O1jZyQkIH7HIAirmDbuJTFdnccHi0j1G4yw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721253327; a=rsa-sha256; cv=none; b=t4YmuC0OlTlFwY0n+GTqFF/ujv0kBV8V2b1tE+MbXnxT83ML/8dFxMwD5X9nBc6Ma67g+w JkvjyL5QQ8xslqVzV0MUwHw2g1AhLGAwjx1D/dWpmLCDy7WA8iDWq/pFnvq2Jp0E4qmdzu nnr6BWUq+xh/m4bENBMAC1Amlj+UNdOPHJ3ziFaaLkjI1UcvdNm7HKu64BChz0aRSx6cbF 88I0WKE8xaf/nM51gP/pN8fih9f/M8huVMVjcQSv2DEijGVMW+2WjGwJFZyDlNIManCaEk Mm2moCEPnKtGzm7YSolg0++j5ovlYOkLL1nfB0ZICD1zfFN1IdFyl5Nfl4WRfg== 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=1721253327; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=wdG9NvxAAS/IuWsnIUX5kXOpfP9zaAmssrIVZU0TY0U=; b=rqZqoVD2h4kRUtHeTfy132CBFK9EaU5hwANHCIkHYDPEMWIpPrktggrhN6+a+sjtv7ujep LRVhR5kR4iSko4R/MAn48/E2yOI0pI39/k566QTTgLhy0G34ouXuGjUgT8z0TGSrpDuzd6 BcOnL2ZohKb9HTol+9/rXXpQGviY0kHDYksfxI7P0qE1ay/feOswzOAIbQc72FD2Exp4Cg J4S2O0VrhmCsvvczFuCv9eNKQCDvXhnsqpWYVAqatLTFYgXqUim4Ef6cGJ63o3MDpc/SSr VclIvd+wxtlwAQu5L3xvmKCNJjCBjaPPtmOG0Xfffb2YclX6Xh/OuB+IEpfsaA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPV9W2svszMBB; Wed, 17 Jul 2024 21:55:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HLtR9J096832; Wed, 17 Jul 2024 21:55:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HLtROa096829; Wed, 17 Jul 2024 21:55:27 GMT (envelope-from git) Date: Wed, 17 Jul 2024 21:55:27 GMT Message-Id: <202407172155.46HLtROa096829@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: 5324cf4f1cf9 - stable/13 - pf: fix sctp deadlock List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 5324cf4f1cf9d93351f966d4a76cf0389d08f3c6 Auto-Submitted: auto-generated The branch stable/13 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=5324cf4f1cf9d93351f966d4a76cf0389d08f3c6 commit 5324cf4f1cf9d93351f966d4a76cf0389d08f3c6 Author: Kristof Provost AuthorDate: 2024-07-09 18:49:49 +0000 Commit: Kristof Provost CommitDate: 2024-07-17 21:54:35 +0000 pf: fix sctp deadlock It is possible for pf_test_state_sctp() to find a state and still return PF_DROP (or not PF_PASS, to be exact). In that case we would run pf_test_rule() unconditionally, but this would overwrite the (locked!) state pointer pf_test_state_sctp() gave us. As a result we will later deadlock, trying the lock the already locked state. Do what we do for UDP and TCP, and explicitly check s for NULL before we run pf_test_rule(). MFC after: 1 week Sponsored by: Orange Business Services (cherry picked from commit a9639adaedb4d67340c4ae386fe8fcd18e4a8a21) --- sys/netpfil/pf/pf.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/netpfil/pf/pf.c b/sys/netpfil/pf/pf.c index 97ae44cff69f..e99886a2d120 100644 --- a/sys/netpfil/pf/pf.c +++ b/sys/netpfil/pf/pf.c @@ -7310,7 +7310,7 @@ pf_test(int dir, int pflags, struct ifnet *ifp, struct mbuf **m0, struct inpcb * V_pfsync_update_state_ptr(s); r = s->rule.ptr; a = s->anchor.ptr; - } else { + } else if (s == NULL) { action = pf_test_rule(&r, &s, pd.dir, kif, m, off, &pd, &a, &ruleset, inp); } @@ -7838,7 +7838,7 @@ pf_test6(int dir, int pflags, struct ifnet *ifp, struct mbuf **m0, struct inpcb V_pfsync_update_state_ptr(s); r = s->rule.ptr; a = s->anchor.ptr; - } else { + } else if (s == NULL) { action = pf_test_rule(&r, &s, pd.dir, kif, m, off, &pd, &a, &ruleset, inp); } From nobody Wed Jul 17 21:55:27 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPV9X1bDSz5QT5w; Wed, 17 Jul 2024 21:55: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPV9X0cbKz4pSn; Wed, 17 Jul 2024 21:55:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721253328; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=K+IjChQ9s3JCd9oAHyJZYkrGbKeqzvGEpJUTafOw5qQ=; b=F1w8bt/3DftL5RyoX5OV182fcRJue5aH9idDF+ixSzU+C/v6aO9PmoblQutb4UurlysUC4 BNHU0KyOG2LL8AjayVi86lAYB5TdHquwAfJDmhz3k8vvXmNqxd8Tjk7GSvhxq9r9mVSX4+ fykBtybepbNYL1YTCPz1O7Fk4tisuLUK+d2pQU2YYMq2z3sJA5q+OD5hQeM069zM2xrKbW cArhK/a2FafNisAmwgcndE4rUeWjGpKhQlD2heYERLWeQgL6edWY88nsGOieGA8u/1TCqA mGBWLuZdviJDkzIs5I9hH5H9fXcnl8gDeg3eYzs2elud0JdYflcga60wMxkEhQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721253328; a=rsa-sha256; cv=none; b=L4/EUKZaZGAnY3QKhRmIzTGHnycUYxnUDodoEvXgcUmgYgaWyiUKSCAIfYM+WjROS8mgJy V/GOeKetQx2MYUcvlnjL1D2YTokm4B9t4tYFrnskefxih2zmOf1wO+p7bJsTliQB/rulPv viHIW8HLDWkKz9y4MmzHsDBICbHhAaIUFx/gfxXnsZRrxw4JTSdAbQAFf7yOTrDN6DkXl3 AuucwYjgqN9Bl989ubHvg6Cu0InvvRXPTL0h177osjgTp4h4Ae7MPZuUgt6ThQ2HX+AdX9 3r51iSZwCYRs+h0hRtmQzsiWfwaPxNjDpx2dhGNVCKkpShA4ppAJrMCTwqKmJQ== 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=1721253328; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=K+IjChQ9s3JCd9oAHyJZYkrGbKeqzvGEpJUTafOw5qQ=; b=AcTkm2L6UeIb4sooGDFPx7CRxh1PhRuoR/kIJon2aF1nWdwvje6Z18qLOd1796DvJMKesP FzQNLv7uvRvXfkh9XBH5zDxVjxhzhopA2qyLnzvmq7iJDUllbeKj2H3oTmkcEe1Eis0B/N Tk4NJqsdHlei+6FNsJOkk8Qi01NfaeaoOrLqU47JN13Cb9ObLKdChw8ouASfwOd3WZaGRQ k1t0a8046PpZcL1zFlgxK03EHrR+c3gJEl/WNYjupzG60N9rstkydvVHGVLI3l9xRnniuW bCkZqfCEdx5FNV9alVu2AzFwGrTDwQSq1CRmje6kp+HoSDFa6dk7DC4IKfvXpw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPV9X0D3wzLsM; Wed, 17 Jul 2024 21:55:28 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46HLtRT2096871; Wed, 17 Jul 2024 21:55:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46HLtRul096868; Wed, 17 Jul 2024 21:55:27 GMT (envelope-from git) Date: Wed, 17 Jul 2024 21:55:27 GMT Message-Id: <202407172155.46HLtRul096868@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: 1981d52a6e29 - stable/14 - pf: fix sctp deadlock List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 1981d52a6e295f4b01a2cb95007806605d5e86ee Auto-Submitted: auto-generated The branch stable/14 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=1981d52a6e295f4b01a2cb95007806605d5e86ee commit 1981d52a6e295f4b01a2cb95007806605d5e86ee Author: Kristof Provost AuthorDate: 2024-07-09 18:49:49 +0000 Commit: Kristof Provost CommitDate: 2024-07-17 15:23:48 +0000 pf: fix sctp deadlock It is possible for pf_test_state_sctp() to find a state and still return PF_DROP (or not PF_PASS, to be exact). In that case we would run pf_test_rule() unconditionally, but this would overwrite the (locked!) state pointer pf_test_state_sctp() gave us. As a result we will later deadlock, trying the lock the already locked state. Do what we do for UDP and TCP, and explicitly check s for NULL before we run pf_test_rule(). MFC after: 1 week Sponsored by: Orange Business Services (cherry picked from commit a9639adaedb4d67340c4ae386fe8fcd18e4a8a21) --- sys/netpfil/pf/pf.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/netpfil/pf/pf.c b/sys/netpfil/pf/pf.c index 6671839fc5ab..4eed6dd31860 100644 --- a/sys/netpfil/pf/pf.c +++ b/sys/netpfil/pf/pf.c @@ -8164,7 +8164,7 @@ pf_test(int dir, int pflags, struct ifnet *ifp, struct mbuf **m0, V_pfsync_update_state_ptr(s); r = s->rule.ptr; a = s->anchor.ptr; - } else { + } else if (s == NULL) { action = pf_test_rule(&r, &s, kif, m, off, &pd, &a, &ruleset, inp); } @@ -8769,7 +8769,7 @@ pf_test6(int dir, int pflags, struct ifnet *ifp, struct mbuf **m0, struct inpcb V_pfsync_update_state_ptr(s); r = s->rule.ptr; a = s->anchor.ptr; - } else { + } else if (s == NULL) { action = pf_test_rule(&r, &s, kif, m, off, &pd, &a, &ruleset, inp); } From nobody Thu Jul 18 07:39:09 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPl720x2rz5Qwdg for ; Thu, 18 Jul 2024 07:39:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPl720BjFz4Qvy; Thu, 18 Jul 2024 07:39:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721288350; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ZSOl3ENFpT6xHsZ55XutaKAc5SdcVWpIK3d1sSqwGhI=; b=VphtkYdtxaWgjzJiPq1/p6Ks+t9CHPbDLV7snwEI421c7czenOAVhlC/sQ2N+TQxJMG0X2 oBt3Y/x5WzqaUD5WMfKDe9j6iYFWeZuxWY2vjQAtA3FbWiachLCyz4LbW3grLoBB0j97c+ J/Ng3dsa2mb9eUHGfkJMyeBtdnMKOVn7/wozNa+MypnwsX4wXK/jnBWACxrvMKJlwwnt4T awYLqw36OgjVMidaTZ7rj9W6fiMYB+sLMfPfPadWINLbv5lKAwm8EgL0esFLBxZWxXUCVa KjgefFLt+iDcXedCol2tKNsBh1pdinrccRB3xstNIr3B/j8cfJKNHfwmMizrXw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721288350; a=rsa-sha256; cv=none; b=A9UGGzFrX4yBA5QpgiJVR8o5u5yNB+qIM4+7SaJZgQUCECFSm4xy3f1HYb437MCl3rxltn ubiS/SQyu59XdAmfr7gxNU3rwlARoQZuDqB9wZv3yM06s1vFkO/Q+PqD+ghFclX8PIDz5k +cXycIs55OG7jiEgCoTHNgj6WgQh5uv5dU7bMj1pBxJbGdnFajKptzaIS8otT2/4+OSzk5 C9VxMDocwOwmUIBg/CSSrRuJ3Huo8opcdq2z89AwFlT3uuwItIhc3OYMTs4ym9+Q3nmUgK DA79YkAEy5Mg5V/2KR9UBIWnHeJHhB7nO1WuW/zD8LhkTFDjKD1K6xn/6TIDsg== 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=1721288350; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ZSOl3ENFpT6xHsZ55XutaKAc5SdcVWpIK3d1sSqwGhI=; b=JRUieool2OsuAE27qqJXBAiiW42EXe5WXnC6VBsbqLf4VNutCTjc/dSa+/HWxNLHM2i7lI 6gVxajM1EiQQ1sj/Eu9Y1wMIfzlmeENyEWBEHmtoIAABnYJ6asJBdX76JGBKMZFLRjUkNs wBSsqehK37V80tZ1tRnRszrFC4L4SOggCQrqGSojvrg79dCB668FchJznf7y8d8b5iggC7 OIkFEOgzpwl/RVCMN9hNlvFZG3hKw8nfgR+qq19sqaTTPavKpvHv+nmU3xI6oXnnzLXCfW C9CXRU8iCF1/+gXcLlOLRMTD+rJzd5anV5GC0aqgu90ALefrifh46gwGjHUMjA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPl716nkYzft5; Thu, 18 Jul 2024 07:39:09 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46I7d9vU080164; Thu, 18 Jul 2024 07:39:09 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46I7d9US080162; Thu, 18 Jul 2024 07:39:09 GMT (envelope-from git) Date: Thu, 18 Jul 2024 07:39:09 GMT Message-Id: <202407180739.46I7d9US080162@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org From: Martin Matuska Subject: git: c98295eed268..1147a2797853 - vendor/openzfs/master - vendor branch updated List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mm X-Git-Repository: src X-Git-Refname: refs/heads/vendor/openzfs/master X-Git-Reftype: branch X-Git-Commit: 1147a279785329a2eaeb01c0610c35fe835a62a6 X-Git-Oldrev: c98295eed2687cee704ef5f8f3218d3d44a6a1d8 X-Git-Newrev: 1147a279785329a2eaeb01c0610c35fe835a62a6 Auto-Submitted: auto-generated The branch vendor/openzfs/master has been updated by mm: URL: https://cgit.FreeBSD.org/src/log/?id=c98295eed268..1147a2797853 49f3ce338587 Linux 6.9: Call add_disk() from workqueue to fix zfs_allow_010_pos (#16282) 5f220c62e1c2 Fix a mis-merge in the zdb man page (#16304) fd51786f86e4 zfs.4: Document the actual default for zfs_txg_history (#16305) f72e081fbf38 FreeBSD: Use a statement expression to implement SET_ERROR() (#16284) 9ffe4413610e Fix zdb "Memory fault" found on FreeBSD ZTS (#16332) 326040b28525 Fix the name of the zfs_prefetch_disable parameter (#16319) 436731276061 zvol: Fix suspend lock leaks (#16270) 156a64161b4f Linux 6.9: Fix UBSAN errors in zap_micro.c a10faf5ce6fe FreeBSD: Use the new freeuio() helper to free dynamically allocated UIOs (#16300) cbd95a950aa5 ZTS: handle FreeBSD version numbers correctly (#16340) 398e675f5839 one-word manpage correction: snapshot->rollback (#16294) f7d8b1333699 Fix missing semicolon in trace_dbuf.h (#16281) c87cb22ba9fa head_errlog: fix use-after-free a7fc4c85e3ad zstd: don't call zstd_mempool_reap if there are no buffers (#16302) 4ee66cdf4ed4 Add building support for Artix Linux (#16265) b409892ae502 Linux 6.10: rework queue limits setup e951dba48a63 Linux 6.10: work harder to avoid kmem_cache_alloc reuse 7ca7bb7fd723 Linux 5.16: use bdev_nr_bytes() to get device capacity f2ebbe46f6c0 Linux 6.9 compat: META (#16358) 41902c8e6da1 Use kmap_local_page instead of kmap_atomic (#16329) 393b7ad69522 zts: test single-disk pool resumes properly after disk pull 5de3ac223623 vdev_open: clear async fault flag after reopen dc91e7452482 zdb: dump ZAP_FLAG_UINT64_KEY ZAPs properly (#16334) ab6d9bd89a87 Make sure avl_tree.avl_pad is not in kernel module (#16280) 1147a2797853 Fix printf typo for `zfs receive -cv` (#16295) From nobody Thu Jul 18 09:08:14 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPn5s6yfRz5R53p; Thu, 18 Jul 2024 09:08: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPn5s50L2z4ZjH; Thu, 18 Jul 2024 09:08:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721293697; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=FyBKXFbpS8PlIbrSo6oHr3s6MFUYVpquI957C7h9b/c=; b=hPs0k9TyF8rqPhokzoYwlE1wWP8+V3eTK/Xs0TDKJI/0GuWoErFGf7uHGLAVDQ9x4RV6nv fAIXU0EVgxmYuF0eeTq4nCpI1wG4G5IWYeDv6iUwynzncQM7h8015ZZsiVJGQcEqnKSJxi zN+eC8IVPRsVzDypfp513bruNLVLydfPUu7OTiPvg7mx5r41wq23kCdCfUcN5h2WT2VIIy 6HbqMPwsmGWymDJmjPnLaSWTgkx5v4OhIDjhSOTRTBVDMJyAWKYMeCQYx5fkK3rgkYgxio BK6koI6xJput+7p1FZfm+714V/qmIzaVeMsIxZwbPrus5wFberSZqpMUFXwAmw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721293697; a=rsa-sha256; cv=none; b=fl0jBdSocvUbILXslJ3BZdejss0ac06Up1T0UDlyC8l5snxDuAlpz5WmRQBlW+wEUz/7Qs wg9keQ+A8tf5kd1NgLRqMBgVCXPzk9RnRfQOFALsolHL4WijAtFViGqEuofAS2qTvV9hlk JUHAHqGMJIC2ihgU2jvoi43uzdMIstBujgjC9gQyI9gwb6eLBVNZzR3t25gtfiwCsxoza1 ZTmEcgFWADwz2Dkfx5x7x3qpeECeFeR/ld3P7z34E5Fr7CRVUp0UYV2PIjnKf+B8FRDfZx zhnwOfjyuONf77fOQKrwoMhmwrStxilz2xWgjWIQx3MglhYR1NDPqkS4dg2Ptw== 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=1721293697; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=FyBKXFbpS8PlIbrSo6oHr3s6MFUYVpquI957C7h9b/c=; b=gUV+M0oQLtAUcA+7hxt/YmHY7efWo1CBU+3v6WOsvkJJVHHb7p3mcvC7Cw+BCl+CTSacgU ARujIT8I0OIBJwPXD4mDErVpPgca5XY2ndrCnfHCSx6+loUcTexWiigaDbwryoOuJp7t4E j1n7FQZCtnoN0u9uYvedJvYrNpaYDthrrcTRW087k/8s2JC8hgUqovQ5WPJErMWqseE9E6 MUCC/au/B3RSMJcquud+tF5Q47GJUwPJ4xrpDjUZy5OIaeQTWcewQqrzVGe8aC+oqche70 +8rE51WmSPwsytE4RtrOk52Vlv4MDMDaRafcG8jMljB/HAVU4Gce8PRonDizKA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPn5s4bnYzhjc; Thu, 18 Jul 2024 09:08:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46I98HOL033145; Thu, 18 Jul 2024 09:08:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46I98E72033136; Thu, 18 Jul 2024 09:08:14 GMT (envelope-from git) Date: Thu, 18 Jul 2024 09:08:14 GMT Message-Id: <202407180908.46I98E72033136@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Martin Matuska Subject: git: 75e1fea68aaa - main - zfs: merge openzfs/zfs@1147a2797 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mm X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 75e1fea68aaa613a20dfdcd0c59dd403aca02c49 Auto-Submitted: auto-generated The branch main has been updated by mm: URL: https://cgit.FreeBSD.org/src/commit/?id=75e1fea68aaa613a20dfdcd0c59dd403aca02c49 commit 75e1fea68aaa613a20dfdcd0c59dd403aca02c49 Merge: a4469a0d19b6 1147a2797853 Author: Martin Matuska AuthorDate: 2024-07-18 07:44:47 +0000 Commit: Martin Matuska CommitDate: 2024-07-18 08:02:12 +0000 zfs: merge openzfs/zfs@1147a2797 Notable upstream pull request merges: #16209 --multi-- icp: rip out everything we don't use #16230 20c8bdd85 FreeBSD: Update use of UMA-related symbols in arc_available_memory #16242 121a2d335 FreeBSD: unregister mountroot eventhandler on unload #16258 5de3ac223 vdev_open: clear async fault flag after reopen #16270 436731276 zvol: Fix suspend lock leaks #16273 c87cb22ba head_errlog: fix use-after-free #16284 f72e081fb FreeBSD: Use a statement expression to implement SET_ERROR() #16300 a10faf5ce FreeBSD: Use the new freeuio() helper to free dynamically allocated UIOs #16302 a7fc4c85e zstd: don't call zstd_mempool_reap if there are no buffers #16334 dc91e7452 zdb: dump ZAP_FLAG_UINT64_KEY ZAPs properly Obtained from: OpenZFS OpenZFS commit: 1147a279785329a2eaeb01c0610c35fe835a62a6 cddl/lib/libicp/Makefile | 4 - cddl/lib/libicp_rescue/Makefile | 4 - sys/contrib/openzfs/META | 2 +- sys/contrib/openzfs/cmd/zdb/zdb.c | 96 ++- sys/contrib/openzfs/config/kernel-blk-queue.m4 | 4 +- sys/contrib/openzfs/config/kernel-blkdev.m4 | 26 + .../openzfs/config/kernel-kmap-local-page.m4 | 23 + sys/contrib/openzfs/config/kernel.m4 | 2 + sys/contrib/openzfs/config/zfs-build.m4 | 10 +- .../openzfs/contrib/bash_completion.d/zfs.in | 2 +- sys/contrib/openzfs/include/libzfs_core.h | 1 + .../openzfs/include/os/freebsd/spl/sys/sdt.h | 2 +- .../include/os/linux/kernel/linux/kmap_compat.h | 10 +- .../openzfs/include/os/linux/spl/sys/kmem_cache.h | 19 +- .../openzfs/include/os/linux/zfs/sys/trace_dbuf.h | 2 +- sys/contrib/openzfs/include/sys/avl_impl.h | 1 + sys/contrib/openzfs/include/sys/crypto/common.h | 27 - sys/contrib/openzfs/include/sys/crypto/icp.h | 3 - sys/contrib/openzfs/include/sys/sha2.h | 27 +- sys/contrib/openzfs/include/sys/skein.h | 9 - sys/contrib/openzfs/include/sys/spa.h | 3 +- sys/contrib/openzfs/lib/libicp/Makefile.am | 4 - sys/contrib/openzfs/lib/libzfs/libzfs_sendrecv.c | 2 +- .../openzfs/lib/libzfs_core/libzfs_core.abi | 6 + sys/contrib/openzfs/lib/libzfs_core/libzfs_core.c | 6 + sys/contrib/openzfs/man/man4/zfs.4 | 4 +- sys/contrib/openzfs/man/man7/dracut.zfs.7 | 2 +- sys/contrib/openzfs/man/man7/zfsprops.7 | 2 +- sys/contrib/openzfs/man/man8/zdb.8 | 3 +- sys/contrib/openzfs/module/Kbuild.in | 5 +- .../openzfs/module/icp/algs/aes/aes_modes.c | 37 +- sys/contrib/openzfs/module/icp/algs/modes/cbc.c | 264 ------- sys/contrib/openzfs/module/icp/algs/modes/ctr.c | 227 ------ sys/contrib/openzfs/module/icp/algs/modes/ecb.c | 127 --- sys/contrib/openzfs/module/icp/algs/modes/gcm.c | 79 +- sys/contrib/openzfs/module/icp/algs/modes/modes.c | 20 +- .../openzfs/module/icp/algs/sha2/sha2_generic.c | 75 +- .../openzfs/module/icp/core/kcf_mech_tabs.c | 8 +- sys/contrib/openzfs/module/icp/illumos-crypto.c | 7 - .../openzfs/module/icp/include/aes/aes_impl.h | 5 - .../openzfs/module/icp/include/modes/modes.h | 142 +--- .../openzfs/module/icp/include/sys/crypto/impl.h | 44 +- .../openzfs/module/icp/include/sys/crypto/spi.h | 40 - sys/contrib/openzfs/module/icp/include/sys/stack.h | 36 - sys/contrib/openzfs/module/icp/include/sys/trap.h | 36 - sys/contrib/openzfs/module/icp/io/aes.c | 854 +-------------------- sys/contrib/openzfs/module/icp/io/sha2_mod.c | 444 +---------- sys/contrib/openzfs/module/icp/io/skein_mod.c | 656 ---------------- .../openzfs/module/os/freebsd/spl/spl_uio.c | 12 +- sys/contrib/openzfs/module/os/freebsd/zfs/arc_os.c | 18 +- .../openzfs/module/os/freebsd/zfs/kmod_core.c | 21 +- .../openzfs/module/os/freebsd/zfs/zvol_os.c | 2 + .../openzfs/module/os/linux/spl/spl-kmem-cache.c | 12 +- sys/contrib/openzfs/module/os/linux/zfs/abd_os.c | 8 +- .../openzfs/module/os/linux/zfs/vdev_disk.c | 14 +- sys/contrib/openzfs/module/os/linux/zfs/zfs_uio.c | 8 +- sys/contrib/openzfs/module/os/linux/zfs/zvol_os.c | 289 +++++-- sys/contrib/openzfs/module/zfs/dsl_dataset.c | 7 +- sys/contrib/openzfs/module/zfs/vdev.c | 1 + sys/contrib/openzfs/scripts/dkms.mkconf | 1 + sys/contrib/openzfs/tests/runfiles/linux.run | 2 +- .../openzfs/tests/test-runner/bin/zts-report.py.in | 1 + .../tests/zfs-tests/cmd/checksum/sha2_test.c | 70 +- .../openzfs/tests/zfs-tests/include/libtest.shlib | 30 +- .../openzfs/tests/zfs-tests/tests/Makefile.am | 1 + .../functional/fault/suspend_resume_single.ksh | 102 +++ .../functional/redacted_send/redacted_deleted.ksh | 2 +- .../functional/redacted_send/redacted_mounts.ksh | 6 +- sys/modules/zfs/zfs_config.h | 12 +- sys/modules/zfs/zfs_gitrev.h | 2 +- 70 files changed, 704 insertions(+), 3329 deletions(-) diff --cc cddl/lib/libicp/Makefile index b1d926d65368,000000000000..b8bd3dc6df95 mode 100644,000000..100644 --- a/cddl/lib/libicp/Makefile +++ b/cddl/lib/libicp/Makefile @@@ -1,141 -1,0 +1,137 @@@ +.PATH: ${SRCTOP}/sys/contrib/openzfs/module/icp + +PACKAGE= zfs +LIB= icp +LIBADD= + +.if ${MACHINE_ARCH} == "amd64" +ASM_SOURCES_C = asm-x86_64/aes/aeskey.c +ASM_SOURCES_AS = \ + asm-x86_64/aes/aes_amd64.S \ + asm-x86_64/aes/aes_aesni.S \ + asm-x86_64/modes/gcm_pclmulqdq.S \ + asm-x86_64/modes/aesni-gcm-x86_64.S \ + asm-x86_64/modes/ghash-x86_64.S \ + asm-x86_64/sha2/sha256-x86_64.S \ + asm-x86_64/sha2/sha512-x86_64.S \ + asm-x86_64/blake3/blake3_avx2.S \ + asm-x86_64/blake3/blake3_avx512.S \ + asm-x86_64/blake3/blake3_sse2.S \ + asm-x86_64/blake3/blake3_sse41.S + +CFLAGS+= -D__amd64 -D_SYS_STACK_H -UHAVE_AES +.elif ${MACHINE_CPUARCH} == "arm" +ASM_SOURCES_C = +ASM_SOURCES_AS = \ + asm-arm/sha2/sha256-armv7.S \ + asm-arm/sha2/sha512-armv7.S +.elif ${MACHINE_ARCH} == "aarch64" +ASM_SOURCES_C = +ASM_SOURCES_AS = \ + asm-aarch64/blake3/b3_aarch64_sse2.S \ + asm-aarch64/blake3/b3_aarch64_sse41.S \ + asm-aarch64/sha2/sha256-armv8.S \ + asm-aarch64/sha2/sha512-armv8.S +.elif ${MACHINE_ARCH} == "powerpc64" +ASM_SOURCES_C = +ASM_SOURCES_AS = \ + asm-ppc64/sha2/sha256-ppc.S \ + asm-ppc64/sha2/sha512-ppc.S \ + asm-ppc64/sha2/sha256-p8.S \ + asm-ppc64/sha2/sha512-p8.S +.elif ${MACHINE_ARCH} == "powerpc64le" +ASM_SOURCES_C = +ASM_SOURCES_AS = \ + asm-ppc64/blake3/b3_ppc64le_sse2.S \ + asm-ppc64/blake3/b3_ppc64le_sse41.S \ + asm-ppc64/sha2/sha256-ppc.S \ + asm-ppc64/sha2/sha512-ppc.S \ + asm-ppc64/sha2/sha256-p8.S \ + asm-ppc64/sha2/sha512-p8.S +.else +ASM_SOURCES_C = +ASM_SOURCES_AS = +.endif + +KERNEL_C = \ + spi/kcf_spi.c \ + api/kcf_ctxops.c \ + api/kcf_cipher.c \ + api/kcf_mac.c \ + algs/aes/aes_impl_aesni.c \ + algs/aes/aes_impl_generic.c \ + algs/aes/aes_impl_x86-64.c \ + algs/aes/aes_impl.c \ + algs/aes/aes_modes.c \ + algs/blake3/blake3.c \ + algs/blake3/blake3_generic.c \ + algs/blake3/blake3_impl.c \ + algs/edonr/edonr.c \ + algs/modes/modes.c \ - algs/modes/cbc.c \ + algs/modes/gcm_generic.c \ + algs/modes/gcm_pclmulqdq.c \ + algs/modes/gcm.c \ - algs/modes/ctr.c \ + algs/modes/ccm.c \ - algs/modes/ecb.c \ + algs/sha2/sha2_generic.c \ + algs/sha2/sha256_impl.c \ + algs/sha2/sha512_impl.c \ + algs/skein/skein.c \ + algs/skein/skein_block.c \ + algs/skein/skein_iv.c \ + illumos-crypto.c \ + io/aes.c \ + io/sha2_mod.c \ - io/skein_mod.c \ + core/kcf_sched.c \ + core/kcf_prov_lib.c \ + core/kcf_callprov.c \ + core/kcf_mech_tabs.c \ + core/kcf_prov_tabs.c \ + $(ASM_SOURCES_C) + +.PATH: ${SRCTOP}/sys/contrib/openzfs/module/zfs +KERNEL_C+= zfs_impl.c + +SRCS= $(ASM_SOURCES_AS) $(KERNEL_C) + +WARNS?= 2 +SHLIB_MAJOR= 3 +CSTD= c99 +CFLAGS+= -DIN_BASE +CFLAGS+= -I${SRCTOP}/sys/contrib/openzfs/include +CFLAGS+= -I${SRCTOP}/sys/contrib/openzfs/lib/libspl/include/ +CFLAGS+= -I${SRCTOP}/sys/contrib/openzfs/lib/libspl/include/os/freebsd +CFLAGS+= -I${SRCTOP}/sys +CFLAGS+= -I${SRCTOP}/cddl/compat/opensolaris/include +CFLAGS+= -I${SRCTOP}/sys/contrib/openzfs/module/icp/include +CFLAGS+= -include ${SRCTOP}/sys/contrib/openzfs/include/os/freebsd/spl/sys/ccompile.h +CFLAGS+= -DHAVE_ISSETUGID +CFLAGS+= -include ${SRCTOP}/sys/modules/zfs/zfs_config.h + +CFLAGS.aes_amd64.S+= -DLOCORE +CFLAGS.aes_aesni.S+= -DLOCORE +CFLAGS.gcm_pclmulqdq.S+= -DLOCORE +CFLAGS.aesni-gcm-x86_64.S+= -DLOCORE +CFLAGS.ghash-x86_64.S+= -DLOCORE +CFLAGS.sha256-x86_64.S+= -DLOCORE +CFLAGS.sha512-x86_64.S+= -DLOCORE +CFLAGS.blake3_avx2.S = -DLOCORE +CFLAGS.blake3_avx512.S = -DLOCORE +CFLAGS.blake3_sse2.S = -DLOCORE +CFLAGS.blake3_sse41.S = -DLOCORE +CFLAGS.b3_aarch64_sse2.S = -DLOCORE +CFLAGS.b3_aarch64_sse41.S = -DLOCORE +CFLAGS.sha256-armv7.S = -DLOCORE +CFLAGS.sha256-armv8.S = -DLOCORE +CFLAGS.sha512-armv7.S = -DLOCORE +CFLAGS.sha512-armv8.S = -DLOCORE +CFLAGS.b3_ppc64le_sse2.S = -DLOCORE +CFLAGS.b3_ppc64le_sse41.S = -DLOCORE +CFLAGS.sha256-p8.S = -DLOCORE +CFLAGS.sha256-ppc.S = -DLOCORE +CFLAGS.sha512-p8.S = -DLOCORE +CFLAGS.sha512-ppc.S = -DLOCORE + + +LDFLAGS.bfd+= -Wl,-znoexecstack + +.include diff --cc cddl/lib/libicp_rescue/Makefile index c969b209a785,000000000000..3b332f736bde mode 100644,000000..100644 --- a/cddl/lib/libicp_rescue/Makefile +++ b/cddl/lib/libicp_rescue/Makefile @@@ -1,138 -1,0 +1,134 @@@ +.PATH: ${SRCTOP}/sys/contrib/openzfs/module/icp + +PACKAGE= utilities +LIB= icp_rescue +LIBADD= + +.if ${MACHINE_ARCH} == "amd64" +ASM_SOURCES_C = asm-x86_64/aes/aeskey.c +ASM_SOURCES_AS = \ + asm-x86_64/aes/aes_amd64.S \ + asm-x86_64/aes/aes_aesni.S \ + asm-x86_64/modes/gcm_pclmulqdq.S \ + asm-x86_64/modes/aesni-gcm-x86_64.S \ + asm-x86_64/sha2/sha256-x86_64.S \ + asm-x86_64/sha2/sha512-x86_64.S \ + asm-x86_64/blake3/blake3_avx2.S \ + asm-x86_64/blake3/blake3_avx512.S \ + asm-x86_64/blake3/blake3_sse2.S \ + asm-x86_64/blake3/blake3_sse41.S + +CFLAGS+= -D__amd64 -D_SYS_STACK_H +.elif ${MACHINE_CPUARCH} == "arm" +ASM_SOURCES_C = +ASM_SOURCES_AS = \ + asm-arm/sha2/sha256-armv7.S \ + asm-arm/sha2/sha512-armv7.S +.elif ${MACHINE_ARCH} == "aarch64" +ASM_SOURCES_C = +ASM_SOURCES_AS = \ + asm-aarch64/blake3/b3_aarch64_sse2.S \ + asm-aarch64/blake3/b3_aarch64_sse41.S \ + asm-aarch64/sha2/sha256-armv8.S \ + asm-aarch64/sha2/sha512-armv8.S +.elif ${MACHINE_ARCH} == "powerpc64" +ASM_SOURCES_C = +ASM_SOURCES_AS = \ + asm-ppc64/sha2/sha256-ppc.S \ + asm-ppc64/sha2/sha512-ppc.S \ + asm-ppc64/sha2/sha256-p8.S \ + asm-ppc64/sha2/sha512-p8.S +.elif ${MACHINE_ARCH} == "powerpc64le" +ASM_SOURCES_C = +ASM_SOURCES_AS = \ + asm-ppc64/blake3/b3_ppc64le_sse2.S \ + asm-ppc64/blake3/b3_ppc64le_sse41.S \ + asm-ppc64/sha2/sha256-ppc.S \ + asm-ppc64/sha2/sha512-ppc.S \ + asm-ppc64/sha2/sha256-p8.S \ + asm-ppc64/sha2/sha512-p8.S +.else +ASM_SOURCES_C = +ASM_SOURCES_AS = +.endif + +KERNEL_C = \ + spi/kcf_spi.c \ + api/kcf_ctxops.c \ + api/kcf_cipher.c \ + api/kcf_mac.c \ + algs/aes/aes_impl_aesni.c \ + algs/aes/aes_impl_generic.c \ + algs/aes/aes_impl_x86-64.c \ + algs/aes/aes_impl.c \ + algs/aes/aes_modes.c \ + algs/blake3/blake3.c \ + algs/blake3/blake3_generic.c \ + algs/blake3/blake3_impl.c \ + algs/edonr/edonr.c \ + algs/modes/modes.c \ - algs/modes/cbc.c \ + algs/modes/gcm_generic.c \ + algs/modes/gcm_pclmulqdq.c \ + algs/modes/gcm.c \ - algs/modes/ctr.c \ + algs/modes/ccm.c \ - algs/modes/ecb.c \ + algs/sha2/sha2_generic.c \ + algs/sha2/sha256_impl.c \ + algs/sha2/sha512_impl.c \ + algs/skein/skein_block.c \ + illumos-crypto.c \ + io/aes.c \ + io/sha2_mod.c \ - io/skein_mod.c \ + core/kcf_sched.c \ + core/kcf_prov_lib.c \ + core/kcf_callprov.c \ + core/kcf_mech_tabs.c \ + core/kcf_prov_tabs.c \ + $(ASM_SOURCES_C) + +.PATH: ${SRCTOP}/sys/contrib/openzfs/module/zfs +KERNEL_C+= zfs_impl.c + +SRCS= $(ASM_SOURCES_AS) $(KERNEL_C) + +WARNS?= 2 +SHLIB_MAJOR= 3 +CSTD= c99 +CFLAGS+= -DIN_BASE +CFLAGS+= -I${SRCTOP}/sys/contrib/openzfs/include +CFLAGS+= -I${SRCTOP}/sys/contrib/openzfs/lib/libspl/include/ +CFLAGS+= -I${SRCTOP}/sys/contrib/openzfs/lib/libspl/include/os/freebsd +CFLAGS+= -I${SRCTOP}/sys +CFLAGS+= -I${SRCTOP}/cddl/compat/opensolaris/include +CFLAGS+= -I${SRCTOP}/sys/contrib/openzfs/module/icp/include +CFLAGS+= -include ${SRCTOP}/sys/contrib/openzfs/include/os/freebsd/spl/sys/ccompile.h +CFLAGS+= -DHAVE_ISSETUGID -UHAVE_AVX -DRESCUE +CFLAGS+= -include ${SRCTOP}/sys/modules/zfs/zfs_config.h + +CFLAGS.aes_amd64.S+= -DLOCORE +CFLAGS.aes_aesni.S+= -DLOCORE +CFLAGS.gcm_pclmulqdq.S+= -DLOCORE +CFLAGS.aesni-gcm-x86_64.S+= -DLOCORE +CFLAGS.ghash-x86_64.S+= -DLOCORE +CFLAGS.sha256-x86_64.S+= -DLOCORE +CFLAGS.sha512-x86_64.S+= -DLOCORE +CFLAGS.gcm.c+= -UCAN_USE_GCM_ASM +CFLAGS.blake3_avx2.S = -DLOCORE +CFLAGS.blake3_avx512.S = -DLOCORE +CFLAGS.blake3_sse2.S = -DLOCORE +CFLAGS.blake3_sse41.S = -DLOCORE +CFLAGS.b3_aarch64_sse2.S = -DLOCORE +CFLAGS.b3_aarch64_sse41.S = -DLOCORE +CFLAGS.sha256-armv7.S = -DLOCORE +CFLAGS.sha512-armv7.S = -DLOCORE +CFLAGS.sha256-armv8.S = -DLOCORE +CFLAGS.sha512-armv8.S = -DLOCORE +CFLAGS.b3_ppc64le_sse2.S = -DLOCORE +CFLAGS.b3_ppc64le_sse41.S = -DLOCORE +CFLAGS.sha256-ppc.S = -DLOCORE +CFLAGS.sha256-p8.S = -DLOCORE +CFLAGS.sha512-ppc.S = -DLOCORE +CFLAGS.sha512-p8.S = -DLOCORE + +LDFLAGS.bfd+= -Wl,-znoexecstack + +.include diff --cc sys/contrib/openzfs/config/kernel-kmap-local-page.m4 index 000000000000,1990914d493d..1990914d493d mode 000000,100644..100644 --- a/sys/contrib/openzfs/config/kernel-kmap-local-page.m4 +++ b/sys/contrib/openzfs/config/kernel-kmap-local-page.m4 diff --cc sys/contrib/openzfs/tests/zfs-tests/tests/functional/fault/suspend_resume_single.ksh index 000000000000,041dadb1eadb..041dadb1eadb mode 000000,100755..100755 --- a/sys/contrib/openzfs/tests/zfs-tests/tests/functional/fault/suspend_resume_single.ksh +++ b/sys/contrib/openzfs/tests/zfs-tests/tests/functional/fault/suspend_resume_single.ksh diff --cc sys/modules/zfs/zfs_config.h index d5e9cebfffc7,000000000000..920bb59e2fc9 mode 100644,000000..100644 --- a/sys/modules/zfs/zfs_config.h +++ b/sys/modules/zfs/zfs_config.h @@@ -1,1233 -1,0 +1,1239 @@@ +/* + */ + +/* 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 + +/* backtrace() is available */ +/* #undef HAVE_BACKTRACE */ + +/* bdevname() is available */ +/* #undef HAVE_BDEVNAME */ + +/* bdev_check_media_change() exists */ +/* #undef HAVE_BDEV_CHECK_MEDIA_CHANGE */ + +/* bdev_file_open_by_path() exists */ +/* #undef HAVE_BDEV_FILE_OPEN_BY_PATH */ + +/* 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 */ + ++/* bdev_nr_bytes() is available */ ++/* #undef HAVE_BDEV_NR_BYTES */ ++ +/* bdev_open_by_path() exists */ +/* #undef HAVE_BDEV_OPEN_BY_PATH */ + +/* bdev_release() exists */ +/* #undef HAVE_BDEV_RELEASE */ + +/* 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(flags) is available */ +/* #undef HAVE_BLKDEV_ISSUE_DISCARD_ASYNC_FLAGS */ + +/* __blkdev_issue_discard() is available */ +/* #undef HAVE_BLKDEV_ISSUE_DISCARD_ASYNC_NOFLAGS */ + +/* blkdev_issue_discard(flags) is available */ +/* #undef HAVE_BLKDEV_ISSUE_DISCARD_FLAGS */ + +/* blkdev_issue_discard() is available */ +/* #undef HAVE_BLKDEV_ISSUE_DISCARD_NOFLAGS */ + +/* blkdev_issue_secure_erase() is available */ +/* #undef HAVE_BLKDEV_ISSUE_SECURE_ERASE */ + +/* blkdev_put() exists */ +/* #undef HAVE_BLKDEV_PUT */ + +/* 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_disk() exists and takes 2 args */ +/* #undef HAVE_BLK_ALLOC_DISK_2ARG */ + +/* 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 */ + +/* block multiqueue hardware context is cached in struct request */ +/* #undef HAVE_BLK_MQ_RQ_HCTX */ + +/* 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 */ + +/* Define to 1 if you have the 'execvpe' function. */ +#define HAVE_EXECVPE 1 + +/* 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 */ + +/* fsync_bdev() is declared in include/blkdev.h */ +/* #undef HAVE_FSYNC_BDEV */ + +/* 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 mnt_idmap* and u32 request_mask */ +/* #undef HAVE_GENERIC_FILLATTR_IDMAP_REQMASK */ + +/* 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 */ + +/* Define to 1 if you have the 'gettid' function. */ +/* #undef HAVE_GETTID */ + +/* 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 */ + +/* mnt_idmap does not have user_namespace */ +/* #undef HAVE_IDMAP_NO_USERNS */ + +/* Define if compiler supports -Wimplicit-fallthrough */ +/* #undef HAVE_IMPLICIT_FALLTHROUGH */ + +/* Define if compiler supports -Winfinite-recursion */ +/* #undef HAVE_INFINITE_RECURSION */ + +/* inode_get_atime() exists in linux/fs.h */ +/* #undef HAVE_INODE_GET_ATIME */ + +/* inode_get_ctime() exists in linux/fs.h */ +/* #undef HAVE_INODE_GET_CTIME */ + +/* inode_get_mtime() exists in linux/fs.h */ +/* #undef HAVE_INODE_GET_MTIME */ + +/* 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_atime_to_ts() exists in linux/fs.h */ +/* #undef HAVE_INODE_SET_ATIME_TO_TS */ + +/* inode_set_ctime_to_ts() exists in linux/fs.h */ +/* #undef HAVE_INODE_SET_CTIME_TO_TS */ + +/* inode_set_flags() exists */ +/* #undef HAVE_INODE_SET_FLAGS */ + +/* inode_set_iversion() exists */ +/* #undef HAVE_INODE_SET_IVERSION */ + +/* inode_set_mtime_to_ts() exists in linux/fs.h */ +/* #undef HAVE_INODE_SET_MTIME_TO_TS */ + +/* 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 */ *** 673 LINES SKIPPED *** From nobody Thu Jul 18 13:19:39 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPtgv5ZStz5RQt4; Thu, 18 Jul 2024 13:19: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPtgv47cnz40qg; Thu, 18 Jul 2024 13:19:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721308779; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Gp9Si0yl+x3L+QcwBnuNxuthXnqAPi+6G8omwPt1k0I=; b=DH2GNK84tYsWRsSR+TASZ5LBHZS/dalGV3oGOf0FxV/U0dL4FafA6fmpBmbqNOZuiElYAX 7THArBB3tSXNytuUtcMM20hfXKzdH8inHnp2FbNao5gxOwc/8GfRnqhTj3Ej3FgaC4cQJi +SPV09SDVIHNzpATQBf80hwfip+JSf8qIBCTMAviNdnkUANph9wMcHacX7QRCCyekOryHd TL0gypeK47srX/1ltLvF/7PqPUQEATxJTA/WC4u29TA/02xGhwvVBWwNGCosiIH9DAI56U c6OFzaCSRQ/aCnklZGWQeqtQmH+pSqP8PkvJ9iiWFDltxrWDFNzTW7FDDzJBcg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721308779; a=rsa-sha256; cv=none; b=uY5iGUemhcfBK8L+j7gpnZo+xQ6W/QMOw0xqLgjbXLonIl10eenAYblpkrHHMARWjcMCki fN6PEOc0wrizmmFmpAeF7hmFzQBmHIwCx49+ItRS51zo/+Oyn/tLjQKtaRWWUSF31ktHrU 3AxHNO8yQxctSdoE6LK5WP2oReFWKmg9ciptTWGld97OM19O+Bw43jq5rQrt7CLw96x8gW VNe1x1l/V03qScJt7ggrV/ztm7KcOAq+u6GCfSAm55utmg1ADGTnDoXXz6/hHtJNyNakUT YFnMaKaAgU+w0QmK7QMIKSeDfxIlva9WYg6ejtMpr4cxb6Au/Bn36qpiJtjhPg== 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=1721308779; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Gp9Si0yl+x3L+QcwBnuNxuthXnqAPi+6G8omwPt1k0I=; b=aAdQPAQrd22uutMUB336A21iov4oE359YFgmAx2vQkXOy/PtK0ETtvuVcdF0Ip6LZ7Xblv yEO45S14HlnQ1zBmqgu6D4x3RlwZDZzL+DZoRAj8AP4HTIAC5Wcyj0cJWjmgwlXfcOTSmt yBk34g/dDTgcn2coNFtXSmTMME1IzjHhXBLzU1feVBD2XwRcSOxAhTKYpHBm0XGmAGfaNP AiblbYvqmYp0IqPJC84Ixwx/Bmn/tADDaeQAjwCdv+nMMp7Ti5MN3H/EoPaAwv2nUmrvto 3Vr8rSuTat46Ro8m/8sm4MXfIbWgJm/mTUMBhcIWD+sRsPFqQmnM8AAilBGm7A== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPtgv3dQWzpmh; Thu, 18 Jul 2024 13:19:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46IDJd07055011; Thu, 18 Jul 2024 13:19:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46IDJdBj055008; Thu, 18 Jul 2024 13:19:39 GMT (envelope-from git) Date: Thu, 18 Jul 2024 13:19:39 GMT Message-Id: <202407181319.46IDJdBj055008@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mark Johnston Subject: git: 257e70f1d5ee - main - kyua: Add FreeBSD Jail execution environment support List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 257e70f1d5ee61037c8c59b116538d3b6b1427a2 Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=257e70f1d5ee61037c8c59b116538d3b6b1427a2 commit 257e70f1d5ee61037c8c59b116538d3b6b1427a2 Author: Igor Ostapenko AuthorDate: 2024-07-16 18:41:12 +0000 Commit: Mark Johnston CommitDate: 2024-07-18 13:18:28 +0000 kyua: Add FreeBSD Jail execution environment support A new Kyua concept is added -- "execution environment". A test can be configured to be run within a specific environment. The test case lifecycle is extended respectively: - execenv init (creates a jail or does nothing for default execenv="host") - test exec - cleanup exec (optional) - execenv cleanup (removes a jail or does nothing for default execenv="host") The following new functionality is provided, from bottom to top: 1 ATF based tests - The new "execenv" metadata property can be set to explicitly ask for an execution environment: "host" or "jail". If it's not defined, as all existing tests do, then it implicitly means "host". - The new "execenv.jail.params" metadata property can be optionally defined to ask Kyua to use specific jail(8) parameters during creation of a temporary jail. An example is "vnet allow.raw_sockets". Kyua implicitly adds "children.max" to "execenv_jail_params" parameters with the maximum possible value. A test case can override it. 2 Kyuafile - The same new metadata properties can be defined on Kyuafile level: "execenv" and "execenv_jail_params". - Note that historically ATF uses dotted style of metadata naming, while Kyua uses underscore style. Hence "execenv.jail.params" vs. "execenv_jail_params". 3 kyua.conf, kyua CLI - The new "execenvs" engine configuration variable can be set to a list of execution environments to run only tests designed for. Tests of not listed environments are skipped. - By default, this variable lists all execution environments supported by a Kyua binary, e.g. execenvs="host jail". - This variable can be changed via "kyua.conf" or via kyua CLI's "-v" parameter. For example, "kyua -v execenvs=host test" will run only host-based tests and skip jail-based ones. - Current value of this variable can be examined with "kyua config". [markj] This feature has not landed upstream yet. See the discussion in https://github.com/freebsd/kyua/pull/224 . Having the ability to automatically jail tests allows many network tests to run in parallel, giving a drastic speedup. So, let's import the feature and start using it in main. Signed-off-by: Igor Ostapenko Reviewed by: markj, kp Tested by: markj, kp MFC after: 3 months Differential Revision: https://reviews.freebsd.org/D45865 --- contrib/kyua/AUTHORS | 1 + contrib/kyua/cli/cmd_config_test.cpp | 12 +- contrib/kyua/doc/kyua.conf.5.in | 13 +- contrib/kyua/doc/kyuafile.5.in | 103 +++++++- contrib/kyua/drivers/report_junit_test.cpp | 8 + contrib/kyua/engine/atf.cpp | 11 +- contrib/kyua/engine/atf_list.cpp | 4 + contrib/kyua/engine/config.cpp | 18 ++ contrib/kyua/engine/execenv/execenv.cpp | 74 ++++++ contrib/kyua/engine/execenv/execenv.hpp | 149 +++++++++++ contrib/kyua/engine/execenv/execenv_host.cpp | 52 ++++ contrib/kyua/engine/execenv/execenv_host.hpp | 63 +++++ contrib/kyua/engine/plain.cpp | 7 +- contrib/kyua/engine/requirements.cpp | 33 +++ contrib/kyua/engine/scheduler.cpp | 274 ++++++++++++++++++- contrib/kyua/engine/scheduler.hpp | 1 + contrib/kyua/engine/tap.cpp | 7 +- contrib/kyua/examples/kyua.conf | 3 + contrib/kyua/integration/cmd_config_test.sh | 2 + contrib/kyua/integration/cmd_report_junit_test.sh | 8 + contrib/kyua/integration/cmd_report_test.sh | 2 + contrib/kyua/main.cpp | 3 + contrib/kyua/model/metadata.cpp | 76 ++++++ contrib/kyua/model/metadata.hpp | 5 + contrib/kyua/model/metadata_test.cpp | 8 +- contrib/kyua/model/test_case_test.cpp | 3 +- contrib/kyua/model/test_program_test.cpp | 13 +- contrib/kyua/os/freebsd/execenv_jail.cpp | 78 ++++++ contrib/kyua/os/freebsd/execenv_jail.hpp | 65 +++++ contrib/kyua/os/freebsd/execenv_jail_manager.cpp | 63 +++++ contrib/kyua/os/freebsd/execenv_jail_manager.hpp | 54 ++++ contrib/kyua/os/freebsd/execenv_jail_stub.cpp | 75 ++++++ contrib/kyua/os/freebsd/main.cpp | 54 ++++ contrib/kyua/os/freebsd/main.hpp | 41 +++ contrib/kyua/os/freebsd/utils/jail.cpp | 306 ++++++++++++++++++++++ contrib/kyua/os/freebsd/utils/jail.hpp | 64 +++++ contrib/kyua/utils/config/nodes.ipp | 9 +- contrib/kyua/utils/process/executor.cpp | 42 +++ contrib/kyua/utils/process/executor.hpp | 1 + usr.bin/kyua/Makefile | 15 +- 40 files changed, 1792 insertions(+), 28 deletions(-) diff --git a/contrib/kyua/AUTHORS b/contrib/kyua/AUTHORS index c7bd72ce776b..4cf65083015a 100644 --- a/contrib/kyua/AUTHORS +++ b/contrib/kyua/AUTHORS @@ -10,3 +10,4 @@ * The FreeBSD Foundation * Google Inc. +* Igor Ostapenko diff --git a/contrib/kyua/cli/cmd_config_test.cpp b/contrib/kyua/cli/cmd_config_test.cpp index f084f99bb90a..a5f6930ba027 100644 --- a/contrib/kyua/cli/cmd_config_test.cpp +++ b/contrib/kyua/cli/cmd_config_test.cpp @@ -61,6 +61,7 @@ fake_config(void) { config::tree user_config = engine::default_config(); user_config.set_string("architecture", "the-architecture"); + user_config.set_string("execenvs", "the-env"); user_config.set_string("parallelism", "128"); user_config.set_string("platform", "the-platform"); //user_config.set_string("unprivileged_user", ""); @@ -83,12 +84,13 @@ ATF_TEST_CASE_BODY(all) cmdline::ui_mock ui; ATF_REQUIRE_EQ(EXIT_SUCCESS, cmd.main(&ui, args, fake_config())); - ATF_REQUIRE_EQ(5, ui.out_log().size()); + ATF_REQUIRE_EQ(6, ui.out_log().size()); ATF_REQUIRE_EQ("architecture = the-architecture", ui.out_log()[0]); - ATF_REQUIRE_EQ("parallelism = 128", ui.out_log()[1]); - ATF_REQUIRE_EQ("platform = the-platform", ui.out_log()[2]); - ATF_REQUIRE_EQ("test_suites.foo.bar = first", ui.out_log()[3]); - ATF_REQUIRE_EQ("test_suites.foo.baz = second", ui.out_log()[4]); + ATF_REQUIRE_EQ("execenvs = the-env", ui.out_log()[1]); + ATF_REQUIRE_EQ("parallelism = 128", ui.out_log()[2]); + ATF_REQUIRE_EQ("platform = the-platform", ui.out_log()[3]); + ATF_REQUIRE_EQ("test_suites.foo.bar = first", ui.out_log()[4]); + ATF_REQUIRE_EQ("test_suites.foo.baz = second", ui.out_log()[5]); ATF_REQUIRE(ui.err_log().empty()); } diff --git a/contrib/kyua/doc/kyua.conf.5.in b/contrib/kyua/doc/kyua.conf.5.in index 05a9499b48c4..7188bb8888c3 100644 --- a/contrib/kyua/doc/kyua.conf.5.in +++ b/contrib/kyua/doc/kyua.conf.5.in @@ -1,4 +1,4 @@ -.\" Copyright 2012 The Kyua Authors. +.\" Copyright 2012-2024 The Kyua Authors. .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without @@ -25,7 +25,7 @@ .\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE .\" OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -.Dd February 20, 2015 +.Dd March 22, 2024 .Dt KYUA.CONF 5 .Os .Sh NAME @@ -36,6 +36,7 @@ .Pp Variables: .Va architecture , +.Va execenvs , .Va platform , .Va test_suites , .Va unprivileged_user . @@ -72,6 +73,14 @@ The following variables are internally recognized by .Bl -tag -width XX -offset indent .It Va architecture Name of the system architecture (aka processor type). +.It Va execenvs +Whitespace-separated list of execution environment names. +.Pp +Only tests which require one of the given execution environments will be run. +.Pp +See +.Xr kyuafile 5 +for the list of possible execution environments. .It Va parallelism Maximum number of test cases to execute concurrently. .It Va platform diff --git a/contrib/kyua/doc/kyuafile.5.in b/contrib/kyua/doc/kyuafile.5.in index 06cb2dbc42a8..a667f5dc2816 100644 --- a/contrib/kyua/doc/kyuafile.5.in +++ b/contrib/kyua/doc/kyuafile.5.in @@ -1,4 +1,4 @@ -.\" Copyright 2012 The Kyua Authors. +.\" Copyright 2012-2024 The Kyua Authors. .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without @@ -25,7 +25,7 @@ .\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE .\" OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -.Dd July 3, 2015 +.Dd March 23, 2024 .Dt KYUAFILE 5 .Os .Sh NAME @@ -173,6 +173,75 @@ Refer to the section below for clarification. .It Va description Textual description of the test. +.It Va execenv +The name of the execution environment to be used for running the test. +If empty or not defined, the +.Sq host +execution environment is meant. +The possible values are: +.Bl -tag -width xUnnnnnnn +.It host +The default environment which runs the test as a usual child process. +.It jail +The +.Fx +.Xr jail 8 +environment. +It creates a temporary jail to run the test and its optional cleanup logic +within. +.Pp +This feature requires +.Xr kyua 1 +to be running with superuser privileges. +.Pp +The difference between +.Va security.jail.children.max +and +.Va security.jail.children.cur +sysctl of the jail +.Xr kyua 1 +is running within must have a value high enough for the jail based tests +planned to be run. +For instance, the value 1 should be enough for a sequential run of simple +tests. +Otherwise, such aspects as parallel test execution and sub-jails spawned +by specific test cases should be considered. +.Pp +The formula of a temporary jail name is +.Sq kyua ++ +.Va test program path ++ +.Sq _ ++ +.Va test case name . +All non-alphanumeric characters are replaced with +.Sq _ . +.Sq kyua_usr_tests_sys_netpfil_pf_pass_block_v4 +is an example for /usr/tests/sys/netpfil/pf/pass_block:v4 test case. +.El +.It Va execenv_jail_params +Additional test-specific whitespace-separated parameters of +.Fx +.Xr jail 8 +to create a temporary jail within which the test is run. +It makes sense only if execenv is set to +.Sq jail . +.sp +.Xr kyua 1 +implicitly passes +.Sq children.max +parameter to +.Xr jail 8 +for a temporary jail with the maximum possible value according to +the jail +.Xr kyua 1 +itself is running within. +It allows tests to easily spawn their own sub-jails without additional +configuration. +It can be overridden via +.Va execenv_jail_params +if needed. .It Va is_exclusive If true, indicates that this test program cannot be executed along any other programs at the same time. @@ -360,6 +429,36 @@ test_suite('FreeBSD') plain_test_program{name='the_test', ['custom.FreeBSD-Bug-Id']='category/12345'} .Ed +.Ss FreeBSD jail execution environment +The following example configures the test to be run within a temporary jail +with +.Xr vnet 9 +support and the permission to create raw sockets: +.Bd -literal -offset indent +syntax(2) + +test_suite('FreeBSD') + +atf_test_program{name='network_test', + execenv='jail', + execenv_jail_params='vnet allow.raw_sockets', + required_user='root'} +.Ed +.Pp +A test case itself may have no requirements in superuser privileges, +but required_user='root' metadata property reminds that the jail execution +environment requires +.Xr kyua 1 +being running with root privileges, and the test is skipped otherwise with +the respective message. The combination of +.Va execenv +set to +.Sq jail +and +.Va required_user +set to +.Sq unprivileged +does not work respectively. .Ss Connecting disjoint test suites Now suppose you had various test suites on your file system and you would like to connect them together so that they could be executed and treated as diff --git a/contrib/kyua/drivers/report_junit_test.cpp b/contrib/kyua/drivers/report_junit_test.cpp index 462dca72f9be..0f009c6befd3 100644 --- a/contrib/kyua/drivers/report_junit_test.cpp +++ b/contrib/kyua/drivers/report_junit_test.cpp @@ -63,6 +63,8 @@ static const char* const default_metadata = "allowed_architectures is empty\n" "allowed_platforms is empty\n" "description is empty\n" + "execenv is empty\n" + "execenv_jail_params is empty\n" "has_cleanup = false\n" "is_exclusive = false\n" "required_configs is empty\n" @@ -80,6 +82,8 @@ static const char* const overriden_metadata = "allowed_architectures is empty\n" "allowed_platforms is empty\n" "description = Textual description\n" + "execenv is empty\n" + "execenv_jail_params is empty\n" "has_cleanup = false\n" "is_exclusive = false\n" "required_configs is empty\n" @@ -199,6 +203,8 @@ ATF_TEST_CASE_BODY(junit_metadata__overrides) .add_allowed_architecture("arch1") .add_allowed_platform("platform1") .set_description("This is a test") + .set_execenv("jail") + .set_execenv_jail_params("vnet") .set_has_cleanup(true) .set_is_exclusive(true) .add_required_config("config1") @@ -215,6 +221,8 @@ ATF_TEST_CASE_BODY(junit_metadata__overrides) + "allowed_architectures = arch1\n" + "allowed_platforms = platform1\n" + "description = This is a test\n" + + "execenv = jail\n" + + "execenv_jail_params = vnet\n" + "has_cleanup = true\n" + "is_exclusive = true\n" + "required_configs = config1\n" diff --git a/contrib/kyua/engine/atf.cpp b/contrib/kyua/engine/atf.cpp index eb63be20b0e7..f6746dd2f29f 100644 --- a/contrib/kyua/engine/atf.cpp +++ b/contrib/kyua/engine/atf.cpp @@ -39,6 +39,7 @@ extern "C" { #include "engine/atf_list.hpp" #include "engine/atf_result.hpp" #include "engine/exceptions.hpp" +#include "engine/execenv/execenv.hpp" #include "model/test_case.hpp" #include "model/test_program.hpp" #include "model/test_result.hpp" @@ -54,6 +55,7 @@ extern "C" { #include "utils/stream.hpp" namespace config = utils::config; +namespace execenv = engine::execenv; namespace fs = utils::fs; namespace process = utils::process; @@ -190,7 +192,10 @@ engine::atf_interface::exec_test(const model::test_program& test_program, args.push_back(F("-r%s") % (control_directory / result_name)); args.push_back(test_case_name); - process::exec(test_program.absolute_path(), args); + + auto e = execenv::get(test_program, test_case_name); + e->init(); + e->exec(args); } @@ -219,7 +224,9 @@ engine::atf_interface::exec_cleanup( } args.push_back(F("%s:cleanup") % test_case_name); - process::exec(test_program.absolute_path(), args); + + auto e = execenv::get(test_program, test_case_name); + e->exec(args); } diff --git a/contrib/kyua/engine/atf_list.cpp b/contrib/kyua/engine/atf_list.cpp index a16b889c74f0..c9c2fed70175 100644 --- a/contrib/kyua/engine/atf_list.cpp +++ b/contrib/kyua/engine/atf_list.cpp @@ -121,6 +121,10 @@ engine::parse_atf_metadata(const model::properties_map& props) mdbuilder.set_string("has_cleanup", value); } else if (name == "require.arch") { mdbuilder.set_string("allowed_architectures", value); + } else if (name == "execenv") { + mdbuilder.set_string("execenv", value); + } else if (name == "execenv.jail.params") { + mdbuilder.set_string("execenv_jail_params", value); } else if (name == "require.config") { mdbuilder.set_string("required_configs", value); } else if (name == "require.files") { diff --git a/contrib/kyua/engine/config.cpp b/contrib/kyua/engine/config.cpp index 3f162a94fbb5..a7c418e3164c 100644 --- a/contrib/kyua/engine/config.cpp +++ b/contrib/kyua/engine/config.cpp @@ -35,6 +35,7 @@ #include #include "engine/exceptions.hpp" +#include "engine/execenv/execenv.hpp" #include "utils/config/exceptions.hpp" #include "utils/config/parser.hpp" #include "utils/config/tree.ipp" @@ -43,6 +44,7 @@ #include "utils/text/operations.ipp" namespace config = utils::config; +namespace execenv = engine::execenv; namespace fs = utils::fs; namespace passwd = utils::passwd; namespace text = utils::text; @@ -59,6 +61,7 @@ static void init_tree(config::tree& tree) { tree.define< config::string_node >("architecture"); + tree.define< config::strings_set_node >("execenvs"); tree.define< config::positive_int_node >("parallelism"); tree.define< config::string_node >("platform"); tree.define< engine::user_node >("unprivileged_user"); @@ -74,6 +77,14 @@ static void set_defaults(config::tree& tree) { tree.set< config::string_node >("architecture", KYUA_ARCHITECTURE); + + std::set< std::string > supported; + for (auto em : execenv::execenvs()) + if (em->is_supported()) + supported.insert(em->name()); + supported.insert(execenv::default_execenv_name); + tree.set< config::strings_set_node >("execenvs", supported); + // TODO(jmmv): Automatically derive this from the number of CPUs in the // machine and forcibly set to a value greater than 1. Still testing // the new parallel implementation as of 2015-02-27 though. @@ -229,6 +240,13 @@ engine::empty_config(void) { config::tree tree(false); init_tree(tree); + + // Tests of Kyua itself tend to use an empty config, i.e. default + // execution environment is used. Let's allow it. + std::set< std::string > supported; + supported.insert(engine::execenv::default_execenv_name); + tree.set< config::strings_set_node >("execenvs", supported); + return tree; } diff --git a/contrib/kyua/engine/execenv/execenv.cpp b/contrib/kyua/engine/execenv/execenv.cpp new file mode 100644 index 000000000000..b043bcda52cb --- /dev/null +++ b/contrib/kyua/engine/execenv/execenv.cpp @@ -0,0 +1,74 @@ +// Copyright 2023 The Kyua Authors. +// All rights reserved. +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * 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. +// * Neither the name of Google Inc. nor the names of its contributors +// may be used to endorse or promote products derived from this software +// without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS 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 COPYRIGHT +// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +#include "engine/execenv/execenv.hpp" + +#include "engine/execenv/execenv_host.hpp" + +namespace execenv = engine::execenv; + +using utils::none; + + +const char* execenv::default_execenv_name = "host"; + + +/// List of registered execution environments, except default host one. +/// +/// Use register_execenv() to add an entry to this global list. +static std::vector< std::shared_ptr< execenv::manager > > + execenv_managers; + + +void +execenv::register_execenv(const std::shared_ptr< execenv::manager > manager) +{ + execenv_managers.push_back(manager); +} + + +const std::vector< std::shared_ptr< execenv::manager> > +execenv::execenvs() +{ + return execenv_managers; +} + + +std::unique_ptr< execenv::interface > +execenv::get(const model::test_program& test_program, + const std::string& test_case_name) +{ + for (auto m : execenv_managers) { + auto e = m->probe(test_program, test_case_name); + if (e != nullptr) + return e; + } + + return std::unique_ptr< execenv::interface >( + new execenv::execenv_host(test_program, test_case_name)); +} diff --git a/contrib/kyua/engine/execenv/execenv.hpp b/contrib/kyua/engine/execenv/execenv.hpp new file mode 100644 index 000000000000..e667ff205d85 --- /dev/null +++ b/contrib/kyua/engine/execenv/execenv.hpp @@ -0,0 +1,149 @@ +// Copyright 2023 The Kyua Authors. +// All rights reserved. +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * 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. +// * Neither the name of Google Inc. nor the names of its contributors +// may be used to endorse or promote products derived from this software +// without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS 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 COPYRIGHT +// OWNER 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. + +/// \file engine/execenv/execenv.hpp +/// Execution environment subsystem interface. + +#if !defined(ENGINE_EXECENV_EXECENV_HPP) +#define ENGINE_EXECENV_EXECENV_HPP + +#include "model/test_program.hpp" +#include "utils/optional.ipp" +#include "utils/process/operations_fwd.hpp" + +using utils::process::args_vector; +using utils::optional; + +namespace engine { +namespace execenv { + + +extern const char* default_execenv_name; + + +/// Abstract interface of an execution environment. +class interface { +protected: + const model::test_program& _test_program; + const std::string& _test_case_name; + +public: + /// Constructor. + /// + /// \param program The test program. + /// \param test_case_name Name of the test case. + interface(const model::test_program& test_program, + const std::string& test_case_name) : + _test_program(test_program), + _test_case_name(test_case_name) + {} + + /// Destructor. + virtual ~interface() {} + + /// Initializes execution environment. + /// + /// It's expected to be called inside a fork which runs + /// scheduler::interface::exec_test(), so we can fail a test fast if its + /// execution environment setup fails, and test execution could use the + /// configured proc environment, if expected. + virtual void init() const = 0; + + /// Cleanups or removes execution environment. + /// + /// It's expected to be called inside a fork for execenv cleanup. + virtual void cleanup() const = 0; + + /// Executes a test within the execution environment. + /// + /// It's expected to be called inside a fork which runs + /// scheduler::interface::exec_test() or exec_cleanup(). + /// + /// \param args The arguments to pass to the binary. + virtual void exec(const args_vector& args) const UTILS_NORETURN = 0; +}; + + +/// Abstract interface of an execution environment manager. +class manager { +public: + /// Destructor. + virtual ~manager() {} + + /// Returns name of an execution environment. + virtual const std::string& name() const = 0; + + /// Returns whether this execution environment is actually supported. + /// + /// It can be compile time and/or runtime check. + virtual bool is_supported() const = 0; + + /// Returns execution environment for a test. + /// + /// It checks if the given test is designed for this execution environment. + /// + /// \param program The test program. + /// \param test_case_name Name of the test case. + /// + /// \return An execenv object if the test conforms, or none. + virtual std::unique_ptr< interface > probe( + const model::test_program& test_program, + const std::string& test_case_name) const = 0; + + // TODO: execenv related extra metadata could be provided by a manager + // not to know how exactly and where it should be added to the kyua +}; + + +/// Registers an execution environment. +/// +/// \param manager Execution environment manager. +void register_execenv(const std::shared_ptr< manager > manager); + + +/// Returns list of registered execenv managers, except default host one. +/// +/// \return A vector of pointers to execenv managers. +const std::vector< std::shared_ptr< manager> > execenvs(); + + +/// Returns execution environment for a test case. +/// +/// \param program The test program. +/// \param test_case_name Name of the test case. +/// +/// \return An execution environment of a test. +std::unique_ptr< execenv::interface > get( + const model::test_program& test_program, + const std::string& test_case_name); + + +} // namespace execenv +} // namespace engine + +#endif // !defined(ENGINE_EXECENV_EXECENV_HPP) diff --git a/contrib/kyua/engine/execenv/execenv_host.cpp b/contrib/kyua/engine/execenv/execenv_host.cpp new file mode 100644 index 000000000000..4e37fca3e7d3 --- /dev/null +++ b/contrib/kyua/engine/execenv/execenv_host.cpp @@ -0,0 +1,52 @@ +// Copyright 2024 The Kyua Authors. +// All rights reserved. +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * 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. +// * Neither the name of Google Inc. nor the names of its contributors +// may be used to endorse or promote products derived from this software +// without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS 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 COPYRIGHT +// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +#include "engine/execenv/execenv_host.hpp" + +#include "utils/fs/path.hpp" +#include "utils/process/operations.hpp" + +void +execenv::execenv_host::init() const +{ + // nothing to do +} + + +void +execenv::execenv_host::cleanup() const +{ + // nothing to do +} + + +void +execenv::execenv_host::exec(const args_vector& args) const +{ + utils::process::exec(_test_program.absolute_path(), args); +} diff --git a/contrib/kyua/engine/execenv/execenv_host.hpp b/contrib/kyua/engine/execenv/execenv_host.hpp new file mode 100644 index 000000000000..2742366cfd6f --- /dev/null +++ b/contrib/kyua/engine/execenv/execenv_host.hpp @@ -0,0 +1,63 @@ +// Copyright 2024 The Kyua Authors. +// All rights reserved. +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * 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. +// * Neither the name of Google Inc. nor the names of its contributors +// may be used to endorse or promote products derived from this software +// without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS 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 COPYRIGHT +// OWNER 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. + +/// \file engine/execenv/execenv_host.hpp +/// Default execution environment. + +#if !defined(ENGINE_EXECENV_EXECENV_HOST_HPP) +#define ENGINE_EXECENV_EXECENV_HOST_HPP + +#include "engine/execenv/execenv.hpp" + +#include "utils/process/operations_fwd.hpp" + +namespace execenv = engine::execenv; + +using utils::process::args_vector; + +namespace engine { +namespace execenv { + + +class execenv_host : public execenv::interface { +public: + execenv_host(const model::test_program& test_program, + const std::string& test_case_name) : + execenv::interface(test_program, test_case_name) + {} + + void init() const; + void cleanup() const; + void exec(const args_vector& args) const UTILS_NORETURN; +}; + + +} // namespace execenv +} // namespace engine + +#endif // !defined(ENGINE_EXECENV_EXECENV_HOST_HPP) diff --git a/contrib/kyua/engine/plain.cpp b/contrib/kyua/engine/plain.cpp index 8346e50bbecf..9a2c63f8b663 100644 --- a/contrib/kyua/engine/plain.cpp +++ b/contrib/kyua/engine/plain.cpp @@ -34,6 +34,7 @@ extern "C" { #include +#include "engine/execenv/execenv.hpp" #include "model/test_case.hpp" #include "model/test_program.hpp" #include "model/test_result.hpp" @@ -47,6 +48,7 @@ extern "C" { #include "utils/sanity.hpp" namespace config = utils::config; +namespace execenv = engine::execenv; namespace fs = utils::fs; namespace process = utils::process; @@ -104,7 +106,10 @@ engine::plain_interface::exec_test( } process::args_vector args; - process::exec(test_program.absolute_path(), args); + + auto e = execenv::get(test_program, test_case_name); + e->init(); + e->exec(args); } diff --git a/contrib/kyua/engine/requirements.cpp b/contrib/kyua/engine/requirements.cpp index a7b0a90d97db..a6a4cae7511c 100644 --- a/contrib/kyua/engine/requirements.cpp +++ b/contrib/kyua/engine/requirements.cpp @@ -28,6 +28,7 @@ #include "engine/requirements.hpp" +#include "engine/execenv/execenv.hpp" #include "model/metadata.hpp" #include "model/types.hpp" #include "utils/config/nodes.ipp" @@ -100,6 +101,34 @@ check_allowed_architectures(const model::strings_set& allowed_architectures, } +/// Checks if test's execenv matches the user configuration. +/// +/// \param execenv Execution environment name a test is designed for. +/// \param user_config Runtime user configuration. +/// +/// \return Empty if the execenv is in the list or an error message otherwise. +static std::string +check_execenv(const std::string& execenv, const config::tree& user_config) +{ + std::string name = execenv; + if (name.empty()) + name = engine::execenv::default_execenv_name; // if test claims nothing + + std::set< std::string > execenvs; + try { + execenvs = user_config.lookup< config::strings_set_node >("execenvs"); + } catch (const config::unknown_key_error&) { + // okay, user config does not define it, empty set then + } + + if (execenvs.find(name) == execenvs.end()) + return F("'%s' execenv is not supported or not allowed by " + "the runtime user configuration") % name; + + return ""; +} + + /// Checks if the allowed platforms match the current architecture. /// /// \param allowed_platforms Set of allowed platforms. @@ -263,6 +292,10 @@ engine::check_reqs(const model::metadata& md, const config::tree& cfg, if (!reason.empty()) return reason; + reason = check_execenv(md.execenv(), cfg); + if (!reason.empty()) + return reason; + reason = check_allowed_platforms(md.allowed_platforms(), cfg); if (!reason.empty()) return reason; diff --git a/contrib/kyua/engine/scheduler.cpp b/contrib/kyua/engine/scheduler.cpp index e7b51d23acca..e75091a40e38 100644 --- a/contrib/kyua/engine/scheduler.cpp +++ b/contrib/kyua/engine/scheduler.cpp @@ -40,6 +40,7 @@ extern "C" { #include "engine/config.hpp" #include "engine/exceptions.hpp" +#include "engine/execenv/execenv.hpp" #include "engine/requirements.hpp" #include "model/context.hpp" #include "model/metadata.hpp" @@ -68,6 +69,7 @@ extern "C" { namespace config = utils::config; namespace datetime = utils::datetime; +namespace execenv = engine::execenv; namespace executor = utils::process::executor; namespace fs = utils::fs; namespace logging = utils::logging; @@ -87,6 +89,10 @@ using utils::optional; datetime::delta scheduler::cleanup_timeout(60, 0); +/// Timeout for the test case execenv cleanup operation. +datetime::delta scheduler::execenv_cleanup_timeout(60, 0); + + /// Timeout for the test case listing operation. /// /// TODO(jmmv): This is here only for testing purposes. Maybe we should expose @@ -206,6 +212,18 @@ struct test_exec_data : public exec_data { /// denote that no further attempts shall be made at cleaning this up. bool needs_cleanup; + /// Whether this test case still needs to have its execenv cleanup executed. + /// + /// This is set externally when the cleanup routine is actually invoked to + /// denote that no further attempts shall be made at cleaning this up. + bool needs_execenv_cleanup; + + /// Original PID of the test case subprocess. + /// + /// This is used for the cleanup upon termination by a signal, to reap the + /// leftovers and form missing exit_handle. + pid_t pid; + /// The exit_handle for this test once it has completed. /// *** 1720 LINES SKIPPED *** From nobody Thu Jul 18 14:11:18 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPvqW3BdHz5RVSd; Thu, 18 Jul 2024 14:11: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPvqV5Gs8z46Ty; Thu, 18 Jul 2024 14:11:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721311878; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=yPVVWrVMil2JdFBCMotDJHy/X7v6F9TH6tuev9/urBs=; b=ep2Sv5XcheoEEhe9vGF3H9bkL92+0SyDmLq88Jf/402S/Zc4CsqBGrEzb/vrnkl0Ykfkm8 2QqidpNtNG7YtgwxB6ynBrndzWboczzkyMBnp8nw0WAR5QbtHEqEYP/c9Kav4vvgH1Ml5p o0ZCzI0hWej9u0Ycj1FfDLadhBYRP0Q/3FLXiEt1x67jVAbrqnqdVCNZZyk9QG+LqYhXCf +G4iHew9J4aVuFTs5h9rkAq2EB9QHcuOKG0D21zxh77nW8SQOOrQ+IDWRhFxYoIni/4OGv F12CU/UA5e67piODp2P57dfM/z2Ekoc2VfpcPm+AZp7MFpAUkA3HnJODuhq6Uw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721311878; a=rsa-sha256; cv=none; b=pJYIimQyJVLI17djPtXsIgwK2DlJ3Dex6q+OmuxGeTa4cQUJACN5a610Uoj5/B70xrO9sw OYjmhrmXe8/nDSdU+/lHHiau5D9VbcyyqNunzqmFxvn9tpPtBlmFnCyi8hWG9d/ufanFEV 5cVni0/fBhwyDjNc+xrZh/YJ8+p3hfmOd5eMQCcjRtgUAsv3EfCTYZcVfHvEFCjhwSsCNw cbs0ZZI1nJPjb4cpuCD1zzAJkqMxuDg3b6Vs7WBLYwA4Hs5WUXo0f1iCrWLO/D0rHvgTgZ SokedLXHBxqUoeiMj76Ad8U54rpjqqqPlIz6kgPUzrSnlGw4XU0vgBrmr1ro0A== 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=1721311878; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=yPVVWrVMil2JdFBCMotDJHy/X7v6F9TH6tuev9/urBs=; b=Wc5zpl+8XnIVeVWoUIrnZKzt8mi00nbN9GT9X90FqRTY3Sq083mnLIzT5Neglm5/XlQt4S kMBK2fQy8l6X92IgTpWjw9lLnx9LEcnr0T1/Z5OD0YlaDfShbH7CP2sJzyCec0OdDiIKe7 /gE/WT0AvGfkd6iofT+HM73Pll2PoJOIk2477Ebt/rG3ByVD3rwxusc1HH1HIbkd0VLXI4 ziZrfjLKrhVXaOHDFkMrzfwGLrjK8w0fyKGmNfG70VfAXIw0Zt4AVfDFNPIWRkHoCXDbJ5 jU2jpysp+KtOAHQCgwXHfQUVr+nm76+BrskVZ/RWRXX/9WsFrXGnR3nxLUkwNQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPvqV4tCTzrgg; Thu, 18 Jul 2024 14:11:18 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46IEBIiA050196; Thu, 18 Jul 2024 14:11:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46IEBI0u050193; Thu, 18 Jul 2024 14:11:18 GMT (envelope-from git) Date: Thu, 18 Jul 2024 14:11:18 GMT Message-Id: <202407181411.46IEBI0u050193@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mark Johnston Subject: git: 2aeb3e204af3 - main - zdb: Chase a missing library dependency List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 2aeb3e204af3ce61fefa727035e68e80498218c1 Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=2aeb3e204af3ce61fefa727035e68e80498218c1 commit 2aeb3e204af3ce61fefa727035e68e80498218c1 Author: Mark Johnston AuthorDate: 2024-07-18 13:57:38 +0000 Commit: Mark Johnston CommitDate: 2024-07-18 13:57:38 +0000 zdb: Chase a missing library dependency Fixes: 75e1fea68aaa ("zfs: merge openzfs/zfs@1147a2797") --- cddl/usr.sbin/zdb/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cddl/usr.sbin/zdb/Makefile b/cddl/usr.sbin/zdb/Makefile index 22ab4421b30a..31013a1d8100 100644 --- a/cddl/usr.sbin/zdb/Makefile +++ b/cddl/usr.sbin/zdb/Makefile @@ -22,7 +22,7 @@ CFLAGS+= \ -include ${ZFSTOP}/include/os/freebsd/spl/sys/ccompile.h \ -DHAVE_ISSETUGID -LIBADD= nvpair umem uutil zdb zfs spl avl zutil zpool crypto +LIBADD= nvpair umem uutil zdb zfs_core zfs spl avl zutil zpool crypto CFLAGS.gcc+= -fms-extensions # Since there are many asserts in this program, it makes no sense to compile From nobody Thu Jul 18 14:54:56 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WPwns0mSFz5RYvc; Thu, 18 Jul 2024 14:54: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WPwns0GCGz4Cgp; Thu, 18 Jul 2024 14:54:57 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721314497; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=3R8ozw3e7g//YUFlQUunk+1PryIZ+tnkPgpy3hGaVgs=; b=u6hIQeb1KNrwEYsKk7Delc04VJAzMfTVplKuTAhMiatSDkZf/VUkI4iGEbGjNNpRhHWK0S m/Cd3TURHo7Ma8SVxH5SpUCugSA7Xhx/14BqTBCnl5Gl3mv1l8k5Z7IYHEplRuLWHb1ZO0 CiNlGxk8hElLl6qi5SKeSOqZfmAcYQfmpCfVBrVxbqiTUh+2e+MdQtanpHh+RFzAIBbXBG /oGTwgM1a1GsM29PTU6Pq6t9TCP2TigwHv7/2Nh37HTHtEjvL4jRLs+GsiBN2nWdKnDUkB UzgVj8BqIcMoFaiyTgclGYnXkG9kfggGaUDFRGYNnzZLNjFFbMu1IZySlW/Nlg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721314497; a=rsa-sha256; cv=none; b=IPMLm1SQJfwkhJp5hSRUerGL+LUTdflWuO9RBAk8hiUGO7DRCkIdWdoAUzWYWCUX9beyED /I0ocX/O+FqnkdYc7ZtKcfWbHywIgMkUsEOYR99Eb5sda9aYMGeNsGZrXTL92YTPHqtq1v ezY4Th7nJ1vVi7USsOJFALIQ49WK/MhUGLLYOXJxDv/38eD6/Qzt5l1eZcKFQzw1wdPoiO V/Lyk2wJcI2tub+Kjde+PnQM81aCCfdSzsBQ17VY1DFCAxCLrGq6ScWpipr/cA+ecRGfM6 nPYO3wyjXIj5j4NC4xnzB3PWNP4D9a95P8YLA5A5bYK49zoq8ddqlwAxNuP+Zw== 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=1721314497; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=3R8ozw3e7g//YUFlQUunk+1PryIZ+tnkPgpy3hGaVgs=; b=HBVRsjXFJC2B0SpiKMXWon+q/BkaqsadNCWeM2pErpvdgLYTc6xHGBzftz1SaRwbDCi8MX oX3Wi73kMlNIL4rKLm9Zy04uitAJswWTHNCabOdhSduv2lLB5l6km3LLqDJNyOEGRzCDLi 1w0Enj2AGsJINWRi281CPzY9pDuU1SN0EJr712m1q2WAO5/xIo+n+hTPrpRmNOcytFZG0E 0YmCk5Js7R6gLwXbRY9tNuJNTAdphrLkHIMgXnvUxENGgmR8Phrz2Jp6riS2ISnzjz+ycU lUAIcUByTS0/8PzQ1pz+e7JSRK1YPoiIpDlgnAIxM1x8FArbfyE7hwJreh6Q2Q== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WPwnr707Qzsxh; Thu, 18 Jul 2024 14:54:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46IEsuZJ022072; Thu, 18 Jul 2024 14:54:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46IEsuUJ022069; Thu, 18 Jul 2024 14:54:56 GMT (envelope-from git) Date: Thu, 18 Jul 2024 14:54:56 GMT Message-Id: <202407181454.46IEsuUJ022069@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mark Johnston Subject: git: f029f6277996 - main - zdb: Fix printf formatting of a uint64_t List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: f029f6277996760be4be42148295231af425cc2d Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=f029f6277996760be4be42148295231af425cc2d commit f029f6277996760be4be42148295231af425cc2d Author: Mark Johnston AuthorDate: 2024-07-18 14:52:52 +0000 Commit: Mark Johnston CommitDate: 2024-07-18 14:52:52 +0000 zdb: Fix printf formatting of a uint64_t This fixes the build on 32-bit platforms. Fixes: dc91e7452482 ("zdb: dump ZAP_FLAG_UINT64_KEY ZAPs properly (#16334)") --- sys/contrib/openzfs/cmd/zdb/zdb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/contrib/openzfs/cmd/zdb/zdb.c b/sys/contrib/openzfs/cmd/zdb/zdb.c index f55c7f7b8176..6063dc3b7cd3 100644 --- a/sys/contrib/openzfs/cmd/zdb/zdb.c +++ b/sys/contrib/openzfs/cmd/zdb/zdb.c @@ -1131,8 +1131,8 @@ dump_zap(objset_t *os, uint64_t object, void *data, size_t size) !!(zap_getflags(zc.zc_zap) & ZAP_FLAG_UINT64_KEY); if (key64) - (void) printf("\t\t0x%010lx = ", - *(uint64_t *)attr.za_name); + (void) printf("\t\t0x%010llx = ", + (u_longlong_t)*(uint64_t *)attr.za_name); else (void) printf("\t\t%s = ", attr.za_name); From nobody Thu Jul 18 17:29:37 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQ0DK4dMvz5RnG1; Thu, 18 Jul 2024 17:29: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQ0DK3gXKz4hT8; Thu, 18 Jul 2024 17:29:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721323777; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=A7C6QM9VcKvwtxE6RAIa37LwWdHudq0LROwPBzq641E=; b=mkX6d7A8uweCKcA7lYrX/lopu26nLh1Y13vYtbfNdZhYPK8lNaWw1BtUGSIFflMsyxSMxZ BJg+IKnxfrBPz2oFDEBeIazmC926KT4bKfm7eBk2qDHapjY4LwPWfPXEWOFvZGtBXaBJbp R2wSlyQ50/vr/SYJZJTx6wYGOn5nXRHI8NVSgK6CFKOj1cAgrtuPNXF4mKxry8haRIu5cZ GIcFHx15iEnTGONtP5RSg81po38pPAoifU74AzR7u9+kyAry+kcDiVRHQFzaCMfiZ+Euze /AcpI3Pv/sUFhEkuCz3sNcKNxzDuo8fwbyoOnw4XgBp/K40r300U2cYMC4DWcg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721323777; a=rsa-sha256; cv=none; b=B9Xt73IxGoed+N/RLzjsOr0mQ0TajXCiX9VvHUUPKXx8fTHypbbNy22kJDw6rYuxgZBdiH bs39Pzww5YqG87i4dJZQIMHsWkLl9qvlSK/05npJ9aVsh6o7OmiMloM5o51rNzMXBNG4cj x1MIoqkjSbPmmDWTn4ca2iwepawsOG2QuMbr23adoAx0aawIkVTLFMDkR6wAK1etTmiDns PatmCPj1v1tzOVJZkUgCiqR4pi1jIx5yxpcat2je/RyQlmIgPnjetd+F0sYtT6VArzubMW v3CS5kgNaamex5UB8sX5lv9mQ/bsm80K1H41Kodon3Bx4wFI8gcZqFP+2atmzA== 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=1721323777; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=A7C6QM9VcKvwtxE6RAIa37LwWdHudq0LROwPBzq641E=; b=O06vsdsKX1VCfV+1emsMitCaV8c72nhKCZV30dS1ID2ESMon5VhiErvTvqaC++be9UNRsO ULR9NYI43hpnWVkDTzkh2fiNo1SreymQTP1DW+Vp6fq0bnfHtTwJjsvQy6rhxKvWhE4LfT lIYiEGLoA7Xep8hQ34ldT2+ysP5GLhUFxHrgF2pEFfAUGYtdcOceIQtX+C6wDn3+qVAoEK rpk45LbFt+i6g6bQs6Wee8C6r3/pwpaQM6TOk/2dOStnYTtKKo6TeuQvKwy9BLlGCJqz1T +Q7lOk4V9UV0oSBUmVWR9xLtfVbZOA1aBBE6yO+4kD9hIjpW6lWvmUgp6Bifmw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQ0DK3GPyzxYH; Thu, 18 Jul 2024 17:29:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46IHTbkb082230; Thu, 18 Jul 2024 17:29:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46IHTbXL082227; Thu, 18 Jul 2024 17:29:37 GMT (envelope-from git) Date: Thu, 18 Jul 2024 17:29:37 GMT Message-Id: <202407181729.46IHTbXL082227@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 03248b3f5079 - main - NOTES: Correct swapped descriptions of virtio_scmi and virtio_scsi List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 03248b3f5079c490d949f4e8725a37624d707e14 Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=03248b3f5079c490d949f4e8725a37624d707e14 commit 03248b3f5079c490d949f4e8725a37624d707e14 Author: John Baldwin AuthorDate: 2024-07-18 17:28:57 +0000 Commit: John Baldwin CommitDate: 2024-07-18 17:28:57 +0000 NOTES: Correct swapped descriptions of virtio_scmi and virtio_scsi Sponsored by: Chelsio Communications --- sys/conf/NOTES | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/conf/NOTES b/sys/conf/NOTES index ecfa7aa5b33a..685125b782ca 100644 --- a/sys/conf/NOTES +++ b/sys/conf/NOTES @@ -2433,8 +2433,8 @@ device virtio_blk # VirtIO Block device device virtio_console # VirtIO Console device device virtio_gpu # VirtIO GPU device device virtio_random # VirtIO Entropy device -device virtio_scmi # VirtIO SCSI device -device virtio_scsi # VirtIO SCMI device +device virtio_scmi # VirtIO SCMI device +device virtio_scsi # VirtIO SCSI device ##################################################################### # HID support From nobody Thu Jul 18 17:56:26 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQ0qG2w8bz5Rq0n; Thu, 18 Jul 2024 17:56: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQ0qG2VRrz4lSn; Thu, 18 Jul 2024 17:56:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721325386; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ilTZCeE++EZ6ncrkb5Kot0qk4FPBJseZ2NB7H4bcflA=; b=KKJh2gXIY60KihhA6M6Q0I12JW8TBNNKqRlnbCdJuMmS3TjUKA6SQQHYeH98bUZCXbYRpL CoTyJGYYXNBC6Vl66tWVivh6iFKEgcMq3FZibRDCEI088t1wv9jj97opTjsUScwDrgmo48 BJ6ZcHIC8Wm//FFjUAXSq/LNjXoM4yq/cVgbbFiEF6S59BTtWTOwq8ZaMXZL5euMwavoFr dlOTcPlR/nIf1LMSivRv/p+tMiem/kP0UfDUBWld6phMkGnzB4gpsN725bIJ6WK9YO7ixh QwFzj/FT96HKWfy3gDTJ/kBPwF3CVkt69MxnolB/P0cw3s6TNCqgIIza7cqSZQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721325386; a=rsa-sha256; cv=none; b=RPKXfoop8y0ipooQmZHAFOuzWl68Q1e5KeFV7Wu3BFWhOZZctY8pBjClTy2QxkhPBfeH/5 ermrsMcvRkX+ftC9gCdKSx8D7q9nz5ZsRLfr5iS5g6aDGJUNBU2Ycrp1iQcXlJHJgIFtfD DXXiUiln3pgkp4SUtqX/FGOar0nhQvKV79Hbobq7hERvgNlD4vLxNWvfrlvlR2Tzrp34j+ 3Vdsu+SBsB0/SBBuYxJHBnxMfZnJiEz3Ojv7wJeuKb5Vzr9JKRp4I5Ad3mUO6uhIqHpGDd 602GRubkJkFYoH19h/bI/nMd4mEsbxzqHJ6KkPBPeLnTnT18Q6lx7AaSdpcWAA== 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=1721325386; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ilTZCeE++EZ6ncrkb5Kot0qk4FPBJseZ2NB7H4bcflA=; b=M9Lq4w1QrnIddCy84TedFKSStiZpbI7ekPmtlRZvGn0aWiqSVCjUWkGQ0DVrZFNR49u+zD egjZmwjiK2uZG83Kt9K9CEQJxZ2ky4eSGZ8KA/SwhckhiadMPrB/h5/5y/Cf0aAFZCd58G AQqt/6C3YOhdiehC+itWVE424s+vqeFwmZpvgn2Y3SDMXB8PZyMAJM1Og5LG7OnSuQsUaY l9JW4weiXBFI72rvMVk500dFoAmq1JG2mqXdXbLdBTmy11hqMp5aHpsLQaq+w5Eove40Jr kgbcck0Angio+l27PoHXBEzB/RZKpM7xY8dshfyLQBzwRBefZoffB5O2pl/Lcw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQ0qG25Kbzycq; Thu, 18 Jul 2024 17:56:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46IHuQDX032212; Thu, 18 Jul 2024 17:56:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46IHuQfZ032209; Thu, 18 Jul 2024 17:56:26 GMT (envelope-from git) Date: Thu, 18 Jul 2024 17:56:26 GMT Message-Id: <202407181756.46IHuQfZ032209@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Jessica Clarke Subject: git: 8415a654d02e - main - Retire non-NEW_PCIB code and remove config option List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jrtc27 X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 8415a654d02e1c4268885e667c539873db570576 Auto-Submitted: auto-generated The branch main has been updated by jrtc27: URL: https://cgit.FreeBSD.org/src/commit/?id=8415a654d02e1c4268885e667c539873db570576 commit 8415a654d02e1c4268885e667c539873db570576 Author: Jessica Clarke AuthorDate: 2024-07-18 17:55:12 +0000 Commit: Jessica Clarke CommitDate: 2024-07-18 17:55:12 +0000 Retire non-NEW_PCIB code and remove config option All architectures enable NEW_PCIB in DEFAULTS (arm being the most recent to do so in 121be555997b (arm: Set NEW_PCIB in DEFAULTS rather than a subset of kernel configs")), so it's time we removed the legacy code that no longer sees much testing and has a significant maintenance burden. Reviewed by: jhb, andrew, emaste Differential Revision: https://reviews.freebsd.org/D32954 --- sys/amd64/conf/DEFAULTS | 2 - sys/amd64/include/resource.h | 2 - sys/arm/conf/DEFAULTS | 1 - sys/arm/include/resource.h | 2 - sys/arm64/cavium/thunder_pcie_pem.c | 18 +- sys/arm64/conf/DEFAULTS | 1 - sys/arm64/include/resource.h | 2 - sys/conf/config.mk | 6 +- sys/conf/options | 1 - sys/dev/acpica/acpi_pcib_acpi.c | 31 +-- sys/dev/hyperv/pcib/vmbus_pcib.c | 3 - sys/dev/hyperv/vmbus/vmbus.c | 11 +- sys/dev/hyperv/vmbus/vmbus_var.h | 2 - sys/dev/ofw/ofw_pcib.c | 20 +- sys/dev/pccbb/pccbb_pci.c | 14 +- sys/dev/pci/pci.c | 12 +- sys/dev/pci/pci_host_generic.c | 26 +-- sys/dev/pci/pci_pci.c | 374 +----------------------------------- sys/dev/pci/pci_subr.c | 3 - sys/dev/pci/pcib_private.h | 19 +- sys/i386/conf/DEFAULTS | 2 - sys/i386/include/resource.h | 2 - sys/modules/cardbus/Makefile | 4 - sys/modules/cbb/Makefile | 4 - sys/powerpc/conf/DEFAULTS | 2 - sys/riscv/conf/DEFAULTS | 1 - sys/riscv/include/resource.h | 2 - sys/x86/include/mptable.h | 4 - sys/x86/pci/pci_bus.c | 6 +- sys/x86/pci/qpi.c | 4 +- sys/x86/x86/mptable.c | 12 -- sys/x86/x86/mptable_pci.c | 11 +- 32 files changed, 64 insertions(+), 540 deletions(-) diff --git a/sys/amd64/conf/DEFAULTS b/sys/amd64/conf/DEFAULTS index 5167cf4d98d0..eb8ee6b76a69 100644 --- a/sys/amd64/conf/DEFAULTS +++ b/sys/amd64/conf/DEFAULTS @@ -25,6 +25,4 @@ options GEOM_PART_GPT # Default congestion control algorithm options CC_CUBIC # include CUBIC congestion control -options NEW_PCIB - options NETLINK # netlink(4) support diff --git a/sys/amd64/include/resource.h b/sys/amd64/include/resource.h index 368a13b88d3a..9477572176e0 100644 --- a/sys/amd64/include/resource.h +++ b/sys/amd64/include/resource.h @@ -39,8 +39,6 @@ #define SYS_RES_DRQ 2 /* isa dma lines */ #define SYS_RES_MEMORY 3 /* i/o memory */ #define SYS_RES_IOPORT 4 /* i/o ports */ -#ifdef NEW_PCIB #define PCI_RES_BUS 5 /* PCI bus numbers */ -#endif #endif /* !_MACHINE_RESOURCE_H_ */ diff --git a/sys/arm/conf/DEFAULTS b/sys/arm/conf/DEFAULTS index 85d090dfa782..1acfe6349b4b 100644 --- a/sys/arm/conf/DEFAULTS +++ b/sys/arm/conf/DEFAULTS @@ -7,5 +7,4 @@ device mem # Default congestion control algorithm options CC_CUBIC # include CUBIC congestion control -options NEW_PCIB options INTRNG # All arm systems use INTRNG these days diff --git a/sys/arm/include/resource.h b/sys/arm/include/resource.h index d6b544d662d4..f7c2633c5f0d 100644 --- a/sys/arm/include/resource.h +++ b/sys/arm/include/resource.h @@ -40,8 +40,6 @@ #define SYS_RES_MEMORY 3 /* i/o memory */ #define SYS_RES_IOPORT 4 /* i/o ports */ #define SYS_RES_GPIO 5 /* general purpose i/o */ -#ifdef NEW_PCIB #define PCI_RES_BUS 6 /* PCI bus numbers */ -#endif #endif /* !_MACHINE_RESOURCE_H_ */ diff --git a/sys/arm64/cavium/thunder_pcie_pem.c b/sys/arm64/cavium/thunder_pcie_pem.c index a27ed810c618..c334342afe4a 100644 --- a/sys/arm64/cavium/thunder_pcie_pem.c +++ b/sys/arm64/cavium/thunder_pcie_pem.c @@ -254,13 +254,13 @@ thunder_pem_write_ivar(device_t dev, device_t child, int index, static int thunder_pem_activate_resource(device_t dev, device_t child, struct resource *r) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) struct thunder_pem_softc *sc; sc = device_get_softc(dev); #endif switch (rman_get_type(r)) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_activate_bus(sc->id, child, r)); #endif @@ -276,13 +276,13 @@ static int thunder_pem_deactivate_resource(device_t dev, device_t child, struct resource *r) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) struct thunder_pem_softc *sc; sc = device_get_softc(dev); #endif switch (rman_get_type(r)) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_deactivate_bus(sc->id, child, r)); #endif @@ -350,13 +350,13 @@ static int thunder_pem_adjust_resource(device_t dev, device_t child, struct resource *res, rman_res_t start, rman_res_t end) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) struct thunder_pem_softc *sc; sc = device_get_softc(dev); #endif switch (rman_get_type(res)) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_adjust_bus(sc->id, child, res, start, end)); #endif @@ -671,7 +671,7 @@ thunder_pem_alloc_resource(device_t dev, device_t child, int type, int *rid, device_t parent_dev; switch (type) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_alloc_bus(sc->id, child, rid, start, end, count, flags)); @@ -718,12 +718,12 @@ static int thunder_pem_release_resource(device_t dev, device_t child, struct resource *res) { device_t parent_dev; -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) struct thunder_pem_softc *sc = device_get_softc(dev); #endif switch (rman_get_type(res)) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_release_bus(sc->id, child, res)); #endif diff --git a/sys/arm64/conf/DEFAULTS b/sys/arm64/conf/DEFAULTS index 5d267af4b7d7..fb8b74783867 100644 --- a/sys/arm64/conf/DEFAULTS +++ b/sys/arm64/conf/DEFAULTS @@ -15,7 +15,6 @@ options GEOM_PART_GPT # Default congestion control algorithm options CC_CUBIC # include CUBIC congestion control -options NEW_PCIB options INTRNG options NETLINK # netlink(4) support diff --git a/sys/arm64/include/resource.h b/sys/arm64/include/resource.h index d4cffb1ae854..336fc11a435a 100644 --- a/sys/arm64/include/resource.h +++ b/sys/arm64/include/resource.h @@ -44,9 +44,7 @@ #define SYS_RES_MEMORY 3 /* i/o memory */ #define SYS_RES_IOPORT 4 /* i/o ports */ #define SYS_RES_GPIO 5 /* general purpose i/o */ -#ifdef NEW_PCIB #define PCI_RES_BUS 6 /* PCI bus numbers */ -#endif #endif /* !_MACHINE_RESOURCE_H_ */ diff --git a/sys/conf/config.mk b/sys/conf/config.mk index 729111b4ef3a..9ef3e7936a48 100644 --- a/sys/conf/config.mk +++ b/sys/conf/config.mk @@ -59,9 +59,9 @@ opt_sctp.h: opt_wlan.h: echo "#define IEEE80211_DEBUG 1" > ${.TARGET} echo "#define IEEE80211_SUPPORT_MESH 1" >> ${.TARGET} -KERN_OPTS.i386=NEW_PCIB DEV_PCI -KERN_OPTS.amd64=NEW_PCIB DEV_PCI -KERN_OPTS.powerpc=NEW_PCIB DEV_PCI +KERN_OPTS.i386=DEV_PCI +KERN_OPTS.amd64=DEV_PCI +KERN_OPTS.powerpc=DEV_PCI KERN_OPTS=MROUTING IEEE80211_DEBUG \ IEEE80211_SUPPORT_MESH DEV_BPF \ ${KERN_OPTS.${MACHINE}} ${KERN_OPTS_EXTRA} diff --git a/sys/conf/options b/sys/conf/options index 928927fe99df..8464fd919ff0 100644 --- a/sys/conf/options +++ b/sys/conf/options @@ -186,7 +186,6 @@ MFI_DEBUG opt_mfi.h MFI_DECODE_LOG opt_mfi.h MPROF_BUFFERS opt_mprof.h MPROF_HASH_SIZE opt_mprof.h -NEW_PCIB opt_global.h NO_ADAPTIVE_MUTEXES opt_adaptive_mutexes.h NO_ADAPTIVE_RWLOCKS NO_ADAPTIVE_SX diff --git a/sys/dev/acpica/acpi_pcib_acpi.c b/sys/dev/acpica/acpi_pcib_acpi.c index 4c3d62a66d58..18fece293183 100644 --- a/sys/dev/acpica/acpi_pcib_acpi.c +++ b/sys/dev/acpica/acpi_pcib_acpi.c @@ -67,9 +67,7 @@ struct acpi_hpcib_softc { int ap_addr; /* device/func of PCI-Host bridge */ ACPI_BUFFER ap_prt; /* interrupt routing table */ -#ifdef NEW_PCIB struct pcib_host_resources ap_host_res; -#endif }; static int acpi_pcib_acpi_probe(device_t bus); @@ -95,7 +93,6 @@ static struct resource *acpi_pcib_acpi_alloc_resource(device_t dev, device_t child, int type, int *rid, rman_res_t start, rman_res_t end, rman_res_t count, u_int flags); -#ifdef NEW_PCIB static int acpi_pcib_acpi_adjust_resource(device_t dev, device_t child, struct resource *r, rman_res_t start, rman_res_t end); @@ -107,7 +104,6 @@ static int acpi_pcib_acpi_activate_resource(device_t dev, static int acpi_pcib_acpi_deactivate_resource(device_t dev, device_t child, struct resource *r); #endif -#endif static int acpi_pcib_request_feature(device_t pcib, device_t dev, enum pci_feature feature); static bus_dma_tag_t acpi_pcib_get_dma_tag(device_t bus, device_t child); @@ -124,12 +120,8 @@ static device_method_t acpi_pcib_acpi_methods[] = { DEVMETHOD(bus_read_ivar, acpi_pcib_read_ivar), DEVMETHOD(bus_write_ivar, acpi_pcib_write_ivar), DEVMETHOD(bus_alloc_resource, acpi_pcib_acpi_alloc_resource), -#ifdef NEW_PCIB DEVMETHOD(bus_adjust_resource, acpi_pcib_acpi_adjust_resource), -#else - DEVMETHOD(bus_adjust_resource, bus_generic_adjust_resource), -#endif -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) DEVMETHOD(bus_release_resource, acpi_pcib_acpi_release_resource), DEVMETHOD(bus_activate_resource, acpi_pcib_acpi_activate_resource), DEVMETHOD(bus_deactivate_resource, acpi_pcib_acpi_deactivate_resource), @@ -183,7 +175,6 @@ acpi_pcib_acpi_probe(device_t dev) return (0); } -#ifdef NEW_PCIB static ACPI_STATUS acpi_pcib_producer_handler(ACPI_RESOURCE *res, void *context) { @@ -290,9 +281,8 @@ acpi_pcib_producer_handler(ACPI_RESOURCE *res, void *context) } return (AE_OK); } -#endif -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) static bool get_decoded_bus_range(struct acpi_hpcib_softc *sc, rman_res_t *startp, rman_res_t *endp) @@ -371,7 +361,7 @@ acpi_pcib_acpi_attach(device_t dev) ACPI_STATUS status; static int bus0_seen = 0; u_int slot, func, busok; -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) struct resource *bus_res; rman_res_t end, start; int rid; @@ -421,7 +411,6 @@ acpi_pcib_acpi_attach(device_t dev) sc->ap_addr = -1; } -#ifdef NEW_PCIB /* * Determine which address ranges this bridge decodes and setup * resource managers for those ranges. @@ -435,7 +424,6 @@ acpi_pcib_acpi_attach(device_t dev) device_printf(sc->ap_dev, "failed to parse resources: %s\n", AcpiFormatException(status)); } -#endif /* * Get our base bus number by evaluating _BBN. @@ -491,7 +479,7 @@ acpi_pcib_acpi_attach(device_t dev) } } -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) /* * If nothing else worked, hope that ACPI at least lays out the * Host-PCI bridges in order and that as a result the next free @@ -578,7 +566,7 @@ acpi_pcib_acpi_attach(device_t dev) errout: device_printf(device_get_parent(dev), "couldn't attach pci bus\n"); -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) pcib_host_res_free(dev, &sc->ap_host_res); #endif return (error); @@ -704,16 +692,13 @@ struct resource * acpi_pcib_acpi_alloc_resource(device_t dev, device_t child, int type, int *rid, rman_res_t start, rman_res_t end, rman_res_t count, u_int flags) { -#ifdef NEW_PCIB struct acpi_hpcib_softc *sc; struct resource *res; -#endif #if defined(__i386__) || defined(__amd64__) start = hostb_alloc_start(type, start, end, count); #endif -#ifdef NEW_PCIB sc = device_get_softc(dev); #ifdef PCI_RES_BUS if (type == PCI_RES_BUS) @@ -734,13 +719,8 @@ acpi_pcib_acpi_alloc_resource(device_t dev, device_t child, int type, int *rid, res = bus_generic_alloc_resource(dev, child, type, rid, start, end, count, flags); return (res); -#else - return (bus_generic_alloc_resource(dev, child, type, rid, start, end, - count, flags)); -#endif } -#ifdef NEW_PCIB int acpi_pcib_acpi_adjust_resource(device_t dev, device_t child, struct resource *r, rman_res_t start, rman_res_t end) @@ -793,7 +773,6 @@ acpi_pcib_acpi_deactivate_resource(device_t dev, device_t child, return (bus_generic_deactivate_resource(dev, child, r)); } #endif -#endif static int acpi_pcib_request_feature(device_t pcib, device_t dev, enum pci_feature feature) diff --git a/sys/dev/hyperv/pcib/vmbus_pcib.c b/sys/dev/hyperv/pcib/vmbus_pcib.c index f6237535cce3..9aec2fac698a 100644 --- a/sys/dev/hyperv/pcib/vmbus_pcib.c +++ b/sys/dev/hyperv/pcib/vmbus_pcib.c @@ -25,7 +25,6 @@ */ #include -#ifdef NEW_PCIB #include "opt_acpi.h" #include @@ -2042,5 +2041,3 @@ DEFINE_CLASS_0(pcib, vmbus_pcib_driver, vmbus_pcib_methods, DRIVER_MODULE(vmbus_pcib, vmbus, vmbus_pcib_driver, 0, 0); MODULE_DEPEND(vmbus_pcib, vmbus, 1, 1, 1); MODULE_DEPEND(vmbus_pcib, pci, 1, 1, 1); - -#endif /* NEW_PCIB */ diff --git a/sys/dev/hyperv/vmbus/vmbus.c b/sys/dev/hyperv/vmbus/vmbus.c index dee738f6e373..4157a4c41cea 100644 --- a/sys/dev/hyperv/vmbus/vmbus.c +++ b/sys/dev/hyperv/vmbus/vmbus.c @@ -1069,15 +1069,12 @@ vmbus_alloc_resource(device_t dev, device_t child, int type, int *rid, device_t parent = device_get_parent(dev); struct resource *res; -#ifdef NEW_PCIB if (type == SYS_RES_MEMORY) { struct vmbus_softc *sc = device_get_softc(dev); res = pcib_host_res_alloc(&sc->vmbus_mmio_res, child, type, rid, start, end, count, flags); - } else -#endif - { + } else { res = BUS_ALLOC_RESOURCE(parent, child, type, rid, start, end, count, flags); } @@ -1158,7 +1155,6 @@ vmbus_get_eventtq_method(device_t bus, device_t dev __unused, int cpu) return (VMBUS_PCPU_GET(sc, event_tq, cpu)); } -#ifdef NEW_PCIB #define VTPM_BASE_ADDR 0xfed40000 #define FOUR_GB (1ULL << 32) @@ -1375,7 +1371,6 @@ vmbus_free_mmio_res(device_t dev) if (hv_fb_res) hv_fb_res = NULL; } -#endif /* NEW_PCIB */ static void vmbus_identify(driver_t *driver, device_t parent) @@ -1460,10 +1455,8 @@ vmbus_doattach(struct vmbus_softc *sc) if (sc->vmbus_flags & VMBUS_FLAG_ATTACHED) return (0); -#ifdef NEW_PCIB vmbus_get_mmio_res(sc->vmbus_dev); vmbus_fb_mmio_res(sc->vmbus_dev); -#endif sc->vmbus_flags |= VMBUS_FLAG_ATTACHED; @@ -1681,9 +1674,7 @@ vmbus_detach(device_t dev) mtx_destroy(&sc->vmbus_prichan_lock); mtx_destroy(&sc->vmbus_chan_lock); -#ifdef NEW_PCIB vmbus_free_mmio_res(dev); -#endif #if defined(__aarch64__) bus_release_resource(device_get_parent(dev), SYS_RES_IRQ, sc->vector, diff --git a/sys/dev/hyperv/vmbus/vmbus_var.h b/sys/dev/hyperv/vmbus/vmbus_var.h index 4e0a769402d5..cadcaa45aae5 100644 --- a/sys/dev/hyperv/vmbus/vmbus_var.h +++ b/sys/dev/hyperv/vmbus/vmbus_var.h @@ -127,10 +127,8 @@ struct vmbus_softc { struct intr_config_hook vmbus_intrhook; -#ifdef NEW_PCIB /* The list of usable MMIO ranges for PCIe pass-through */ struct pcib_host_resources vmbus_mmio_res; -#endif #if defined(__aarch64__) struct resource *ires; diff --git a/sys/dev/ofw/ofw_pcib.c b/sys/dev/ofw/ofw_pcib.c index ebc09fccd93e..3f55e45f5b92 100644 --- a/sys/dev/ofw/ofw_pcib.c +++ b/sys/dev/ofw/ofw_pcib.c @@ -421,13 +421,13 @@ static struct resource * ofw_pcib_alloc_resource(device_t bus, device_t child, int type, int *rid, rman_res_t start, rman_res_t end, rman_res_t count, u_int flags) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) struct ofw_pci_softc *sc; sc = device_get_softc(bus); #endif switch (type) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_alloc_bus(sc->sc_pci_domain, child, rid, start, end, count, flags)); @@ -445,13 +445,13 @@ ofw_pcib_alloc_resource(device_t bus, device_t child, int type, int *rid, static int ofw_pcib_release_resource(device_t bus, device_t child, struct resource *res) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) struct ofw_pci_softc *sc; sc = device_get_softc(bus); #endif switch (rman_get_type(res)) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_release_bus(sc->sc_pci_domain, child, res)); #endif @@ -505,13 +505,13 @@ ofw_pcib_translate_resource(device_t bus, int type, rman_res_t start, static int ofw_pcib_activate_resource(device_t bus, device_t child, struct resource *res) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) struct ofw_pci_softc *sc; sc = device_get_softc(bus); #endif switch (rman_get_type(res)) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_activate_bus(sc->sc_pci_domain, child, res)); #endif @@ -621,13 +621,13 @@ ofw_pcib_bus_get_bus_tag(device_t bus, device_t child) static int ofw_pcib_deactivate_resource(device_t bus, device_t child, struct resource *res) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) struct ofw_pci_softc *sc; sc = device_get_softc(bus); #endif switch (rman_get_type(res)) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_deactivate_bus(sc->sc_pci_domain, child, res)); @@ -644,13 +644,13 @@ static int ofw_pcib_adjust_resource(device_t bus, device_t child, struct resource *res, rman_res_t start, rman_res_t end) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) struct ofw_pci_softc *sc; sc = device_get_softc(bus); #endif switch (rman_get_type(res)) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_adjust_bus(sc->sc_pci_domain, child, res, start, end)); diff --git a/sys/dev/pccbb/pccbb_pci.c b/sys/dev/pccbb/pccbb_pci.c index 3b66b3df3852..eca370d17ca5 100644 --- a/sys/dev/pccbb/pccbb_pci.c +++ b/sys/dev/pccbb/pccbb_pci.c @@ -276,7 +276,7 @@ cbb_print_config(device_t dev) static int cbb_pci_attach(device_t brdev) { -#if !(defined(NEW_PCIB) && defined(PCI_RES_BUS)) +#if !defined(PCI_RES_BUS) static int curr_bus_number = 2; /* XXX EVILE BAD (see below) */ uint32_t pribus; #endif @@ -293,7 +293,7 @@ cbb_pci_attach(device_t brdev) sc->cbdev = NULL; sc->domain = pci_get_domain(brdev); sc->pribus = pcib_get_bus(parent); -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) pci_write_config(brdev, PCIR_PRIBUS_2, sc->pribus, 1); pcib_setup_secbus(brdev, &sc->bus, 1); #else @@ -351,7 +351,7 @@ cbb_pci_attach(device_t brdev) CTLFLAG_RD, &sc->subbus, 0, "io range 2 open"); #endif -#if !(defined(NEW_PCIB) && defined(PCI_RES_BUS)) +#if !defined(PCI_RES_BUS) /* * This is a gross hack. We should be scanning the entire pci * tree, assigning bus numbers in a way such that we (1) can @@ -429,13 +429,13 @@ err: static int cbb_pci_detach(device_t brdev) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) struct cbb_softc *sc = device_get_softc(brdev); #endif int error; error = cbb_detach(brdev); -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) if (error == 0) pcib_free_secbus(brdev, &sc->bus); #endif @@ -787,7 +787,7 @@ cbb_pci_filt(void *arg) return retval; } -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) static struct resource * cbb_pci_alloc_resource(device_t bus, device_t child, int type, int *rid, rman_res_t start, rman_res_t end, rman_res_t count, u_int flags) @@ -931,7 +931,7 @@ static device_method_t cbb_methods[] = { /* bus methods */ DEVMETHOD(bus_read_ivar, cbb_read_ivar), DEVMETHOD(bus_write_ivar, cbb_write_ivar), -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) DEVMETHOD(bus_alloc_resource, cbb_pci_alloc_resource), DEVMETHOD(bus_adjust_resource, cbb_pci_adjust_resource), DEVMETHOD(bus_release_resource, cbb_pci_release_resource), diff --git a/sys/dev/pci/pci.c b/sys/dev/pci/pci.c index 171c6b710a32..efe017f9a3ba 100644 --- a/sys/dev/pci/pci.c +++ b/sys/dev/pci/pci.c @@ -405,7 +405,7 @@ static int pci_clear_bars; SYSCTL_INT(_hw_pci, OID_AUTO, clear_bars, CTLFLAG_RDTUN, &pci_clear_bars, 0, "Ignore firmware-assigned resources for BARs."); -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) static int pci_clear_buses; SYSCTL_INT(_hw_pci, OID_AUTO, clear_buses, CTLFLAG_RDTUN, &pci_clear_buses, 0, "Ignore firmware-assigned bus numbers."); @@ -3706,7 +3706,7 @@ xhci_early_takeover(device_t self) bus_release_resource(self, SYS_RES_MEMORY, rid, res); } -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) static void pci_reserve_secbus(device_t bus, device_t dev, pcicfgregs *cfg, struct resource_list *rl) @@ -4118,7 +4118,7 @@ pci_add_resources(device_t bus, device_t dev, int force, uint32_t prefetchmask) uhci_early_takeover(dev); } -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) /* * Reserve resources for secondary bus ranges behind bridge * devices. @@ -5551,7 +5551,7 @@ pci_alloc_multi_resource(device_t dev, device_t child, int type, int *rid, rl = &dinfo->resources; cfg = &dinfo->cfg; switch (type) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_alloc_secbus(dev, child, rid, start, end, count, flags)); @@ -5576,7 +5576,6 @@ pci_alloc_multi_resource(device_t dev, device_t child, int type, int *rid, break; case SYS_RES_IOPORT: case SYS_RES_MEMORY: -#ifdef NEW_PCIB /* * PCI-PCI bridge I/O window resources are not BARs. * For those allocations just pass the request up the @@ -5595,7 +5594,6 @@ pci_alloc_multi_resource(device_t dev, device_t child, int type, int *rid, type, rid, start, end, count, flags)); } } -#endif /* Reserve resources for this BAR if needed. */ rle = resource_list_find(rl, type, *rid); if (rle == NULL) { @@ -5668,7 +5666,6 @@ pci_release_resource(device_t dev, device_t child, struct resource *r) } #endif -#ifdef NEW_PCIB /* * PCI-PCI bridge I/O window resources are not BARs. For * those allocations just pass the request up the tree. @@ -5683,7 +5680,6 @@ pci_release_resource(device_t dev, device_t child, struct resource *r) return (bus_generic_release_resource(dev, child, r)); } } -#endif rl = &dinfo->resources; return (resource_list_release(rl, dev, child, r)); diff --git a/sys/dev/pci/pci_host_generic.c b/sys/dev/pci/pci_host_generic.c index c3dba9d72484..c3f4f03b76ad 100644 --- a/sys/dev/pci/pci_host_generic.c +++ b/sys/dev/pci/pci_host_generic.c @@ -416,13 +416,13 @@ int pci_host_generic_core_release_resource(device_t dev, device_t child, struct resource *res) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) struct generic_pcie_core_softc *sc; sc = device_get_softc(dev); #endif switch (rman_get_type(res)) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_release_bus(sc->ecam, child, res)); #endif @@ -506,17 +506,17 @@ struct resource * pci_host_generic_core_alloc_resource(device_t dev, device_t child, int type, int *rid, rman_res_t start, rman_res_t end, rman_res_t count, u_int flags) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) struct generic_pcie_core_softc *sc; #endif struct resource *res; -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) sc = device_get_softc(dev); #endif switch (type) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) case PCI_RES_BUS: res = pci_domain_alloc_bus(sc->ecam, child, rid, start, end, count, flags); @@ -543,13 +543,13 @@ pci_host_generic_core_alloc_resource(device_t dev, device_t child, int type, static int generic_pcie_activate_resource(device_t dev, device_t child, struct resource *r) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) struct generic_pcie_core_softc *sc; sc = device_get_softc(dev); #endif switch (rman_get_type(r)) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_activate_bus(sc->ecam, child, r)); #endif @@ -565,13 +565,13 @@ static int generic_pcie_deactivate_resource(device_t dev, device_t child, struct resource *r) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) struct generic_pcie_core_softc *sc; sc = device_get_softc(dev); #endif switch (rman_get_type(r)) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_deactivate_bus(sc->ecam, child, r)); #endif @@ -587,13 +587,13 @@ static int generic_pcie_adjust_resource(device_t dev, device_t child, struct resource *res, rman_res_t start, rman_res_t end) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) struct generic_pcie_core_softc *sc; sc = device_get_softc(dev); #endif switch (rman_get_type(res)) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_adjust_bus(sc->ecam, child, res, start, end)); @@ -619,7 +619,7 @@ generic_pcie_map_resource(device_t dev, device_t child, struct resource *r, type = rman_get_type(r); switch (type) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (EINVAL); #endif @@ -658,7 +658,7 @@ generic_pcie_unmap_resource(device_t dev, device_t child, struct resource *r, type = rman_get_type(r); switch (type) { -#if defined(NEW_PCIB) && defined(PCI_RES_BUS) +#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (EINVAL); #endif diff --git a/sys/dev/pci/pci_pci.c b/sys/dev/pci/pci_pci.c index 40b22c9802c4..7977b9148c9b 100644 --- a/sys/dev/pci/pci_pci.c +++ b/sys/dev/pci/pci_pci.c @@ -58,19 +58,16 @@ #include "pcib_if.h" static int pcib_probe(device_t dev); -static int pcib_suspend(device_t dev); static int pcib_resume(device_t dev); static bus_child_present_t pcib_child_present; static bus_alloc_resource_t pcib_alloc_resource; -#ifdef NEW_PCIB static bus_adjust_resource_t pcib_adjust_resource; static bus_release_resource_t pcib_release_resource; static bus_activate_resource_t pcib_activate_resource; static bus_deactivate_resource_t pcib_deactivate_resource; static bus_map_resource_t pcib_map_resource; static bus_unmap_resource_t pcib_unmap_resource; -#endif static int pcib_reset_child(device_t dev, device_t child, int flags); static int pcib_power_for_sleep(device_t pcib, device_t dev, @@ -101,7 +98,7 @@ static device_method_t pcib_methods[] = { DEVMETHOD(device_attach, pcib_attach), DEVMETHOD(device_detach, pcib_detach), DEVMETHOD(device_shutdown, bus_generic_shutdown), - DEVMETHOD(device_suspend, pcib_suspend), + DEVMETHOD(device_suspend, bus_generic_suspend), DEVMETHOD(device_resume, pcib_resume), /* Bus interface */ @@ -109,19 +106,12 @@ static device_method_t pcib_methods[] = { DEVMETHOD(bus_read_ivar, pcib_read_ivar), DEVMETHOD(bus_write_ivar, pcib_write_ivar), DEVMETHOD(bus_alloc_resource, pcib_alloc_resource), -#ifdef NEW_PCIB DEVMETHOD(bus_adjust_resource, pcib_adjust_resource), DEVMETHOD(bus_release_resource, pcib_release_resource), DEVMETHOD(bus_activate_resource, pcib_activate_resource), DEVMETHOD(bus_deactivate_resource, pcib_deactivate_resource), DEVMETHOD(bus_map_resource, pcib_map_resource), DEVMETHOD(bus_unmap_resource, pcib_unmap_resource), -#else - DEVMETHOD(bus_adjust_resource, bus_generic_adjust_resource), - DEVMETHOD(bus_release_resource, bus_generic_release_resource), - DEVMETHOD(bus_activate_resource, bus_generic_activate_resource), - DEVMETHOD(bus_deactivate_resource, bus_generic_deactivate_resource), -#endif DEVMETHOD(bus_setup_intr, bus_generic_setup_intr), DEVMETHOD(bus_teardown_intr, bus_generic_teardown_intr), DEVMETHOD(bus_reset_child, pcib_reset_child), @@ -150,11 +140,8 @@ static device_method_t pcib_methods[] = { DEFINE_CLASS_0(pcib, pcib_driver, pcib_methods, sizeof(struct pcib_softc)); EARLY_DRIVER_MODULE(pcib, pci, pcib_driver, NULL, NULL, BUS_PASS_BUS); -#if defined(NEW_PCIB) || defined(PCI_HP) SYSCTL_DECL(_hw_pci); -#endif -#ifdef NEW_PCIB static int pci_clear_pcib; SYSCTL_INT(_hw_pci, OID_AUTO, clear_pcib, CTLFLAG_RDTUN, &pci_clear_pcib, 0, "Clear firmware-assigned resources for PCI-PCI bridge I/O windows."); @@ -808,140 +795,6 @@ pcib_alloc_subbus(struct pcib_secbus *bus, device_t child, int *rid, } #endif -#else - -/* - * Is the prefetch window open (eg, can we allocate memory in it?) - */ -static int -pcib_is_prefetch_open(struct pcib_softc *sc) -{ - return (sc->pmembase > 0 && sc->pmembase < sc->pmemlimit); -} - -/* - * Is the nonprefetch window open (eg, can we allocate memory in it?) - */ -static int -pcib_is_nonprefetch_open(struct pcib_softc *sc) -{ - return (sc->membase > 0 && sc->membase < sc->memlimit); -} - -/* - * Is the io window open (eg, can we allocate ports in it?) - */ -static int -pcib_is_io_open(struct pcib_softc *sc) -{ - return (sc->iobase > 0 && sc->iobase < sc->iolimit); -} - -/* - * Get current I/O decode. - */ -static void -pcib_get_io_decode(struct pcib_softc *sc) -{ - device_t dev; - uint32_t iolow; - - dev = sc->dev; - - iolow = pci_read_config(dev, PCIR_IOBASEL_1, 1); - if ((iolow & PCIM_BRIO_MASK) == PCIM_BRIO_32) - sc->iobase = PCI_PPBIOBASE( - pci_read_config(dev, PCIR_IOBASEH_1, 2), iolow); - else - sc->iobase = PCI_PPBIOBASE(0, iolow); - - iolow = pci_read_config(dev, PCIR_IOLIMITL_1, 1); - if ((iolow & PCIM_BRIO_MASK) == PCIM_BRIO_32) - sc->iolimit = PCI_PPBIOLIMIT( - pci_read_config(dev, PCIR_IOLIMITH_1, 2), iolow); - else - sc->iolimit = PCI_PPBIOLIMIT(0, iolow); -} - -/* - * Get current memory decode. - */ -static void -pcib_get_mem_decode(struct pcib_softc *sc) -{ - device_t dev; - pci_addr_t pmemlow; - - dev = sc->dev; - - sc->membase = PCI_PPBMEMBASE(0, - pci_read_config(dev, PCIR_MEMBASE_1, 2)); - sc->memlimit = PCI_PPBMEMLIMIT(0, - pci_read_config(dev, PCIR_MEMLIMIT_1, 2)); - - pmemlow = pci_read_config(dev, PCIR_PMBASEL_1, 2); - if ((pmemlow & PCIM_BRPM_MASK) == PCIM_BRPM_64) - sc->pmembase = PCI_PPBMEMBASE( - pci_read_config(dev, PCIR_PMBASEH_1, 4), pmemlow); - else - sc->pmembase = PCI_PPBMEMBASE(0, pmemlow); - - pmemlow = pci_read_config(dev, PCIR_PMLIMITL_1, 2); - if ((pmemlow & PCIM_BRPM_MASK) == PCIM_BRPM_64) - sc->pmemlimit = PCI_PPBMEMLIMIT( - pci_read_config(dev, PCIR_PMLIMITH_1, 4), pmemlow); - else - sc->pmemlimit = PCI_PPBMEMLIMIT(0, pmemlow); -} - -/* - * Restore previous I/O decode. - */ -static void -pcib_set_io_decode(struct pcib_softc *sc) -{ - device_t dev; - uint32_t iohi; - - dev = sc->dev; - - iohi = sc->iobase >> 16; - if (iohi > 0) - pci_write_config(dev, PCIR_IOBASEH_1, iohi, 2); - pci_write_config(dev, PCIR_IOBASEL_1, sc->iobase >> 8, 1); - - iohi = sc->iolimit >> 16; - if (iohi > 0) - pci_write_config(dev, PCIR_IOLIMITH_1, iohi, 2); - pci_write_config(dev, PCIR_IOLIMITL_1, sc->iolimit >> 8, 1); -} - -/* - * Restore previous memory decode. - */ -static void -pcib_set_mem_decode(struct pcib_softc *sc) -{ - device_t dev; - pci_addr_t pmemhi; - - dev = sc->dev; - - pci_write_config(dev, PCIR_MEMBASE_1, sc->membase >> 16, 2); *** 719 LINES SKIPPED *** From nobody Thu Jul 18 17:56:27 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQ0qH3P7Zz5Rq7N; Thu, 18 Jul 2024 17:56: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQ0qH2zqXz4lW3; Thu, 18 Jul 2024 17:56:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721325387; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ASS/AkQJBamgADECYD/FERyobeFDoS9ByA8DdYOXG+Q=; b=tIDXOBBETe9RNe5D/SRFGVJldc3KNomCgiBQiK1KuSyg06MqrHoyG89MIg8RBvx+1psFM0 o+sRVg+91jGZ2cT2UIC0HsY27am2L+LKKN8itw1Jr994iwkXlIN6zYNwqho9P6TQJGad0F 0545ZBnoqgpV2VlwUf66UTV/0keqx/YqC7HgFHVTrVHMXs7hSFa1FhazBnuDZytwLsvmsA NqkyKmjq+pU2Yc+K/l0fdt2mqrXst4REz7STld/bzBmpuACH4X3lQSDD+26yLMYUUqqx8P I1HfqbVfUU+67t7SArbbBVcp11/zJe96scmaLqtZ5zrA4vnDC2DUYv8nKB1waQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721325387; a=rsa-sha256; cv=none; b=R73t+ePFr+0ViVc94Epa+rAdt4idXPJNj6etW4ExERq2EQl70yx2TUzWeXqKnt+jxS81qb nWAGXjH1/BxKz8uRfOBYiej1IrIZYPKjNr6Z/Q4E9ThrkqKh+NVVSg8E8PdzwyBe5G03vg l1E4ViN5iQO4xmLrahcjD0lEiX9Sxn/rhMqSXX/NWYPzD6r5ujDFEZtbDCBs3cwbfDnapQ Ogb3aXQtDQaM8Qp38FDVp6AY1LZQ+lPwtHwUMp/g3Tkfg2NUB8x64Prpb7E//+gJTteb0k hQ5ePHazH5LBgxz+TGrBuIJXLf/i9xSw8tmSHRRuydNIPRumE0cpzHv7YDq0ZQ== 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=1721325387; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ASS/AkQJBamgADECYD/FERyobeFDoS9ByA8DdYOXG+Q=; b=pWAc4Hk0YAGS2pUjV7MkPPIISt5JzL+lhsppW2d8eSDRpwDAALT6NEMpU7R089vlCWvuwC 0DTb/6/DFKzu0WuzSGiqqc5LDC7wBM61yp0u2AYNNAf/zCYNCtSIOXCyDNWiYsDf+0dGn9 taxZawFko4thFkODThgJF/UzRG/g5XhTi4EJ9BoGjFIMD9LxwAoMCS57aD+OIDMQR8F/4R irqKJh+ZhXcrh0z5+SOFPAlLs9foRlf22aNkXiHN1FCR5ZSfJwZk9te0Y3bdKpqbTTBW4F UzJ5Ot+6d4tQDtSSBWXgzaQK4Vho18o6KIh7VV/Te+G+AgJC8L8gVT9b67RhfA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQ0qH2XwzzyXt; Thu, 18 Jul 2024 17:56:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46IHuRLk032251; Thu, 18 Jul 2024 17:56:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46IHuRhK032248; Thu, 18 Jul 2024 17:56:27 GMT (envelope-from git) Date: Thu, 18 Jul 2024 17:56:27 GMT Message-Id: <202407181756.46IHuRhK032248@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Jessica Clarke Subject: git: e1d442a6db14 - main - Retire unused non-PCI_RES_BUS code List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jrtc27 X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e1d442a6db14adcfc11fc204225037da4332dd21 Auto-Submitted: auto-generated The branch main has been updated by jrtc27: URL: https://cgit.FreeBSD.org/src/commit/?id=e1d442a6db14adcfc11fc204225037da4332dd21 commit e1d442a6db14adcfc11fc204225037da4332dd21 Author: Jessica Clarke AuthorDate: 2024-07-18 17:55:33 +0000 Commit: Jessica Clarke CommitDate: 2024-07-18 17:55:33 +0000 Retire unused non-PCI_RES_BUS code All architectures define PCI_RES_BUS unconditionally now that only NEW_PCIB is supported, so we no longer need the legacy code. Reviewed by: jhb, andrew Differential Revision: https://reviews.freebsd.org/D32955 --- sys/arm/mv/mv_pci.c | 18 ----------- sys/arm64/cavium/thunder_pcie_pem.c | 18 ----------- sys/dev/acpica/acpi_pcib_acpi.c | 35 --------------------- sys/dev/cardbus/cardbus.c | 10 ------ sys/dev/cardbus/cardbusvar.h | 2 -- sys/dev/ofw/ofw_pcib.c | 20 ------------ sys/dev/pccbb/pccbb_pci.c | 46 ---------------------------- sys/dev/pci/pci.c | 18 ----------- sys/dev/pci/pci_host_generic.c | 26 ---------------- sys/dev/pci/pci_pci.c | 61 +------------------------------------ sys/dev/pci/pci_private.h | 2 -- sys/dev/pci/pci_subr.c | 2 -- sys/dev/pci/pcib_private.h | 4 --- sys/x86/pci/pci_bus.c | 11 ------- sys/x86/pci/qpi.c | 9 ------ sys/x86/x86/mptable_pci.c | 10 ------ 16 files changed, 1 insertion(+), 291 deletions(-) diff --git a/sys/arm/mv/mv_pci.c b/sys/arm/mv/mv_pci.c index eb1af5a4e237..87c6fbae3ca4 100644 --- a/sys/arm/mv/mv_pci.c +++ b/sys/arm/mv/mv_pci.c @@ -913,11 +913,9 @@ mv_pcib_alloc_resource(device_t dev, device_t child, int type, int *rid, case SYS_RES_IOPORT: case SYS_RES_MEMORY: break; -#ifdef PCI_RES_BUS case PCI_RES_BUS: return (pci_domain_alloc_bus(sc->ap_segment, child, rid, start, end, count, flags)); -#endif default: return (BUS_ALLOC_RESOURCE(device_get_parent(dev), dev, type, rid, start, end, count, flags)); @@ -941,20 +939,16 @@ static int mv_pcib_adjust_resource(device_t dev, device_t child, struct resource *r, rman_res_t start, rman_res_t end) { -#ifdef PCI_RES_BUS struct mv_pcib_softc *sc = device_get_softc(dev); -#endif switch (rman_get_type(r)) { case SYS_RES_IOPORT: case SYS_RES_MEMORY: return (bus_generic_rman_adjust_resource(dev, child, r, start, end)); -#ifdef PCI_RES_BUS case PCI_RES_BUS: return (pci_domain_adjust_bus(sc->ap_segment, child, r, start, end)); -#endif default: return (bus_generic_adjust_resource(dev, child, r, start, end)); } @@ -963,18 +957,14 @@ mv_pcib_adjust_resource(device_t dev, device_t child, static int mv_pcib_release_resource(device_t dev, device_t child, struct resource *res) { -#ifdef PCI_RES_BUS struct mv_pcib_softc *sc = device_get_softc(dev); -#endif switch (rman_get_type(res)) { case SYS_RES_IOPORT: case SYS_RES_MEMORY: return (bus_generic_rman_release_resource(dev, child, res)); -#ifdef PCI_RES_BUS case PCI_RES_BUS: return (pci_domain_release_bus(sc->ap_segment, child, res)); -#endif default: return (bus_generic_release_resource(dev, child, res)); } @@ -983,18 +973,14 @@ mv_pcib_release_resource(device_t dev, device_t child, struct resource *res) static int mv_pcib_activate_resource(device_t dev, device_t child, struct resource *r) { -#ifdef PCI_RES_BUS struct mv_pcib_softc *sc = device_get_softc(dev); -#endif switch (rman_get_type(r)) { case SYS_RES_IOPORT: case SYS_RES_MEMORY: return (bus_generic_rman_activate_resource(dev, child, r)); -#ifdef PCI_RES_BUS case PCI_RES_BUS: return (pci_domain_activate_bus(sc->ap_segment, child, r)); -#endif default: return (bus_generic_activate_resource(dev, child, r)); } @@ -1003,18 +989,14 @@ mv_pcib_activate_resource(device_t dev, device_t child, struct resource *r) static int mv_pcib_deactivate_resource(device_t dev, device_t child, struct resource *r) { -#ifdef PCI_RES_BUS struct mv_pcib_softc *sc = device_get_softc(dev); -#endif switch (rman_get_type(r)) { case SYS_RES_IOPORT: case SYS_RES_MEMORY: return (bus_generic_rman_deactivate_resource(dev, child, r)); -#ifdef PCI_RES_BUS case PCI_RES_BUS: return (pci_domain_deactivate_bus(sc->ap_segment, child, r)); -#endif default: return (bus_generic_deactivate_resource(dev, child, r)); } diff --git a/sys/arm64/cavium/thunder_pcie_pem.c b/sys/arm64/cavium/thunder_pcie_pem.c index c334342afe4a..89393d9701d0 100644 --- a/sys/arm64/cavium/thunder_pcie_pem.c +++ b/sys/arm64/cavium/thunder_pcie_pem.c @@ -254,16 +254,12 @@ thunder_pem_write_ivar(device_t dev, device_t child, int index, static int thunder_pem_activate_resource(device_t dev, device_t child, struct resource *r) { -#if defined(PCI_RES_BUS) struct thunder_pem_softc *sc; sc = device_get_softc(dev); -#endif switch (rman_get_type(r)) { -#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_activate_bus(sc->id, child, r)); -#endif case SYS_RES_MEMORY: case SYS_RES_IOPORT: return (bus_generic_rman_activate_resource(dev, child, r)); @@ -276,16 +272,12 @@ static int thunder_pem_deactivate_resource(device_t dev, device_t child, struct resource *r) { -#if defined(PCI_RES_BUS) struct thunder_pem_softc *sc; sc = device_get_softc(dev); -#endif switch (rman_get_type(r)) { -#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_deactivate_bus(sc->id, child, r)); -#endif case SYS_RES_MEMORY: case SYS_RES_IOPORT: return (bus_generic_rman_deactivate_resource(dev, child, r)); @@ -350,16 +342,12 @@ static int thunder_pem_adjust_resource(device_t dev, device_t child, struct resource *res, rman_res_t start, rman_res_t end) { -#if defined(PCI_RES_BUS) struct thunder_pem_softc *sc; sc = device_get_softc(dev); -#endif switch (rman_get_type(res)) { -#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_adjust_bus(sc->id, child, res, start, end)); -#endif case SYS_RES_MEMORY: case SYS_RES_IOPORT: return (bus_generic_rman_adjust_resource(dev, child, res, start, @@ -671,11 +659,9 @@ thunder_pem_alloc_resource(device_t dev, device_t child, int type, int *rid, device_t parent_dev; switch (type) { -#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_alloc_bus(sc->id, child, rid, start, end, count, flags)); -#endif case SYS_RES_IOPORT: case SYS_RES_MEMORY: break; @@ -718,15 +704,11 @@ static int thunder_pem_release_resource(device_t dev, device_t child, struct resource *res) { device_t parent_dev; -#if defined(PCI_RES_BUS) struct thunder_pem_softc *sc = device_get_softc(dev); -#endif switch (rman_get_type(res)) { -#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_release_bus(sc->id, child, res)); -#endif case SYS_RES_MEMORY: case SYS_RES_IOPORT: return (bus_generic_rman_release_resource(dev, child, res)); diff --git a/sys/dev/acpica/acpi_pcib_acpi.c b/sys/dev/acpica/acpi_pcib_acpi.c index 18fece293183..ff211102cc3c 100644 --- a/sys/dev/acpica/acpi_pcib_acpi.c +++ b/sys/dev/acpica/acpi_pcib_acpi.c @@ -96,14 +96,12 @@ static struct resource *acpi_pcib_acpi_alloc_resource(device_t dev, static int acpi_pcib_acpi_adjust_resource(device_t dev, device_t child, struct resource *r, rman_res_t start, rman_res_t end); -#ifdef PCI_RES_BUS static int acpi_pcib_acpi_release_resource(device_t dev, device_t child, struct resource *r); static int acpi_pcib_acpi_activate_resource(device_t dev, device_t child, struct resource *r); static int acpi_pcib_acpi_deactivate_resource(device_t dev, device_t child, struct resource *r); -#endif static int acpi_pcib_request_feature(device_t pcib, device_t dev, enum pci_feature feature); static bus_dma_tag_t acpi_pcib_get_dma_tag(device_t bus, device_t child); @@ -121,15 +119,9 @@ static device_method_t acpi_pcib_acpi_methods[] = { DEVMETHOD(bus_write_ivar, acpi_pcib_write_ivar), DEVMETHOD(bus_alloc_resource, acpi_pcib_acpi_alloc_resource), DEVMETHOD(bus_adjust_resource, acpi_pcib_acpi_adjust_resource), -#if defined(PCI_RES_BUS) DEVMETHOD(bus_release_resource, acpi_pcib_acpi_release_resource), DEVMETHOD(bus_activate_resource, acpi_pcib_acpi_activate_resource), DEVMETHOD(bus_deactivate_resource, acpi_pcib_acpi_deactivate_resource), -#else - DEVMETHOD(bus_release_resource, bus_generic_release_resource), - DEVMETHOD(bus_activate_resource, bus_generic_activate_resource), - DEVMETHOD(bus_deactivate_resource, bus_generic_deactivate_resource), -#endif DEVMETHOD(bus_setup_intr, bus_generic_setup_intr), DEVMETHOD(bus_teardown_intr, bus_generic_teardown_intr), DEVMETHOD(bus_get_cpus, acpi_pcib_get_cpus), @@ -243,11 +235,9 @@ acpi_pcib_producer_handler(ACPI_RESOURCE *res, void *context) case ACPI_IO_RANGE: type = SYS_RES_IOPORT; break; -#ifdef PCI_RES_BUS case ACPI_BUS_NUMBER_RANGE: type = PCI_RES_BUS; break; -#endif default: return (AE_OK); } @@ -282,7 +272,6 @@ acpi_pcib_producer_handler(ACPI_RESOURCE *res, void *context) return (AE_OK); } -#if defined(PCI_RES_BUS) static bool get_decoded_bus_range(struct acpi_hpcib_softc *sc, rman_res_t *startp, rman_res_t *endp) @@ -296,7 +285,6 @@ get_decoded_bus_range(struct acpi_hpcib_softc *sc, rman_res_t *startp, *endp = rle->end; return (true); } -#endif static int acpi_pcib_osc(struct acpi_hpcib_softc *sc, uint32_t osc_ctl) @@ -361,11 +349,9 @@ acpi_pcib_acpi_attach(device_t dev) ACPI_STATUS status; static int bus0_seen = 0; u_int slot, func, busok; -#if defined(PCI_RES_BUS) struct resource *bus_res; rman_res_t end, start; int rid; -#endif int error, domain; uint8_t busno; @@ -479,7 +465,6 @@ acpi_pcib_acpi_attach(device_t dev) } } -#if defined(PCI_RES_BUS) /* * If nothing else worked, hope that ACPI at least lays out the * Host-PCI bridges in order and that as a result the next free @@ -524,18 +509,6 @@ acpi_pcib_acpi_attach(device_t dev) } } } -#else - /* - * If nothing else worked, hope that ACPI at least lays out the - * host-PCI bridges in order and that as a result our unit number - * is actually our bus number. There are several reasons this - * might not be true. - */ - if (busok == 0) { - sc->ap_bus = device_get_unit(dev); - device_printf(dev, "trying bus number %d\n", sc->ap_bus); - } -#endif /* If this is bus 0 on segment 0, note that it has been seen already. */ if (sc->ap_segment == 0 && sc->ap_bus == 0) @@ -566,9 +539,7 @@ acpi_pcib_acpi_attach(device_t dev) errout: device_printf(device_get_parent(dev), "couldn't attach pci bus\n"); -#if defined(PCI_RES_BUS) pcib_host_res_free(dev, &sc->ap_host_res); -#endif return (error); } @@ -700,11 +671,9 @@ acpi_pcib_acpi_alloc_resource(device_t dev, device_t child, int type, int *rid, #endif sc = device_get_softc(dev); -#ifdef PCI_RES_BUS if (type == PCI_RES_BUS) return (pci_domain_alloc_bus(sc->ap_segment, child, rid, start, end, count, flags)); -#endif res = pcib_host_res_alloc(&sc->ap_host_res, child, type, rid, start, end, count, flags); @@ -728,15 +697,12 @@ acpi_pcib_acpi_adjust_resource(device_t dev, device_t child, struct acpi_hpcib_softc *sc; sc = device_get_softc(dev); -#ifdef PCI_RES_BUS if (rman_get_type(r) == PCI_RES_BUS) return (pci_domain_adjust_bus(sc->ap_segment, child, r, start, end)); -#endif return (pcib_host_res_adjust(&sc->ap_host_res, child, r, start, end)); } -#ifdef PCI_RES_BUS int acpi_pcib_acpi_release_resource(device_t dev, device_t child, struct resource *r) @@ -772,7 +738,6 @@ acpi_pcib_acpi_deactivate_resource(device_t dev, device_t child, return (pci_domain_deactivate_bus(sc->ap_segment, child, r)); return (bus_generic_deactivate_resource(dev, child, r)); } -#endif static int acpi_pcib_request_feature(device_t pcib, device_t dev, enum pci_feature feature) diff --git a/sys/dev/cardbus/cardbus.c b/sys/dev/cardbus/cardbus.c index ffa90ebb6224..ff6a0992c6b9 100644 --- a/sys/dev/cardbus/cardbus.c +++ b/sys/dev/cardbus/cardbus.c @@ -93,13 +93,10 @@ static int cardbus_attach(device_t cbdev) { struct cardbus_softc *sc; -#ifdef PCI_RES_BUS int rid; -#endif sc = device_get_softc(cbdev); sc->sc_dev = cbdev; -#ifdef PCI_RES_BUS rid = 0; sc->sc_bus = bus_alloc_resource(cbdev, PCI_RES_BUS, &rid, pcib_get_bus(cbdev), pcib_get_bus(cbdev), 1, 0); @@ -107,25 +104,18 @@ cardbus_attach(device_t cbdev) device_printf(cbdev, "failed to allocate bus number\n"); return (ENXIO); } -#else - device_printf(cbdev, "Your bus numbers may be AFU\n"); -#endif return (0); } static int cardbus_detach(device_t cbdev) { -#ifdef PCI_RES_BUS struct cardbus_softc *sc; -#endif cardbus_detach_card(cbdev); -#ifdef PCI_RES_BUS sc = device_get_softc(cbdev); device_printf(cbdev, "Freeing up the allocatd bus\n"); (void)bus_release_resource(cbdev, PCI_RES_BUS, 0, sc->sc_bus); -#endif return (0); } diff --git a/sys/dev/cardbus/cardbusvar.h b/sys/dev/cardbus/cardbusvar.h index 5ebedf2e2621..12ad42ee94f7 100644 --- a/sys/dev/cardbus/cardbusvar.h +++ b/sys/dev/cardbus/cardbusvar.h @@ -68,9 +68,7 @@ struct cardbus_devinfo struct cardbus_softc { device_t sc_dev; -#ifdef PCI_RES_BUS struct resource *sc_bus; -#endif }; /* diff --git a/sys/dev/ofw/ofw_pcib.c b/sys/dev/ofw/ofw_pcib.c index 3f55e45f5b92..3dd90ab5002c 100644 --- a/sys/dev/ofw/ofw_pcib.c +++ b/sys/dev/ofw/ofw_pcib.c @@ -421,17 +421,13 @@ static struct resource * ofw_pcib_alloc_resource(device_t bus, device_t child, int type, int *rid, rman_res_t start, rman_res_t end, rman_res_t count, u_int flags) { -#if defined(PCI_RES_BUS) struct ofw_pci_softc *sc; sc = device_get_softc(bus); -#endif switch (type) { -#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_alloc_bus(sc->sc_pci_domain, child, rid, start, end, count, flags)); -#endif case SYS_RES_MEMORY: case SYS_RES_IOPORT: return (bus_generic_rman_alloc_resource(bus, child, type, rid, @@ -445,16 +441,12 @@ ofw_pcib_alloc_resource(device_t bus, device_t child, int type, int *rid, static int ofw_pcib_release_resource(device_t bus, device_t child, struct resource *res) { -#if defined(PCI_RES_BUS) struct ofw_pci_softc *sc; sc = device_get_softc(bus); -#endif switch (rman_get_type(res)) { -#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_release_bus(sc->sc_pci_domain, child, res)); -#endif case SYS_RES_MEMORY: case SYS_RES_IOPORT: return (bus_generic_rman_release_resource(bus, child, res)); @@ -505,16 +497,12 @@ ofw_pcib_translate_resource(device_t bus, int type, rman_res_t start, static int ofw_pcib_activate_resource(device_t bus, device_t child, struct resource *res) { -#if defined(PCI_RES_BUS) struct ofw_pci_softc *sc; sc = device_get_softc(bus); -#endif switch (rman_get_type(res)) { -#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_activate_bus(sc->sc_pci_domain, child, res)); -#endif case SYS_RES_MEMORY: case SYS_RES_IOPORT: return (bus_generic_rman_activate_resource(bus, child, res)); @@ -621,17 +609,13 @@ ofw_pcib_bus_get_bus_tag(device_t bus, device_t child) static int ofw_pcib_deactivate_resource(device_t bus, device_t child, struct resource *res) { -#if defined(PCI_RES_BUS) struct ofw_pci_softc *sc; sc = device_get_softc(bus); -#endif switch (rman_get_type(res)) { -#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_deactivate_bus(sc->sc_pci_domain, child, res)); -#endif case SYS_RES_MEMORY: case SYS_RES_IOPORT: return (bus_generic_rman_deactivate_resource(bus, child, res)); @@ -644,17 +628,13 @@ static int ofw_pcib_adjust_resource(device_t bus, device_t child, struct resource *res, rman_res_t start, rman_res_t end) { -#if defined(PCI_RES_BUS) struct ofw_pci_softc *sc; sc = device_get_softc(bus); -#endif switch (rman_get_type(res)) { -#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_adjust_bus(sc->sc_pci_domain, child, res, start, end)); -#endif case SYS_RES_MEMORY: case SYS_RES_IOPORT: return (bus_generic_rman_adjust_resource(bus, child, res, diff --git a/sys/dev/pccbb/pccbb_pci.c b/sys/dev/pccbb/pccbb_pci.c index eca370d17ca5..263ef0fd8aa8 100644 --- a/sys/dev/pccbb/pccbb_pci.c +++ b/sys/dev/pccbb/pccbb_pci.c @@ -276,10 +276,6 @@ cbb_print_config(device_t dev) static int cbb_pci_attach(device_t brdev) { -#if !defined(PCI_RES_BUS) - static int curr_bus_number = 2; /* XXX EVILE BAD (see below) */ - uint32_t pribus; -#endif struct cbb_softc *sc = (struct cbb_softc *)device_get_softc(brdev); struct sysctl_ctx_list *sctx; struct sysctl_oid *soid; @@ -293,13 +289,8 @@ cbb_pci_attach(device_t brdev) sc->cbdev = NULL; sc->domain = pci_get_domain(brdev); sc->pribus = pcib_get_bus(parent); -#if defined(PCI_RES_BUS) pci_write_config(brdev, PCIR_PRIBUS_2, sc->pribus, 1); pcib_setup_secbus(brdev, &sc->bus, 1); -#else - sc->bus.sec = pci_read_config(brdev, PCIR_SECBUS_2, 1); - sc->bus.sub = pci_read_config(brdev, PCIR_SUBBUS_2, 1); -#endif SLIST_INIT(&sc->rl); rid = CBBR_SOCKBASE; @@ -351,32 +342,6 @@ cbb_pci_attach(device_t brdev) CTLFLAG_RD, &sc->subbus, 0, "io range 2 open"); #endif -#if !defined(PCI_RES_BUS) - /* - * This is a gross hack. We should be scanning the entire pci - * tree, assigning bus numbers in a way such that we (1) can - * reserve 1 extra bus just in case and (2) all sub buses - * are in an appropriate range. - */ - DEVPRINTF((brdev, "Secondary bus is %d\n", sc->bus.sec)); - pribus = pci_read_config(brdev, PCIR_PRIBUS_2, 1); - if (sc->bus.sec == 0 || sc->pribus != pribus) { - if (curr_bus_number <= sc->pribus) - curr_bus_number = sc->pribus + 1; - if (pribus != sc->pribus) { - DEVPRINTF((brdev, "Setting primary bus to %d\n", - sc->pribus)); - pci_write_config(brdev, PCIR_PRIBUS_2, sc->pribus, 1); - } - sc->bus.sec = curr_bus_number++; - sc->bus.sub = curr_bus_number++; - DEVPRINTF((brdev, "Secondary bus set to %d subbus %d\n", - sc->bus.sec, sc->bus.sub)); - pci_write_config(brdev, PCIR_SECBUS_2, sc->bus.sec, 1); - pci_write_config(brdev, PCIR_SUBBUS_2, sc->bus.sub, 1); - } -#endif - /* Map and establish the interrupt. */ rid = 0; sc->irq_res = bus_alloc_resource_any(brdev, SYS_RES_IRQ, &rid, @@ -429,16 +394,12 @@ err: static int cbb_pci_detach(device_t brdev) { -#if defined(PCI_RES_BUS) struct cbb_softc *sc = device_get_softc(brdev); -#endif int error; error = cbb_detach(brdev); -#if defined(PCI_RES_BUS) if (error == 0) pcib_free_secbus(brdev, &sc->bus); -#endif return (error); } @@ -787,7 +748,6 @@ cbb_pci_filt(void *arg) return retval; } -#if defined(PCI_RES_BUS) static struct resource * cbb_pci_alloc_resource(device_t bus, device_t child, int type, int *rid, rman_res_t start, rman_res_t end, rman_res_t count, u_int flags) @@ -836,7 +796,6 @@ cbb_pci_release_resource(device_t bus, device_t child, struct resource *r) } return (cbb_release_resource(bus, child, r)); } -#endif /************************************************************************/ /* PCI compat methods */ @@ -931,14 +890,9 @@ static device_method_t cbb_methods[] = { /* bus methods */ DEVMETHOD(bus_read_ivar, cbb_read_ivar), DEVMETHOD(bus_write_ivar, cbb_write_ivar), -#if defined(PCI_RES_BUS) DEVMETHOD(bus_alloc_resource, cbb_pci_alloc_resource), DEVMETHOD(bus_adjust_resource, cbb_pci_adjust_resource), DEVMETHOD(bus_release_resource, cbb_pci_release_resource), -#else - DEVMETHOD(bus_alloc_resource, cbb_alloc_resource), - DEVMETHOD(bus_release_resource, cbb_release_resource), -#endif DEVMETHOD(bus_activate_resource, cbb_activate_resource), DEVMETHOD(bus_deactivate_resource, cbb_deactivate_resource), DEVMETHOD(bus_driver_added, cbb_driver_added), diff --git a/sys/dev/pci/pci.c b/sys/dev/pci/pci.c index efe017f9a3ba..bda6919e9552 100644 --- a/sys/dev/pci/pci.c +++ b/sys/dev/pci/pci.c @@ -405,11 +405,9 @@ static int pci_clear_bars; SYSCTL_INT(_hw_pci, OID_AUTO, clear_bars, CTLFLAG_RDTUN, &pci_clear_bars, 0, "Ignore firmware-assigned resources for BARs."); -#if defined(PCI_RES_BUS) static int pci_clear_buses; SYSCTL_INT(_hw_pci, OID_AUTO, clear_buses, CTLFLAG_RDTUN, &pci_clear_buses, 0, "Ignore firmware-assigned bus numbers."); -#endif static int pci_enable_ari = 1; SYSCTL_INT(_hw_pci, OID_AUTO, enable_ari, CTLFLAG_RDTUN, &pci_enable_ari, @@ -3706,7 +3704,6 @@ xhci_early_takeover(device_t self) bus_release_resource(self, SYS_RES_MEMORY, rid, res); } -#if defined(PCI_RES_BUS) static void pci_reserve_secbus(device_t bus, device_t dev, pcicfgregs *cfg, struct resource_list *rl) @@ -3862,7 +3859,6 @@ pci_alloc_secbus(device_t dev, device_t child, int *rid, rman_res_t start, return (resource_list_alloc(rl, dev, child, PCI_RES_BUS, rid, start, end, count, flags)); } -#endif static int pci_ea_bei_to_rid(device_t dev, int bei) @@ -4118,13 +4114,11 @@ pci_add_resources(device_t bus, device_t dev, int force, uint32_t prefetchmask) uhci_early_takeover(dev); } -#if defined(PCI_RES_BUS) /* * Reserve resources for secondary bus ranges behind bridge * devices. */ pci_reserve_secbus(bus, dev, cfg, rl); -#endif } static struct pci_devinfo * @@ -4470,14 +4464,11 @@ pci_attach_common(device_t dev) { struct pci_softc *sc; int busno, domain; -#ifdef PCI_RES_BUS int rid; -#endif sc = device_get_softc(dev); domain = pcib_get_domain(dev); busno = pcib_get_bus(dev); -#ifdef PCI_RES_BUS rid = 0; sc->sc_bus = bus_alloc_resource(dev, PCI_RES_BUS, &rid, busno, busno, 1, 0); @@ -4485,7 +4476,6 @@ pci_attach_common(device_t dev) device_printf(dev, "failed to allocate bus number\n"); return (ENXIO); } -#endif if (bootverbose) device_printf(dev, "domain=%d, physical bus=%d\n", domain, busno); @@ -4517,20 +4507,16 @@ pci_attach(device_t dev) int pci_detach(device_t dev) { -#ifdef PCI_RES_BUS struct pci_softc *sc; -#endif int error; error = bus_generic_detach(dev); if (error) return (error); -#ifdef PCI_RES_BUS sc = device_get_softc(dev); error = bus_release_resource(dev, PCI_RES_BUS, 0, sc->sc_bus); if (error) return (error); -#endif return (device_delete_children(dev)); } @@ -5111,10 +5097,8 @@ pci_child_detached(device_t dev, device_t child) pci_printf(&dinfo->cfg, "Device leaked memory resources\n"); if (resource_list_release_active(rl, dev, child, SYS_RES_IOPORT) != 0) pci_printf(&dinfo->cfg, "Device leaked I/O resources\n"); -#ifdef PCI_RES_BUS if (resource_list_release_active(rl, dev, child, PCI_RES_BUS) != 0) pci_printf(&dinfo->cfg, "Device leaked PCI bus numbers\n"); -#endif pci_cfg_save(child, dinfo, 1); } @@ -5551,11 +5535,9 @@ pci_alloc_multi_resource(device_t dev, device_t child, int type, int *rid, rl = &dinfo->resources; cfg = &dinfo->cfg; switch (type) { -#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_alloc_secbus(dev, child, rid, start, end, count, flags)); -#endif case SYS_RES_IRQ: /* * Can't alloc legacy interrupt once MSI messages have diff --git a/sys/dev/pci/pci_host_generic.c b/sys/dev/pci/pci_host_generic.c index c3f4f03b76ad..b47a90348388 100644 --- a/sys/dev/pci/pci_host_generic.c +++ b/sys/dev/pci/pci_host_generic.c @@ -416,16 +416,12 @@ int pci_host_generic_core_release_resource(device_t dev, device_t child, struct resource *res) { -#if defined(PCI_RES_BUS) struct generic_pcie_core_softc *sc; sc = device_get_softc(dev); -#endif switch (rman_get_type(res)) { -#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_release_bus(sc->ecam, child, res)); -#endif case SYS_RES_IOPORT: case SYS_RES_MEMORY: return (bus_generic_rman_release_resource(dev, child, res)); @@ -506,22 +502,16 @@ struct resource * pci_host_generic_core_alloc_resource(device_t dev, device_t child, int type, int *rid, rman_res_t start, rman_res_t end, rman_res_t count, u_int flags) { -#if defined(PCI_RES_BUS) struct generic_pcie_core_softc *sc; -#endif struct resource *res; -#if defined(PCI_RES_BUS) sc = device_get_softc(dev); -#endif switch (type) { -#if defined(PCI_RES_BUS) case PCI_RES_BUS: res = pci_domain_alloc_bus(sc->ecam, child, rid, start, end, count, flags); break; -#endif case SYS_RES_IOPORT: case SYS_RES_MEMORY: res = bus_generic_rman_alloc_resource(dev, child, type, rid, @@ -543,16 +533,12 @@ pci_host_generic_core_alloc_resource(device_t dev, device_t child, int type, static int generic_pcie_activate_resource(device_t dev, device_t child, struct resource *r) { -#if defined(PCI_RES_BUS) struct generic_pcie_core_softc *sc; sc = device_get_softc(dev); -#endif switch (rman_get_type(r)) { -#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_activate_bus(sc->ecam, child, r)); -#endif case SYS_RES_IOPORT: case SYS_RES_MEMORY: return (bus_generic_rman_activate_resource(dev, child, r)); @@ -565,16 +551,12 @@ static int generic_pcie_deactivate_resource(device_t dev, device_t child, struct resource *r) { -#if defined(PCI_RES_BUS) struct generic_pcie_core_softc *sc; sc = device_get_softc(dev); -#endif switch (rman_get_type(r)) { -#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_deactivate_bus(sc->ecam, child, r)); -#endif case SYS_RES_IOPORT: case SYS_RES_MEMORY: return (bus_generic_rman_deactivate_resource(dev, child, r)); @@ -587,17 +569,13 @@ static int generic_pcie_adjust_resource(device_t dev, device_t child, struct resource *res, rman_res_t start, rman_res_t end) { -#if defined(PCI_RES_BUS) struct generic_pcie_core_softc *sc; sc = device_get_softc(dev); -#endif switch (rman_get_type(res)) { -#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (pci_domain_adjust_bus(sc->ecam, child, res, start, end)); -#endif case SYS_RES_IOPORT: case SYS_RES_MEMORY: return (bus_generic_rman_adjust_resource(dev, child, res, @@ -619,10 +597,8 @@ generic_pcie_map_resource(device_t dev, device_t child, struct resource *r, type = rman_get_type(r); switch (type) { -#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (EINVAL); -#endif case SYS_RES_IOPORT: case SYS_RES_MEMORY: break; @@ -658,10 +634,8 @@ generic_pcie_unmap_resource(device_t dev, device_t child, struct resource *r, type = rman_get_type(r); switch (type) { -#if defined(PCI_RES_BUS) case PCI_RES_BUS: return (EINVAL); -#endif case SYS_RES_IOPORT: case SYS_RES_MEMORY: break; diff --git a/sys/dev/pci/pci_pci.c b/sys/dev/pci/pci_pci.c index 7977b9148c9b..0d74cfcf907e 100644 --- a/sys/dev/pci/pci_pci.c +++ b/sys/dev/pci/pci_pci.c @@ -178,10 +178,8 @@ static int pcib_is_resource_managed(struct pcib_softc *sc, struct resource *r) { -#ifdef PCI_RES_BUS if (rman_get_type(r) == PCI_RES_BUS) return (rman_is_region_manager(r, &sc->bus.rman)); -#endif return (pcib_get_resource_window(sc, r) != NULL); } @@ -605,7 +603,6 @@ pcib_free_windows(struct pcib_softc *sc) pcib_release_window(sc, &sc->io, SYS_RES_IOPORT); } -#ifdef PCI_RES_BUS /* * Allocate a suitable secondary bus for this bridge if needed and * initialize the resource manager for the secondary bus range. Note @@ -793,7 +790,6 @@ pcib_alloc_subbus(struct pcib_secbus *bus, device_t child, int *rid, flags)); return (NULL); } -#endif #ifdef PCI_HP /* @@ -1400,10 +1396,6 @@ pcib_attach_common(device_t dev) * Get current bridge configuration. */ sc->domain = pci_get_domain(dev); -#if !defined(PCI_RES_BUS) - sc->bus.sec = pci_read_config(dev, PCIR_SECBUS_1, 1); - sc->bus.sub = pci_read_config(dev, PCIR_SUBBUS_1, 1); -#endif sc->bridgectl = pci_read_config(dev, PCIR_BRIDGECTL_1, 2); /* @@ -1431,20 +1423,6 @@ pcib_attach_common(device_t dev) * Quirk handling. */ switch (pci_get_devid(dev)) { -#if !defined(PCI_RES_BUS) - case 0x12258086: /* Intel 82454KX/GX (Orion) */ - { - uint8_t supbus; - - supbus = pci_read_config(dev, 0x41, 1); - if (supbus != 0xff) { - sc->bus.sec = supbus + 1; - sc->bus.sub = supbus + 1; - } - break; - } -#endif - /* * The i82380FB mobile docking controller is a PCI-PCI bridge, * and it is a subtractive bridge. However, the ProgIf is wrong @@ -1457,34 +1435,6 @@ pcib_attach_common(device_t dev) case 0x060513d7: /* Toshiba ???? */ sc->flags |= PCIB_SUBTRACTIVE; break; - -#if !defined(PCI_RES_BUS) - /* Compaq R3000 BIOS sets wrong subordinate bus number. */ - case 0x00dd10de: - { - char *cp; - - if ((cp = kern_getenv("smbios.planar.maker")) == NULL) - break; - if (strncmp(cp, "Compal", 6) != 0) { - freeenv(cp); - break; - } - freeenv(cp); - if ((cp = kern_getenv("smbios.planar.product")) == NULL) - break; - if (strncmp(cp, "08A0", 4) != 0) { - freeenv(cp); - break; - } - freeenv(cp); - if (sc->bus.sub < 0xa) { - pci_write_config(dev, PCIR_SUBBUS_1, 0xa, 1); - sc->bus.sub = pci_read_config(dev, PCIR_SUBBUS_1, 1); - } - break; - } -#endif } if (pci_msi_device_blacklisted(dev)) @@ -1508,9 +1458,7 @@ pcib_attach_common(device_t dev) #ifdef PCI_HP pcib_probe_hotplug(sc); #endif -#ifdef PCI_RES_BUS pcib_setup_secbus(dev, &sc->bus, 1); -#endif pcib_probe_windows(sc); #ifdef PCI_HP if (sc->flags & PCIB_HOTPLUG) @@ -1617,9 +1565,7 @@ pcib_detach(device_t dev) if (error) return (error); pcib_free_windows(sc); -#ifdef PCI_RES_BUS pcib_free_secbus(dev, &sc->bus); -#endif return (0); } @@ -2097,11 +2043,9 @@ pcib_alloc_resource(device_t dev, device_t child, int type, int *rid, } switch (type) { -#ifdef PCI_RES_BUS case PCI_RES_BUS: return (pcib_alloc_subbus(&sc->bus, child, rid, start, end, count, flags)); -#endif case SYS_RES_IOPORT: if (pcib_is_isa_range(sc, start, end, count)) return (NULL); @@ -2181,7 +2125,6 @@ pcib_adjust_resource(device_t bus, device_t child, struct resource *r, if (!pcib_is_resource_managed(sc, r)) return (bus_generic_adjust_resource(bus, child, r, start, end)); *** 210 LINES SKIPPED *** From nobody Thu Jul 18 18:33:07 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQ1db2mgYz5RsHL; Thu, 18 Jul 2024 18:33: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQ1db22Rbz4pWr; Thu, 18 Jul 2024 18:33:07 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721327587; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=YLd7tMipG/XnB46zHsDoxcXNAv7bPe6uZ2ak6jjbpF8=; b=pf6AWg9aS7jZznCfGSM7LJKL25VWzwsaBsCLzkaYSMTkkBz1FD61CS5GWXvAyQdUCwpEmn xsRcRZfgK7XwSYxipzJUG6DiWfdq/Ehx8lqkb1Hw+vkKduRVAQKUlAtc/uaiZFRVP7izpI jU5U6p4Vp8H6VcgfBPAsrsDcmqicRNvhbLcL922fElBhyeSgMHIzRmK79Y03nECSmzDHJl 3M9OvC44E7oMH0OI7i6qtbqx6wcpM30NwuO9rbNkkEOc+4/lcr8aeuQuwxncoVe9XidyKj 5JmP2YjQr0WFhvZkmHl5hcU98vReqLiwnQUctCKmTh3LllOVKLSquWoj4bA8VQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721327587; a=rsa-sha256; cv=none; b=YWIlFGjDtoVH712r4CRlT2Ud9zzheSaTFjLO5HzGpjRbeUxLNTvMu/4WyYf+IS3ffxrodc Rm5zOxgAoH8sseMkkqP5kbKR6fLWQRp48x9DQrV9XNZ4KGBKVkRIB32dVeuv1iXaS8qa7z Qpt7cM9GVLizCsWz3L922WyWnDOIShXc0Yg52QBGJmC1s2vPwHQ7lqlmEpTV5SqUTBOGN7 m45qGzBKUxeC6mOFefv5fFwxzBfR0a2Q9YlFMJD0IZgoQQRPvIcke8jqs4DaXsqyMZMXVB P+ydzOFxfPFj7n4/aoV2NTeSeuBKBCtTmmNxV3elg6Tp/kx/q+63NHABVJcDSw== 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=1721327587; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=YLd7tMipG/XnB46zHsDoxcXNAv7bPe6uZ2ak6jjbpF8=; b=Tc6CCcgd2hgMWP47yeNVqqZsWP5houkGokFqQo/xi5lsChS2FI3fT3CH2tfjJ7nNsCE/Fk C24/byNgMF/uvjQog4xSGvVgxX5H6KEI5cX1gXm0ijie7hiCSIi63vdq73l5NtXkwrTCpG FHqtIkH7SaDzhnWly0h0YxuxTpRa2NkQ3WeHuHK+dg83bdgmC5IxYsLf94JqEXDFIh2mWY DnYR52zben1K3HmufsRZQyVW4LCgVV1zBkFiK4Wemc2qnnNsH9+J3UxH4WhABlXd9E1N0b RKvJSt6yrQUW42BAVL5R2t0VNzh5bjPPjEaPk7VCXB2gmxfe0tlR+3GdKFmtRA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQ1db1dqDz10Sl; Thu, 18 Jul 2024 18:33:07 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46IIX7Jq000118; Thu, 18 Jul 2024 18:33:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46IIX72t000115; Thu, 18 Jul 2024 18:33:07 GMT (envelope-from git) Date: Thu, 18 Jul 2024 18:33:07 GMT Message-Id: <202407181833.46IIX72t000115@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mitchell Horne Subject: git: f38669ef6d6a - main - tarfs.4: update title after move to section four List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: f38669ef6d6aab32e9e17e9631345b188f00b583 Auto-Submitted: auto-generated The branch main has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=f38669ef6d6aab32e9e17e9631345b188f00b583 commit f38669ef6d6aab32e9e17e9631345b188f00b583 Author: Alexander Ziaee AuthorDate: 2024-07-14 08:47:37 +0000 Commit: Mitchell Horne CommitDate: 2024-07-18 18:32:33 +0000 tarfs.4: update title after move to section four Reviewed by: imp Fixes: 1687d7 (move filesystems to s4) Pull Request: https://github.com/freebsd/freebsd-src/pull/1325 --- share/man/man4/tarfs.4 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/man/man4/tarfs.4 b/share/man/man4/tarfs.4 index 56c56ac43287..50cd287b3302 100644 --- a/share/man/man4/tarfs.4 +++ b/share/man/man4/tarfs.4 @@ -25,7 +25,7 @@ .\" SUCH DAMAGE. .\" .Dd February 14, 2023 -.Dt TARFS 5 +.Dt TARFS 4 .Os .Sh NAME .Nm tarfs From nobody Thu Jul 18 18:55:28 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQ27N2CFTz5QB9g; Thu, 18 Jul 2024 18:55: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQ27N1Xvlz4rnn; Thu, 18 Jul 2024 18:55:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721328928; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=POfW/+rgrpz7Tq7s2YGQ9jWDaL5KHYPpdaOyRE2pNWY=; b=op98G1IKgLC8rAcRfmoxYSWYSYxjISV0Z9FLMM20z4AeZIcgUZVARqwapgydL1UaQm3fSy HNvgjQhUYnZx/sXX+8XbhIZopsGKGzPF7i5SQ9jkOrWNV+ceom0sHzXWfDdEuSlF0Hl23M UVLlBwUwlHPmSyh4ESRYTDNa63XVo5T3xbxV80zfkghs39M3PPuO+YwlQHEp5E6ywND1m/ 1Eeehm8G/1Kktmb53HWyCWKfLpjDsxPqrAYMHvWBVgmwg8opA46axJbRYooXd8/qLkPxtt AZE8N1ofNl64ZX7xNbDVnF4N/cwmgSJGJkszw3u59mRXq/FzilRsW2gQ9f2+2w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721328928; a=rsa-sha256; cv=none; b=D14HJ+ql9jId0YCqtjnIeFOseT2+Ev0lopWPHjL9sd2niv6m/r4NzF7NQWF5/QKCRWkrEk b/IkT1uuuToEabCvECah9W+Wcbc7CHC6T94c5mVtS9cPPJnqlz0cf5WVUcjpNDWmiT6NZu xiZVuFV79KZ6PYrkTzqraQ8fNUwxIr8hBUt9c2uy7CM3QOqDcGZLYmlb89KwHPqOCmRIZw bEKQRzIpFsoByZzIK0DEHatZsOqohrIzGnumkKgCYihZuz4oO5Oi405T6dO5a3qzAlgbJO TzHjcjz4bGYMQWHV3ZPNtgTvZugxhF36eYREAIFvQxI7Bt0iWDwx8QiJezO+Rg== 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=1721328928; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=POfW/+rgrpz7Tq7s2YGQ9jWDaL5KHYPpdaOyRE2pNWY=; b=h4oa/SWhWgWIg1WgbLtbm9lmyzR0huabGKmUtx6/qw/MONOb2ZGA4dG0qFFRi9XXIfyw6o 6RLBcPDqQw3jex1MIsGfhQqC82SH5tiGNvbWoru4ua1oylzrnXEDm+lUSwbW4GMkxke/aO cRv5DLn7TryUl/qMeC5phCImhVqUiSLTvFV+uYTyppL/IjfEch76nppOz1YRWW4qEbKSf0 A36BL2q2lK3AFKaGvlj+MKZXC1oChcMyoJzei6n4xz2U3vmOC2FGPlEfQeuN/dtewXTmir Dxe/oz7UD19TRwUcE+rfVrpbypVmA4JktxzzqwIxELE+8Xs0LRqdluVM70DZqA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQ27N12BJz10nn; Thu, 18 Jul 2024 18:55:28 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46IItSd1034243; Thu, 18 Jul 2024 18:55:28 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46IItS87034240; Thu, 18 Jul 2024 18:55:28 GMT (envelope-from git) Date: Thu, 18 Jul 2024 18:55:28 GMT Message-Id: <202407181855.46IItS87034240@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: ee912ee57a21 - main - nvmecontrol: Treat requested KeepAlive timeout as seconds List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: ee912ee57a213b25fc9e559054e5869b4a6b2f61 Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=ee912ee57a213b25fc9e559054e5869b4a6b2f61 commit ee912ee57a213b25fc9e559054e5869b4a6b2f61 Author: John Baldwin AuthorDate: 2024-07-18 18:54:43 +0000 Commit: John Baldwin CommitDate: 2024-07-18 18:54:43 +0000 nvmecontrol: Treat requested KeepAlive timeout as seconds The internal KATO is stored in milliseconds, so convert the command line argument (given in seconds) to milliseconds before passing to nvmf_connect(). Sponsored by: Chelsio Communications --- sbin/nvmecontrol/connect.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sbin/nvmecontrol/connect.c b/sbin/nvmecontrol/connect.c index 14bd0cce1f8f..ef614eca2e2a 100644 --- a/sbin/nvmecontrol/connect.c +++ b/sbin/nvmecontrol/connect.c @@ -82,7 +82,7 @@ connect_nvm_controller(enum nvmf_trtype trtype, int adrfam, const char *address, io = calloc(opt.num_io_queues, sizeof(*io)); error = connect_nvm_queues(&aparams, trtype, adrfam, address, port, - cntlid, subnqn, opt.hostnqn, opt.kato, &admin, io, + cntlid, subnqn, opt.hostnqn, opt.kato * 1000, &admin, io, opt.num_io_queues, opt.queue_size, &cdata); if (error != 0) { free(io); From nobody Thu Jul 18 18:59:05 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQ2CY3zrJz5QBHP; Thu, 18 Jul 2024 18:59: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQ2CY3TMnz4s8T; Thu, 18 Jul 2024 18:59:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721329145; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=hZHkhcry8T5Isvz6dTnY/fcm5miyz4LKECnRgQ+5C/c=; b=S8cODqMGEbqgq1X568ih6rZteV91/EIPlKaGnEnZ7UW/ULbtCnEDXwpmtj9AlArETc5x90 oqFOAvJijLyUaWeylRatdZ1mdYj/ukgLdB5PzF/ztJY4djTUM8Mnm60iV+8vioZNrVQnbb ZhCLmnDZV93ARH82+J+uaDetR/vW+6Jn2skTL7+2YF6GQxkMt9dVhkJNmERLrW31cXuWzo GESP9hj7Q5Y7wvIBJGxJLe35AjSDBMNhUusNk1VFeIYWiO5G3TxCtWzqvgIJctwXxEhTSl Jz5v/KecCdZDqQZ3w+UZ2TZY1EsaAgsSXHAs8MjNk9a6Dl3wLWMzP7GgDvU2lQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721329145; a=rsa-sha256; cv=none; b=p5aajiBpmejkLAePuiX7PyCu4svUG5HZI7SSeA+F3c2BTWz4/jEpT9WPJN8UoN+mhurQ2W swlbYghD0w7WsW8xhZPFMXC9cntqySa9hXyKoVeTqXM5CGgsaEMANGwB9fICd3XXFUH4pk 70k4eN9m5yWFgp45Ujrd2GnEq1t/UMrfWRUbTZNY/JiIAIEQYKDdMsX6x4//jpLWV3Z0/X rbJcymVJpowjVJ7cL1uHeYmm9Ys9B+oQjIkliQZjfEBpq0YbbuebwwuZGtS+BUhC9Fwo3D mMJ2uMb+mRqnx81nfIy7VyVhdfhBLBsg3mSg4xB5JuUzYFkpTy6UATkqULJ4ww== 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=1721329145; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=hZHkhcry8T5Isvz6dTnY/fcm5miyz4LKECnRgQ+5C/c=; b=lyMHQF9DRDrXLpQ+L7no04h7s6rNXzTd+e2z9prDeBn7U2tGxlUSM1mn7InScVo1rCewHf 4NRPW8AESLubq8l+wBAAGgwCF3coGFCixKGOr26sWx4zyTTnPrrf2U9qRnRnkhMAmiwpeN wTZKP3EaLsVCZ29RSiKfAAMPbOQFws0IMYWBkgJHrHBCmBJV9iX8MbRyISRviZ5rWrSRt/ Z9z/k0UTZstEUIU8P5oqUOGr5/ikEj8ke+Rwq86zlvI0nwtvLqawQpjqjUdUARwAHreIej EwPWHjuKLFC39OLpkiY/R2Cr1/M7g9Q1NI7xvg4KkpbUUehSvhtZRB6f9FsVgQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQ2CY2sZbz115s; Thu, 18 Jul 2024 18:59:05 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46IIx56O034854; Thu, 18 Jul 2024 18:59:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46IIx5jk034851; Thu, 18 Jul 2024 18:59:05 GMT (envelope-from git) Date: Thu, 18 Jul 2024 18:59:05 GMT Message-Id: <202407181859.46IIx5jk034851@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Doug Moore Subject: git: a527b9cb721a - main - axgbe: use standard rounddown_pow_of_two List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: dougm X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: a527b9cb721a597a0bc5313ac55290cc6a91deac Auto-Submitted: auto-generated The branch main has been updated by dougm: URL: https://cgit.FreeBSD.org/src/commit/?id=a527b9cb721a597a0bc5313ac55290cc6a91deac commit a527b9cb721a597a0bc5313ac55290cc6a91deac Author: Doug Moore AuthorDate: 2024-07-18 18:56:31 +0000 Commit: Doug Moore CommitDate: 2024-07-18 18:56:31 +0000 axgbe: use standard rounddown_pow_of_two Drop an implementation of __rounddown_pow_of_two, which triggers Coverity warnings, and use the libkern implementation of rounddown_pow_of_two instead. Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D46022 --- sys/dev/axgbe/xgbe-sysctl.c | 20 ++------------------ 1 file changed, 2 insertions(+), 18 deletions(-) diff --git a/sys/dev/axgbe/xgbe-sysctl.c b/sys/dev/axgbe/xgbe-sysctl.c index 16523381e1a3..df81b1d7f0ae 100644 --- a/sys/dev/axgbe/xgbe-sysctl.c +++ b/sys/dev/axgbe/xgbe-sysctl.c @@ -244,22 +244,6 @@ exit_bad_op(void) return(-EINVAL); } -static inline unsigned -fls_long(unsigned long l) -{ - - if (sizeof(l) == 4) - return (fls(l)); - return (fls64(l)); -} - -static inline __attribute__((const)) -unsigned long __rounddown_pow_of_two(unsigned long n) -{ - - return (1UL << (fls_long(n) - 1)); -} - static inline int get_ubuf(struct sysctl_req *req, char *ubuf) { @@ -1049,12 +1033,12 @@ sysctl_ringparam_handler(SYSCTL_HANDLER_ARGS) return (-EINVAL); } - rx = __rounddown_pow_of_two(sys_op->rx_pending); + rx = rounddown_pow_of_two(sys_op->rx_pending); if (rx != sys_op->rx_pending) axgbe_printf(1, "rx ring param rounded to power of 2: %u\n", rx); - tx = __rounddown_pow_of_two(sys_op->tx_pending); + tx = rounddown_pow_of_two(sys_op->tx_pending); if (tx != sys_op->tx_pending) axgbe_printf(1, "tx ring param rounded to power of 2: %u\n", tx); From nobody Thu Jul 18 22:23:18 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQ6lB5mxpz5QW8j; Thu, 18 Jul 2024 22:23: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQ6lB5GPSz4GRf; Thu, 18 Jul 2024 22:23:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721341398; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=UrQtoMFUv00NUCX1K/pXsBmOpTKF0g4KLzJatEQYm6o=; b=IhlkjZHMPQvj//rZm9C/4WqtnXhrVXtc8EKpmGmTWsKl8eyVxbTbLgZNc9M79LebYBNDPP dCKCpl2l5bzVBO/rBxUcGMCN7fM9im0crqZnGYtPqwU++pK4xVVKFxAN1hxu7nUO6QpmAB 8Bv961KwMZJBVklQKlUpfXwsR2T/CZ3puIC5fyBuYdL5C9anH09pPrfw/oEgt0Su1xR9c3 jExXeEJIx0Zju2gjsaDib1PN3W8sYLoPI1Qx9kDTea3HGzOcoJX1xEWcEyEH6m9VS2r8yY 2qnC47glcqbyL3LDYSZ6S5bikmpndAe7qPAZbU64bvlCF9HkAqcSzSsIYyjHSg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721341398; a=rsa-sha256; cv=none; b=xTrRmcODp3vta+pZwO+0kg7Es7A/smTDiAeTzHDjRvdfUyTltVo1CAPEyUbqLTxIKF45o1 9GxhLWXcwTAZcams8oFz70nc+jBh5LCmt1K+wigu6HRN9H3zEAH3YBxrEcrhR1AK2TlkM9 QSRJ2lGWsfPd+sxpBJReEK0k1AoSytkslQu8XESaqYv7ZjZrxJqFscGcr+fY0cud2YAIfr 3HzQNxJww2g+XAOZ7o5hAHt1YuAyKHq/oQkyibFfVeozp1C+Tr/fZOeh1289UTN2JYt7AL 8qiEcW5A8KURpEzYLZH4EO0ZHCSaemtExNCA6V5vA4sqXolxX/3mY/BqpcqUiQ== 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=1721341398; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=UrQtoMFUv00NUCX1K/pXsBmOpTKF0g4KLzJatEQYm6o=; b=pNHqZpeP+2KC7fJwRnv1BtD2owj/Z+FyeBRnncPAk1ki72pAwAxLjVpPL8TYBCuJ1fGdPI xGbTBNhAVmQi5ltQvKHnDaLFqOVKEFKwnC5XRFoX+oJ4yLojPdV64IuQP30IhR+4XhSt9X 8GfyUXpc4Y1U4kvpwMSEFMgLV0hEUM0lKLQVl2QWZ9gtpssEhC8Gv6ajOrU+flHsPRYPj9 5QSppmvx61BhZGu9DdKZWzNrJpVIIxTOudYFUAnXscVKdBX0fIVdSow3J2bEITiKbwfLv6 aevSju5eHdPMzYydLxDGr0CX0KeDGtCCr55QILNg8lK41xQ3fL39HFTPd/5a2g== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQ6lB4s5Yz15pn; Thu, 18 Jul 2024 22:23:18 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46IMNIWc090803; Thu, 18 Jul 2024 22:23:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46IMNI2j090800; Thu, 18 Jul 2024 22:23:18 GMT (envelope-from git) Date: Thu, 18 Jul 2024 22:23:18 GMT Message-Id: <202407182223.46IMNI2j090800@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Doug Moore Subject: git: e82cee21ba3b - main - axgbe: drop unused function List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: dougm X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e82cee21ba3b4410771b7a9e94e9fac013f24ee4 Auto-Submitted: auto-generated The branch main has been updated by dougm: URL: https://cgit.FreeBSD.org/src/commit/?id=e82cee21ba3b4410771b7a9e94e9fac013f24ee4 commit e82cee21ba3b4410771b7a9e94e9fac013f24ee4 Author: Doug Moore AuthorDate: 2024-07-18 22:21:45 +0000 Commit: Doug Moore CommitDate: 2024-07-18 22:21:45 +0000 axgbe: drop unused function A recent change dropped the only use of fls64() in axgbe, so drop its definition. Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D46030 --- sys/dev/axgbe/xgbe_osdep.h | 7 ------- 1 file changed, 7 deletions(-) diff --git a/sys/dev/axgbe/xgbe_osdep.h b/sys/dev/axgbe/xgbe_osdep.h index cea8b4797bf9..1f0359657dcd 100644 --- a/sys/dev/axgbe/xgbe_osdep.h +++ b/sys/dev/axgbe/xgbe_osdep.h @@ -232,13 +232,6 @@ __ffsl(long mask) return (ffsl(mask) - 1); } -static inline int -fls64(uint64_t mask) -{ - - return (flsll(mask)); -} - static inline int get_bitmask_order(unsigned int count) { From nobody Fri Jul 19 05:23:01 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQJ3T67H4z5QwcC; Fri, 19 Jul 2024 05:23: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQJ3T5W22z4sLx; Fri, 19 Jul 2024 05:23:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721366581; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=tYxTlpx6z5doEraMSjS/v9xLV7WT8KVJPwXyLcdjdEA=; b=PU80iJqLTAeyplDlMVrU4F0UZ67gecwugVwfmcFWfACrD6ScTIZVM4kpZ4bpudiffXVihw T1rMOCrohnDVVll+PjdVSqmnE16zxl5dvBD8RleESpQvk0Gp0u1ovxFl+q3UYoDGXJmuYW l/SXL7JhesBCyHCShGniHhboKe+1c4v6sFAaZTr1QIZU0XbX4Tc5HZy53UCO1ShtlCTm1s OclhWSl9iuZJR1gjO7RpU7Ilya+U2l3eeJS5kPYVeD4zDfmMG+1gJ2w0p3qGx64q0lQYvN o9scgoVbOPzKLAJq/jn/13+bxbbCg1hzydJnEpsjUB07Ndc9loFSzvMQ8NQ4Qg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721366581; a=rsa-sha256; cv=none; b=sL9zk11ZeUv4x5mAUxJMC8BhYTusuSd6+tyWL9roTV15WiqFcplUgni9cW1srLH6HbcWAL 4ol0N1XezCqEh1okvgOOu/6d9n8xsYZjphn2yxo4/urg50oww1wrmgBCVqa9P+dG8iRqwt 2v2NWbNU8L8UT21h6b61HxM3vrpkmR076UWtVIRrfQ1piB4J31O1XVe6v43cgEH5T4pja9 /m9EFJaniPfQo/dJZ8Cm8l1QJqniRRc1Xj4SgRP7vOom+K1vBDOCqh+gNc1ug71Roa5syC 25km7feQtlF7dofLpJmAK8ybH4gJ5nY/rKv0S1376vyV72Tz0If/YiOodDkDow== 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=1721366581; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=tYxTlpx6z5doEraMSjS/v9xLV7WT8KVJPwXyLcdjdEA=; b=x981odO4ouEDRgYrJI63L59vOCcILklkvkjzCSvVSuVEIueWxccUg4/Js5yRKUVqIqWh52 sSLpxS1sipMqqHD8stbb7FbrdSC8B5gvngcKjq/Ae8QNj6KpCdFp+AIXDQ0dLsdBchxL90 VocB2RDXsXsPOapqVNC/ZRoCEtmvG8QrMGlR2WQeWgWr8K4Da9PdA7McGxCMLUkIjWxI7q hlXBSkiwFs4+H4V4cjgl9/txIxPjFML2sbWNVC+yoi7rqRpprihH/KvWpfRx2/MZF1uOF2 6dzERqLE5RXRnNR0AtwqlOCeKclWBJeW8vEwMQkypWDiG1GQYsurja0OiGZObQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQJ3T56tQzKL2; Fri, 19 Jul 2024 05:23:01 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46J5N1Mb041215; Fri, 19 Jul 2024 05:23:01 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46J5N1Oo041212; Fri, 19 Jul 2024 05:23:01 GMT (envelope-from git) Date: Fri, 19 Jul 2024 05:23:01 GMT Message-Id: <202407190523.46J5N1Oo041212@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: f7331f4ec87e - main - cdefs.9: Fix clang version, and gcc version List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: f7331f4ec87eef7ff9e2aa0109fcee06d71edff2 Auto-Submitted: auto-generated The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=f7331f4ec87eef7ff9e2aa0109fcee06d71edff2 commit f7331f4ec87eef7ff9e2aa0109fcee06d71edff2 Author: Warner Losh AuthorDate: 2024-07-19 05:21:15 +0000 Commit: Warner Losh CommitDate: 2024-07-19 05:22:51 +0000 cdefs.9: Fix clang version, and gcc version There's no clang 19 that we support, so remove that from the list. Also, jhb will soon commit gcc 14 support, so add it while I'm here so I don't forget later. Submited by: jhb Sponsored by: Netflix --- share/man/man9/cdefs.9 | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/share/man/man9/cdefs.9 b/share/man/man9/cdefs.9 index a065e0bd7d1d..71b3e7fd4f81 100644 --- a/share/man/man9/cdefs.9 +++ b/share/man/man9/cdefs.9 @@ -3,7 +3,7 @@ .\" .\" SPDX-License-Identifier: BSD-2-Clause .\" -.Dd July 8, 2024 +.Dd July 18, 2024 .Dt CDEFS 9 .Os .Sh NAME @@ -40,10 +40,13 @@ They are not intended as a general portability layer. Due to testing constraints, tcc and pcc may not always work. .It Compilers supported for building Fx itself: .Bl -column -offset 0n indent-two -.It Sy Compiler Ta Sy Versions -.It gcc Ta 12, 13 -.It clang Ta 16, 17, 19 +.It Sy Compiler Ta Sy Major Versions Supported +.It gcc Ta 12, 13, 14 +.It clang Ta 16, 17, 18 .El +.Pp +Please note: Not every single minor versions of these compilers +will work or are supported. .Sh Macros and Magic for Programming Environment .Nm defines (or refrains from defining) a number of macros to increase portability From nobody Fri Jul 19 05:23:32 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQJ4K6708z5QwhP for ; Fri, 19 Jul 2024 05:23:45 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-pg1-x535.google.com (mail-pg1-x535.google.com [IPv6:2607:f8b0:4864:20::535]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "WR4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQJ4K0ZK1z4sqJ for ; Fri, 19 Jul 2024 05:23:45 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Authentication-Results: mx1.freebsd.org; dkim=pass header.d=bsdimp-com.20230601.gappssmtp.com header.s=20230601 header.b=Q5OwO42B; dmarc=none; spf=none (mx1.freebsd.org: domain of wlosh@bsdimp.com has no SPF policy when checking 2607:f8b0:4864:20::535) smtp.mailfrom=wlosh@bsdimp.com Received: by mail-pg1-x535.google.com with SMTP id 41be03b00d2f7-70b2421471aso1065867a12.0 for ; Thu, 18 Jul 2024 22:23:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20230601.gappssmtp.com; s=20230601; t=1721366623; x=1721971423; darn=freebsd.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=NGlhsLo8j+mDtjqr1Z7mYTbb9doMKD6weV7z3GZMONE=; b=Q5OwO42BvUzx99mU0vALtOmSNfzzb7pApSg26ALDlITLrewutoTus2YdT8Rz1auvsL ug/M+kDv29lQuv3V4ETIULpegNKb1TNWv1+nVwMYF5FABGqjW1bD68GOD4Q6G4og51J+ LKZ86K2uuDgf6pI8CUKnU7oLCseOUbPfNaQFWykW04Xg0M2m+FkkvmAiTV1A3/k7jTQo Ke/I+mw3jUO3yRiSU3soE3t5tUCMGhvxaj/jI91iQPpnfeXPJPdLJgHxUdrZTYSbLWbW neCwJKqsOQPzyUDLwP9c//gqjpE/136GbraDj+bB4C1cmZhZYXhZLeEUKoNZBeYEUuRR nvNQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721366623; x=1721971423; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=NGlhsLo8j+mDtjqr1Z7mYTbb9doMKD6weV7z3GZMONE=; b=TuQGw+NpDBn5oRIMWtKEkevhdYBUk9ICAp1MCaNinzhqPYS8hKFcnHJBLixPufUU1s mY2pFAa+EKAYMSOuQMV528+lMwOZF0WjwbANKCSJwRMobDQbXZlO3KVE7Yss6tHTcG/7 mtmALeIR3qXEYc30eO4HXYpPhjgFtXuHhT9MYXA0vr+TFBkkzdBQxTVdjwyV3DBUlKd9 LMroiJNJil/rW8boeSd/L8/MmQJaoFelypTKhfi9bf4lTuYQjqMqEQDFpPZAbub+5m7B uUcTYQRnT/7+lOjg98jDCtaiUhOWUegBVowYgIqJcgrMSmlu7pt24l33vXCOUcNWO/7X yv1A== X-Forwarded-Encrypted: i=1; AJvYcCVM6bgZ8rJk0wV7FLqwqUvssAUp9RRI1PdVSSbZZt3ep4Mapf0yk3XR6IoAW1Gj9m4LRuajb/uCn7EHFRVeD1bz8QLANSzvn2ysq9jpQn6u X-Gm-Message-State: AOJu0YxHDNypFWLJCHqHHr5zVwgOJOnsK1dDOSAD3XgB4mKwbUZHsErQ 1tiyIRHnks4sZzVUN3Z345606NxvajnmbhFKvcMlnQKC21Wmc80oMLs+fPjlxqqlV+0GCGaxwGg ASLz8G4x1Jzk3uPdUH1WKDB4uyP9lGcRaPjBK1Q== X-Google-Smtp-Source: AGHT+IHKigYajdMELE7yy0Zcyl6B4MVmA4dlalPYl749zs777H25IDCfuAelnDl7y0ccnbSAXh4VR5iMErn62djAbEk= X-Received: by 2002:a05:6a20:d503:b0:1c2:922f:379c with SMTP id adf61e73a8af0-1c3fdcf522bmr7464020637.23.1721366623583; Thu, 18 Jul 2024 22:23:43 -0700 (PDT) List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 References: <202407082254.468MsOMU064769@gitrepo.freebsd.org> <8b3bd285-ce3e-4958-9bd4-ac486eda5ebb@FreeBSD.org> In-Reply-To: <8b3bd285-ce3e-4958-9bd4-ac486eda5ebb@FreeBSD.org> From: Warner Losh Date: Thu, 18 Jul 2024 23:23:32 -0600 Message-ID: Subject: Re: git: 4122295afcbf - main - cdefs(9): Start to document what sys/cdefs.h does To: John Baldwin Cc: Warner Losh , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Content-Type: multipart/alternative; boundary="000000000000209bbb061d92e6d8" X-Spamd-Bar: -- X-Spamd-Result: default: False [-2.99 / 15.00]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_SHORT(-0.99)[-0.993]; FORGED_SENDER(0.30)[imp@bsdimp.com,wlosh@bsdimp.com]; R_DKIM_ALLOW(-0.20)[bsdimp-com.20230601.gappssmtp.com:s=20230601]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; RCVD_COUNT_ONE(0.00)[1]; MIME_TRACE(0.00)[0:+,1:+,2:~]; ARC_NA(0.00)[]; TO_DN_SOME(0.00)[]; MISSING_XM_UA(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[2607:f8b0:4864:20::535:from]; DMARC_NA(0.00)[bsdimp.com]; MLMMJ_DEST(0.00)[dev-commits-src-all@freebsd.org]; FROM_NEQ_ENVFROM(0.00)[imp@bsdimp.com,wlosh@bsdimp.com]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_FIVE(0.00)[5]; R_SPF_NA(0.00)[no SPF record]; PREVIOUSLY_DELIVERED(0.00)[dev-commits-src-all@freebsd.org]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCVD_TLS_LAST(0.00)[]; DKIM_TRACE(0.00)[bsdimp-com.20230601.gappssmtp.com:+] X-Rspamd-Queue-Id: 4WQJ4K0ZK1z4sqJ --000000000000209bbb061d92e6d8 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Fixed. Sorry it took so long. Warner On Tue, Jul 9, 2024 at 7:09=E2=80=AFAM John Baldwin wrote= : > On 7/8/24 18:54, Warner Losh wrote: > > The branch main has been updated by imp: > > > > URL: > https://cgit.FreeBSD.org/src/commit/?id=3D4122295afcbf4b7ad0623bbf35f36dc= 3278ac028 > > > > commit 4122295afcbf4b7ad0623bbf35f36dc3278ac028 > > Author: Warner Losh > > AuthorDate: 2024-07-02 22:45:49 +0000 > > Commit: Warner Losh > > CommitDate: 2024-07-08 22:54:02 +0000 > > > > cdefs(9): Start to document what sys/cdefs.h does > > > > --- > > share/man/man9/Makefile | 1 + > > share/man/man9/cdefs.9 | 405 > ++++++++++++++++++++++++++++++++++++++++++++++++ > > 2 files changed, 406 insertions(+) > > > > diff --git a/share/man/man9/cdefs.9 b/share/man/man9/cdefs.9 > > new file mode 100644 > > index 000000000000..a065e0bd7d1d > > --- /dev/null > > +++ b/share/man/man9/cdefs.9 > > @@ -0,0 +1,405 @@ > > +.Sh Supported Compilers > > +.Bl -tag -offset 2n -width 0 > > +.It Compilers supported for building programs on Fx : > > +.Bl -column -offset 0n indent-two > > +.It Sy Compiler Ta Sy Versions > > +.It gcc Ta 9, 10, 11, 12, 13, 14 > > +.It clang Ta 10, 11, 12, 13, 14, 15, 16, 17, 18 > > +.It TinyC (tcc) Ta 0.9 > > +.It pcc Ta 1.1 > > +.El > > +.Pp > > +Due to testing constraints, tcc and pcc may not always work. > > +.It Compilers supported for building Fx itself: > > +.Bl -column -offset 0n indent-two > > +.It Sy Compiler Ta Sy Versions > > +.It gcc Ta 12, 13 > > +.It clang Ta 16, 17, 19 > > s/19/18/? > > -- > John Baldwin > > --000000000000209bbb061d92e6d8 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Fixed. Sorry it took so long.

Warner

On Tue, Jul 9, 2024 at 7:09=E2=80=AFAM John Baldwin <<= a href=3D"mailto:jhb@freebsd.org">jhb@freebsd.org> wrote:
<= blockquote class=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;border-l= eft:1px solid rgb(204,204,204);padding-left:1ex">On 7/8/24 18:54, Warner Lo= sh wrote:
> The branch main has been updated by imp:
>
> URL: https://= cgit.FreeBSD.org/src/commit/?id=3D4122295afcbf4b7ad0623bbf35f36dc3278ac028<= /a>
>
> commit 4122295afcbf4b7ad0623bbf35f36dc3278ac028
> Author:=C2=A0 =C2=A0 =C2=A0Warner Losh <imp@FreeBSD.org>
> AuthorDate: 2024-07-02 22:45:49 +0000
> Commit:=C2=A0 =C2=A0 =C2=A0Warner Losh <imp@FreeBSD.org>
> CommitDate: 2024-07-08 22:54:02 +0000
>
>=C2=A0 =C2=A0 =C2=A0 cdefs(9): Start to document what sys/cdefs.h does<= br> >=C2=A0 =C2=A0 =C2=A0
> ---
>=C2=A0 =C2=A0share/man/man9/Makefile |=C2=A0 =C2=A01 +
>=C2=A0 =C2=A0share/man/man9/cdefs.9=C2=A0 | 405 +++++++++++++++++++++++= +++++++++++++++++++++++++
>=C2=A0 =C2=A02 files changed, 406 insertions(+)
>
> diff --git a/share/man/man9/cdefs.9 b/share/man/man9/cdefs.9
> new file mode 100644
> index 000000000000..a065e0bd7d1d
> --- /dev/null
> +++ b/share/man/man9/cdefs.9
> @@ -0,0 +1,405 @@
> +.Sh Supported Compilers
> +.Bl -tag -offset 2n -width 0
> +.It Compilers supported for building programs on Fx :
> +.Bl -column -offset 0n indent-two
> +.It Sy Compiler Ta Sy Versions
> +.It gcc Ta 9, 10, 11, 12, 13, 14
> +.It clang Ta 10, 11, 12, 13, 14, 15, 16, 17, 18
> +.It TinyC (tcc) Ta 0.9
> +.It pcc Ta 1.1
> +.El
> +.Pp
> +Due to testing constraints, tcc and pcc may not always work.
> +.It Compilers supported for building Fx itself:
> +.Bl -column -offset 0n indent-two
> +.It Sy Compiler Ta Sy Versions
> +.It gcc Ta 12, 13
> +.It clang Ta 16, 17, 19

s/19/18/?

--
John Baldwin

--000000000000209bbb061d92e6d8-- From nobody Fri Jul 19 07:56:24 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQMSS27k5z5R9yn; Fri, 19 Jul 2024 07:56: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQMSS1Y5Nz46JS; Fri, 19 Jul 2024 07:56:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721375784; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=I4chyFmP1ajvjMQ8vK06USCSsXYfHgE8KptbXlcBHY4=; b=x7O16uPe6dy57JNZFIa+SiOaoN+FThumFunx0xy3M/L7JVuqQZNE977CU3U6eTQTmEKe3m F/7TOmuFaJxoOXEfTtafHVmPXUiL7JTq0xuE+mhkEWWcnxkSAs889EP6WDfYyYiVLm906H c6yG2Lm25f/MVo/TTnXHJRdgyQMORglvEhPgNEKmxWbMBpKDL/HEu4FHW4oAsH9fJ5WI2U ndoZH8FCJLKuUHGYw3QJSveByZQYwrDbyrwtGAvaZplemZsKJlERfn446CxCsPM/RLvlAG s/Rjr4bWCKly+pLBxlaL03AamMBzFfGcWaqH0XhiFXDWAFGYvEloHmxmhHexeA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721375784; a=rsa-sha256; cv=none; b=EdoYm/Bw7n+U473NHZkorqyONOKA+b3X2GNzZyJIpGhAmWu7XxN8B5Qeo3zhtDD15Gsl35 DUaFWzt++5emcSieb/5vT2UkUTJsPM8PogieD2eRWHOHc5Wh5iWUg4Am8rNYb3TYeCX7zQ eYO5Sy9eHNkXP8B6y5ecpq1Y0XqbNoKpiu3WBJzX2htaVBgJsT3RvGxjoxAOj8KkG/R8n0 4JJR0feOIDgk7Hr65bOW6sI/pxpkQhqZKtFdyy/vzPF276uPyGUcy7KrhjN12Wyx/2/gut LcYl+bRyZI/C6mIZzPtJT+kcLBy/Fq8onpEMtidQbjF67yNmFLN1xaVourHhNg== 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=1721375784; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=I4chyFmP1ajvjMQ8vK06USCSsXYfHgE8KptbXlcBHY4=; b=Z8zaxUc+9byYsXnJBS4lvHg5oS2NgqSe1nuv5UnhyxE++BqWCQ2RZAsRTeHXQ9fcFyVzoK TQoPAaN3mUnCWmhXPsApJA/D8uDLq22aRie8OR8yEgF1OazAli0J4yopQv8uI0h735x0YB Mq2Z16kieizFUHrau6V53GKAgA/zoIivN/cUomw7UkZUw7KJ82wMltCqgsRFFM0eJM5vs4 QigqutLfPY+qROU4jSpOvtZsu7+S2cRU7b6LHSmXn0Ug0dDZZXvMKpeG8tMrF4wAKLxyyO u7YNnKBeOSSg8/gVLsp+MmPtTiCYLtHiE4lDIRWTtXPpNsMPFW8oZFm7ohWzEQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQMSS18YszPBk; Fri, 19 Jul 2024 07:56:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46J7uO3L093444; Fri, 19 Jul 2024 07:56:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46J7uO6T093441; Fri, 19 Jul 2024 07:56:24 GMT (envelope-from git) Date: Fri, 19 Jul 2024 07:56:24 GMT Message-Id: <202407190756.46J7uO6T093441@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Peter Holm Subject: git: 94e62a5f91db - main - stress2: Exclude one more test List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: pho X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 94e62a5f91dba60e42c701998a970b5cf7e9d036 Auto-Submitted: auto-generated The branch main has been updated by pho: URL: https://cgit.FreeBSD.org/src/commit/?id=94e62a5f91dba60e42c701998a970b5cf7e9d036 commit 94e62a5f91dba60e42c701998a970b5cf7e9d036 Author: Peter Holm AuthorDate: 2024-07-19 07:55:39 +0000 Commit: Peter Holm CommitDate: 2024-07-19 07:55:39 +0000 stress2: Exclude one more test --- tools/test/stress2/misc/all.exclude | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/test/stress2/misc/all.exclude b/tools/test/stress2/misc/all.exclude index f8936d9efee8..91fb68afabfc 100644 --- a/tools/test/stress2/misc/all.exclude +++ b/tools/test/stress2/misc/all.exclude @@ -57,6 +57,7 @@ suj12.sh Waiting for fix 20230319 suj19.sh https://people.freebsd.org/~pho/stress/log/log0378.txt 20221113 suj27.sh https://people.freebsd.org/~pho/stress/log/log0387.txt 20221113 suj36.sh https://people.freebsd.org/~pho/stress/log/log0392.txt 20221114 +swap3.sh https://people.freebsd.org/~pho/stress/log/log0543.txt 20240719 swapoff2.sh swap_pager_force_pagein: read from swap failed 20171223 swapoff3.sh Excessive OOM killing 20220403 swapoff5.sh log0005.txt, known issue 20210111 From nobody Fri Jul 19 08:10:37 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQMmt0KwMz5RCFb; Fri, 19 Jul 2024 08:10: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQMms5LZGz4Cd6; Fri, 19 Jul 2024 08:10:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721376637; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=tIGGFAQE+N/w1ZogRX0Q9aRIxvb7MUHUTgiyMGSPL4w=; b=mt1xrnRZAvKpGOq0kFNU7tRt8d3wFV0CDvG1yCKFfNLHjt2Hp3S1q8EIOBLyqoQOcYTRx+ XDKIpnc+GL4I9+v1FxiCepw9Z6GnI1LNXN7LIXCWAhEgYQY3QfOf7pMs/7M3VsURCkd9Vv 6XynUxPShFW9+FYOLu7gyXjoY6antIyNlnM8zDIuf+DbXmwKB3W2R5ITuePddr2DHllzU4 eV8PBMcKKjOFVVQOBG40gGRgbb6mt8l2VQompH5sIYE7eSm3xSO9aasKkOZJupmV+jDQxt Qkd59ALQQX9H/MdyViRsBJCotflWAG4kCD+R7ZfDqGOhFMtXwZkkKpIwnAzr+g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721376637; a=rsa-sha256; cv=none; b=kuOCveEB4dAMmcADIeVWu6b6xeaExQ1SFyNd9XN00CGUynNgpRaVrhoimaMn2lRUti9m97 wf0eKW41yLlq7EPRI2kfYzPaILvpKkFIkwuVBzraY2V/I+sX4KNiVXAu1/yRPRHBW/2sMm wgRR4jByl7kG2Fs93feTmfXBP/DgUn3yBs6Drcju/Xms6CBeiHGMip/AXFH0vA3NAu+XcA d/eH6li6JTgXY59/l36mFp7lp0arxmhAfp2Q8fSDbEce2gTtBSghwf9ueM//hKxdxw6x0o jTkKI60naNQ7zKNnyVlXiQfHPVL/n1+8jFbik0Im66VcCZqCI+6vdNIrzCFdZg== 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=1721376637; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=tIGGFAQE+N/w1ZogRX0Q9aRIxvb7MUHUTgiyMGSPL4w=; b=uabos6DtpuBYVo+AuMcCWD0P3q7/a3NhF4wBRFJ8wWSameDUO2U+q8VMmJHlXn/X+M/enF /nZGFujLezVAP1r95NIBf/WWWbSYA9iiGWV4SOvw2O2lkRUGw3M0kA0rtwjH7KOKCh3Lsh gYztzqM0CBmUXA038ijknnUEf0ODM62HztFNJmIi5Zw1vrGlBjh2Ke50Vv5e9RSpDcL6QT YC0f8fpjf6YLOVJuEQ3ePiqgLwoatlWw4Cv276IOEO76sbCMPzkVx0YNyvVu7MRcoufoV5 CibaGR1ip4IvNHv+6Ut9W1RRcM2+FlTKQWyEyYkSAlmED1f71cAnOGM+606TKw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQMms4rsCzNhK; Fri, 19 Jul 2024 08:10:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46J8Ab3w022715; Fri, 19 Jul 2024 08:10:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46J8Abup022712; Fri, 19 Jul 2024 08:10:37 GMT (envelope-from git) Date: Fri, 19 Jul 2024 08:10:37 GMT Message-Id: <202407190810.46J8Abup022712@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: fb05f761ac0b - main - siftr: remove the shutdown_pre_sync event handler on unload List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: fb05f761ac0b28b03eb057e36fe118f007d43d73 Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=fb05f761ac0b28b03eb057e36fe118f007d43d73 commit fb05f761ac0b28b03eb057e36fe118f007d43d73 Author: Kristof Provost AuthorDate: 2024-07-19 06:08:14 +0000 Commit: Kristof Provost CommitDate: 2024-07-19 06:09:58 +0000 siftr: remove the shutdown_pre_sync event handler on unload PR: 280351 MFC after: 2 weeks --- sys/netinet/siftr.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sys/netinet/siftr.c b/sys/netinet/siftr.c index bf0cdc2ac4cc..ea1fbc8ff394 100644 --- a/sys/netinet/siftr.c +++ b/sys/netinet/siftr.c @@ -273,6 +273,7 @@ static struct mtx siftr_pkt_queue_mtx; static struct mtx siftr_pkt_mgr_mtx; static struct thread *siftr_pkt_manager_thr = NULL; static char direction[2] = {'i','o'}; +static eventhandler_tag siftr_shutdown_tag; /* Required function prototypes. */ static int siftr_sysctl_enabled_handler(SYSCTL_HANDLER_ARGS); @@ -1310,6 +1311,7 @@ static int deinit_siftr(void) { /* Cleanup. */ + EVENTHANDLER_DEREGISTER(shutdown_pre_sync, siftr_shutdown_tag); siftr_manage_ops(SIFTR_DISABLE); hashdestroy(counter_hash, M_SIFTR, siftr_hashmask); mtx_destroy(&siftr_pkt_queue_mtx); @@ -1324,8 +1326,8 @@ deinit_siftr(void) static int init_siftr(void) { - EVENTHANDLER_REGISTER(shutdown_pre_sync, siftr_shutdown_handler, NULL, - SHUTDOWN_PRI_FIRST); + siftr_shutdown_tag = EVENTHANDLER_REGISTER(shutdown_pre_sync, + siftr_shutdown_handler, NULL, SHUTDOWN_PRI_FIRST); /* Initialise our flow counter hash table. */ counter_hash = hashinit(SIFTR_EXPECTED_MAX_TCP_FLOWS, M_SIFTR, From nobody Fri Jul 19 14:26:43 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQX6t4gQ8z5RkXK; Fri, 19 Jul 2024 14:26:46 +0000 (UTC) (envelope-from kp@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 "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQX6t45t7z4m6c; Fri, 19 Jul 2024 14:26:46 +0000 (UTC) (envelope-from kp@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721399206; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=H34F2qk4nK8QSnhm6GjAldkPLoJTEpaJy/aCMyugH8M=; b=Gg8hAXMaKyZPraB2x8cF5hTPa5BRraWS8L6P+Bad7f0T8jERH219UoSPJ/Mr17iXA9H8cq 1mJp7B3S19Qq/SZaCvaxtAVoyCFfsA4d+CE0ViIdtdkOc02o8cd46U12x2b0n7pv+lO9n+ GYzYRnPr46O6FEg8iBKlzxip1rdGOBXJGELpkxhTJ2nc3tZB7MnSJL/369YgJHa8XEfiWK ohCrwZ2E6KUYFAE4rpUnpG5p8kkzCUH9Ihx8YSu+7XD1O8Abxfjf5Ztj/gK5v4EUZj2ihP tLu1wFv2H4+yrIrP7xf9h83KyNYnvJsPW27EJuSt+sAEtdqBBWGrrumus+u1YA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721399206; a=rsa-sha256; cv=none; b=WwpYkmmA97lGG3qw+Ox77UbmucutmBVG0aIv4RWYON++i7PTREp12zs+RsmMhHegRmwXX3 /3mj6j0h+NQJTQVE+sjGyrdqZWlnBu0SkFWMvf1U/ppYdmviD3O9PvKaok/Wun7g9ahaRH L+Na/KM/nfIL3g8F+KOEvB10O2bVUIg3b9WU2/HY31yQm+JngY2tOgyQdhDhDv5Gl22594 NZu5VUOpqDWSK50k/IV1y+yFuAU4cgKjJS35XjvpNX+pFyNE0K4cFqJN+vFRClBx6r/2H4 6kvK0CaMwzGEkFFdahXes0igdyiuXmEx20aC3TTVF4WZ0/AkSz1mG0leNxM8CQ== 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=1721399206; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=H34F2qk4nK8QSnhm6GjAldkPLoJTEpaJy/aCMyugH8M=; b=U/u6Owt9G1De+VAMWyv+2FcfsUDOel6icaKbdfbMgsRVIDmi/wVRA+gXoDSVud6Gwka1pG E/sQPeHD09fJPXGyp5AVWfB9CVwt6b/u+Pij5Q1NedAMQYVJOyqyOSlJxW6x/idd7o6vQk kWGJ/yWYbWYVMamOYqU/K6LYc5k5r2mr/3gNXXdjssTcWB8/YjPe7F3MCGlly0+bwz+Jfb O2HvFcOdRufDbTHZqPD4NVUZA/pRJ6WJSpnCH+tmArH9ciysJmsudv3rjSEl2F8csvFlza aqFgP2KKYRRdkpIN6SbRsZmchRg5IsJw7nmzhq1kSlDejfViiAmquTE0tUpFWQ== Received: from venus.codepro.be (venus.codepro.be [5.9.86.228]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "mx1.codepro.be", Issuer "R3" (verified OK)) (Authenticated sender: kp) by smtp.freebsd.org (Postfix) with ESMTPSA id 4WQX6t1ty4z1Lf5; Fri, 19 Jul 2024 14:26:46 +0000 (UTC) (envelope-from kp@FreeBSD.org) Received: by venus.codepro.be (Postfix, authenticated sender kp) id 24EB054BCD; Fri, 19 Jul 2024 16:26:44 +0200 (CEST) From: Kristof Provost To: Konstantin Belousov Cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: ef2a572bf6bd - main - ipsec_offload: kernel infrastructure Date: Fri, 19 Jul 2024 16:26:43 +0200 X-Mailer: MailMate (1.14r5937) Message-ID: In-Reply-To: <202407121125.46CBP8eo093121@gitrepo.freebsd.org> References: <202407121125.46CBP8eo093121@gitrepo.freebsd.org> List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="=_MailMate_AF135622-7B0D-4427-95DE-D24615AC4C5A_=" --=_MailMate_AF135622-7B0D-4427-95DE-D24615AC4C5A_= Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: quoted-printable On 12 Jul 2024, at 13:25, Konstantin Belousov wrote: > The branch main has been updated by kib: > > URL: = > https://cgit.FreeBSD.org/src/commit/?id=3Def2a572bf6bdcac97ef29ce631d2f= 50f938e1ec8 > > commit ef2a572bf6bdcac97ef29ce631d2f50f938e1ec8 > Author: Konstantin Belousov > AuthorDate: 2021-08-22 19:38:04 +0000 > Commit: Konstantin Belousov > CommitDate: 2024-07-12 04:27:58 +0000 > > ipsec_offload: kernel infrastructure > > Inline IPSEC offload moves almost whole IPSEC processing from the > CPU/MCU and possibly crypto accelerator, to the network card. > > The transmitted packet content is not touched by CPU during TX > operations, kernel only does the required policy and security > association lookups to find out that given flow is offloaded, and = > then > packet is transmitted as plain text to the card. For driver = > convenience, > a metadata is attached to the packet identifying SA which must = > process > the packet. Card does encryption of the payload, padding, = > calculates > authentication, and does the reformat according to the policy. > > Similarly, on receive, card does the decapsulation, decryption, = > and > authentification. Kernel receives the identifier of SA that was > used to process the packet, together with the plain-text packet. > > Overall, payload octets are only read or written by card DMA = > engine, > removing a lot of memory subsystem overhead, and saving CPU time = > because > IPSEC algos calculations are avoided. > > If driver declares support for inline IPSEC offload (with the > IFCAP2_IPSEC_OFFLOAD capability set and registering method table = > struct > if_ipsec_accel_methods), kernel offers the SPD and SAD to driver. > Driver decides which policies and SAs can be offloaded based on > hardware capacity, and acks/nacks each SA for given interface to > kernel. Kernel needs to keep this information to make a decision = > to > skip software processing on TX, and to assume processing already = > done > on RX. This shadow SPD/SAD database of offloads is rooted from > policies (struct secpolicy accel_ifps, struct ifp_handle_sp) and = > SAs > (struct secasvar accel_ipfs, struct ifp_handle_sav). > > Some extensions to the PF_KEY socket allow to limit interfaces for > which given SP/SA could be offloaded (proposed for offload). = > Also, > additional statistics extensions allow to observe = > allocation/octet/use > counters for specific SA. > > Since SPs and SAs are typically instantiated in non-sleepable = > context, > while offloading them into card is expected to require costly = > async > manipulations of the card state, calls to the driver for offload = > and > termination are executed in the threaded taskqueue. It also = > solves > the issue of allocating resources needed for the offload database. > Neither ipf_handle_sp nor ipf_handle_sav do not add reference to = > the > owning SP/SA, the offload must be terminated before last reference = > is > dropped. ipsec_accel only adds transient references to ensure = > safe > pointer ownership by taskqueue. > > Maintaining the SA counters for hardware-accelerated packets is = > the > duty of the driver. The helper = > ipsec_accel_drv_sa_lifetime_update() > is provided to hide accel infrastructure from drivers which would = > use > expected callout to query hardware periodically for updates. > > Reviewed by: rscheff (transport, stack integration), np > Sponsored by: NVIDIA networking > Differential revision: https://reviews.freebsd.org/D44219 > --- > sys/conf/files | 2 + > sys/conf/options | 1 + > sys/modules/ipsec/Makefile | 5 +- > sys/netipsec/ipsec.c | 17 + > sys/netipsec/ipsec.h | 11 + > sys/netipsec/ipsec_input.c | 11 + > sys/netipsec/ipsec_offload.c | 1061 = > ++++++++++++++++++++++++++++++++++++++++++ > sys/netipsec/ipsec_offload.h | 191 ++++++++ > sys/netipsec/ipsec_output.c | 15 + > sys/netipsec/ipsec_pcb.c | 38 +- > sys/netipsec/key.c | 270 ++++++++++- > sys/netipsec/key.h | 6 + > sys/netipsec/key_debug.c | 5 + > sys/netipsec/keydb.h | 14 + > 14 files changed, 1628 insertions(+), 19 deletions(-) > I=E2=80=99m seeing messages like `ipsec_accel_sa_install_newkey: spi 0x10= 01 = flags 0x40 seq 0` running the test suite now. Are those stray debug printfs? Best regards, Kristof --=_MailMate_AF135622-7B0D-4427-95DE-D24615AC4C5A_= Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable

On 12 Jul 2024, at 13:25, Konstantin Belousov wrote:

The branch main has been updated by= kib:

URL: https://cgit.FreeBSD.org/src/co= mmit/?id=3Def2a572bf6bdcac97ef29ce631d2f50f938e1ec8

commit ef2a572bf6bdcac97ef29ce631d2f50f938e1ec8
Author: Konstantin Belousov <kib@FreeBSD.org>
AuthorDate: 2021-08-22 19:38:04 +0000
Commit: Konstantin Belousov <kib@FreeBSD.org>
CommitDate: 2024-07-12 04:27:58 +0000

ipsec_offload: kernel infrastructure

Inline IPSEC offload moves almost whole IPSEC process= ing from the
CPU/MCU and possibly crypto accelerator, to the network card.

The transmitted packet content is not touched by CPU = during TX
operations, kernel only does the required policy and security
association lookups to find out that given flow is offloaded, and the= n
packet is transmitted as plain text to the card. For driver convenien= ce,
a metadata is attached to the packet identifying SA which must proces= s
the packet. Card does encryption of the payload, padding, calculates
authentication, and does the reformat according to the policy.

Similarly, on receive, card does the decapsulation, d= ecryption, and
authentification. Kernel receives the identifier of SA that was
used to process the packet, together with the plain-text packet.

Overall, payload octets are only read or written by c= ard DMA engine,
removing a lot of memory subsystem overhead, and saving CPU time beca= use
IPSEC algos calculations are avoided.

If driver declares support for inline IPSEC offload (= with the
IFCAP2_IPSEC_OFFLOAD capability set and registering method table stru= ct
if_ipsec_accel_methods), kernel offers the SPD and SAD to driver.
Driver decides which policies and SAs can be offloaded based on
hardware capacity, and acks/nacks each SA for given interface to
kernel. Kernel needs to keep this information to make a decision to
skip software processing on TX, and to assume processing already done=
on RX. This shadow SPD/SAD database of offloads is rooted from
policies (struct secpolicy accel_ifps, struct ifp_handle_sp) and SAs
(struct secasvar accel_ipfs, struct ifp_handle_sav).

Some extensions to the PF_KEY socket allow to limit i= nterfaces for
which given SP/SA could be offloaded (proposed for offload). Also,
additional statistics extensions allow to observe allocation/octet/us= e
counters for specific SA.

Since SPs and SAs are typically instantiated in non-s= leepable context,
while offloading them into card is expected to require costly async
manipulations of the card state, calls to the driver for offload and
termination are executed in the threaded taskqueue. It also solves
the issue of allocating resources needed for the offload database.
Neither ipf_handle_sp nor ipf_handle_sav do not add reference to the
owning SP/SA, the offload must be terminated before last reference is=
dropped. ipsec_accel only adds transient references to ensure safe
pointer ownership by taskqueue.

Maintaining the SA counters for hardware-accelerated = packets is the
duty of the driver. The helper ipsec_accel_drv_sa_lifetime_update()
is provided to hide accel infrastructure from drivers which would use=
expected callout to query hardware periodically for updates.

Reviewed by: rscheff (transport, stack integration= ), np
Sponsored by: NVIDIA networking
Differential revision: https://reviews.freebsd.org/D44219
---
sys/conf/files | 2 +
sys/conf/options | 1 +
sys/modules/ipsec/Makefile | 5 +-
sys/netipsec/ipsec.c | 17 +
sys/netipsec/ipsec.h | 11 +
sys/netipsec/ipsec_input.c | 11 +
sys/netipsec/ipsec_offload.c | 1061 ++++++++++++++++++++++++++++++++++++= ++++++
sys/netipsec/ipsec_offload.h | 191 ++++++++
sys/netipsec/ipsec_output.c | 15 +
sys/netipsec/ipsec_pcb.c | 38 +-
sys/netipsec/key.c | 270 ++++++++++-
sys/netipsec/key.h | 6 +
sys/netipsec/key_debug.c | 5 +
sys/netipsec/keydb.h | 14 +
14 files changed, 1628 insertions(+), 19 deletions(-)


I=E2=80=99m seeing messages like ipsec_accel_sa_install_newkey: spi = 0x1001 flags 0x40 seq 0 running the test suite now.
Are those stray debug printfs?

Best regards,
Kristof

--=_MailMate_AF135622-7B0D-4427-95DE-D24615AC4C5A_=-- From nobody Fri Jul 19 15:40:14 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQYlf58mDz5Rr9d; Fri, 19 Jul 2024 15:40: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQYlf4TK1z4shD; Fri, 19 Jul 2024 15:40:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721403614; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=WD+LufB9BvXXcWXHuKOlBk/DO0i0MDOoHUmk+3u5BUU=; b=gW0Y4tTVb3UunKYqcezWTQTirAwB+xLJ4cshZp8WCP8zV9bt2XpYqt8RIr7dTwfF61U8pC 5qVvKZsvNAu41g49bOzDcS5rqIxXlDr6ZBarc6moAG7SaVtdgU7+hX+FRkv442KXuRHaBT yl5ArEqjbd2HH8ERUu3VPtY/mhUo4HHoIW44ZRq16ziqRad18x3ir4MrgAQfPxiai7W3MT yplLO66WmP4czFTR0p8M76tySFVC0FKLYiZGnY1FE8SpeHMIbN9Z2/hEHCq/ERycA0+yOo FVmiHkFwutjmd7UdxetRXs75OeBlSZDce2B5cYId/DkMxnO3eBJmKxgcILn5wg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721403614; a=rsa-sha256; cv=none; b=EK4BalN6sxjT71S4CycAJaeG1y+CdIxwUkhYlMk1Wfecgxr2/KgVB8GdEVnT6yaXTLvnna hunZFPK3OXvZcX0tljhULGipC5qmbUKux349V+yFPNEIwpxt3VzCXFhejPJPI1JKRKwi7y rCJ3VpTxWT0mz3YEU6fv+tQL/gGx1p9BMc/afXSPCLy7hI0HPw/O9dsGywbeI6MbGwLcbW QXAg6uxIN9RHVfJ3dai9lSploHXKg5+ihWZ/UZE6njDE9T8N0yNxqpPAXnFsuOoehFEFk8 yoxZ01cGhzbF+FZMKy4vA9Q6pggiEdxZADKJb0bn1gaSzTenrmPW6mm73Xp0CA== 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=1721403614; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=WD+LufB9BvXXcWXHuKOlBk/DO0i0MDOoHUmk+3u5BUU=; b=rRppGPolNU+eossLXAjrnQaBHkxq0rAbiBRUfxhNcE65RCA8ZIALzruhAKDYDKikiLgHqz SlbLGCzUKp3eGWAXHVR/7JZRW9fvhvp4d6cGrYpfzmB7FoPITP6otSxmbrzjVw3SPdrNAy i/fqO4qkZWAij5F0BRRWoPPxFyNggzm38hjP9Kx7obM1AQ/nf2g4lj9In88t2wEHaBa42X zHQcSs0kyCgV0dzyapO2f+TqMSbE0xVH1U7qGMYKuG4/2Q95bdhSmauuPPvuHWvGgbNfdE PeV8hfT8kdN0afoTSwGdE32pffgP8pqzl2yMYf60p3LqxGTvmvyqDksrhAGohw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQYlf45Clzd8P; Fri, 19 Jul 2024 15:40:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JFeESR080684; Fri, 19 Jul 2024 15:40:14 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JFeEFl080678; Fri, 19 Jul 2024 15:40:14 GMT (envelope-from git) Date: Fri, 19 Jul 2024 15:40:14 GMT Message-Id: <202407191540.46JFeEFl080678@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: John Baldwin Subject: git: 422911ca5873 - stable/14 - NOTES: Move OFED options to MI NOTES List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 422911ca5873bd945e52d60f99b135488d3b6846 Auto-Submitted: auto-generated The branch stable/14 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=422911ca5873bd945e52d60f99b135488d3b6846 commit 422911ca5873bd945e52d60f99b135488d3b6846 Author: John Baldwin AuthorDate: 2024-04-09 22:02:58 +0000 Commit: John Baldwin CommitDate: 2024-07-18 17:06:06 +0000 NOTES: Move OFED options to MI NOTES Disable in armv7 NOTES to match sys/modules/Makefile Reviewed by: imp Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D44686 (cherry picked from commit 973d3a82096bc135f6c230e348e2f33c382096bc) --- sys/amd64/conf/NOTES | 13 ------------- sys/arm/conf/NOTES | 5 +++++ sys/conf/NOTES | 13 +++++++++++++ sys/i386/conf/NOTES | 13 ------------- 4 files changed, 18 insertions(+), 26 deletions(-) diff --git a/sys/amd64/conf/NOTES b/sys/amd64/conf/NOTES index 9c91a4fa9bbb..761728337ac2 100644 --- a/sys/amd64/conf/NOTES +++ b/sys/amd64/conf/NOTES @@ -90,19 +90,6 @@ options DEVICE_POLLING options BPF_JITTER -# OpenFabrics Enterprise Distribution (Infiniband). -options OFED -options OFED_DEBUG_INIT - -# Sockets Direct Protocol -options SDP -options SDP_DEBUG - -# IP over Infiniband -options IPOIB -options IPOIB_DEBUG -options IPOIB_CM - ##################################################################### # CLOCK OPTIONS diff --git a/sys/arm/conf/NOTES b/sys/arm/conf/NOTES index 74ee03dd4764..e868d6b60496 100644 --- a/sys/arm/conf/NOTES +++ b/sys/arm/conf/NOTES @@ -66,6 +66,11 @@ nooptions COMPAT_FREEBSD9 nooptions PPC_PROBE_CHIPSET nooptions MAXCPU # value is set in machine/param.h +nooptions OFED +nooptions SDP +nooptions IPOIB +nooptions IPOIB_CM + nodevice sym nodevice ccr diff --git a/sys/conf/NOTES b/sys/conf/NOTES index c6434d1ea85d..5da6c6292c83 100644 --- a/sys/conf/NOTES +++ b/sys/conf/NOTES @@ -768,6 +768,19 @@ options SCTP_PACKET_LOGGING options SCTP_LTRACE_CHUNKS options SCTP_LTRACE_ERRORS +# OpenFabrics Enterprise Distribution (Infiniband). +options OFED +options OFED_DEBUG_INIT + +# Sockets Direct Protocol +options SDP +options SDP_DEBUG + +# IP over Infiniband +options IPOIB +options IPOIB_DEBUG +options IPOIB_CM + # altq(9). Enable the base part of the hooks with the ALTQ option. # Individual disciplines must be built into the base system and can not be # loaded as modules at this point. ALTQ requires a stable TSC so if yours is diff --git a/sys/i386/conf/NOTES b/sys/i386/conf/NOTES index ce115b1640e0..45613c10c583 100644 --- a/sys/i386/conf/NOTES +++ b/sys/i386/conf/NOTES @@ -238,19 +238,6 @@ options DEVICE_POLLING options BPF_JITTER -# OpenFabrics Enterprise Distribution (Infiniband). -options OFED -options OFED_DEBUG_INIT - -# Sockets Direct Protocol -options SDP -options SDP_DEBUG - -# IP over Infiniband -options IPOIB -options IPOIB_DEBUG -options IPOIB_CM - ##################################################################### # CLOCK OPTIONS From nobody Fri Jul 19 15:40:15 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQYlg6VCyz5RrG9; Fri, 19 Jul 2024 15:40: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQYlg50p4z4sY2; Fri, 19 Jul 2024 15:40:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721403615; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=BpfKoWNeI3JNMhX+dsl3ZTuGsdJ6rLjPRc4e0H66C30=; b=j/he1S/7xQO2FHx2tSKXB3LQRr4EO7GfNzeF6+bdxWDhB77A7lfPglFHeMn3ZTD5HDpNld L+JTLy9OKzw3E7U3tbIJBgneSJ5X5QvBs36g4KX1DrZsiS0qS/rlTY0yr3dICrUaF3Obft 1ybkPcuvvLTcU2MYNrCpW34WjY5CP9FTQB/1xZYIc345I8Q3BYFlZmBbOVP1Hq1DBvDOzh irRBX3blELU6c9iZ4jCgFer+PyXP/1XaJ1FiZPesKSU9OzDaHa/1BYJst33wvJvN4x/p2k 7PZhfnce1EbgYm8sT8GNGk7gQ5kGzVaLucaP3HAa/NR/ju8PuGpCl6NFKyR4Rg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721403615; a=rsa-sha256; cv=none; b=PbcduRE82d6ViO4URQO4o6fcMtBt3v55wG4VzIDBMxBZHkleBOCKixom23MXftppcDeOoI XL1Mqj/vbh1RqkXnkhH9sN7aRyU/QZMuPAF4FUvi5dBv3o5QGvo21SEhotHDaWrMBh1+sh NQunZoWgwJhg0THE394LyOd0gx9ubpdLxIy9XZaEFIrGo65upEqePEggYZXBEm2Vd17oNg NxhL4kdjNdxvykIHKGmevapViTiogWsH0pIFQW9FziMbLjf5dKzYH3tGI0lb0UcyzcT8rl 3L9tAIpwJWnhQzMY9Wp8QnI0akKh8MpbsbDXj/YXd06yxXwsEF+76PD62+w6Jg== 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=1721403615; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=BpfKoWNeI3JNMhX+dsl3ZTuGsdJ6rLjPRc4e0H66C30=; b=GJ8ERcKPOgqdYFS+shJ9fpEEhAoDMbqKuzhWsR8o5Eof1cuZmJT9wN43ukvpP70MTvJSkx rpO9JVNARayLq8OgbxkwON5anZtn32XIQF9M09MzUlksr0pXJYFAvFGOZ4tGb7fAUonyWS 5QxvD8coVmjkHdyl/3ymsoxUOujsMRiPbClFQAN4RaOZ9QU33umSZH10GzZJu2PT12FoQn ZcAu3jYd4gBriyP2PEhNYndBcZMNERRmRPT4dZmFxF7oR4e7guuNOnBiljup/L4nSY+gBm 7+kQmBmWsNJeNSLmHeqImSPuEd3CFiXxsRnufMiZH7jYL4PKzAiErTfokqAPZw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQYlg4bWrzdfM; Fri, 19 Jul 2024 15:40:15 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JFeFWa081381; Fri, 19 Jul 2024 15:40:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JFeFfU081372; Fri, 19 Jul 2024 15:40:15 GMT (envelope-from git) Date: Fri, 19 Jul 2024 15:40:15 GMT Message-Id: <202407191540.46JFeFfU081372@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: John Baldwin Subject: git: 41302e9e78ad - stable/14 - iser: Add kernel build glue List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 41302e9e78ad89b87e2436b382378d3aed6e4484 Auto-Submitted: auto-generated The branch stable/14 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=41302e9e78ad89b87e2436b382378d3aed6e4484 commit 41302e9e78ad89b87e2436b382378d3aed6e4484 Author: John Baldwin AuthorDate: 2024-04-09 22:02:58 +0000 Commit: John Baldwin CommitDate: 2024-07-18 17:14:00 +0000 iser: Add kernel build glue 'device iser' is documented in iser(4) but not supported. Hook it up to the build. Reviewed by: imp Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D44687 (cherry picked from commit 60bb979b3c3224f01e96f7e3c92a270977d2587b) --- sys/conf/files | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/sys/conf/files b/sys/conf/files index e223514dc280..6dca944b9f61 100644 --- a/sys/conf/files +++ b/sys/conf/files @@ -1903,6 +1903,14 @@ dev/iscsi/icl_conn_if.m optional cfiscsi | iscsi dev/iscsi/icl_soft.c optional iscsi dev/iscsi/icl_soft_proxy.c optional iscsi dev/iscsi/iscsi.c optional iscsi scbus +dev/iser/icl_iser.c optional iser \ + compile-with "${OFED_C} -DICL_KERNEL_PROXY" +dev/iser/iser_initiator.c optional iser \ + compile-with "${OFED_C} -DICL_KERNEL_PROXY" +dev/iser/iser_memory.c optional iser \ + compile-with "${OFED_C} -DICL_KERNEL_PROXY" +dev/iser/iser_verbs.c optional iser \ + compile-with "${OFED_C} -DICL_KERNEL_PROXY" dev/ismt/ismt.c optional ismt dev/isl/isl.c optional isl iicbus dev/isp/isp.c optional isp From nobody Fri Jul 19 15:40:16 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQYlj0xgxz5Rr9l; Fri, 19 Jul 2024 15:40: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQYlh5qFDz4sbW; Fri, 19 Jul 2024 15:40:16 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721403616; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=XdtoJGwwL87uKSsbRphL3bdkRGtqlt/3F8yLK2xc1mE=; b=aOY0qEFLORLV0qr7s4Yt+KVffzjOJYTyjnvCBOfy5n0DU1UAv7fyXXRNJGBnRi47+9Qt8g 6b4fOm4dKcP4bX78mMfbIjo9VxvUN53OAMHj9ggB9pRxjZ8VwY+/r1kg8spMhVDjScALe+ DxU93RZjsmgmtYNGuMnM8viiqece4RJMrslP2DVvg4ENfyEMB1E+cctD8AF4mjMK8JfQZi e+frtntX5b508OapUz2FpjkT41Cc5PKsEhsRtCflZ+ht4tdbDC4yc6x8pVTKLVhmOjx3/p gaIF7VJO4y4zBxBxkrW7JHKuzV477uEB/r0u6B3E5DdPMIgehJtWIB1j/JpCXA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721403616; a=rsa-sha256; cv=none; b=h9NJMrlksmw8WsDfTX0bUEej4X/s4UsvMHJlrjBLQmztA2qso/vgs5d7ZcRkWfONLdZ/O9 szKcTk6R9Dnr/gK/2jy4+YvlITWMeMphtAec+RxLV0jIStsqFDs/jsH5DWANUk2Y6Zf1gU 6cipRF/ZamB8UIrXjFfE+odFbKN/FIBrJZk5e9Ab7qvL1aSnxaI5Nmxw+394qNcansZE6Y rCPhjHCKXfaD+QPu0REcpDJ1GQLTzOZKt4AyvJXfjWfGSDED93JFtVHqsU00GJPF0H5ykK Mg1VTcNcMNzyGEdEVJRr59kOHaV5LEYJXzqQGHhoXgGZYSH4om+ukJ/rmNBkHg== 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=1721403616; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=XdtoJGwwL87uKSsbRphL3bdkRGtqlt/3F8yLK2xc1mE=; b=AWnCUDDlM/fVGjI1x22dRIUNZ6GbW8b/TwNO5uMk42jtWxcCK7GEWi+bi0DN58l8GSUe53 A3WCoz1DxSvwjJPt58hTBrgqZzhZXKEXWpJL+aFEZV8QNTLT19wQOyZ8jHHdvka9yWxuRp rVS+Rcwna7GXxl0LQjhka6EMd1CqNv6BrnwGpWHplWl549mS9/sqWUHPfX8Hsim6yJ5R0v N6hP2Scr+EwMQrPSYnEfJBbzBCoY/iiq+2UtARxyIxp4KSC2HEoDZelDBusmVLUknTgieX rAVwb11JQLi6QOyk3hwcAjy/mS7gN6x+O6KvR9vLKEeSRC4bSJBw4EzY0oBFCQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQYlh59NWzchr; Fri, 19 Jul 2024 15:40:16 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JFeGVn082025; Fri, 19 Jul 2024 15:40:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JFeGdQ082017; Fri, 19 Jul 2024 15:40:16 GMT (envelope-from git) Date: Fri, 19 Jul 2024 15:40:16 GMT Message-Id: <202407191540.46JFeGdQ082017@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: John Baldwin Subject: git: d6f503b7815a - stable/14 - NOTES: Add devices for iSCSI support List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: d6f503b7815a59ac3ae735ec0f009005e0d04563 Auto-Submitted: auto-generated The branch stable/14 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=d6f503b7815a59ac3ae735ec0f009005e0d04563 commit d6f503b7815a59ac3ae735ec0f009005e0d04563 Author: John Baldwin AuthorDate: 2024-04-09 22:02:58 +0000 Commit: John Baldwin CommitDate: 2024-07-18 17:14:08 +0000 NOTES: Add devices for iSCSI support Reviewed by: imp Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D44688 (cherry picked from commit 76f22e353f66d9ec1c1bea1d72eeec56078d4728) --- sys/arm/conf/NOTES | 1 + sys/conf/NOTES | 17 +++++++++++++---- 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/sys/arm/conf/NOTES b/sys/arm/conf/NOTES index e868d6b60496..e89ce0e408d5 100644 --- a/sys/arm/conf/NOTES +++ b/sys/arm/conf/NOTES @@ -71,6 +71,7 @@ nooptions SDP nooptions IPOIB nooptions IPOIB_CM +nodevice iser nodevice sym nodevice ccr diff --git a/sys/conf/NOTES b/sys/conf/NOTES index 5da6c6292c83..9d2ab71623ed 100644 --- a/sys/conf/NOTES +++ b/sys/conf/NOTES @@ -1458,6 +1458,19 @@ options SCSI_PT_DEFAULT_TIMEOUT=60 # a topology with the SES device that's on the box these drives are in.... options SES_ENABLE_PASSTHROUGH +# iSCSI +# +# iSCSI permits access to SCSI peripherals over a network connection +# (e.g. via a TCP/IP socket) + +device cfiscsi # CAM Target Layer iSCSI target frontend +device iscsi # iSCSI initiator +device iser # iSCSI Extensions for RDMA (iSER) initiator + +# Options used in dev/iscsi (Software iSCSI stack) +# +options ISCSI_INITIATOR_DEBUG=9 + ##################################################################### # MISCELLANEOUS DEVICES AND OPTIONS @@ -1617,10 +1630,6 @@ options AHD_REG_PRETTY_PRINT # Bitmap of units to enable targetmode operations. options AHD_TMODE_ENABLE -# Options used in dev/iscsi (Software iSCSI stack) -# -options ISCSI_INITIATOR_DEBUG=9 - # Options used in dev/isp/ (Qlogic SCSI/FC driver). # # ISP_TARGET_MODE - enable target mode operation From nobody Fri Jul 19 15:40:17 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQYlk1rvYz5RrDF; Fri, 19 Jul 2024 15:40: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQYlj6Gxnz4sWH; Fri, 19 Jul 2024 15:40:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721403617; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VLpOwmDK9LkWvcnzxqLMMtPwgbvJNAWFV/uqRFqNXy0=; b=drEWp6iiAhz/aiPlZ1aRkO36GMS01bsDR47kFitoMPvMmUJso/2cOWSlO8SvlaSIZ4NSP8 6bfewFp8Ll4m0SL5V3iP+/b/CLiXUYivobHrwX3agvAvLiGoJLOXpfTrbVCCGiQwUtEH+X vAl+P6OXUzzI/EU+Aa0QX26O0SLconE+/2AJ3oT45vhdkZOh1ZY5feXXxQrcATiBmtMkcS dZpOTLnuxwsNucXn/fm6lHEQU2L4Uw04sM5sHeKEQiP3jx18XuebfUzpW597g/uJHlz0B3 U1OhwcDODIOxTFr3Xj4QLvZxsrRPNCOL7qajLOG7QIBUec2Knt7WWqI9op+Gow== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721403617; a=rsa-sha256; cv=none; b=DZwN81sM7J1gTuoSBU8lTr+1aDrLFjLlZJdXRs/PvUXP00TY2SufT8IdAGTzfqiPifGL5p YrG5JRrJWLKPISuOjthtukQnx5L4hmW4vqrb47CC3TN5KbGzodWkziRa+LLxE+rFmSrMJS 9qntV2QyCAtZdmmD+8GTTBz3mXiS9HLAjO3CguXXxHV6l4QwtpbsURcYYZppXVv/TBPJna Nnuf6nYUPdxVi+o4DsNiAwRnfpEh9RWCYT1L44VntcBm3vdgT23PVkE4UMB2bfObBHgYYW rh6Bzb3t5FwpKotIgtafVe839Ic3K+QUIwnGV34IEr5Rm8AKXVHXiHvu59qp9w== 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=1721403617; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VLpOwmDK9LkWvcnzxqLMMtPwgbvJNAWFV/uqRFqNXy0=; b=CJHpjhf8tnjcwgvvKv1RTO9j8D0101QxqhIeg+dM/9AIHXUI0Oyw2gsxOvfAUCYafxa1WH HXrU19cD2/0wylOrbKvrcSBRDtxYzXckrXNvl0aNwbjJHigb5buaF1x9Y/1uyMU+mAsFlG 0oO1uQGCOfLmclUdn8xNtzNgXZd3vA/tUvxAJaVU8VMf2nPGoXkfplb6QDwCTq0SEx8rc2 YZ1oNR+PPTY0r6uh6odBv5X0DmymsGJlXrXiXIkZyob506DZ/lfuGm/PQ5f5SwTyPxSlHK XpLIlJ8UZFsb3Ns7HWlcsx4PONJjT6cHpmXkyYBozIt32R4W1/Bul8Xa10kS2Q== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQYlj5sslzdfN; Fri, 19 Jul 2024 15:40:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JFeHC7082670; Fri, 19 Jul 2024 15:40:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JFeHhI082667; Fri, 19 Jul 2024 15:40:17 GMT (envelope-from git) Date: Fri, 19 Jul 2024 15:40:17 GMT Message-Id: <202407191540.46JFeHhI082667@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: John Baldwin Subject: git: 15e2ffbbfade - stable/14 - NOTES: Tidy entries for SATA controllers List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 15e2ffbbfade7cf5e37ff4e3259f698436d425d4 Auto-Submitted: auto-generated The branch stable/14 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=15e2ffbbfade7cf5e37ff4e3259f698436d425d4 commit 15e2ffbbfade7cf5e37ff4e3259f698436d425d4 Author: John Baldwin AuthorDate: 2024-04-09 22:02:58 +0000 Commit: John Baldwin CommitDate: 2024-07-18 17:14:22 +0000 NOTES: Tidy entries for SATA controllers - Add typical comments after device entries (copied from amd64 GENERIC) - Add an entry for 'device ada'. Normally this is pulled in via 'device sd', but is documented in ada(4) and can be used to include ATA/SATA disk support in a kernel without SCSI disk support. Reviewed by: imp Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D44689 (cherry picked from commit a508f5d92a93cda11b0c68084dbb181f97e7f5f7) --- sys/conf/NOTES | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/sys/conf/NOTES b/sys/conf/NOTES index 9d2ab71623ed..3217bdcb9600 100644 --- a/sys/conf/NOTES +++ b/sys/conf/NOTES @@ -1682,9 +1682,10 @@ device mrsas # LSI/Avago MegaRAID SAS/SATA, 6Gb/s and 12Gb/s # These drivers are part of cam(4) subsystem. They supersede less featured # ata(4) subsystem drivers, supporting same hardware. -device ahci -device mvs -device siis +device ahci # AHCI-compatible SATA controllers +device mvs # Marvell 88SX50XX/88SX60XX/88SX70XX/SoC SATA +device siis # SiliconImage SiI3124/SiI3132/SiI3531 SATA +device ada # ATA/SATA direct access devices (aka disks) # # The 'ATA' driver supports all legacy ATA/ATAPI controllers, including @@ -1694,7 +1695,7 @@ device siis # the 'atacore' driver then selecting the drivers on a per vendor basis. # For example to build a system which only supports a VIA chipset, # omit 'ata' and include the 'atacore', 'atapci' and 'atavia' drivers. -device ata +device ata # Legacy ATA/SATA controllers # Modular ATA #device atacore # Core ATA functionality From nobody Fri Jul 19 15:40:18 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQYll1wGzz5Rr9r; Fri, 19 Jul 2024 15:40: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQYll09Tnz4sYm; Fri, 19 Jul 2024 15:40:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721403619; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=8tVv6thUbq+kOq5I+oAfqWJTzJAU+y9scHKqIY1bXO8=; b=BIIhj5rwj1l4cn7xdGV/XCk1xG77bZyzxxwZaLivQKyFK0IKB/u9sR5mcUtcKQMcAXtKPd 7eCeaTKTOCbM0DylIPRDTvbHnhUl69oc3D1CEd429HqMUMCzntImhcWO/oGHih4NGLim03 fv/VKwrnPWTNehoR2/006KJYtHGZLynxVlevQMnO4RJyxJJ/XcmhOHMh+jYcKcxFH/ckv1 yUUwuEsRxnrHTpSKxdbK3PMOnp7qB4BG6xoi46E38+SzGp8I6rtxZLazrwm7cJXUt7CSam 7PIFLWWGcPFElYamamXa6fgkkhEYUHG63uIKOyUwZIYHJQwAhgCBYC8lDBua9Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721403619; a=rsa-sha256; cv=none; b=I65TzDJetMtKLmWYK88CMLcmL4DvUcohyWHSI1Z8mR7WF8vBftIvhVB/8HezyD+WADEWR+ Uy4/3PXxFt+CEaDKMIMQcZ7Yu6BKCUPmS6hINC7i+mCRQc0UT82t1uhvNwDafld5Q1zr/o 8T/PfEyJjJ1fYT3g5jg+4zxbh/A/m2SWXl8zsth8E2d4+E8k7iJcqS8yAFwjsCoLk0Oq9l VWkoybglVZ/VGDQkmUpeRtRiAGwUnry0TSCxOdEgbmfQOMaoXNP7RcwyEyFEF9+im/OAch HUA6cV96r2WL6Oh9y1tVHJx63yhIlNy4vTeJNzPiT1WXnrCeySPKwfU/YjzQOg== 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=1721403619; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=8tVv6thUbq+kOq5I+oAfqWJTzJAU+y9scHKqIY1bXO8=; b=xbO3JW1LR55fiRiTX3xvsO2lG5OHzSWqX3ctCUd2eSPLZdT8MKKf8ONZY8iJtWteYW0QWG 1gwcr0rI0Ww+MXjPKocDyxI4H91C+iRozZd+Zur2nO0HytKTtJ2lsohp2FZ+mg5eFpcyDP 7AcHTteaMi0KChk+U1fD/h4gRO8J2xNjIlsW64XIgp7W4Tv13ymLia4nDyEahKyrrKVd/k E0ZqUD5+BurCl+s2PN1lTVc88xt3BssvhzntMAs/M7YXqneBKhMSnqZsjJb7BK/iNCUKml zTwXFzuRuDKyzTi65yNkIx51sNivy1tUTu3LkAhuqTWPyBysB1YtTu50LZCDtA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQYlk6v9tzd8Q; Fri, 19 Jul 2024 15:40:18 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JFeIn0082724; Fri, 19 Jul 2024 15:40:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JFeIql082721; Fri, 19 Jul 2024 15:40:18 GMT (envelope-from git) Date: Fri, 19 Jul 2024 15:40:18 GMT Message-Id: <202407191540.46JFeIql082721@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: John Baldwin Subject: git: 24687a65dd7f - stable/14 - sys: Enable NVMe drivers on all architectures List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 24687a65dd7f7eb4042f783b9d0f5af4f969f13c Auto-Submitted: auto-generated The branch stable/14 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=24687a65dd7f7eb4042f783b9d0f5af4f969f13c commit 24687a65dd7f7eb4042f783b9d0f5af4f969f13c Author: John Baldwin AuthorDate: 2024-04-09 22:02:58 +0000 Commit: John Baldwin CommitDate: 2024-07-18 17:19:18 +0000 sys: Enable NVMe drivers on all architectures The NVMe drivers are portable and are already included statically in GENERIC on other architectures such as aarch64 and riscv64. Reviewed by: imp Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D44690 (cherry picked from commit 16e846fa1ed3c97419b55b292f77b0f4209f0875) --- share/man/man4/Makefile | 11 ++--------- sys/modules/Makefile | 8 ++------ 2 files changed, 4 insertions(+), 15 deletions(-) diff --git a/share/man/man4/Makefile b/share/man/man4/Makefile index aa55108d8b4e..612b063de3de 100644 --- a/share/man/man4/Makefile +++ b/share/man/man4/Makefile @@ -408,9 +408,9 @@ MAN= aac.4 \ ${_if_ntb.4} \ null.4 \ numa.4 \ - ${_nvd.4} \ + nvd.4 \ ${_nvdimm.4} \ - ${_nvme.4} \ + nvme.4 \ ${_nvram.4} \ oce.4 \ ocs_fc.4\ @@ -843,8 +843,6 @@ _ntb_hw_amd.4= ntb_hw_amd.4 _ntb_hw_intel.4= ntb_hw_intel.4 _ntb_hw_plx.4= ntb_hw_plx.4 _ntb_transport.4=ntb_transport.4 -_nvd.4= nvd.4 -_nvme.4= nvme.4 _nvram.4= nvram.4 _padlock.4= padlock.4 _pchtherm.4= pchtherm.4 @@ -892,11 +890,6 @@ _vmm.4= vmm.4 .endif .endif -.if ${MACHINE_CPUARCH} == "powerpc" -_nvd.4= nvd.4 -_nvme.4= nvme.4 -.endif - .if ${MACHINE_CPUARCH} == "amd64" || ${MACHINE_CPUARCH} == "i386" || \ ${MACHINE_CPUARCH} == "aarch64" _gve.4= gve.4 diff --git a/sys/modules/Makefile b/sys/modules/Makefile index 56a28b4b71ec..674ae1a86bc5 100644 --- a/sys/modules/Makefile +++ b/sys/modules/Makefile @@ -291,9 +291,9 @@ SUBDIR= \ nmdm \ nullfs \ ${_ntb} \ - ${_nvd} \ + nvd \ ${_nvdimm} \ - ${_nvme} \ + nvme \ ${_nvram} \ oce \ ${_ocs_fc} \ @@ -798,8 +798,6 @@ _iwmfw= iwmfw _iwnfw= iwnfw .endif _nfe= nfe -_nvd= nvd -_nvme= nvme _nvram= nvram .if ${MK_CRYPT} != "no" || defined(ALL_MODULES) _padlock= padlock @@ -881,8 +879,6 @@ _cfi= cfi _cpufreq= cpufreq _exca= exca _ffec= ffec -_nvd= nvd -_nvme= nvme .endif .if ${MACHINE_ARCH:Mpowerpc64*} != "" From nobody Fri Jul 19 15:40:20 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQYlm2DZ6z5Rr5H; Fri, 19 Jul 2024 15:40: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQYlm0xgPz4scX; Fri, 19 Jul 2024 15:40:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721403620; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=f1iINIzDdIlb78Xy8iMPY93DdBFg8va73/n6Ui21CtA=; b=ORssLxl/3T/ltB53c8XxAcf1FnwQDVmHOfXpcg9oOG0FNKr07DTFseLo5sK41879NXvpGM 4oNeADvQq3aphMVAw8bTpZeanOxYy9PIQ3VLPGXsDu32mhSeimVl9V1r8KPUHLOJDpp2io DYh/hACRnqTrjFFxQNWd+CUaM920IsAv1Rp4NNIAK84GvOVgPoAQ9yOTulnzj1BklTRXJn fNt3a/wE5J82CW63+W9qWwnFxwwdKzjoZxbe/XdBm1Unx0a2j/YRsu2//Lr8xNWoAe18I2 InoCb0PwVbVI7wTBjPCemdsn+o6xwi2rb9corn4TMyMfpPZt6eKCaatwM4FWVA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721403620; a=rsa-sha256; cv=none; b=vUHJCNa5UJ99BR3hRciTaNTlFEbwuSmRY6maZgzFmoBOb1xDG77aYuXXNY+zHLf7CBjZ7J v17nt97b8Nju9Cg0emW5RpNcnGRyKeZFA0SwNp1p3Oo7O+bgLGDJnzChfSOjHmMGGEYn6T dQDGApG6u/KmIvDXvzx8VUQN/1vnIuPPfGTC6y3M0tHVbVtaJ/x0pzsXiIAQBPDHqL+pzr UxH2zZ+wBiedvqdyKMdyeAg9LE/HiP0CrrIhxmYA5DtuYwV2QapYbApDMT4kJI98tYpJSO YPPx5tVojjZQ0/t41Fy1d5VxH6oEQBq+kD/ilat9WTZXyhmZtjJLdeoPagnvFQ== 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=1721403620; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=f1iINIzDdIlb78Xy8iMPY93DdBFg8va73/n6Ui21CtA=; b=BvdVrceI01e9WhduKBxJSK/aT6OiHjnEzUfkZQt56lLY6Y1KIX4eOTKbx9UqlEUFS21gTW hQvloWn/MEM4EfzwRmmM0A9HRs3a3mkzfXCfLJQgTtGtx5Xmji7AKK0OHbq4573/Qi7k6f bfYNtOGhkHxqpzZR+0M3NIHBhSDUA+RLFxyldylPOTxVweeO8unCD5iKhWU9F31oh8opGg o5+omw8Ic1cEyeCT+pOvOix5895yXgu2Q6aIGtigNqLUewMPUgFzb9WhiWoTVvZXXxkCTP 18IDoHfe4rEIrl9D8/ZbBPJpvi+ybiHnWQkvwOEKGum8U4mhiPPwiL2iwBG0XQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQYlm0TGnzdKh; Fri, 19 Jul 2024 15:40:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JFeK3p082772; Fri, 19 Jul 2024 15:40:20 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JFeKgB082769; Fri, 19 Jul 2024 15:40:20 GMT (envelope-from git) Date: Fri, 19 Jul 2024 15:40:20 GMT Message-Id: <202407191540.46JFeKgB082769@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: John Baldwin Subject: git: 9f756367a07a - stable/14 - NOTES: Move NVMe entries to MI file List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 9f756367a07a0e29f671e36be87a12f64799dc7b Auto-Submitted: auto-generated The branch stable/14 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=9f756367a07a0e29f671e36be87a12f64799dc7b commit 9f756367a07a0e29f671e36be87a12f64799dc7b Author: John Baldwin AuthorDate: 2024-04-09 22:02:58 +0000 Commit: John Baldwin CommitDate: 2024-07-18 17:20:12 +0000 NOTES: Move NVMe entries to MI file While here, adjust the sample setting for NVME_USE_NVD to use a non-default setting as is typical in entries in NOTES. Discussed with: imp Reviewed by: manu Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D44691 (cherry picked from commit 8f7105a20697d47060dbedc966cf085a64aeced6) --- sys/amd64/conf/NOTES | 5 ----- sys/arm64/conf/NOTES | 5 ----- sys/conf/NOTES | 11 +++++++++++ sys/i386/conf/NOTES | 5 ----- sys/riscv/conf/NOTES | 5 ----- 5 files changed, 11 insertions(+), 20 deletions(-) diff --git a/sys/amd64/conf/NOTES b/sys/amd64/conf/NOTES index 761728337ac2..39ecfb529be5 100644 --- a/sys/amd64/conf/NOTES +++ b/sys/amd64/conf/NOTES @@ -439,11 +439,6 @@ device imcsmb device isci options ISCI_LOGGING # enable debugging in isci HAL -# -# NVM Express (NVMe) support -device nvme # base NVMe driver -device nvd # expose NVMe namespaces as disks, depends on nvme - # # Intel Volume Management Device (VMD) support device vmd diff --git a/sys/arm64/conf/NOTES b/sys/arm64/conf/NOTES index 031b5f9567b5..c2d718e9f307 100644 --- a/sys/arm64/conf/NOTES +++ b/sys/arm64/conf/NOTES @@ -101,11 +101,6 @@ device ice_ddp # Intel 800 Series DDP Package # Etherswitch devices device e6000sw # Marvell mv88e6085 based switches -# NVM Express (NVMe) support -device nvme # base NVMe driver -options NVME_USE_NVD=0 # prefer the cam(4) based nda(4) driver -device nvd # expose NVMe namespaces as disks, depends on nvme - # MMC/SD/SDIO Card slot support device sdhci_xenon # Marvell Xenon SD/MMC controller device aw_mmc # Allwinner SD/MMC controller diff --git a/sys/conf/NOTES b/sys/conf/NOTES index 3217bdcb9600..96e850bd1dbe 100644 --- a/sys/conf/NOTES +++ b/sys/conf/NOTES @@ -1672,6 +1672,17 @@ device mfip # LSI MegaRAID SAS passthrough, requires CAM options MFI_DEBUG device mrsas # LSI/Avago MegaRAID SAS/SATA, 6Gb/s and 12Gb/s +# NVM Express +# +# nvme: PCI-express NVM Express host controllers +# nda: CAM NVMe disk driver +# nvd: non-CAM NVMe disk driver + +device nvme # base NVMe driver +options NVME_USE_NVD=1 # Use nvd(4) instead of the CAM nda(4) driver +device nda # NVMe direct access devices (aka disks) +device nvd # expose NVMe namespaces as disks, depends on nvme + # # Serial ATA host controllers: # diff --git a/sys/i386/conf/NOTES b/sys/i386/conf/NOTES index 45613c10c583..6692a9dba10e 100644 --- a/sys/i386/conf/NOTES +++ b/sys/i386/conf/NOTES @@ -634,11 +634,6 @@ device ips device isci options ISCI_LOGGING # enable debugging in isci HAL -# -# NVM Express (NVMe) support -device nvme # base NVMe driver -device nvd # expose NVMe namespaces as disks, depends on nvme - # # Intel Volume Management Device (VMD) support device vmd diff --git a/sys/riscv/conf/NOTES b/sys/riscv/conf/NOTES index 52720f6d83d1..bcf45aa78e9c 100644 --- a/sys/riscv/conf/NOTES +++ b/sys/riscv/conf/NOTES @@ -40,11 +40,6 @@ device virtio_blk # VirtIO Block device device virtio_mmio # VirtIO MMIO bus device virtio_random # VirtIO Entropy device -# NVM Express (NVMe) support -device nvme # base NVMe driver -options NVME_USE_NVD=0 # prefer the cam(4) based nda(4) driver -device nvd # expose NVMe namespaces as disks, depends on nvme - # NOTE: dtrace introduces CDDL-licensed components into the kernel device dtrace # dtrace core device dtraceall # include all dtrace modules From nobody Fri Jul 19 15:40:21 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQYln4nd8z5Rr0C; Fri, 19 Jul 2024 15:40: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQYln2GG7z4sfs; Fri, 19 Jul 2024 15:40:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721403621; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=U2APpmA3b0xywnHftghp5lHjvArk8gZL2+tcKvVz6/8=; b=Ad9WoczzlrqwEeO4Tk2W9DPSkk3QNQdWvuYGWFkqR8hO201+UsFt0USwhr1/z7nfjFRkPn uO3Mm9Lj2aTamXKI57wn7FRnFvC0Ad3dtVB+QYrJx/pUPhE1eXOHx2UFB/IpRV+YJ4gvvo XbRUhHF15vqSutdopCZYg+GGJJuiQrOxBTpUfUThfGtnRQG3Yv2h0Qjo+gJ+FhYIhw3Me/ M9zH9wfwafL84KKS83OHbqNN3TfTHzkIjBH/cMiLuCe4mg410Tn4ozqrhYvm022/rrjb6R IW9Lrb0fPgYpbaWDNnqijvSxpsmdIrlIip5AvCknSSyBObWoqrO7ICLtiE8wZA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721403621; a=rsa-sha256; cv=none; b=lO8uOlOj9Y7B84Ev5i69HEwPK/e0AR2AgC0AzGOyKhfkwCgwvQZTs7XUOfzj5GW0h4GAZ5 /R8817U69+2+Aop7JXcHiG40UocWlGomJr8GVYPooSgGJ3FDCGsPsQ6KF41cw1vi3ntcYL vAQxAjF/59691SEDN6/ZFafQIQG9UaCI9yYAXc9eyajGYT7odsDw6uOpjmbbtqToQ0ydkm YIAGrEnGmgD/RQPeTcPTHaBw2JcLB6IVglniwyqVo3SmP+RAhY8ys4TX5zm/Lxwa2DcxDP 5qNydxcpIOFziYFNy4xYHjiqmRVM/XiXTSZkPNywPYgZtNfYKQMrypKhXw1JwA== 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=1721403621; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=U2APpmA3b0xywnHftghp5lHjvArk8gZL2+tcKvVz6/8=; b=DHonpgTyV+iaxd32sGkjSAyTHSg0PZGvgk0iQTYLkGM0yTGBLQ1zwhRdHJf5Y0bgWsGXVp EXBDWs2AiPHgf9L9H5rj8UACQDnSW/2lbF2ABvjjRpeezOS4dY86DzIJIIaemykNaPFUbt KeY0tpczPZgw9xBCYHU4Sz7MUytXf8ew8ldOsW/sUcQuX5ORy7LR9fJ6BZKDgu4kTZ4NZs WjyCIh2LxJV9EQGg+3D75+MJ12gMdyIb4Z22hedUwrAF9NVYzHF0cXgT8y++TdlHu0FcVU d40rpYNpZFoNAPTABC9I2iY9kkaLxt1DoTM79nDIIxUUZJRHo3DwdlhPEIjElA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQYln1q7GzdMl; Fri, 19 Jul 2024 15:40:21 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JFeLQV082826; Fri, 19 Jul 2024 15:40:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JFeLkK082823; Fri, 19 Jul 2024 15:40:21 GMT (envelope-from git) Date: Fri, 19 Jul 2024 15:40:21 GMT Message-Id: <202407191540.46JFeLkK082823@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: John Baldwin Subject: git: ff74083a6c35 - stable/14 - files.x86: Pull in some more duplicate lines from files.{amd64,i386} List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: ff74083a6c35df8a970f3dfa52325c028eddb565 Auto-Submitted: auto-generated The branch stable/14 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=ff74083a6c35df8a970f3dfa52325c028eddb565 commit ff74083a6c35df8a970f3dfa52325c028eddb565 Author: John Baldwin AuthorDate: 2024-04-12 21:35:45 +0000 Commit: John Baldwin CommitDate: 2024-07-18 17:20:41 +0000 files.x86: Pull in some more duplicate lines from files.{amd64,i386} Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D44759 (cherry picked from commit b9c6fa339d9c7c90a1c0f9ebc000ecbde8873508) --- sys/conf/files.amd64 | 32 +------------------------------- sys/conf/files.i386 | 32 -------------------------------- sys/conf/files.x86 | 32 ++++++++++++++++++++++++++++++++ 3 files changed, 33 insertions(+), 63 deletions(-) diff --git a/sys/conf/files.amd64 b/sys/conf/files.amd64 index 1c0592009e93..58946eb3c663 100644 --- a/sys/conf/files.amd64 +++ b/sys/conf/files.amd64 @@ -109,10 +109,6 @@ crypto/openssl/amd64/sha1-x86_64.S optional ossl crypto/openssl/amd64/sha256-x86_64.S optional ossl crypto/openssl/amd64/sha512-x86_64.S optional ossl crypto/openssl/amd64/ossl_aes_gcm.c optional ossl -dev/acpi_support/acpi_wmi_if.m standard -dev/agp/agp_amd64.c optional agp -dev/agp/agp_i810.c optional agp -dev/agp/agp_via.c optional agp dev/amdgpio/amdgpio.c optional amdgpio dev/axgbe/if_axgbe_pci.c optional axp dev/axgbe/xgbe-desc.c optional axp @@ -240,20 +236,7 @@ dev/ixl/i40e_adminq.c optional ixl pci \ compile-with "${NORMAL_C} -I$S/dev/ixl" dev/ixl/i40e_dcb.c optional ixl pci \ compile-with "${NORMAL_C} -I$S/dev/ixl" -dev/nctgpio/nctgpio.c optional nctgpio dev/ncthwm/ncthwm.c optional ncthwm superio -dev/nfe/if_nfe.c optional nfe pci -dev/ntb/if_ntb/if_ntb.c optional if_ntb -dev/ntb/ntb_transport.c optional ntb_transport | if_ntb -dev/ntb/ntb.c optional ntb | ntb_transport | if_ntb | ntb_hw_amd | ntb_hw_intel | ntb_hw_plx | ntb_hw -dev/ntb/ntb_if.m optional ntb | ntb_transport | if_ntb | ntb_hw_amd | ntb_hw_intel | ntb_hw_plx | ntb_hw -dev/ntb/ntb_hw/ntb_hw_amd.c optional ntb_hw_amd | ntb_hw -dev/ntb/ntb_hw/ntb_hw_intel.c optional ntb_hw_intel | ntb_hw -dev/ntb/ntb_hw/ntb_hw_plx.c optional ntb_hw_plx | ntb_hw -dev/ntb/test/ntb_tool.c optional ntb_tool -dev/nvram/nvram.c optional nvram isa -dev/random/ivy.c optional rdrand_rng !random_loadable -dev/random/nehemiah.c optional padlock_rng !random_loadable dev/qlxge/qls_dbg.c optional qlxge pci dev/qlxge/qls_dump.c optional qlxge pci dev/qlxge/qls_hw.c optional qlxge pci @@ -388,29 +371,16 @@ dev/smartpqi/smartpqi_request.c optional smartpqi dev/smartpqi/smartpqi_response.c optional smartpqi dev/smartpqi/smartpqi_sis.c optional smartpqi dev/smartpqi/smartpqi_tag.c optional smartpqi -dev/speaker/spkr.c optional speaker dev/sume/if_sume.c optional sume -dev/superio/superio.c optional superio isa dev/syscons/apm/apm_saver.c optional apm_saver apm -dev/syscons/scvesactl.c optional sc vga vesa -dev/syscons/scvgarndr.c optional sc vga -dev/tpm/tpm.c optional tpm -dev/tpm/tpm20.c optional tpm +dev/tpm/tpm20.c optional tpm dev/tpm/tpm_crb.c optional tpm acpi dev/tpm/tpm_tis.c optional tpm acpi dev/tpm/tpm_acpi.c optional tpm acpi dev/tpm/tpm_isa.c optional tpm isa -dev/uart/uart_cpu_x86.c optional uart -dev/viawd/viawd.c optional viawd -dev/vmd/vmd.c optional vmd | vmd_bus -dev/wbwd/wbwd.c optional wbwd -dev/wdatwd/wdatwd.c optional wdatwd dev/p2sb/p2sb.c optional p2sb pci dev/p2sb/lewisburg_gpiocm.c optional lbggpiocm p2sb dev/p2sb/lewisburg_gpio.c optional lbggpio lbggpiocm -isa/syscons_isa.c optional sc -isa/vga_isa.c optional vga -kern/imgact_aout.c optional compat_aout kern/link_elf_obj.c standard # # IA32 binary support diff --git a/sys/conf/files.i386 b/sys/conf/files.i386 index a55d5302b3e1..41c51a7aa9c5 100644 --- a/sys/conf/files.i386 +++ b/sys/conf/files.i386 @@ -22,49 +22,20 @@ crypto/openssl/i386/sha256-586.S optional ossl crypto/openssl/i386/sha512-586.S optional ossl dev/agp/agp_ali.c optional agp dev/agp/agp_amd.c optional agp -dev/agp/agp_amd64.c optional agp dev/agp/agp_ati.c optional agp -dev/agp/agp_i810.c optional agp dev/agp/agp_intel.c optional agp dev/agp/agp_nvidia.c optional agp dev/agp/agp_sis.c optional agp -dev/agp/agp_via.c optional agp dev/glxiic/glxiic.c optional glxiic dev/glxsb/glxsb.c optional glxsb dev/glxsb/glxsb_hash.c optional glxsb dev/hyperv/vmbus/i386/hyperv_machdep.c optional hyperv dev/le/if_le_isa.c optional le isa -dev/nctgpio/nctgpio.c optional nctgpio -dev/nfe/if_nfe.c optional nfe pci -dev/ntb/if_ntb/if_ntb.c optional if_ntb -dev/ntb/ntb_transport.c optional ntb_transport | if_ntb -dev/ntb/ntb.c optional ntb | ntb_transport | if_ntb | ntb_hw_amd | ntb_hw_intel | ntb_hw_plx | ntb_hw -dev/ntb/ntb_if.m optional ntb | ntb_transport | if_ntb | ntb_hw_amd | ntb_hw_intel | ntb_hw_plx | ntb_hw -dev/ntb/ntb_hw/ntb_hw_amd.c optional ntb_hw_amd | ntb_hw -dev/ntb/ntb_hw/ntb_hw_intel.c optional ntb_hw_intel | ntb_hw -dev/ntb/ntb_hw/ntb_hw_plx.c optional ntb_hw_plx | ntb_hw -dev/ntb/test/ntb_tool.c optional ntb_tool -dev/nvram/nvram.c optional nvram isa dev/ofw/ofw_pcib.c optional fdt pci dev/pcf/pcf_isa.c optional pcf -dev/random/ivy.c optional rdrand_rng !random_loadable -dev/random/nehemiah.c optional padlock_rng !random_loadable dev/sbni/if_sbni.c optional sbni dev/sbni/if_sbni_isa.c optional sbni isa dev/sbni/if_sbni_pci.c optional sbni pci -dev/speaker/spkr.c optional speaker -dev/superio/superio.c optional superio isa -dev/syscons/scvesactl.c optional sc vga vesa -dev/syscons/scvgarndr.c optional sc vga -dev/tpm/tpm.c optional tpm -dev/tpm/tpm_acpi.c optional tpm acpi -dev/tpm/tpm_isa.c optional tpm isa -dev/uart/uart_cpu_x86.c optional uart -dev/viawd/viawd.c optional viawd -dev/vmd/vmd.c optional vmd -dev/acpi_support/acpi_wmi_if.m standard -dev/wbwd/wbwd.c optional wbwd -dev/wdatwd/wdatwd.c optional wdatwd i386/acpica/acpi_machdep.c optional acpi i386/acpica/acpi_wakeup.c optional acpi acpi_wakecode.o optional acpi \ @@ -134,9 +105,6 @@ i386/i386/vm86.c standard i386/i386/vm_machdep.c standard i386/pci/pci_cfgreg.c optional pci i386/pci/pci_pir.c optional pci -isa/syscons_isa.c optional sc -isa/vga_isa.c optional vga -kern/imgact_aout.c optional compat_aout kern/subr_sfbuf.c standard libkern/divdi3.c standard libkern/divmoddi4.c standard diff --git a/sys/conf/files.x86 b/sys/conf/files.x86 index 445bbf9091ba..c6d705e9715d 100644 --- a/sys/conf/files.x86 +++ b/sys/conf/files.x86 @@ -58,6 +58,10 @@ dev/acpica/acpi_pcib_acpi.c optional acpi pci dev/acpica/acpi_pcib_pci.c optional acpi pci dev/acpica/acpi_pxm.c optional acpi dev/acpica/acpi_timer.c optional acpi +dev/acpi_support/acpi_wmi_if.m standard +dev/agp/agp_amd64.c optional agp +dev/agp/agp_i810.c optional agp +dev/agp/agp_via.c optional agp dev/amdsbwd/amdsbwd.c optional amdsbwd dev/amdsmn/amdsmn.c optional amdsmn | amdtemp dev/amdtemp/amdtemp.c optional amdtemp @@ -292,14 +296,42 @@ dev/mana/mana_sysctl.c optional mana dev/mana/shm_channel.c optional mana dev/mana/hw_channel.c optional mana dev/mana/gdma_util.c optional mana +dev/nctgpio/nctgpio.c optional nctgpio +dev/nfe/if_nfe.c optional nfe pci +dev/ntb/if_ntb/if_ntb.c optional if_ntb +dev/ntb/ntb_transport.c optional ntb_transport | if_ntb +dev/ntb/ntb.c optional ntb | ntb_transport | if_ntb | ntb_hw_amd | ntb_hw_intel | ntb_hw_plx | ntb_hw +dev/ntb/ntb_if.m optional ntb | ntb_transport | if_ntb | ntb_hw_amd | ntb_hw_intel | ntb_hw_plx | ntb_hw +dev/ntb/ntb_hw/ntb_hw_amd.c optional ntb_hw_amd | ntb_hw +dev/ntb/ntb_hw/ntb_hw_intel.c optional ntb_hw_intel | ntb_hw +dev/ntb/ntb_hw/ntb_hw_plx.c optional ntb_hw_plx | ntb_hw +dev/ntb/test/ntb_tool.c optional ntb_tool +dev/nvram/nvram.c optional nvram isa +dev/random/ivy.c optional rdrand_rng !random_loadable +dev/random/nehemiah.c optional padlock_rng !random_loadable dev/qat_c2xxx/qat.c optional qat_c2xxx dev/qat_c2xxx/qat_ae.c optional qat_c2xxx dev/qat_c2xxx/qat_c2xxx.c optional qat_c2xxx dev/qat_c2xxx/qat_hw15.c optional qat_c2xxx dev/smbios/smbios_subr.c standard +dev/speaker/spkr.c optional speaker +dev/superio/superio.c optional superio isa +dev/syscons/scvesactl.c optional sc vga vesa +dev/syscons/scvgarndr.c optional sc vga +dev/tpm/tpm.c optional tpm +dev/tpm/tpm_acpi.c optional tpm acpi +dev/tpm/tpm_isa.c optional tpm isa +dev/uart/uart_cpu_x86.c optional uart +dev/viawd/viawd.c optional viawd +dev/vmd/vmd.c optional vmd | vmd_bus +dev/wbwd/wbwd.c optional wbwd +dev/wdatwd/wdatwd.c optional wdatwd +isa/syscons_isa.c optional sc +isa/vga_isa.c optional vga libkern/strcmp.c standard libkern/strncmp.c standard libkern/x86/crc32_sse42.c standard +kern/imgact_aout.c optional compat_aout # # x86 shared code between IA32 and AMD64 architectures # From nobody Fri Jul 19 15:40:22 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQYlp568gz5Rr0G; Fri, 19 Jul 2024 15:40: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQYlp3G36z4sZZ; Fri, 19 Jul 2024 15:40:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721403622; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=BHhsqA66XvDqyC6d+fofPPenoKPj+IHYlZV/9Zph5YY=; b=FPcTUHtRedS0epuY2YTbX7WSE7PxJ1thdm2hfNf6M5N0xHPebjnu2wFEGCAqUIK8wFpD+P SafUicyHBVhjhbl4I+m6tfswWDIR2NisOnLjyi/HZBre+/ofX+M3KnzpYzs5eT32b/IYod 7twMHbXIBH2RJxpujOgHiLLFTUj2OfMAJ9XcwnejF4SJfkZM3SZ22+IhbX5pnZseG8KdKV 9cOG2HKjM12zjn1fasPJD8RWGHbvmR+j+VJm9ZjDF9/rvv6rBeXaL4dYLvhLB/JYeMF+/S iGtiBq7TPaVgfFiD66b7aJqoTTIlJ0cGry3Wl+TjKvrIkG9e+qTojeCZ2U2iSw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721403622; a=rsa-sha256; cv=none; b=tVWPSq9vbaPrYPB+s1yZ+XbFYBvH+lKzHZCIYMMvGYEhgPLayNGV+bNLvQJXCh/bG4LGoh O+p2QycTn3lu8//1OOtzeWt0GVW+2+WatZT/eCSKhvupmJtnO0gDjxR1R4gKXyOFMOe8As 4mLGFt3HDJpoXxghfQyxZQeET5BbV0JkBiaKYFRK6IGukxQToPkfjl6DVsyKLE9OhnF0k/ 7nAz6/IMjJk8eSl+RK3U7l65d+sTlvZhGlskXe+lwY+MHkOyyhsErR4UHKDrB1aUt4rc8i FZKcyyBJIIXbhfv6gu6tDA2ZZbCD8l6LaqUhfGqBmU/JyidibjOLaZPj8YdNog== 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=1721403622; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=BHhsqA66XvDqyC6d+fofPPenoKPj+IHYlZV/9Zph5YY=; b=jSJxuLeCZBQrl41+14LxCp/RiagngqgltJGBM/xlOJjoTDlr4OLwMd0oNmOaJsVfb/foi7 1edpd9vyE0ojQ/0xoh86jQNeWmF8gXFQG3+ItbAd/UK98/rYZd7xURzC6CPapoqz6XqmUK pPEcP0qs8H+2+SzFfqSOZLvvTkPj6iUXfkmWILu7IGQm+HkFaFwzr5gJxU1HJEceKEDmrr Yjnzo53eOA6ElXGSHqFSqwspCsu6JbEO/6DQziBGIU1ToNStQL/rYdoNexd2IDv0mZxS9l E/m1rxDMlnJVwPlLVaQE4YJV5xbz+mzcqTxukhzHW4dqW2mF/yTKFQxMV4qCwQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQYlp2rCYzdfP; Fri, 19 Jul 2024 15:40:22 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JFeMEC082877; Fri, 19 Jul 2024 15:40:22 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JFeMM4082874; Fri, 19 Jul 2024 15:40:22 GMT (envelope-from git) Date: Fri, 19 Jul 2024 15:40:22 GMT Message-Id: <202407191540.46JFeMM4082874@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: John Baldwin Subject: git: c68dcc078121 - stable/14 - NOTES: Move IEEE80211_DEBUG_REFCNT to the MI NOTES file List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: c68dcc078121f8c8c50492173b028cb3bd0b486b Auto-Submitted: auto-generated The branch stable/14 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=c68dcc078121f8c8c50492173b028cb3bd0b486b commit c68dcc078121f8c8c50492173b028cb3bd0b486b Author: John Baldwin AuthorDate: 2024-04-14 02:09:38 +0000 Commit: John Baldwin CommitDate: 2024-07-18 17:20:50 +0000 NOTES: Move IEEE80211_DEBUG_REFCNT to the MI NOTES file This option is not specific to amd64 Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D44779 (cherry picked from commit 9c3fd2c1c7b8887d2ffaf14c61b04c55657d68bf) --- sys/amd64/conf/NOTES | 3 --- sys/conf/NOTES | 1 + 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/sys/amd64/conf/NOTES b/sys/amd64/conf/NOTES index 39ecfb529be5..23561d740a0b 100644 --- a/sys/amd64/conf/NOTES +++ b/sys/amd64/conf/NOTES @@ -368,9 +368,6 @@ device iwn6000g2bfw device iwn6050fw device wpifw -# net80211 options -options IEEE80211_DEBUG_REFCNT - # # Non-Transparent Bridge (NTB) drivers # diff --git a/sys/conf/NOTES b/sys/conf/NOTES index 96e850bd1dbe..3cf23f2976dc 100644 --- a/sys/conf/NOTES +++ b/sys/conf/NOTES @@ -883,6 +883,7 @@ device vxlan # and ath drivers and will eventually be required by all 802.11 drivers. device wlan options IEEE80211_DEBUG #enable debugging msgs +options IEEE80211_DEBUG_REFCNT options IEEE80211_SUPPORT_MESH #enable 802.11s D3.0 support options IEEE80211_SUPPORT_TDMA #enable TDMA support From nobody Fri Jul 19 15:40:23 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQYlq6R88z5RrDJ; Fri, 19 Jul 2024 15:40: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQYlq4CZqz4syt; Fri, 19 Jul 2024 15:40:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721403623; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VGxQrgXrmr30XBwiQEOby21u0/9nmL/FB7DK0I6cJjU=; b=Zts/CGxuzCeNbDPhBmp8ltDSDidal0rUhCGrCaGKTNzM94I8FhSZFHC3Yg5oRb5/gncvcL J8XNhurC21SJ1OKvgx8jbHLz5nuw5a7Qb1WMOOJyynRysq+Gx6uHlRYiUjkgc4CbuBFblo HXAtAyvPWPqsb/4xjc56JlGRq49T7/PdXa4B2NFQgMpp+pC8dDpSycpRiC0zTr+KO0+Kfc u5ER0MmC3ntOOTWS24VLEvM2LrplKyP+I6iPGWkD1bzNR9gbMo92gX9VI13rDTN/Pd3N66 6Kj8XoIR2Q8RBgn8W18aQp4Cgbrn06EA5ImIPTpe37X91cf0eK9y46CoTxRsTQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721403623; a=rsa-sha256; cv=none; b=m3T+1htReIu0PMLLfXkXvgtjYFPV9fcB/wF0vr6OVujSWLS89p5VF9gcj5N8a3AVmaP7TJ nk1RE6QdjAh69zpxscM8kT/NmLFbICMN3t80wbZR5tjA4t/hadgpXsxmpGIPNIME6ZwNUf Vsa9sEJ+LDg7m24V0h9sDuWvEymMZzkzTuvrMlCZZNOFCAom/UScEYq1Q1CejzDizjpIIy 4p9YqYZQq9VJtyqkLL+XnVutjv8pY0+2q9D0+FZMHePcl3eUV/qpe4+BptxEckiLYPVdAX oq/wWl8Big/PHS/0ZfnOAdsRXPbTEQxiED0KnTlFGGQ99rV68HkAcwQgTXQEgw== 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=1721403623; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VGxQrgXrmr30XBwiQEOby21u0/9nmL/FB7DK0I6cJjU=; b=HseH4Aa6KrZuBb3nC/rmi0VEU3NhMmQq2JKJuJ9ZBgL5uj9eH5uY4SZWxWZyN6z67DBr5i aua9Sylv/iKUPabYt9ylN2snM+uKo2sIllC81Xp/QcZXnpAfB1k++YLKtmF2zfWSdXKL/4 /P/24Yeg6VMegQKKyyRZ4vyFEj0aLAo0Fm2Vb2c+qkfZeeAPMOSxkrAsec1r4d/fdonevt NuiZDrKhTsfIHpa364awKODwsgZbXpikZv82k0sjoYcKSTVmjLZ2dmO9Yn7J47ILblHKyY nA8vq7YCfzWOfUnM2beRx1WNV7qRLaOnM+8EqEGjAYEWvsflQnOEiyYR+MBjNQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQYlq3r8Gzdp0; Fri, 19 Jul 2024 15:40:23 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JFeNHs082932; Fri, 19 Jul 2024 15:40:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JFeNfZ082929; Fri, 19 Jul 2024 15:40:23 GMT (envelope-from git) Date: Fri, 19 Jul 2024 15:40:23 GMT Message-Id: <202407191540.46JFeNfZ082929@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: John Baldwin Subject: git: 97d1a0cde140 - stable/14 - NOTES: Move safe(4) to the MI NOTES file List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 97d1a0cde140e2537093628e68d616cfd9eb1406 Auto-Submitted: auto-generated The branch stable/14 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=97d1a0cde140e2537093628e68d616cfd9eb1406 commit 97d1a0cde140e2537093628e68d616cfd9eb1406 Author: John Baldwin AuthorDate: 2024-04-14 02:09:57 +0000 Commit: John Baldwin CommitDate: 2024-07-18 17:20:58 +0000 NOTES: Move safe(4) to the MI NOTES file Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D44780 (cherry picked from commit ff3569be6fe01839affdefa14f55cc03a1f4f9d0) --- sys/amd64/conf/NOTES | 8 -------- sys/conf/NOTES | 4 ++++ sys/i386/conf/NOTES | 7 ------- 3 files changed, 4 insertions(+), 15 deletions(-) diff --git a/sys/amd64/conf/NOTES b/sys/amd64/conf/NOTES index 23561d740a0b..e85ddd20d58d 100644 --- a/sys/amd64/conf/NOTES +++ b/sys/amd64/conf/NOTES @@ -450,14 +450,6 @@ device pmspcv # Only for legacy Atom C2XXX chipsets. device qat_c2xxx -# -# SafeNet crypto driver: can be moved to the MI NOTES as soon as -# it's tested on a big-endian machine -# -device safe # SafeNet 1141 -options SAFE_DEBUG # enable debugging support: hw.safe.debug -options SAFE_RNDTEST # enable rndtest support - # # VirtIO support # diff --git a/sys/conf/NOTES b/sys/conf/NOTES index 3cf23f2976dc..af5bdde74732 100644 --- a/sys/conf/NOTES +++ b/sys/conf/NOTES @@ -2632,6 +2632,10 @@ device hifn # Hifn 7951, 7781, etc. options HIFN_DEBUG # enable debugging support: hw.hifn.debug options HIFN_RNDTEST # enable rndtest support +device safe # SafeNet 1141 +options SAFE_DEBUG # enable debugging support: hw.safe.debug +options SAFE_RNDTEST # enable rndtest support + ##################################################################### diff --git a/sys/i386/conf/NOTES b/sys/i386/conf/NOTES index 6692a9dba10e..eee1424b2118 100644 --- a/sys/i386/conf/NOTES +++ b/sys/i386/conf/NOTES @@ -641,13 +641,6 @@ device vmd # # PMC-Sierra SAS/SATA controller device pmspcv -# -# SafeNet crypto driver: can be moved to the MI NOTES as soon as -# it's tested on a big-endian machine -# -device safe # SafeNet 1141 -options SAFE_DEBUG # enable debugging support: hw.safe.debug -options SAFE_RNDTEST # enable rndtest support # # glxiic is an I2C driver for the AMD Geode LX CS5536 System Management Bus From nobody Fri Jul 19 15:40:24 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQYlr6gdlz5RrGN; Fri, 19 Jul 2024 15:40: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQYlr50RJz4srP; Fri, 19 Jul 2024 15:40:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721403624; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=zWsZeCjVaDsSfnv7Hyp2zN4ah3lP9edbZBR0W3N2/dc=; b=sdIiQyNwERZYo9POolJaaW0+/otxfSJO97tucMzBN0ASXOofmFL7RZwxFYPtfkCIS8sZD+ rufipIjc9go/AwWiKbadBFszNVSc3dn/ISN+eTgxegmTasrvgfxH3A91fAOETgvavTIP3U Kjqbep8oU01nlpzL1EcCbwiKPsjMYV2zcESNBidSz92bqPs5jh2Y/JsCYvTbdKV55FCdJn vMIyvMXCKyoeJsgMPyEdugu6BuzzJ9iBaXIc0kRRqJLoYOWWjgxhp7nXOQYnoWiET+wOh/ DnEQi4wEOnkHtaLJeDvOpjFF8VmOH68gdYnaQelZWOh1+zgfDofHOdwUgQTt7w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721403624; a=rsa-sha256; cv=none; b=yiUtPpuZWbUM0RH/eok8/hD4F21WdNlQbKFrxU4mxlxtWVCRBVcN2IGdY0RAcMVIdLyoFI KMUg1Uc390F4kQTYtr2MCmW2aReNCjT7SSpuo9pQPCX1ISVXC78Tl5sUQigsW2FV4xfTsS pArWsvSohdZFHgd5M6SeAYmJvR69MufnN2Umv0xqLkDC6bsJYq47lM6IwQObZ6xUFDxYQb Z+BEPyS5KkyEbtc3Nuzo6d7vkWJKuUyJGKvcaz84FpSS44+0GxPNCeOPEearSj2cKR+mDd QKSFj4DQ49N/Uzx7EPZlALRlX8pQ/pZ2i1CURGZ54glJHNvSC4On9j1xtoUwrA== 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=1721403624; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=zWsZeCjVaDsSfnv7Hyp2zN4ah3lP9edbZBR0W3N2/dc=; b=EHIg6ZDI2c4UEt7l5Z7V4m6Mm7sQrdzvYjAcbstF0NUdtyYjQwLWen0pne/Zuf/TRu+77Q c/7GhWpTw37Sr15/eIFa1XAZuPY6kYFbLEteue7e9Jn84cs8fr1hGJBJwhz52vuWa61BCu UStx5dbhsC7eoWgAQVd0FHYtZdLRTqoJ6AVlt0YluV1NSHBnWT1lO8B0W/jEr6Th8mmEBY 92qbR7cDNj6AMGgIEnq4qV20Fty3pOJYiPIe3oNghfqeyflskQjNDRWKjIVWXa3jQeYJiu rz0GIUhkcusOjssLLBXbYPrG94OyRRgbENfmnzpqbaD2IbI5WJw0wTcy3Dl3rg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQYlr4cTczchs; Fri, 19 Jul 2024 15:40:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JFeOLm082984; Fri, 19 Jul 2024 15:40:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JFeO5d082981; Fri, 19 Jul 2024 15:40:24 GMT (envelope-from git) Date: Fri, 19 Jul 2024 15:40:24 GMT Message-Id: <202407191540.46JFeO5d082981@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: John Baldwin Subject: git: e1d29e6b1246 - stable/14 - files: Sort the VirtIO device entries List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: e1d29e6b124677c31bbc55936edb521ad3472150 Auto-Submitted: auto-generated The branch stable/14 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=e1d29e6b124677c31bbc55936edb521ad3472150 commit e1d29e6b124677c31bbc55936edb521ad3472150 Author: John Baldwin AuthorDate: 2024-04-14 02:10:14 +0000 Commit: John Baldwin CommitDate: 2024-07-18 17:24:57 +0000 files: Sort the VirtIO device entries Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D44781 (cherry picked from commit 1d51575980bd246c1583cd02df47278aac5b6f4c) --- sys/conf/files | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/conf/files b/sys/conf/files index 6dca944b9f61..47601d3c7cff 100644 --- a/sys/conf/files +++ b/sys/conf/files @@ -3407,12 +3407,12 @@ dev/virtio/mmio/virtio_mmio_cmdline.c optional virtio_mmio dev/virtio/mmio/virtio_mmio_fdt.c optional virtio_mmio fdt dev/virtio/mmio/virtio_mmio_if.m optional virtio_mmio dev/virtio/network/if_vtnet.c optional vtnet -dev/virtio/block/virtio_blk.c optional virtio_blk dev/virtio/balloon/virtio_balloon.c optional virtio_balloon +dev/virtio/block/virtio_blk.c optional virtio_blk +dev/virtio/console/virtio_console.c optional virtio_console dev/virtio/gpu/virtio_gpu.c optional virtio_gpu -dev/virtio/scsi/virtio_scsi.c optional virtio_scsi dev/virtio/random/virtio_random.c optional virtio_random -dev/virtio/console/virtio_console.c optional virtio_console +dev/virtio/scsi/virtio_scsi.c optional virtio_scsi dev/vkbd/vkbd.c optional vkbd dev/vmgenc/vmgenc_acpi.c optional acpi dev/vmware/vmxnet3/if_vmx.c optional vmx From nobody Fri Jul 19 15:40:25 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQYlt0QJyz5Rr7W; Fri, 19 Jul 2024 15:40: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQYls5nScz4stt; Fri, 19 Jul 2024 15:40:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721403625; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=5C416QbXsUTcPwrpERByqQEl5u44/kGv1Z8p4ndq9ZY=; b=hMTLoYKxUE2penOhGxWI6Zp19bYmIAR2Yj5lLRVc6yMSf8rjf/ySAUE85DhBURcGxIOagX 6JYiHwc4cRN7fBvx8BGiFZN6cYKKhnYcMA0h7DdZ5ghz+NUrzZ6+3etK3k+b2UFmu0YIw/ EEAC7you726TkbjtxyWenxzlPAXU1RxoRRSc+/FZsp/AqQV1JgZs1cZma7QO/NZUa2P8uI 7yLZbD8Mz4sAPD9TS1Njobmq2YMfDq2Vbu+AYEPBh83wih3AgEA27kSkYYpUxx27CkGefM 11NkOgN6BAhQZQAPMCODiM0sZse5o2OIby61PIlBs1ez9tyKItCfoZ/yUeWa9g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721403625; a=rsa-sha256; cv=none; b=sjGI+vKHsKLSfshgKSfkLo/StZ28ix1AEsD8g3OLEnCMhlL3dy47lKja0wcvc67Cv46Afz d0J57zfFMbtMao9rRTvSiDKMX3NAHOwrHjD46ODVNlzZPiDOLs7gOTcFXsTsonbotfnIC0 mGAIXOItd2+nPmsN+XfxZBKTjnMnUkS721uHvw22o5C6O3Oz2uXOF3KSk32L40ZEUArntX txFFx5eqKD5oSrPp3vBuELOaM/9XpkezgBkmCJ7bUog77S1ji9KU36NA06+icFMm6EXnHW FdX68PR0b0DY9Ypk8DsC9X2sGZTBR+5fcFtCxOwmPyOD1Llu1JIdt8F9H/Fw+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=1721403625; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=5C416QbXsUTcPwrpERByqQEl5u44/kGv1Z8p4ndq9ZY=; b=plGE4ZpTbZas2t3CDX8DFmSrEpydP6p6w2NEYiLVvaqr0ydyWn23dCCO6c8K7g+kp6ckrB xAewwYwXqjEsPtNBFYTdQfMYeuZW4SE2XnpoPnWDgnfVrndxyDDPD0wk7eIoHHSF6Xp/1i dRWd05L45N1CbyHiVm/bcpG87EVWut1CB86fTc3G2iC2gc1tD1+JHne7VCoIR3QvV5CPfU h8sALIn90KOUt6d62nFW3MIuVfQcC3Syd4jlJxIhqUPJmM5ImIQQYlpwfOl0LkGXiyfZwk ePAn1PpUy17Tnvku5ducNy6jkTeczI7klr4IWKQqg3fksDcu5yszi8eDT3Zmag== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQYls5P3DzdfQ; Fri, 19 Jul 2024 15:40:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JFePWN083043; Fri, 19 Jul 2024 15:40:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JFePan083040; Fri, 19 Jul 2024 15:40:25 GMT (envelope-from git) Date: Fri, 19 Jul 2024 15:40:25 GMT Message-Id: <202407191540.46JFePan083040@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: John Baldwin Subject: git: c0e4d9487392 - stable/14 - NOTES: Move the VirtIO entries to the MI NOTES file List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: c0e4d948739274a9befbeb8541ba20512be15632 Auto-Submitted: auto-generated The branch stable/14 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=c0e4d948739274a9befbeb8541ba20512be15632 commit c0e4d948739274a9befbeb8541ba20512be15632 Author: John Baldwin AuthorDate: 2024-04-14 02:10:27 +0000 Commit: John Baldwin CommitDate: 2024-07-18 17:30:41 +0000 NOTES: Move the VirtIO entries to the MI NOTES file While here, add virtio_gpu Reviewed by: imp, emaste Differential Revision: https://reviews.freebsd.org/D44782 (cherry picked from commit 1f678b6ba215aad01a1610772c77af653a981601) --- sys/amd64/conf/NOTES | 18 ------------------ sys/arm64/conf/NOTES | 7 ------- sys/conf/NOTES | 19 +++++++++++++++++++ sys/i386/conf/NOTES | 18 ------------------ sys/riscv/conf/NOTES | 8 -------- 5 files changed, 19 insertions(+), 51 deletions(-) diff --git a/sys/amd64/conf/NOTES b/sys/amd64/conf/NOTES index e85ddd20d58d..237dc4b030be 100644 --- a/sys/amd64/conf/NOTES +++ b/sys/amd64/conf/NOTES @@ -450,24 +450,6 @@ device pmspcv # Only for legacy Atom C2XXX chipsets. device qat_c2xxx -# -# VirtIO support -# -# The virtio entry provides a generic bus for use by the device drivers. -# It must be combined with an interface that communicates with the host. -# Multiple such interfaces are defined by the VirtIO specification. FreeBSD -# only has support for PCI. Therefore, virtio_pci must be statically -# compiled in or loaded as a module for the device drivers to function. -# -device virtio # Generic VirtIO bus (required) -device virtio_pci # VirtIO PCI Interface -device vtnet # VirtIO Ethernet device -device virtio_blk # VirtIO Block device -device virtio_scsi # VirtIO SCSI device -device virtio_balloon # VirtIO Memory Balloon device -device virtio_random # VirtIO Entropy device -device virtio_console # VirtIO Console device - # Linux KVM paravirtualization support device kvm_clock # KVM paravirtual clock driver diff --git a/sys/arm64/conf/NOTES b/sys/arm64/conf/NOTES index c2d718e9f307..add17c6bf0ea 100644 --- a/sys/arm64/conf/NOTES +++ b/sys/arm64/conf/NOTES @@ -60,13 +60,6 @@ device al_udma # Universal DMA # Qualcomm Snapdragon drivers device qcom_gcc # Global Clock Controller -# VirtIO support -device virtio -device virtio_pci -device virtio_mmio -device virtio_blk -device vtnet - # Google Virtual NIC device gve # Google Virtual NIC (gVNIC) driver diff --git a/sys/conf/NOTES b/sys/conf/NOTES index af5bdde74732..663ec0282491 100644 --- a/sys/conf/NOTES +++ b/sys/conf/NOTES @@ -2406,6 +2406,25 @@ options NSFBUFS=1024 # options DEBUG_LOCKS +# +# VirtIO support +# +# The virtio entry provides a generic bus for use by the device drivers. +# It must be combined with an interface that communicates with the host. +# Multiple such interfaces are defined by the VirtIO specification +# including PCI and MMIO. +# +device virtio # Generic VirtIO bus (required) +device virtio_mmio # VirtIO MMIO Interface +device virtio_pci # VirtIO PCI Interface +device vtnet # VirtIO Ethernet device +device virtio_balloon # VirtIO Memory Balloon device +device virtio_blk # VirtIO Block device +device virtio_console # VirtIO Console device +device virtio_gpu # VirtIO GPU device +device virtio_random # VirtIO Entropy device +device virtio_scsi # VirtIO SCSI device + ##################################################################### # HID support device hid # Generic HID support diff --git a/sys/i386/conf/NOTES b/sys/i386/conf/NOTES index eee1424b2118..bab537ac1dfe 100644 --- a/sys/i386/conf/NOTES +++ b/sys/i386/conf/NOTES @@ -654,24 +654,6 @@ device glxiic # AMD Geode LX CS5536 System Management Bus # device glxsb # AMD Geode LX Security Block -# -# VirtIO support -# -# The virtio entry provides a generic bus for use by the device drivers. -# It must be combined with an interface that communicates with the host. -# Multiple such interfaces defined by the VirtIO specification. FreeBSD -# only has support for PCI. Therefore, virtio_pci must be statically -# compiled in or loaded as a module for the device drivers to function. -# -device virtio # Generic VirtIO bus (required) -device virtio_pci # VirtIO PCI Interface -device vtnet # VirtIO Ethernet device -device virtio_blk # VirtIO Block device -device virtio_scsi # VirtIO SCSI device -device virtio_balloon # VirtIO Memory Balloon device -device virtio_random # VirtIO Entropy device -device virtio_console # VirtIO Console device - # Linux KVM paravirtualization support device kvm_clock # KVM paravirtual clock driver diff --git a/sys/riscv/conf/NOTES b/sys/riscv/conf/NOTES index bcf45aa78e9c..37be977fc384 100644 --- a/sys/riscv/conf/NOTES +++ b/sys/riscv/conf/NOTES @@ -32,14 +32,6 @@ device riscv_syscon # Backlight subsystem device backlight -# VirtIO support -device virtio # Generic VirtIO bus (required) -device virtio_pci # VirtIO PCI device -device vtnet # VirtIO Ethernet device -device virtio_blk # VirtIO Block device -device virtio_mmio # VirtIO MMIO bus -device virtio_random # VirtIO Entropy device - # NOTE: dtrace introduces CDDL-licensed components into the kernel device dtrace # dtrace core device dtraceall # include all dtrace modules From nobody Fri Jul 19 15:40:26 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQYlv2KyFz5Rr7Z; Fri, 19 Jul 2024 15:40: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQYlt6kWkz4t53; Fri, 19 Jul 2024 15:40:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721403626; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=8LrLhK+m2IonWVB02Kf71ago9mW/heWIM27wnd5OJ6k=; b=G+H/fzaVPx0/Ywkq+FIBDjUXut4YhiuVjTFbbh3ucQKJkqI5xcGJY3n7r6JupLnvQq1x3f KLGO3Oz7OkIv8o1uMtfJfGcUN3HeX2cFafJ5H0jvda/0940X00HzIZ26Bpg82ZW0QyA9Zd xWQ5+TGJLeMqow2FdDZn03sO7QFpBZcExVIXgGd8WVOkhYZCrc+o+6XuM6cxjR+pdbXsk2 fhFhc391oqgWvGmFuWgZLlC2E4pOFm0bAmJK09hskyDEhtEwji7nmVcZD88Po8qVqqJlV4 7JvgKXzCIpsyu0POcoBZVjNCPfARiLwtfVIvNsC9bTTdOYxsJk15ShEE3jvmVg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721403626; a=rsa-sha256; cv=none; b=QzcbL+810pmTDkJz94r6pTgf+SPM02+SjCItXGJDH2WuadHzxCAadAeon9wsUIplabVdC0 KPPAnEak6SjpTgrfGiHNSqEYbRDVHNKrmgPIMUlWCwnNVeGgySkcfVHgdhCSuqUXAygAL3 u9fDZ+XmW7ROv7aMyzPbuhl+dC9H1GQfS1RFyXC1Vtp2gEw0w1YYHDmKz3jlg/gVj6JmXD utIk1MesenIWGSf5TlD2TgBDzxNKpC8bDAJH+ZQkgSmomLhiBNnXe+6QWrCgPfkFs72tc4 rRkZRoJLyhr1PY3K3RHudpTNsxPYuFiiHkBQP8Xs7zfs60+zDSb5ogYrCfaLuw== 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=1721403626; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=8LrLhK+m2IonWVB02Kf71ago9mW/heWIM27wnd5OJ6k=; b=Kky8pLkgTtdS1grkXNFr62Yd2x9G7TK++UniPr9bjqeTKc/2xorWTaSVISiSiGffg9nRcE 7CDJF/1W+iqK1F9F4hBPfsfv4tbT+RQR6hIzKuELr3qrlooLNPEdwjWL/NBfeUJRGRJ6cY wePle7F4t/l/1DOdwogZ84pLFnGfGJ77lrUNAQnIFSukGiwjNWytr0AnknycdCB75XHu2g Y3DUWUTDTHJeVcmSMagHNM0nGR4KVc9483vHwzg/8/TUCtISwXo07yRGjbYz54SGz88kWN pbBqlRIYTvEXeu2beTmVzAyqMrm1wKblZB59P7HJqieGBc/kgARcEy3ocoeGnQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQYlt6Lgyzd8R; Fri, 19 Jul 2024 15:40:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JFeQ0D083098; Fri, 19 Jul 2024 15:40:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JFeQTH083095; Fri, 19 Jul 2024 15:40:26 GMT (envelope-from git) Date: Fri, 19 Jul 2024 15:40:26 GMT Message-Id: <202407191540.46JFeQTH083095@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: John Baldwin Subject: git: 65e871e7c19a - stable/14 - i386: Use DEV_HYPERV to enable HyperV APIC vector List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 65e871e7c19a2dc9548df8f1cd189ad282c25b3d Auto-Submitted: auto-generated The branch stable/14 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=65e871e7c19a2dc9548df8f1cd189ad282c25b3d commit 65e871e7c19a2dc9548df8f1cd189ad282c25b3d Author: John Baldwin AuthorDate: 2024-04-14 02:10:44 +0000 Commit: John Baldwin CommitDate: 2024-07-18 17:31:50 +0000 i386: Use DEV_HYPERV to enable HyperV APIC vector This avoids requiring both 'device hyperv' and 'options HYPERV' for kernel configs. Instead, just 'device hyperv' can now be used matching the kernel configuration used for amd64. Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D44783 (cherry picked from commit e045163cce955c32332a02a8eb9a48f3c2cd3c3f) --- sys/conf/options.i386 | 2 +- sys/i386/conf/GENERIC | 2 -- sys/i386/conf/NOTES | 1 - sys/i386/i386/exception.S | 2 +- 4 files changed, 2 insertions(+), 5 deletions(-) diff --git a/sys/conf/options.i386 b/sys/conf/options.i386 index c827e0bb7a69..326cb03fde8c 100644 --- a/sys/conf/options.i386 +++ b/sys/conf/options.i386 @@ -97,7 +97,7 @@ NPX_DEBUG opt_npx.h BPF_JITTER opt_bpf.h # Hyper-V support -HYPERV opt_hyperv.h +DEV_HYPERV opt_hyperv.h XENHVM opt_global.h diff --git a/sys/i386/conf/GENERIC b/sys/i386/conf/GENERIC index 1a57015d0dcc..c5ad0a613eaa 100644 --- a/sys/i386/conf/GENERIC +++ b/sys/i386/conf/GENERIC @@ -316,8 +316,6 @@ device virtio_balloon # VirtIO Memory Balloon device device kvm_clock # KVM paravirtual clock driver # HyperV drivers and enhancement support -# NOTE: HYPERV depends on hyperv. They must be added or removed together. -options HYPERV # Kernel support for HyperV drivers device hyperv # HyperV drivers # Xen HVM Guest Optimizations diff --git a/sys/i386/conf/NOTES b/sys/i386/conf/NOTES index bab537ac1dfe..d421f2511478 100644 --- a/sys/i386/conf/NOTES +++ b/sys/i386/conf/NOTES @@ -660,7 +660,6 @@ device kvm_clock # KVM paravirtual clock driver # Google Virtual NIC device gve # Google Virtual NIC (gVNIC) driver -options HYPERV device hyperv # HyperV drivers device hvhid # HyperV HID device diff --git a/sys/i386/i386/exception.S b/sys/i386/i386/exception.S index 32456b63092b..a2a59db3c836 100644 --- a/sys/i386/i386/exception.S +++ b/sys/i386/i386/exception.S @@ -450,7 +450,7 @@ ENTRY(fork_trampoline) #include #endif -#ifdef HYPERV +#ifdef DEV_HYPERV .data .p2align 4 .text From nobody Fri Jul 19 15:40:27 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQYlw2KgVz5Rr7b; Fri, 19 Jul 2024 15:40: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQYlw0t9cz4sxR; Fri, 19 Jul 2024 15:40:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721403628; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Rdeo4LEWDbxBXvyXEfgSwJY3BAYVa6VifrCkth2FlXk=; b=r3kMHPcUXaUmDeLMxGeJN5Kz/dpF00EcuBzVOTjSB+nu9NKxptfPqTnAEgYSYlcpJXTRPH SlDzBR5X8Va34nckgwnXKp8UGzA0sW7ZjNacJoMesxXsBzc5vgAYXQOwrbKLpTU5MMNE+s lJ+MRwbG0Z+w+2UHResmC4Ks55fPG3bXgdOIqAKgi4lT97qOlZ1eYEK8Ptz3dYcJ2B1aIU wXEMV5031qx4IuWgS38QjsQdEnOkB2dqNetKDIvXxkgQ6W86f7QdJGHUKMKgX6i6eLwFM0 UzH66WYCtcPFh4E/aq7ZNpBGPIb+lEuiInQP6xVPfDu0svq0zh84SjoZMzlufA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721403628; a=rsa-sha256; cv=none; b=q4qf6TQ/Hl712epubW9jhwPjIp2eRwcB8eC7P5BMcWqY1kht134ghCV2sDea5kDqAu/jny bpaQLFgPg8/t4aNYlSf71SQaGV5tMuPDQsL90WduTqFvKJexXTn87+6/k2fb/hodfvqDcj yYZ6515djPz3UEs1So+xnjDE+gflpky+ySFgPLLxPKgo/Hv0APcOScqAj0UUFTfS2cg2k1 ikCgLxvuerBC5qh5NpC+J7/aZxOJQuAZd9iKZuq5Tt99e5jC2Z5NSInwm6+8T/mn3l0Ea+ p6gGfqJyuQld3PjT55HbMWUMDBj76QpFng0TnkkVfbDndqEksDKY5eqN9D9EfA== 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=1721403628; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Rdeo4LEWDbxBXvyXEfgSwJY3BAYVa6VifrCkth2FlXk=; b=EJTgwyaqKeef/rzh4DZQ3AygfNB8VmHS3Zs+1M9J0kTACLhPT0zByL37jzqeKvEqxoj20M 9KDBmubChrZE6ud0Op3YSWSAuAsM/57N1s8v17gaquSEAi8n522D0/Z25mDn5MtBvkJB3X sOMiUhnc2I4GTfPID7eY34yY5CoXzzU+vOcweCKfamW/cGqCvB/0+q5kApLwBAYiDTpkJ1 JadJnrbxXnhef/T6Mq9h2e/Mn/FNgrapHmF0kN0XlxKxDjUlalpOMmIDQ8ullgILXdR3R0 cJ0qjDEb8Yxua1wvURzd2tzM7eUWhtOxvQpryvzUtjs3aljWqH4pikjq2/Wj3A== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQYlw0JqpzdfR; Fri, 19 Jul 2024 15:40:28 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JFeR3w083143; Fri, 19 Jul 2024 15:40:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JFeRuL083140; Fri, 19 Jul 2024 15:40:27 GMT (envelope-from git) Date: Fri, 19 Jul 2024 15:40:27 GMT Message-Id: <202407191540.46JFeRuL083140@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: John Baldwin Subject: git: 6563c2a32878 - stable/14 - x86 NOTES: Remove some obsolete comments List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 6563c2a3287868e2b32abc54d43252b523282fcd Auto-Submitted: auto-generated The branch stable/14 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=6563c2a3287868e2b32abc54d43252b523282fcd commit 6563c2a3287868e2b32abc54d43252b523282fcd Author: John Baldwin AuthorDate: 2024-04-14 02:11:06 +0000 Commit: John Baldwin CommitDate: 2024-07-18 17:31:59 +0000 x86 NOTES: Remove some obsolete comments Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D44784 (cherry picked from commit 717b22e18ca249dee0ec858c6571f68e00008290) --- sys/amd64/conf/NOTES | 3 --- sys/i386/conf/NOTES | 12 ------------ 2 files changed, 15 deletions(-) diff --git a/sys/amd64/conf/NOTES b/sys/amd64/conf/NOTES index 237dc4b030be..25001d5f80fe 100644 --- a/sys/amd64/conf/NOTES +++ b/sys/amd64/conf/NOTES @@ -575,9 +575,6 @@ options IICHID_SAMPLING # Workaround missing GPIO INTR support ##################################################################### # ABI Emulation -#XXX keep these here for now and reactivate when support for emulating -#XXX these 32 bit binaries is added. - # Enable 32-bit runtime support for FreeBSD/i386 binaries. options COMPAT_FREEBSD32 diff --git a/sys/i386/conf/NOTES b/sys/i386/conf/NOTES index d421f2511478..dc3107349711 100644 --- a/sys/i386/conf/NOTES +++ b/sys/i386/conf/NOTES @@ -683,18 +683,6 @@ device hvhid # HyperV HID device # The Rev 2 host cards use a 32K chunk, on a 32K boundary. # The cards can use an IRQ of 11, 12 or 15. -# Notes on the Sony Programmable I/O controller -# This is a temporary driver that should someday be replaced by something -# that hooks into the ACPI layer. The device is hooked to the PIIX4's -# General Device 10 decoder, which means you have to fiddle with PCI -# registers to map it in, even though it is otherwise treated here as -# an ISA device. At the moment, the driver polls, although the device -# is capable of generating interrupts. It largely undocumented. -# The port location in the hint is where you WANT the device to be -# mapped. 0x10a0 seems to be traditional. At the moment the jogdial -# is the only thing truly supported, but apparently a fair percentage -# of the Vaio extra features are controlled by this device. - device ipmi device smapi device smbios From nobody Fri Jul 19 15:40:29 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQYlx2tPgz5Rr0Q; Fri, 19 Jul 2024 15:40: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQYlx1rY5z4sxg; Fri, 19 Jul 2024 15:40:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721403629; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=XvS8009RoCY3aj3IEuFPQpJLcMpGl87QN4tK3/53ZO8=; b=epXsOuMkjanpxVZN5I80fmlS2qe3Qs1IWYyrBa4HVMeQIxrfe6Racn1yDfdfmJcPZtiooJ jx84iwnBkYAM+3Sq2AR/la9mxjF2g2NGOMjl/WCKxrf4f6Ko3JMFKXK6MjLxVcpuQIPs3L UpNmIpeaMEJu0haOIhBC0b4TSiRoulutqK6QyHvvTRVe2/H+OCnBGG2fdRBETgJMxmSlNn Q+CGaz/KoFAB14DedqjSQ5Iu7Rl2lUcFvSquSVpNb2fxOYb90BW3XI/RQ0Bi7punjdkNQA sJ46FvN3xaACdaIOyKcZv4a1P3MMJIumsJCLlfRrsj6JVbRelt8mvEr7ulfk2A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721403629; a=rsa-sha256; cv=none; b=ucFeVUHsTtOChdEQ+DGWnRW3zrIaU+5GGRkVmIwHAy3moCJJ/0yrLl5hhTs5sYDvOXiqK6 FrNzZs0ossYXqr/F9LiRxjNFjs7zTeBzxF2rBb9sSrB/cX0bJp7kUZBobnirPVUCsudUip XkDzvsmitu6oCU3i1kLa0/Hpostc8+iZuA1xPOBJSorwfrGzNEOB7j4BO+y4ZOV8lpLn4x B5CrNIcWhECeh0NkhWgkyY00pXHcCavcCp1FrUbphyp3eBOExHXrVSs6/XqauizfFomlwj fU0o5MLNcnS2kL1PCoehqSQdMLDStb2LnLtWYbIxXB5Ka2I2YcbiAqQtzj/a1w== 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=1721403629; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=XvS8009RoCY3aj3IEuFPQpJLcMpGl87QN4tK3/53ZO8=; b=QYXJp92Wu13ItZqiYrQCImX5t0HmK5fWSB4YG7JWGlGy3X9sUuhpSS4RtTn+n4cRXqZFcc n1B8Tl7euqWU3ZSFcnfOmMVP32BpyJ23kk0qMU59/O+nHBmt/i21nG1DCyoQG4/fT9fRBz kyKb3vrskB83ApazwNnpC4RSRSOxV9x0F069almlAj9/a4J0gyxv/ltf95pPxUEcVDlDBr VQvd7R3SYKkk8+n2xCszq7cQDYLaIhISaZnMuxPUMAE3X03yJWmJgLDDgNtRkTQQredXXz eVgTmb501MEFdfgkZThzMF1hoWyOYK5yX86v+NAKOi14Q81Pxz0OpgBfA31G7A== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQYlx1SgrzdMm; Fri, 19 Jul 2024 15:40:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JFeT1r083203; Fri, 19 Jul 2024 15:40:29 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JFeTS4083200; Fri, 19 Jul 2024 15:40:29 GMT (envelope-from git) Date: Fri, 19 Jul 2024 15:40:29 GMT Message-Id: <202407191540.46JFeTS4083200@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: John Baldwin Subject: git: 883640ffd7c6 - stable/14 - x86 NOTES: Move NKPT and PMAP_SHPGPERPROC options to VM OPTIONS section List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 883640ffd7c62fdcc3c3a72dd5b3a88bd0620a5e Auto-Submitted: auto-generated The branch stable/14 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=883640ffd7c62fdcc3c3a72dd5b3a88bd0620a5e commit 883640ffd7c62fdcc3c3a72dd5b3a88bd0620a5e Author: John Baldwin AuthorDate: 2024-04-14 02:11:21 +0000 Commit: John Baldwin CommitDate: 2024-07-18 17:32:30 +0000 x86 NOTES: Move NKPT and PMAP_SHPGPERPROC options to VM OPTIONS section Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D44785 (cherry picked from commit b620daf63309f655546caa060ea79cb230e4c9bc) --- sys/amd64/conf/NOTES | 16 ++++++++-------- sys/i386/conf/NOTES | 32 ++++++++++++++++---------------- 2 files changed, 24 insertions(+), 24 deletions(-) diff --git a/sys/amd64/conf/NOTES b/sys/amd64/conf/NOTES index 25001d5f80fe..0c418f6359ac 100644 --- a/sys/amd64/conf/NOTES +++ b/sys/amd64/conf/NOTES @@ -554,14 +554,6 @@ options ENABLE_ALART # Control alarm on Intel intpm driver # device amdsmn -# -# Number of initial kernel page table pages used for early bootstrap. -# This number should include enough pages to map the kernel and any -# modules or other data loaded with the kernel by the loader. Each -# page table page maps 2MB. -# -options NKPT=31 - # EFI Runtime Services support options EFIRT @@ -590,6 +582,14 @@ options ZFS ##################################################################### # VM OPTIONS +# +# Number of initial kernel page table pages used for early bootstrap. +# This number should include enough pages to map the kernel and any +# modules or other data loaded with the kernel by the loader. Each +# page table page maps 2MB. +# +options NKPT=31 + # KSTACK_PAGES is the number of memory pages to assign to the kernel # stack of each thread. diff --git a/sys/i386/conf/NOTES b/sys/i386/conf/NOTES index dc3107349711..8f6098301b12 100644 --- a/sys/i386/conf/NOTES +++ b/sys/i386/conf/NOTES @@ -764,6 +764,22 @@ device superio # options ENABLE_ALART # Control alarm on Intel intpm driver +# +# HID-over-I2C support +# +device iichid # HID-over-I2C support +options IICHID_DEBUG # Enable HID-over-I2C debug messages +options IICHID_SAMPLING # Workaround missing GPIO INTR support + +##################################################################### +# ABI Emulation + +# Enable (32-bit) a.out binary support +options COMPAT_AOUT + +##################################################################### +# VM OPTIONS + # # Set the number of PV entries per process. Increasing this can # stop panics related to heavy use of shared memory. However, that can @@ -786,22 +802,6 @@ options PMAP_SHPGPERPROC=201 # options NKPT=31 -# -# HID-over-I2C support -# -device iichid # HID-over-I2C support -options IICHID_DEBUG # Enable HID-over-I2C debug messages -options IICHID_SAMPLING # Workaround missing GPIO INTR support - -##################################################################### -# ABI Emulation - -# Enable (32-bit) a.out binary support -options COMPAT_AOUT - -##################################################################### -# VM OPTIONS - # KSTACK_PAGES is the number of memory pages to assign to the kernel # stack of each thread. From nobody Fri Jul 19 15:40:30 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQYly5jWBz5RqxG; Fri, 19 Jul 2024 15:40: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQYly3318z4tBW; Fri, 19 Jul 2024 15:40:30 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721403630; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=P7Aht0ta0oQjki3trJV7KnjGQEuNQ5jhKGIh/O24x70=; b=vbtEnQo8Jl05gLFcx8MTvbVd5Mq75NTwjROeV+Ldmj2i78Wip7dTlSXyLOouPWLQw5rxx6 bAafz4a6fTFBXPmo84OUXMLQn6UXdSDHofXmezQ18uD8/UkeIKbe0JreLfxdf35iZhSaVB 7xA4vZtlNZqyklqhPrnGnKZF8lhQIMINzW61eQqJXfVRU1/FMYFByUgRL79dTTGSZ03Zxr BCDzhgMLi3bt5quSU4KHTgsKzIvVwN39Os6yg2b/wMy3lF5vYXUpaSybSp6H2bCFivnDfQ HbZ0EljIuI1SHo6SSj4UFSkgboIUCgWmJ6ott3BfQObkK2hDm6kzq7NGBjGz/A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721403630; a=rsa-sha256; cv=none; b=jsizaC/5NUMCaCgyLU9gRft9YWpHGLgHnWw056HMyiwsN+OvH3CScY/s+5x3xW2zveSMNU Ch94NBx9x6lcaj4OZsa4TlrlDPsoo+fzU6XQpMfsauDKLxK+LV+cVDKG9KWtvn+sBK9ub+ iOEMFJtfkrBLDr32M+rvuctbf6o6tEG5ikPA+jmWLQ6eT5FX0JmfbYQVk970pmQ8kx9+Qs emtY7zanEiLAlgt5FYJcIuj/4dwb5ng813WM4ayYqWFo+vpVm122rVyBME6G/Xc6nRTscx KKmRRFYs3RsgBXXfrcqWMjqlYyU5qJYKFDBb2D4S6E2wQ8ub/E4EBGDNEKe9Ig== 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=1721403630; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=P7Aht0ta0oQjki3trJV7KnjGQEuNQ5jhKGIh/O24x70=; b=Bz4x3vuAZU7f2dhpw97NKU27htmsgXS9rKFjcTG3dow33UUbtFYUPALXIa5guenrRihuXi x4GvIPGFC6Ha7Y5S448obsf8ALRoHfkqzUKOJZjjAXO89CJZpqBaC3E7N9HFDIm+icUU8B I7X3fMiGTZkoDRg2oIhVflqUgRs2FR1nt/NFEJY3dlDbJLn9YLFrLyfqJDkemfss9dsxzc b2RQOry14SZnvXVjgQNtYdVqT8C0IfjQPiref8+07y+w++eXCrEos5MQsDfZSLKzEJrFdO G4p8B+1j88bWBiuxnaMA+O5EcztNdLjygs4uWryETj+s8gi7nh+Qkou0xmKuSw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQYly2f7czdZK; Fri, 19 Jul 2024 15:40:30 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JFeUA3083270; Fri, 19 Jul 2024 15:40:30 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JFeUnj083267; Fri, 19 Jul 2024 15:40:30 GMT (envelope-from git) Date: Fri, 19 Jul 2024 15:40:30 GMT Message-Id: <202407191540.46JFeUnj083267@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: John Baldwin Subject: git: d1c97c1871d2 - stable/14 - NOTES: Move ENABLE_ALART option to MI NOTES next to intpm device List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: d1c97c1871d200eaf52dd75f2e039d1306b28536 Auto-Submitted: auto-generated The branch stable/14 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=d1c97c1871d200eaf52dd75f2e039d1306b28536 commit d1c97c1871d200eaf52dd75f2e039d1306b28536 Author: John Baldwin AuthorDate: 2024-04-14 02:11:49 +0000 Commit: John Baldwin CommitDate: 2024-07-18 17:33:03 +0000 NOTES: Move ENABLE_ALART option to MI NOTES next to intpm device This option is for this driver. Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D44786 (cherry picked from commit 5ea0b89242dbc1e4d4bac16983291a7c3803f88e) --- sys/amd64/conf/NOTES | 5 ----- sys/conf/NOTES | 1 + sys/i386/conf/NOTES | 5 ----- 3 files changed, 1 insertion(+), 10 deletions(-) diff --git a/sys/amd64/conf/NOTES b/sys/amd64/conf/NOTES index 0c418f6359ac..286e35d4865c 100644 --- a/sys/amd64/conf/NOTES +++ b/sys/amd64/conf/NOTES @@ -544,11 +544,6 @@ device cpuctl # device superio -# -# System Management Bus (SMB) -# -options ENABLE_ALART # Control alarm on Intel intpm driver - # # AMD System Management Network (SMN) # diff --git a/sys/conf/NOTES b/sys/conf/NOTES index 663ec0282491..913b155b0995 100644 --- a/sys/conf/NOTES +++ b/sys/conf/NOTES @@ -2221,6 +2221,7 @@ device rtsx device smbus # Bus support, required for smb below. device intpm +options ENABLE_ALART # Control alarm on Intel intpm driver device alpm device ichsmb device viapm diff --git a/sys/i386/conf/NOTES b/sys/i386/conf/NOTES index 8f6098301b12..7137fd983c66 100644 --- a/sys/i386/conf/NOTES +++ b/sys/i386/conf/NOTES @@ -759,11 +759,6 @@ device cpuctl # device superio -# -# System Management Bus (SMB) -# -options ENABLE_ALART # Control alarm on Intel intpm driver - # # HID-over-I2C support # From nobody Fri Jul 19 15:40:31 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQYlz6yPCz5RrB9; Fri, 19 Jul 2024 15:40: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQYlz40yBz4t46; Fri, 19 Jul 2024 15:40:31 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721403631; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=stK0xWBuM6blWGXhiwYokfAXl346spyE30yoV1UoRF4=; b=fxDtqUZEq9zuYo7dZmOtH1ze6rQdpewsSvRgucm/Kb9IWoa6fBEEcE+mspwKEdaPUqVLNU t8nYA13xAQqT5rTjjkpRNHAoSVOoi5n83tBds9as7+nJzwDXVEa2F7sjFa/1rBUPNBE0EA HYRP72Xpk9TaZv3Hj9OlJpL99lS6qMIxb5x1yFSg2+4D+z/qVVwVaOvZwdLELDi9wuyVnG AcWZdxL5Zev+/11q00IVlT8dnGaKrnP15BZcXHFYB007mUcQsPc+zkYYprLFjEyowteykS AeT2sRg5jbiAJ2PhClEfstOiQQDe83WJi87qGl+v0VxDLGzJMQwt/RtCxo5k2w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721403631; a=rsa-sha256; cv=none; b=LRdlDbBFeSjRUZYl8HUok+we8M75JpJZfr2Sv8IBzBawkyKAz4ni0GDrs2Xw5sQOHjOJtJ huDZREqltMDQP72xcT2U2SD/WfbjfiHti572dStci0BKVJptAlHtEDHe3pMW0XdPN9M1kb 1rE1a4inwFY1KXclNpyJk4+CBhDtaV6yTkTvyxgiY5ce7ov7CKDWqFfLnd25lTVU29QTQ1 u+qD6Fbb61bxaSPuWGwWQxqD4nEKKoZwz9vCbfAu4S4CN2b2OBfXrXdFQRL3+QqnV45eKc ZksyaOd1DnBbFmNerQ+xWTtV/4PZgIWGlu8R0JSyoEACwPcTJN2rHq9L/p/3+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=1721403631; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=stK0xWBuM6blWGXhiwYokfAXl346spyE30yoV1UoRF4=; b=rZQ3vq314RajXiV2WEYW7YeTt7vryU5dbWJCFXq3VsG6UlfShcTa5gzgPneRnigFRw8eBg KILEcDIMIOUcAZfXSb712IP6YFAwIAIMON1qnCv7JBXMp9H2FgpodgYtBYrZpM8mGrGKpb vUEv9BDphV1UBu6wM3qHnk5Dbz7ZQFxl5p2WcyjlkUInRsv2QT0/u3JtB/1doyoDVJdkgh gkP3+o6qcMvc5yg4q+AfqG3+hcVBaUMLcbo2hz5xAyOxDkhWLk4Q90+AIfqsLi07XfmL9x g8C5uin285IHvJMxo/LAyUlcRRISq3Tq60xsCEoloUcE9RbffWR0VfaxBRCN6A== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQYlz3L60zdMn; Fri, 19 Jul 2024 15:40:31 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JFeVai083330; Fri, 19 Jul 2024 15:40:31 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JFeVou083327; Fri, 19 Jul 2024 15:40:31 GMT (envelope-from git) Date: Fri, 19 Jul 2024 15:40:31 GMT Message-Id: <202407191540.46JFeVou083327@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: John Baldwin Subject: git: eb1f2709509f - stable/14 - x86 NOTES: Move shared options from amd/i386 NOTES to x86 NOTES List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: eb1f2709509f985901f9751319d1e36ec8695a10 Auto-Submitted: auto-generated The branch stable/14 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=eb1f2709509f985901f9751319d1e36ec8695a10 commit eb1f2709509f985901f9751319d1e36ec8695a10 Author: John Baldwin AuthorDate: 2024-04-14 02:12:07 +0000 Commit: John Baldwin CommitDate: 2024-07-18 17:33:13 +0000 x86 NOTES: Move shared options from amd/i386 NOTES to x86 NOTES While here, reorder some of the entries using headers more aligned with sys/conf/NOTES. Also add a pointer from the amd64/i386 NOTES files to x86 NOTES. The "extra" ACPI device drivers were only present in i386 NOTES previously. Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D44787 (cherry picked from commit 1f38677ba40b26b861e063e130117143c9342c5d) --- sys/amd64/conf/NOTES | 501 ++---------------------------------------------- sys/i386/conf/NOTES | 521 ++------------------------------------------------ sys/x86/conf/NOTES | 528 +++++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 566 insertions(+), 984 deletions(-) diff --git a/sys/amd64/conf/NOTES b/sys/amd64/conf/NOTES index 286e35d4865c..c82be3945ac7 100644 --- a/sys/amd64/conf/NOTES +++ b/sys/amd64/conf/NOTES @@ -2,52 +2,24 @@ # NOTES -- Lines that can be cut/pasted into kernel and hints configs. # # This file contains machine dependent kernel configuration notes. For -# machine independent notes, look in /sys/conf/NOTES. +# machine independent notes, look in /sys/conf/NOTES. For notes shared +# with i386, look in /sys/x86/conf/NOTES. # # -# -# Enable the kernel DTrace hooks which are required to load the DTrace -# kernel modules. -# -options KDTRACE_HOOKS - -# DTrace core -# NOTE: introduces CDDL-licensed components into the kernel -#device dtrace - -# DTrace modules -#device dtrace_profile -#device dtrace_sdt -#device dtrace_fbt -#device dtrace_systrace -#device dtrace_prototype -#device dtnfscl -#device dtmalloc +# GCOV (code coverage) support -# Alternatively include all the DTrace modules -#device dtraceall +options LINDEBUGFS +options GCOV ##################################################################### # SMP OPTIONS: -# -# Notes: -# -# IPI_PREEMPTION instructs the kernel to preempt threads running on other -# CPUS if needed. Relies on the PREEMPTION option # Optional: -options IPI_PREEMPTION device atpic # Optional legacy pic support device mptable # Optional MPSPEC mptable support -# Debugging options. -# -options COUNT_XINVLTLB_HITS # Counters for TLB events -options COUNT_IPIS # Per-CPU IPI interrupt counters - - ##################################################################### # CPU OPTIONS @@ -63,179 +35,16 @@ cpu HAMMER # aka K8, aka Opteron & Athlon64 # Options for CPU features. # - -##################################################################### -# NETWORKING OPTIONS - -# -# DEVICE_POLLING adds support for mixed interrupt-polling handling -# of network device drivers, which has significant benefits in terms -# of robustness to overloads and responsivity, as well as permitting -# accurate scheduling of the CPU time between kernel network processing -# and other activities. The drawback is a moderate (up to 1/HZ seconds) -# potential increase in response times. -# It is strongly recommended to use HZ=1000 or 2000 with DEVICE_POLLING -# to achieve smoother behaviour. -# Additionally, you can enable/disable polling at runtime with help of -# the ifconfig(8) utility, and select the CPU fraction reserved to -# userland with the sysctl variable kern.polling.user_frac -# (default 50, range 0..100). -# -# Not all device drivers support this mode of operation at the time of -# this writing. See polling(4) for more details. - -options DEVICE_POLLING - -# BPF_JITTER adds support for BPF just-in-time compiler. - -options BPF_JITTER - - -##################################################################### -# CLOCK OPTIONS - -# Provide read/write access to the memory in the clock chip. -device nvram # Access to rtc cmos via /dev/nvram - - -##################################################################### -# MISCELLANEOUS DEVICES AND OPTIONS - -device speaker #Play IBM BASIC-style noises out your speaker -envvar hint.speaker.0.at="isa" -envvar hint.speaker.0.port="0x61" - - -##################################################################### -# HARDWARE BUS CONFIGURATION - -# -# ISA bus -# -device isa - -# -# Options for `isa': -# -# AUTO_EOI_1 enables the `automatic EOI' feature for the master 8259A -# interrupt controller. This saves about 0.7-1.25 usec for each interrupt. -# This option breaks suspend/resume on some portables. -# -# AUTO_EOI_2 enables the `automatic EOI' feature for the slave 8259A -# interrupt controller. This saves about 0.7-1.25 usec for each interrupt. -# Automatic EOI is documented not to work for the slave with the -# original i8259A, but it works for some clones and some integrated -# versions. -# -# MAXMEM specifies the amount of RAM on the machine; if this is not -# specified, FreeBSD will first read the amount of memory from the CMOS -# RAM, so the amount of memory will initially be limited to 64MB or 16MB -# depending on the BIOS. If the BIOS reports 64MB, a memory probe will -# then attempt to detect the installed amount of RAM. If this probe -# fails to detect >64MB RAM you will have to use the MAXMEM option. -# The amount is in kilobytes, so for a machine with 128MB of RAM, it would -# be 131072 (128 * 1024). -# -# BROKEN_KEYBOARD_RESET disables the use of the keyboard controller to -# reset the CPU for reboot. This is needed on some systems with broken -# keyboard controllers. - -options AUTO_EOI_1 -#options AUTO_EOI_2 - -options MAXMEM=(128*1024) -#options BROKEN_KEYBOARD_RESET - -# -# AGP GART support -device agp - -# -# AGP debugging. -# -options AGP_DEBUG - ##################################################################### # HARDWARE DEVICE CONFIGURATION -# To include support for VGA VESA video modes -options VESA - -# Turn on extra debugging checks and output for VESA support. -options VESA_DEBUG - -device dpms # DPMS suspend & resume via VESA BIOS - -# x86 real mode BIOS emulator, required by atkbdc/dpms/vesa -options X86BIOS - # # Optional devices: # -# PS/2 mouse -device psm -envvar hint.psm.0.at="atkbdc" -envvar hint.psm.0.irq="12" - -# Options for psm: -options PSM_HOOKRESUME #hook the system resume event, useful - #for some laptops -options PSM_RESETAFTERSUSPEND #reset the device at the resume event - -# The keyboard controller; it controls the keyboard and the PS/2 mouse. -device atkbdc -envvar hint.atkbdc.0.at="isa" -envvar hint.atkbdc.0.port="0x060" - -# The AT keyboard -device atkbd -envvar hint.atkbd.0.at="atkbdc" -envvar hint.atkbd.0.irq="1" - -# Options for atkbd: -options ATKBD_DFLT_KEYMAP # specify the built-in keymap -makeoptions ATKBD_DFLT_KEYMAP=fr.dvorak - -# `flags' for atkbd: -# 0x01 Force detection of keyboard, else we always assume a keyboard -# 0x02 Don't reset keyboard, useful for some newer ThinkPads -# 0x03 Force detection and avoid reset, might help with certain -# dockingstations -# 0x04 Old-style (XT) keyboard support, useful for older ThinkPads - -# Video card driver for VGA adapters. -device vga -envvar hint.vga.0.at="isa" - -# Options for vga: -# Try the following option if the mouse pointer is not drawn correctly -# or font does not seem to be loaded properly. May cause flicker on -# some systems. -options VGA_ALT_SEQACCESS - -# If you can dispense with some vga driver features, you may want to -# use the following options to save some memory. -#options VGA_NO_FONT_LOADING # don't save/load font -#options VGA_NO_MODE_CHANGE # don't change video modes - -# Older video cards may require this option for proper operation. -options VGA_SLOW_IOACCESS # do byte-wide i/o's to TS and GDC regs - -# The following option probably won't work with the LCD displays. -options VGA_WIDTH90 # support 90 column modes - -# Debugging. -options VGA_DEBUG - # vt(4) drivers. -device vt_vga # VGA device vt_efifb # EFI framebuffer -device vt_vbefb # VBE framebuffer - -# Linear framebuffer driver for S3 VESA 1.2 cards. Works on top of VESA. -device s3pci # 3Dfx Voodoo Graphics, Voodoo II /dev/3dfx CDEV support. This will create # the /dev/3dfx0 device to work with glide implementations. This should get @@ -246,19 +55,18 @@ device s3pci device tdfx # Enable 3Dfx Voodoo support # -# ACPI support using the Intel ACPI Component Architecture reference -# implementation. +# RAID adapters # -# ACPI_DEBUG enables the use of the debug.acpi.level and debug.acpi.layer -# kernel environment variables to select initial debugging levels for the -# Intel ACPICA code. (Note that the Intel code must also have USE_DEBUGGER -# defined when it is built). -device acpi -options ACPI_DEBUG +#XXX this stores pointers in a 32bit field that is defined by the hardware +#device pst -# The cpufreq(4) driver provides support for non-ACPI CPU frequency control -device cpufreq +# +# Microsemi smartpqi controllers. +# These controllers have a SCSI-like interface, and require the +# CAM infrastructure. +# +device smartpqi # # Network interfaces: @@ -266,183 +74,38 @@ device cpufreq # axp: AMD EPYC integrated NIC # Requires the miibus module -# bxe: Broadcom NetXtreme II (BCM5771X/BCM578XX) PCIe 10Gb Ethernet -# adapters. # ice: Intel 800 Series Physical Function # Requires the ice_ddp module for full functionality -# igc: Intel I225 2.5Gb Ethernet adapter -# ipw: Intel PRO/Wireless 2100 IEEE 802.11 adapter -# Requires the ipw firmware module # irdma: Intel 800 Series RDMA driver # Requires the ice module -# iwi: Intel PRO/Wireless 2200BG/2225BG/2915ABG IEEE 802.11 adapters -# Requires the iwi firmware module -# iwn: Intel Wireless WiFi Link 1000/105/135/2000/4965/5000/6000/6050 abgn -# 802.11 network adapters -# Requires the iwn firmware module -# mthca: Mellanox HCA InfiniBand -# mlx4ib: Mellanox ConnectX HCA InfiniBand -# mlx4en: Mellanox ConnectX HCA Ethernet -# nfe: nVidia nForce MCP on-board Ethernet Networking (BSD open source) # qlxgb: QLogic 3200 and 8200 series 10 Gigabit Ethernet & CNA Adapter # qlxgbe: QLogic 8300 series 10 Gigabit Ethernet & CNA Adapter # qlxge: QLogic 8100 series 10 Gigabit Ethernet & CNA Adapter # qlnxe: Cavium QLogic 41000/45000 series 10/25/40/100 Gigabit Ethernet & CNA Adapter # sfxge: Solarflare SFC9000 family 10Gb Ethernet adapters -# vmx: VMware VMXNET3 Ethernet (BSD open source) -# wpi: Intel 3945ABG Wireless LAN controller -# Requires the wpi firmware module device axp # AMD EPYC integrated NIC -device bxe # Broadcom NetXtreme II BCM5771X/BCM578XX 10GbE -device igc # Intel I225 2.5G Ethernet -device ipw # Intel 2100 wireless NICs. -device iwi # Intel 2200BG/2225BG/2915ABG wireless NICs. -device iwn # Intel 4965/1000/5000/6000 wireless NICs. device ixl # Intel 700 Series Physical Function device iavf # Intel Adaptive Virtual Function device ice # Intel 800 Series Physical Function device ice_ddp # Intel 800 Series DDP Package device irdma # Intel 800 Series RDMA driver -device mthca # Mellanox HCA InfiniBand -device mlx4 # Shared code module between IB and Ethernet -device mlx4ib # Mellanox ConnectX HCA InfiniBand -device mlx4en # Mellanox ConnectX HCA Ethernet -device nfe # nVidia nForce MCP on-board Ethernet device qlxgb # QLogic 3200/8200 Ethernet device qlxgbe # QLogic 8300 Ethernet device qlxge # QLogic 8100 Ethernet device qlnxe # QLogic 41000/45000 Ethernet device sfxge # Solarflare SFC9000 10Gb Ethernet -device vmx # VMware VMXNET3 Ethernet -device wpi # Intel 3945ABG wireless NICs. - -# IEEE 802.11 adapter firmware modules - -# Intel PRO/Wireless 2100 firmware: -# ipwfw: BSS/IBSS/monitor mode firmware -# ipwbssfw: BSS mode firmware -# ipwibssfw: IBSS mode firmware -# ipwmonitorfw: Monitor mode firmware -# Intel PRO/Wireless 2200BG/2225BG/2915ABG firmware: -# iwifw: BSS/IBSS/monitor mode firmware -# iwibssfw: BSS mode firmware -# iwiibssfw: IBSS mode firmware -# iwimonitorfw: Monitor mode firmware -# Intel Wireless WiFi Link 4965/1000/5000/6000 series firmware: -# iwnfw: Single module to support all devices -# iwn1000fw: Specific module for the 1000 only -# iwn105fw: Specific module for the 105 only -# iwn135fw: Specific module for the 135 only -# iwn2000fw: Specific module for the 2000 only -# iwn2030fw: Specific module for the 2030 only -# iwn4965fw: Specific module for the 4965 only -# iwn5000fw: Specific module for the 5000 only -# iwn5150fw: Specific module for the 5150 only -# iwn6000fw: Specific module for the 6000 only -# iwn6000g2afw: Specific module for the 6000g2a only -# iwn6000g2bfw: Specific module for the 6000g2b only -# iwn6050fw: Specific module for the 6050 only -# wpifw: Intel 3945ABG Wireless LAN Controller firmware - -device iwifw -device iwibssfw -device iwiibssfw -device iwimonitorfw -device ipwfw -device ipwbssfw -device ipwibssfw -device ipwmonitorfw -device iwnfw -device iwn1000fw -device iwn105fw -device iwn135fw -device iwn2000fw -device iwn2030fw -device iwn4965fw -device iwn5000fw -device iwn5150fw -device iwn6000fw -device iwn6000g2afw -device iwn6000g2bfw -device iwn6050fw -device wpifw - -# -# Non-Transparent Bridge (NTB) drivers -# -device if_ntb # Virtual NTB network interface -device ntb_transport # NTB packet transport driver -device ntb # NTB hardware interface -device ntb_hw_amd # AMD NTB hardware driver -device ntb_hw_intel # Intel NTB hardware driver -device ntb_hw_plx # PLX NTB hardware driver - -# -#XXX this stores pointers in a 32bit field that is defined by the hardware -#device pst - -# -# Areca 11xx and 12xx series of SATA II RAID controllers. -# CAM is required. -# -device arcmsr # Areca SATA II RAID - -# -# Microsemi smartpqi controllers. -# These controllers have a SCSI-like interface, and require the -# CAM infrastructure. -# -device smartpqi - -# -# Adaptec FSA RAID controllers, including integrated DELL controllers, -# the Dell PERC 2/QC and the HP NetRAID-4M -device aac -device aacp # SCSI Passthrough interface (optional, CAM required) -# -# Highpoint RocketRAID 27xx. -device hpt27xx - -# -# Highpoint RocketRAID 182x. -device hptmv - -# -# Highpoint DC7280 and R750. -device hptnr - -# -# Highpoint RocketRAID. Supports RR172x, RR222x, RR2240, RR232x, RR2340, -# RR2210, RR174x, RR2522, RR231x, RR230x. -device hptrr - -# -# Highpoint RocketRaid 3xxx series SATA RAID -device hptiop - -# -# IBM (now Adaptec) ServeRAID controllers -device ips +##################################################################### # -# Intel integrated Memory Controller (iMC) SMBus controller -# Sandybridge-Xeon, Ivybridge-Xeon, Haswell-Xeon, Broadwell-Xeon -device imcsmb - +# Miscellaneous hardware: # -# Intel C600 (Patsburg) integrated SAS controller -device isci -options ISCI_LOGGING # enable debugging in isci HAL -# -# Intel Volume Management Device (VMD) support -device vmd +device ioat # Intel I/OAT DMA engine -# -# PMC-Sierra SAS/SATA controller -device pmspcv +# EFI Runtime Services support +options EFIRT # # Intel QuickAssist driver with OpenCrypto support @@ -450,115 +113,12 @@ device pmspcv # Only for legacy Atom C2XXX chipsets. device qat_c2xxx -# Linux KVM paravirtualization support -device kvm_clock # KVM paravirtual clock driver - -# Google Virtual NIC -device gve # Google Virtual NIC (gVNIC) driver - -# Microsoft Hyper-V enhancement support -device hyperv # HyperV drivers -device hvhid # HyperV HID device - # Xen HVM Guest Optimizations options XENHVM # Xen HVM kernel infrastructure device xenefi # Xen EFI timer device device xenpci # Xen HVM Hypervisor services driver device xentimer # Xen x86 PV timer device -##################################################################### - -# -# Miscellaneous hardware: -# -# ipmi: Intelligent Platform Management Interface -# pbio: Parallel (8255 PPI) basic I/O (mode 0) port (e.g. Advantech PCL-724) -# smbios: DMI/SMBIOS entry point (requires EFIRT option) -# vpd: Vital Product Data kernel interface -# asmc: Apple System Management Controller -# si: Specialix International SI/XIO or SX intelligent serial card -# tpm: Trusted Platform Module - -# Notes on the Specialix SI/XIO driver: -# The host card is memory, not IO mapped. -# The Rev 1 host cards use a 64K chunk, on a 32K boundary. -# The Rev 2 host cards use a 32K chunk, on a 32K boundary. -# The cards can use an IRQ of 11, 12 or 15. - -device ipmi -device pbio -envvar hint.pbio.0.at="isa" -envvar hint.pbio.0.port="0x360" -device smbios -device vpd -device asmc -device tpm -device padlock_rng # VIA Padlock RNG -device rdrand_rng # Intel Bull Mountain RNG -device aesni # AES-NI OpenCrypto module -device ossl # OpenSSL OpenCrypto module -device ioat # Intel I/OAT DMA engine - -# -# Laptop/Notebook options: -# - -device backlight - -# -# I2C Bus -# - -# -# Hardware watchdog timers: -# -# ichwd: Intel ICH watchdog timer -# amdsbwd: AMD SB7xx watchdog timer -# viawd: VIA south bridge watchdog timer -# wbwd: Winbond watchdog timer -# itwd: ITE Super I/O watchdog timer -# -device ichwd -device amdsbwd -device viawd -device wbwd -device itwd - -# -# Temperature sensors: -# -# coretemp: on-die sensor on Intel Core and newer CPUs -# amdtemp: on-die sensor on AMD K8/K10/K11 CPUs -# -device coretemp -device amdtemp - -# -# CPU control pseudo-device. Provides access to MSRs, CPUID info and -# microcode update feature. -# -device cpuctl - -# -# SuperIO driver. -# -device superio - -# -# AMD System Management Network (SMN) -# -device amdsmn - -# EFI Runtime Services support -options EFIRT - -# -# HID-over-I2C support -# -device iichid # HID-over-I2C support -options IICHID_DEBUG # Enable HID-over-I2C debug messages -options IICHID_SAMPLING # Workaround missing GPIO INTR support - ##################################################################### # ABI Emulation @@ -593,26 +153,3 @@ options KSTACK_PAGES=5 # Enable detailed accounting by the PV entry allocator. options PV_STATS - -##################################################################### - -# More undocumented options for linting. -# Note that documenting these are not considered an affront. - -options KBDIO_DEBUG=2 -options KBD_MAXRETRY=4 -options KBD_MAXWAIT=6 -options KBD_RESETDELAY=201 - -options PSM_DEBUG=1 - -options TIMER_FREQ=((14318182+6)/12) - -options VM_KMEM_SIZE -options VM_KMEM_SIZE_MAX -options VM_KMEM_SIZE_SCALE - -# GCOV (code coverage) support - -options LINDEBUGFS -options GCOV diff --git a/sys/i386/conf/NOTES b/sys/i386/conf/NOTES index 7137fd983c66..93dc00634cc0 100644 --- a/sys/i386/conf/NOTES +++ b/sys/i386/conf/NOTES @@ -2,32 +2,11 @@ # NOTES -- Lines that can be cut/pasted into kernel and hints configs. # # This file contains machine dependent kernel configuration notes. For -# machine independent notes, look in /sys/conf/NOTES. +# machine independent notes, look in /sys/conf/NOTES. For notes shared +# with amd64, look in /sys/x86/conf/NOTES. # # -# -# Enable the kernel DTrace hooks which are required to load the DTrace -# kernel modules. -# -options KDTRACE_HOOKS - -# DTrace core -# NOTE: introduces CDDL-licensed components into the kernel -#device dtrace - -# DTrace modules -#device dtrace_profile -#device dtrace_sdt -#device dtrace_fbt -#device dtrace_systrace -#device dtrace_prototype -#device dtnfscl -#device dtmalloc - -# Alternatively include all the DTrace modules -#device dtraceall - ##################################################################### # SMP OPTIONS: @@ -57,13 +36,6 @@ device apic # I/O apic # Optional: options MPTABLE_FORCE_HTT # Enable HTT CPUs with the MP Table -options IPI_PREEMPTION - -# Debugging options. -# -options COUNT_XINVLTLB_HITS # Counters for TLB events -options COUNT_IPIS # Per-CPU IPI interrupt counters - ##################################################################### @@ -211,111 +183,6 @@ options NPX_DEBUG # enable npx debugging # options PERFMON - -##################################################################### -# NETWORKING OPTIONS - -# -# DEVICE_POLLING adds support for mixed interrupt-polling handling -# of network device drivers, which has significant benefits in terms -# of robustness to overloads and responsivity, as well as permitting -# accurate scheduling of the CPU time between kernel network processing -# and other activities. The drawback is a moderate (up to 1/HZ seconds) -# potential increase in response times. -# It is strongly recommended to use HZ=1000 or 2000 with DEVICE_POLLING -# to achieve smoother behaviour. -# Additionally, you can enable/disable polling at runtime with help of -# the ifconfig(8) utility, and select the CPU fraction reserved to -# userland with the sysctl variable kern.polling.user_frac -# (default 50, range 0..100). -# -# Not all device drivers support this mode of operation at the time of -# this writing. See polling(4) for more details. - -options DEVICE_POLLING - -# BPF_JITTER adds support for BPF just-in-time compiler. - -options BPF_JITTER - - -##################################################################### -# CLOCK OPTIONS - -# Provide read/write access to the memory in the clock chip. -device nvram # Access to rtc cmos via /dev/nvram - - -##################################################################### -# MISCELLANEOUS DEVICES AND OPTIONS - -device speaker #Play IBM BASIC-style noises out your speaker -envvar hint.speaker.0.at="isa" -envvar hint.speaker.0.port="0x61" - - -##################################################################### -# HARDWARE BUS CONFIGURATION - -# -# ISA bus -# -device isa - -# -# Options for `isa': -# -# AUTO_EOI_1 enables the `automatic EOI' feature for the master 8259A -# interrupt controller. This saves about 0.7-1.25 usec for each interrupt. -# This option breaks suspend/resume on some portables. -# -# AUTO_EOI_2 enables the `automatic EOI' feature for the slave 8259A -# interrupt controller. This saves about 0.7-1.25 usec for each interrupt. -# Automatic EOI is documented not to work for the slave with the -# original i8259A, but it works for some clones and some integrated -# versions. -# -# MAXMEM specifies the amount of RAM on the machine; if this is not -# specified, FreeBSD will first read the amount of memory from the CMOS -# RAM, so the amount of memory will initially be limited to 64MB or 16MB -# depending on the BIOS. If the BIOS reports 64MB, a memory probe will -# then attempt to detect the installed amount of RAM. If this probe -# fails to detect >64MB RAM you will have to use the MAXMEM option. -# The amount is in kilobytes, so for a machine with 128MB of RAM, it would -# be 131072 (128 * 1024). -# -# BROKEN_KEYBOARD_RESET disables the use of the keyboard controller to -# reset the CPU for reboot. This is needed on some systems with broken -# keyboard controllers. - -options AUTO_EOI_1 -#options AUTO_EOI_2 - -options MAXMEM=(128*1024) -#options BROKEN_KEYBOARD_RESET - -# -# AGP GART support -device agp - -# AGP debugging. -options AGP_DEBUG - - -##################################################################### -# HARDWARE DEVICE CONFIGURATION - -# To include support for VGA VESA video modes -options VESA - -# Turn on extra debugging checks and output for VESA support. -options VESA_DEBUG - -device dpms # DPMS suspend & resume via VESA BIOS - -# x86 real mode BIOS emulator, required by atkbdc/dpms/vesa -options X86BIOS - # # Hints for the non-optional Numeric Processing eXtension driver. envvar hint.npx.0.flags="0x0" @@ -339,72 +206,14 @@ envvar hint.npx.0.irq="13" # Flag 0x08 automatically disables the i586 optimized routines. # + +##################################################################### +# HARDWARE DEVICE CONFIGURATION + # # Optional devices: # -# PS/2 mouse -device psm -envvar hint.psm.0.at="atkbdc" -envvar hint.psm.0.irq="12" - -# Options for psm: -options PSM_HOOKRESUME #hook the system resume event, useful - #for some laptops -options PSM_RESETAFTERSUSPEND #reset the device at the resume event - -# The keyboard controller; it controls the keyboard and the PS/2 mouse. -device atkbdc -envvar hint.atkbdc.0.at="isa" -envvar hint.atkbdc.0.port="0x060" - -# The AT keyboard -device atkbd -envvar hint.atkbd.0.at="atkbdc" -envvar hint.atkbd.0.irq="1" - -# Options for atkbd: -options ATKBD_DFLT_KEYMAP # specify the built-in keymap -makeoptions ATKBD_DFLT_KEYMAP=fr.dvorak - -# `flags' for atkbd: -# 0x01 Force detection of keyboard, else we always assume a keyboard -# 0x02 Don't reset keyboard, useful for some newer ThinkPads -# 0x03 Force detection and avoid reset, might help with certain -# dockingstations -# 0x04 Old-style (XT) keyboard support, useful for older ThinkPads - -# Video card driver for VGA adapters. -device vga -envvar hint.vga.0.at="isa" - -# Options for vga: -# Try the following option if the mouse pointer is not drawn correctly -# or font does not seem to be loaded properly. May cause flicker on -# some systems. -options VGA_ALT_SEQACCESS - -# If you can dispense with some vga driver features, you may want to -# use the following options to save some memory. -#options VGA_NO_FONT_LOADING # don't save/load font -#options VGA_NO_MODE_CHANGE # don't change video modes - -# Older video cards may require this option for proper operation. -options VGA_SLOW_IOACCESS # do byte-wide i/o's to TS and GDC regs - -# The following option probably won't work with the LCD displays. -options VGA_WIDTH90 # support 90 column modes - -# Debugging. -options VGA_DEBUG - -# vt(4) drivers. -device vt_vga -device vt_vbefb - -# Linear framebuffer driver for S3 VESA 1.2 cards. Works on top of VESA. -device s3pci - # 3Dfx Voodoo Graphics, Voodoo II /dev/3dfx CDEV support. This will create # the /dev/3dfx0 device to work with glide implementations. This should get # linked to /dev/3dfx and /dev/voodoo. Note that this is not the same as @@ -414,73 +223,19 @@ device s3pci device tdfx # Enable 3Dfx Voodoo support -options IOMMU # Enable IOMMU support - # -# ACPI support using the Intel ACPI Component Architecture reference -# implementation. +# RAID adapters # -# ACPI_DEBUG enables the use of the debug.acpi.level and debug.acpi.layer -# kernel environment variables to select initial debugging levels for the -# Intel ACPICA code. (Note that the Intel code must also have USE_DEBUGGER -# defined when it is built). - -device acpi -options ACPI_DEBUG - -# ACPI WMI Mapping driver -device acpi_wmi - -# ACPI Asus Extras (LCD backlight/brightness, video output, etc.) -device acpi_asus - -# ACPI Fujitsu Extras (Buttons) -device acpi_fujitsu - -# ACPI extras driver for HP laptops -device acpi_hp - -# ACPI extras driver for IBM laptops -device acpi_ibm - -# ACPI Panasonic Extras (LCD backlight/brightness, video output, etc.) -device acpi_panasonic - -# ACPI Sony extra (LCD brightness) -device acpi_sony - -# ACPI Toshiba Extras (LCD backlight/brightness, video output, etc.) -device acpi_toshiba - -# ACPI Video Extensions (LCD backlight/brightness, video output, etc.) -device acpi_video - -# ACPI Docking Station -device acpi_dock - -# ACPI ASOC ATK0110 ASUSTeK AI Booster (voltage, temperature and fan sensors) -device aibs +device pst -# The cpufreq(4) driver provides support for non-ACPI CPU frequency control -device cpufreq +# +# Adaptec by PMC RAID controllers, Series 6/7/8 and upcoming families +device aacraid # Container interface, CAM required # # Network interfaces: # -# bxe: Broadcom NetXtreme II (BCM5771X/BCM578XX) PCIe 10Gb Ethernet -# adapters. -# igc: Intel I225 2.5G Ethernet adapter -# ipw: Intel PRO/Wireless 2100 IEEE 802.11 adapter -# iwi: Intel PRO/Wireless 2200BG/2225BG/2915ABG IEEE 802.11 adapters -# Requires the iwi firmware module -# iwn: Intel Wireless WiFi Link 1000/105/135/2000/4965/5000/6000/6050 abgn -# 802.11 network adapters -# Requires the iwn firmware module -# mthca: Mellanox HCA InfiniBand -# mlx4ib: Mellanox ConnectX HCA InfiniBand -# mlx4en: Mellanox ConnectX HCA Ethernet -# nfe: nVidia nForce MCP on-board Ethernet Networking (BSD open source) # sbni: Granch SBNI12-xx ISA and PCI adapters # vmx: VMware VMXNET3 Ethernet (BSD open source) # wpi: Intel 3945ABG Wireless LAN controller @@ -488,214 +243,31 @@ device cpufreq # Order for ISA/EISA devices is important here -device bxe # Broadcom NetXtreme II BCM5771X/BCM578XX 10GbE envvar hint.cs.0.at="isa" envvar hint.cs.0.port="0x300" envvar hint.ed.0.at="isa" envvar hint.ed.0.port="0x280" envvar hint.ed.0.irq="5" envvar hint.ed.0.maddr="0xd8000" -device igc # Intel I225 2.5G Ethernet -device ipw # Intel 2100 wireless NICs. -device iwi # Intel 2200BG/2225BG/2915ABG wireless NICs. -device iwn # Intel 4965/1000/5000/6000 wireless NICs. # Hint for the i386-only ISA front-end of le(4). envvar hint.le.0.at="isa" envvar hint.le.0.port="0x280" envvar hint.le.0.irq="10" envvar hint.le.0.drq="0" -device mthca # Mellanox HCA InfiniBand -device mlx4 # Shared code module between IB and Ethernet -device mlx4ib # Mellanox ConnectX HCA InfiniBand -device mlx4en # Mellanox ConnectX HCA Ethernet -device nfe # nVidia nForce MCP on-board Ethernet device sbni envvar hint.sbni.0.at="isa" envvar hint.sbni.0.port="0x210" envvar hint.sbni.0.irq="0xefdead" envvar hint.sbni.0.flags="0" -device vmx # VMware VMXNET3 Ethernet -device wpi # Intel 3945ABG wireless NICs. - *** 844 LINES SKIPPED *** From nobody Fri Jul 19 15:40:32 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQYm06Shxz5RrGW; Fri, 19 Jul 2024 15:40: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQYm04ZYsz4syS; Fri, 19 Jul 2024 15:40:32 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721403632; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6YcNve4jkzp78sSQ/XF27ElP6e0tEYBhdtbfrJ1TtUs=; b=kSRigS4UyD8yQKBenLx5jpm+RL9FFoKqfNjxfn6HbItvD8HWYPUEmYJKwsR9QJ5A0Fv2+c lSZGKlh3ht38ZnowsRe9UuUQRiCBlbEI08J61FvUnpbLlrga2hrvWBY9MaPhE8u7bP9I2C Hkc7lhPQDv74smzeoanH4HpxOl1ROJ78gA/RIoEukF8d4lGLW9MrEhVer7+2bOAedbsEqR zFVrl7psk2hD8dM+dcDgORYpIcyj6yW3ZA1kyvtB0TrJcy6/UNsJF023Tss5Fd4TstV4/B 9oSW31w+husFDin/mbr7smvP1h0+nlhXr/5UXeL9uf1pu+EWP64Zha3wroxcOw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721403632; a=rsa-sha256; cv=none; b=mb9fwNx4fp1Q1A+JGLnjZdtYPPdpaw/BjwVOHDE1LAgLLaSHWwh/X4qiGo2pAavW8Tw2jW YPAozmqrbN8uQ+1squHsFWKoRSmdPvrT7mDxAID3lwl5NRLwS/t1O7xrDXk1rqhTCrmhIk nXV3DxlaoF1tYHeyevZGdl78kbz1Lz0vdmIVoLOIPs8mO5ycQfZpX/xeDPNzEe6WtTWtyA 3TIqMn+aFKvdsWUo7afrh4A89Yw0Hh8w3KfnnJHIkFb8RTY4LysSUZSIjIR0i1zyP4g9x7 rsH1a/sPiqLyXUN+3q/oakZMiK5kqObwVkP22+tS20Ej1dzoutSOwzGGs2ET4Q== 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=1721403632; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6YcNve4jkzp78sSQ/XF27ElP6e0tEYBhdtbfrJ1TtUs=; b=aCxL4w4uhs+AwYQa0Q4e/PT8iz2nSovMI6ueuSxs9xcDoEuKg7O6s91Jx7SWat9X0Y+0tH w8sZk/7QK0oUm5W8+kqdv/27gTo2kTzt4klVmL15TxmR9F1g0rcqiZn5Pd7z4rjg1hTx0T oG3Ul6OGYLmgopG5fLunBqsohL2L27I7uQ15TACaQz19YfgQP/cVP5/2s2ZeHqQVTAhC7P cnm9v7eB+77yMqIQ9f2sv7JaXkr7Sdw2Teh7+ooGk5vN0dvmSFKYuneSX/5eZk4LGLflIE Opyq1vqnczxX7hYZHTF+b6UgAp3FS1iJlMKfdR/GTih4ZdjM5qudOnOPG6Unag== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQYm04B5hzdZL; Fri, 19 Jul 2024 15:40:32 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JFeWpR083372; Fri, 19 Jul 2024 15:40:32 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JFeWki083369; Fri, 19 Jul 2024 15:40:32 GMT (envelope-from git) Date: Fri, 19 Jul 2024 15:40:32 GMT Message-Id: <202407191540.46JFeWki083369@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: John Baldwin Subject: git: 4ecd329b73fa - stable/14 - sys: Retire the ISCSI_INITIATOR_DEBUG option List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 4ecd329b73fad35e2812a30ce55b9b4d43162471 Auto-Submitted: auto-generated The branch stable/14 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=4ecd329b73fad35e2812a30ce55b9b4d43162471 commit 4ecd329b73fad35e2812a30ce55b9b4d43162471 Author: John Baldwin AuthorDate: 2024-04-14 02:16:13 +0000 Commit: John Baldwin CommitDate: 2024-07-18 17:33:23 +0000 sys: Retire the ISCSI_INITIATOR_DEBUG option This was used by the old iSCSI initiator, not the current one. Reported by: trasz (cherry picked from commit f3f04c4027a71421b38094bb22e3aa4710ddcc38) --- sys/conf/NOTES | 4 ---- sys/conf/options | 3 --- 2 files changed, 7 deletions(-) diff --git a/sys/conf/NOTES b/sys/conf/NOTES index 913b155b0995..2011f8edcc74 100644 --- a/sys/conf/NOTES +++ b/sys/conf/NOTES @@ -1468,10 +1468,6 @@ device cfiscsi # CAM Target Layer iSCSI target frontend device iscsi # iSCSI initiator device iser # iSCSI Extensions for RDMA (iSER) initiator -# Options used in dev/iscsi (Software iSCSI stack) -# -options ISCSI_INITIATOR_DEBUG=9 - ##################################################################### # MISCELLANEOUS DEVICES AND OPTIONS diff --git a/sys/conf/options b/sys/conf/options index afeb4bd83c06..37f09dc7ff3b 100644 --- a/sys/conf/options +++ b/sys/conf/options @@ -416,9 +416,6 @@ ISP_DEFAULT_ROLES opt_isp.h ISP_INTERNAL_TARGET opt_isp.h ISP_FCTAPE_OFF opt_isp.h -# Options used only in dev/iscsi -ISCSI_INITIATOR_DEBUG opt_iscsi_initiator.h - # Net stuff. ACCEPT_FILTER_DATA ACCEPT_FILTER_DNS From nobody Fri Jul 19 16:18:19 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQZbc1LC8z5Rv2t; Fri, 19 Jul 2024 16:18: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQZbc0qsmz53yG; Fri, 19 Jul 2024 16:18:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721405900; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=lNUpqqv/gl+/IkwveGdnV+mH/dgNjdB+KgxPgO0RCtQ=; b=ZRdZ2oOChkDpLyNgWnYG4oY1uY9soMFUmdK6VB8mIyPQ33d66XeXIOD9cuOQXKlA5EoltH V6nYjasM1yTAeVx+V5bKmY5+z7bxdmbuSjDyh+LcgY9N14vvp6WcrkPbw+TLxqoPuGNik5 d4DASSHjZj9/kjPJK302qqvnyd17jB7i9udpinYYCrm50jfdHRKZ/Rr6R/gV2zOa+vA4Qj Y1pTv9snewKEXR01Sol3Iigmtm/g8z8v5gpu+iKbW7EOjtvw30fCA2jXCT224T98kEEvAw Xz/a/INXFWfNo0k2/AtTCkjlychATGM8/8hOptFxfvyI23EhxwnB3gXCihZ1RQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721405900; a=rsa-sha256; cv=none; b=rUaGVVxIDiGLA2i04p4DYNZw8gGQfIfL0QrY8FVkXoXRTrUXSiN0pMr/TXyc8GoVrI9ggF C60eLoBFh26wsxsGHes7mA+SpGnTWHmlHvY3+2X6cbHdxMJIAEHNOqBwrqmCO3HnaFPXuU nj1x0BcVNak0yIDeThXaDzwNi2c6XytrXAm/nkPDRXtYCn3mFnIfzhykKxzTQEVAhB/PFs b+MNuclZDWOTS2bMosPpPSEKQg3NlvK3ftyovcMCmNqcexNVVdfAYralq1EvbZ6LqEcATk vmm6fsUm0qSRVPrqSLXwGM8Z4EG4DYlG/86Vogg145cnlqBPjWarlpYjFt73Vg== 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=1721405900; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=lNUpqqv/gl+/IkwveGdnV+mH/dgNjdB+KgxPgO0RCtQ=; b=TrWUqa9k2Y8LEPFC4u6Yf8uYcz7SC1YnPd8LXtEcTVKRVAJTAqsGC0L3/Ga4+g80FkQxZ3 0PoI4IweX3tCkH0GLdFKQVQuLcxC+E1w5Syz/2XEBDW2U/IqINhHChJqrwMjs8XXlrqWQx 8K8xsMbBNGzUWb29+8UoU4j2CwzHLw7fOPLV64d8xO6lH5QoTSXGdBL0A1SDCFs3tkXqPA Ihxs4MWICdJ6zBX4EWETkrFYgDXM6FvqW7Mch8+RcTiA6Xj1KlWLyQ1rLEGKIvvxm/m/i5 quS38UsUozL6ZbDc7LFnGZVKUrD3I1LEWQAR4QNB6ixzFRt4rokwsaKBs+bA2w== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQZbc0QxRzfw4; Fri, 19 Jul 2024 16:18:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JGIJp8043395; Fri, 19 Jul 2024 16:18:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JGIJFK043392; Fri, 19 Jul 2024 16:18:19 GMT (envelope-from git) Date: Fri, 19 Jul 2024 16:18:19 GMT Message-Id: <202407191618.46JGIJFK043392@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Navdeep Parhar Subject: git: bbc326241d91 - main - cxgbe/t4_tom: Detach the toep from the tcpcb when entering TIME_WAIT. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: bbc326241d91ab2cee2ec2c5c0aa8a906480132f Auto-Submitted: auto-generated The branch main has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=bbc326241d91ab2cee2ec2c5c0aa8a906480132f commit bbc326241d91ab2cee2ec2c5c0aa8a906480132f Author: Navdeep Parhar AuthorDate: 2024-07-17 05:23:33 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-19 16:12:31 +0000 cxgbe/t4_tom: Detach the toep from the tcpcb when entering TIME_WAIT. The kernel used to call tod_pcb_detach when entering TIME_WAIT but that seems to have changed, likely with the TIME_WAIT overhaul in the kernel some time ago. Catch up by having the driver perform the detach. The hardware does not handle TIME_WAIT so it's important to detach and let the kernel arm the 2MSL timer to deal with it. Reported by: Sony Arpita Das @ Chelsio Reviewed by: jhb MFC after: 1 week Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D45990 --- sys/dev/cxgbe/tom/t4_cpl_io.c | 2 ++ sys/dev/cxgbe/tom/t4_tom.c | 2 +- sys/dev/cxgbe/tom/t4_tom.h | 1 + 3 files changed, 4 insertions(+), 1 deletion(-) diff --git a/sys/dev/cxgbe/tom/t4_cpl_io.c b/sys/dev/cxgbe/tom/t4_cpl_io.c index 842e72bf8b2b..cb229d327386 100644 --- a/sys/dev/cxgbe/tom/t4_cpl_io.c +++ b/sys/dev/cxgbe/tom/t4_cpl_io.c @@ -1393,6 +1393,7 @@ do_peer_close(struct sge_iq *iq, const struct rss_header *rss, struct mbuf *m) case TCPS_FIN_WAIT_2: restore_so_proto(so, inp->inp_vflag & INP_IPV6); + t4_pcb_detach(NULL, tp); tcp_twstart(tp); INP_UNLOCK_ASSERT(inp); /* safe, we have a ref on the inp */ NET_EPOCH_EXIT(et); @@ -1454,6 +1455,7 @@ do_close_con_rpl(struct sge_iq *iq, const struct rss_header *rss, switch (tp->t_state) { case TCPS_CLOSING: /* see TCPS_FIN_WAIT_2 in do_peer_close too */ restore_so_proto(so, inp->inp_vflag & INP_IPV6); + t4_pcb_detach(NULL, tp); tcp_twstart(tp); release: INP_UNLOCK_ASSERT(inp); /* safe, we have a ref on the inp */ diff --git a/sys/dev/cxgbe/tom/t4_tom.c b/sys/dev/cxgbe/tom/t4_tom.c index 3fe34c7c01a3..10ee78681365 100644 --- a/sys/dev/cxgbe/tom/t4_tom.c +++ b/sys/dev/cxgbe/tom/t4_tom.c @@ -359,7 +359,7 @@ release_offload_resources(struct toepcb *toep) * Also gets called when an offloaded active open fails and the TOM wants the * kernel to take the TCP PCB back. */ -static void +void t4_pcb_detach(struct toedev *tod __unused, struct tcpcb *tp) { #if defined(KTR) || defined(INVARIANTS) diff --git a/sys/dev/cxgbe/tom/t4_tom.h b/sys/dev/cxgbe/tom/t4_tom.h index 805d8bc0d644..fb74642d61f7 100644 --- a/sys/dev/cxgbe/tom/t4_tom.h +++ b/sys/dev/cxgbe/tom/t4_tom.h @@ -468,6 +468,7 @@ __be32 calc_options2(struct vi_info *, struct conn_params *); uint64_t select_ntuple(struct vi_info *, struct l2t_entry *); int negative_advice(int); int add_tid_to_history(struct adapter *, u_int); +void t4_pcb_detach(struct toedev *, struct tcpcb *); /* t4_connect.c */ void t4_init_connect_cpl_handlers(void); From nobody Fri Jul 19 16:18:21 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQZbd2l9zz5RvGB; Fri, 19 Jul 2024 16:18: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQZbd1mkKz543h; Fri, 19 Jul 2024 16:18:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721405901; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Dk8krFrepggL7ynLKEvNpR4vfu4ETt66pY1d7tSKppw=; b=ULvV0CP/W94+B/+92DjdBcyDzP0l1ZqiH31E83u07j20VG2HlMp9ltZ9BW2eY5HcWvDZLB /iZfsbGmmhwTCus9LLNqfytze1Jl/WeAiXFjbsQtraht5drrWUQ8zLOSN4+cUg96bssJNS ghCCYhihUHefVt0lCKoA8XBtZ3NIFZ2GU4+19gpFXTRdob0wvKT0Eg+XUfKU+1+r5HbUZL WYlfASHcy/fNA9jYs0n0k7VA+L/y4+KX68hgns/8BbhGwd6TVaso5hQHCgXrRX6dtIHVtc 6+9ce3vFPv2XQktegX4JeXnwOMXMLwrQZdaT/3I1zGxsiHYCxsfn4fBjnJ671g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721405901; a=rsa-sha256; cv=none; b=qQnFmN4kkPh2lPtCcfW2YucGc9WEjuQs7eSdMIcXnmpHwb9snj9fu5oDqHtFvNmfbB8+81 FVK/l07L84oTmWR5dCB7JeF7V92V6NR0L3Tpt6tsmYsMmDNZA7BdVutYvvq02PBfEzeM1s QBfRrUmJmp3Fe33FYEnWkQx9L+e2JuMhDjrxsPG4FELum9cg354yvuDz13d9eFuYr1G67T dwpahk1Gyv8suq0lv9Ww4GyDu8DddONBNod2+rR/1LxuH0D0YjgUcx1e8KZe43wYG7IETn /iK8syAwu5k4oIW674mmWjvZ2jmleQJV4l6TIB+T83vu9PJfL/457vvidixKAQ== 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=1721405901; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Dk8krFrepggL7ynLKEvNpR4vfu4ETt66pY1d7tSKppw=; b=a332s6gZZoAelpjazlnwrkjsDtXFhBUaYmrvwD/FPWYziD+g2Y2T4iWGWFWctJ1kR2GMdR rcd6buPGGxu+NCbIoFhXG3VCqKTRjnkJOkOo/U20VW7YLXPmVbnCLbBysjeiXEdhHz4pDt SwGWFPJ2MzG5vF7Y1UXraCsH4wi2r5KSzjcXP+1Vf/eULDUh1yxAN5EyFbKcRYuHx/H/Rd 6MpAsv4MvJRW9Y8kh6pYowK1SKFoVwDZyGy3+hbuHEGgT38cE5MShC0IXJ0NdpadA5bZvj W+KelJW6d688RKfetJ/Oe2qOt3t/lC4PDKPYBXijWGUl7+h0KYy6tkDt0jCUQQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQZbd1P2xzfsx; Fri, 19 Jul 2024 16:18:21 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JGILwN043460; Fri, 19 Jul 2024 16:18:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JGILP3043457; Fri, 19 Jul 2024 16:18:21 GMT (envelope-from git) Date: Fri, 19 Jul 2024 16:18:21 GMT Message-Id: <202407191618.46JGILP3043457@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Navdeep Parhar Subject: git: 27479403a764 - main - cxgbe/t4_tom: Free up hardware resources when the final CPL is received. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 27479403a764cf3b97194887a1f819c1e35357aa Auto-Submitted: auto-generated The branch main has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=27479403a764cf3b97194887a1f819c1e35357aa commit 27479403a764cf3b97194887a1f819c1e35357aa Author: Navdeep Parhar AuthorDate: 2024-07-16 00:39:40 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-19 16:12:36 +0000 cxgbe/t4_tom: Free up hardware resources when the final CPL is received. Final CPL means the tid is done in the hardware and other resources associated with it can be freed right away. There is no need to wait for the kernel to detach the toepcb. Reviewed by: jhb MFC after: 1 week Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D45991 --- sys/dev/cxgbe/tom/t4_tom.c | 58 +++++++++++++++++++++++++++++++--------------- 1 file changed, 39 insertions(+), 19 deletions(-) diff --git a/sys/dev/cxgbe/tom/t4_tom.c b/sys/dev/cxgbe/tom/t4_tom.c index 10ee78681365..645822b6f781 100644 --- a/sys/dev/cxgbe/tom/t4_tom.c +++ b/sys/dev/cxgbe/tom/t4_tom.c @@ -97,6 +97,7 @@ static struct uld_info tom_uld_info = { }; static void release_offload_resources(struct toepcb *); +static void done_with_toepcb(struct toepcb *); static int alloc_tid_tabs(struct tid_info *); static void free_tid_tabs(struct tid_info *); static void free_tom_data(struct adapter *, struct tom_data *); @@ -311,12 +312,42 @@ release_offload_resources(struct toepcb *toep) KASSERT(!(toep->flags & TPF_CPL_PENDING), ("%s: %p has CPL pending.", __func__, toep)); - KASSERT(!(toep->flags & TPF_ATTACHED), - ("%s: %p is still attached.", __func__, toep)); CTR5(KTR_CXGBE, "%s: toep %p (tid %d, l2te %p, ce %p)", __func__, toep, tid, toep->l2te, toep->ce); + if (toep->l2te) { + t4_l2t_release(toep->l2te); + toep->l2te = NULL; + } + if (tid >= 0) { + remove_tid(sc, tid, toep->ce ? 2 : 1); + release_tid(sc, tid, toep->ctrlq); + toep->tid = -1; + } + if (toep->ce) { + t4_release_clip_entry(sc, toep->ce); + toep->ce = NULL; + } + if (toep->params.tc_idx != -1) + t4_release_cl_rl(sc, toep->vi->pi->port_id, toep->params.tc_idx); +} + +/* + * Both the driver and kernel are done with the toepcb. + */ +static void +done_with_toepcb(struct toepcb *toep) +{ + struct tom_data *td = toep->td; + + KASSERT(!(toep->flags & TPF_CPL_PENDING), + ("%s: %p has CPL pending.", __func__, toep)); + KASSERT(!(toep->flags & TPF_ATTACHED), + ("%s: %p is still attached.", __func__, toep)); + + CTR(KTR_CXGBE, "%s: toep %p (0x%x)", __func__, toep, toep->flags); + /* * These queues should have been emptied at approximately the same time * that a normal connection's socket's so_snd would have been purged or @@ -329,20 +360,9 @@ release_offload_resources(struct toepcb *toep) ddp_assert_empty(toep); #endif MPASS(TAILQ_EMPTY(&toep->aiotx_jobq)); - - if (toep->l2te) - t4_l2t_release(toep->l2te); - - if (tid >= 0) { - remove_tid(sc, tid, toep->ce ? 2 : 1); - release_tid(sc, tid, toep->ctrlq); - } - - if (toep->ce) - t4_release_clip_entry(sc, toep->ce); - - if (toep->params.tc_idx != -1) - t4_release_cl_rl(sc, toep->vi->pi->port_id, toep->params.tc_idx); + MPASS(toep->tid == -1); + MPASS(toep->l2te == NULL); + MPASS(toep->ce == NULL); mtx_lock(&td->toep_list_lock); TAILQ_REMOVE(&td->toep_list, toep, link); @@ -392,7 +412,7 @@ t4_pcb_detach(struct toedev *tod __unused, struct tcpcb *tp) toep->flags &= ~TPF_ATTACHED; if (!(toep->flags & TPF_CPL_PENDING)) - release_offload_resources(toep); + done_with_toepcb(toep); } /* @@ -988,9 +1008,9 @@ final_cpl_received(struct toepcb *toep) toep->flags &= ~(TPF_CPL_PENDING | TPF_WAITING_FOR_FINAL); mbufq_drain(&toep->ulp_pduq); mbufq_drain(&toep->ulp_pdu_reclaimq); - + release_offload_resources(toep); if (!(toep->flags & TPF_ATTACHED)) - release_offload_resources(toep); + done_with_toepcb(toep); if (!in_pcbrele_wlocked(inp)) INP_WUNLOCK(inp); From nobody Fri Jul 19 16:18:22 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQZbf5CWWz5RvGC; Fri, 19 Jul 2024 16:18: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQZbf2xz5z53wW; Fri, 19 Jul 2024 16:18:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721405902; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=wIJjVE7vhFn8ZddRWF9oqqtaIKqJ1b2Nb66xYd8HiF8=; b=wDu79q0s8iNgu3WqqYciULa7r2WTfCrmkuE2XBmvdfVTU6kqRVjTnqYBfgbxVpQsxxXDL5 QOuMk6MsmMeDHQABMfynCS9oWzMMsPDr1BFU1ofuB7okjm5hg9wQ+zchQcDMuQwuVBTRAF MeIgMXeD4nnTlGlscwn3j7dukg8AN7ifOP0yjAP+olHaMyKxGFQEiOSt1PO2RUgwvpDZTs wYxOHcECP3n+4016mmugB0/cOJxj8Uvw8sm+ygZfKnOX+ohzWhvrWw84lkvuSp7VCIFvFH xmeASiyxehr9dE3pWtu3KIlhL59X9uJniYKQCzRmr35EI7g0KL+M+Lel/DmUhA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721405902; a=rsa-sha256; cv=none; b=VqndSYLccOFAYojDn35i/ssafb1Gk9j1WpPSLzVztZmqPR4ccZINMuBY81ohiH0rKrOQA0 YKh0q+3CJU24OOyaz1TkfPg4mOdNdmbyUQqG4u10TrRgOOsT3c04gDo4W5mmqOVyu0Kskp 8M1DwJYHW285UlWhtihkoQ3Y5FE4ucp8KO4xuhsKwgCCEJnF6zWCFsWsPpHFaeiJSAe4Rj YsIe9S7Sdpnd8cKjFuzMcETo5C5RimEY/zwEDRQNERUqbLdZj1N5fcoUQmQ5S8Iw4Ylf0U UTO9f59iBZQKqo4kQ3gO0i/93Rp/mrfyMtCXslaZ90EnDZHjF1RRE3enhe0jjA== 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=1721405902; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=wIJjVE7vhFn8ZddRWF9oqqtaIKqJ1b2Nb66xYd8HiF8=; b=tnQvXQdGx7cnRTkQc42mDr2MEfCR1kZZY3Fo0utnfbLYBwIOgIy/cz5BIsRPhTqSPI3q8/ K9C/iDTfEHRBl9hUfCRwndit0eqOcEZ0/jgtTILMjvL6epOSFnMDxW1ypBbZk2GKaxExZA Opqv6c/oWVIRe+UogwlPM0JhIgf4sEQG0tAj8GLlhtnX+v5uz/shCPFUvqaFvO8oKpbaSf RvO999RK6q0bfIgEYhsRiJr3mZ9s11wiQcNex65w53Xlsi6SgtbJmKJBY5GMqPgd+fgRdd aMmxw0fZ23d73dltWbeDPvWkpshJjPCHFQwbNTbXckILfatNh/VBz4ylzaKC6Q== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQZbf2Wwqzfw5; Fri, 19 Jul 2024 16:18:22 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JGIMnn043526; Fri, 19 Jul 2024 16:18:22 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JGIMP2043523; Fri, 19 Jul 2024 16:18:22 GMT (envelope-from git) Date: Fri, 19 Jul 2024 16:18:22 GMT Message-Id: <202407191618.46JGIMP2043523@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Navdeep Parhar Subject: git: cfcfd3c7bf5b - main - cxgbe(4): Make no assumptions about the start and size of the L2T table. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: cfcfd3c7bf5b60da42b13ac5d8085c762613c302 Auto-Submitted: auto-generated The branch main has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=cfcfd3c7bf5b60da42b13ac5d8085c762613c302 commit cfcfd3c7bf5b60da42b13ac5d8085c762613c302 Author: Navdeep Parhar AuthorDate: 2024-07-18 20:16:30 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-19 16:12:46 +0000 cxgbe(4): Make no assumptions about the start and size of the L2T table. Do not assume that the table starts at index 0 and is typically 4K in size. The only thing the driver needs to verify is that its use of F_SYNC_WR doesn't collide with the L2T hwidx range. Reviewed by: jhb MFC after: 1 week Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D46028 --- sys/dev/cxgbe/t4_l2t.c | 17 +++++++++++------ sys/dev/cxgbe/t4_l2t.h | 2 -- sys/dev/cxgbe/t4_main.c | 6 +++--- sys/dev/cxgbe/tom/t4_tom_l2t.c | 21 +++++++++++++-------- 4 files changed, 27 insertions(+), 19 deletions(-) diff --git a/sys/dev/cxgbe/t4_l2t.c b/sys/dev/cxgbe/t4_l2t.c index 005dce826ccb..90f184f5e666 100644 --- a/sys/dev/cxgbe/t4_l2t.c +++ b/sys/dev/cxgbe/t4_l2t.c @@ -369,14 +369,19 @@ int do_l2t_write_rpl(struct sge_iq *iq, const struct rss_header *rss, struct mbuf *m) { + struct adapter *sc = iq->adapter; const struct cpl_l2t_write_rpl *rpl = (const void *)(rss + 1); - unsigned int tid = GET_TID(rpl); - unsigned int idx = tid % L2T_SIZE; + const u_int hwidx = GET_TID(rpl) & ~(F_SYNC_WR | V_TID_QID(M_TID_QID)); + const bool sync = GET_TID(rpl) & F_SYNC_WR; - if (__predict_false(rpl->status != CPL_ERR_NONE)) { - log(LOG_ERR, - "Unexpected L2T_WRITE_RPL (%u) for entry at hw_idx %u\n", - rpl->status, idx); + MPASS(iq->abs_id == G_TID_QID(GET_TID(rpl))); + + if (__predict_false(hwidx < sc->vres.l2t.start) || + __predict_false(hwidx >= sc->vres.l2t.start + sc->vres.l2t.size) || + __predict_false(rpl->status != CPL_ERR_NONE)) { + CH_ERR(sc, "%s: hwidx %u, rpl %u, sync %u; L2T st %u, sz %u\n", + __func__, hwidx, rpl->status, sync, sc->vres.l2t.start, + sc->vres.l2t.size); return (EINVAL); } diff --git a/sys/dev/cxgbe/t4_l2t.h b/sys/dev/cxgbe/t4_l2t.h index 36a41e459a5d..991b4476eb61 100644 --- a/sys/dev/cxgbe/t4_l2t.h +++ b/sys/dev/cxgbe/t4_l2t.h @@ -35,8 +35,6 @@ #define V_SYNC_WR(x) ((x) << S_SYNC_WR) #define F_SYNC_WR V_SYNC_WR(1) -enum { L2T_SIZE = 4096 }; /* # of L2T entries */ - enum { L2T_STATE_VALID, /* entry is up to date */ L2T_STATE_STALE, /* entry may be used but needs revalidation */ diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c index 99400dc9aadb..11dd9e1d24a3 100644 --- a/sys/dev/cxgbe/t4_main.c +++ b/sys/dev/cxgbe/t4_main.c @@ -5262,9 +5262,9 @@ get_params__post_init(struct adapter *sc) } sc->vres.l2t.start = val[4]; sc->vres.l2t.size = val[5] - val[4] + 1; - KASSERT(sc->vres.l2t.size <= L2T_SIZE, - ("%s: L2 table size (%u) larger than expected (%u)", - __func__, sc->vres.l2t.size, L2T_SIZE)); + /* val[5] is the last hwidx and it must not collide with F_SYNC_WR */ + if (sc->vres.l2t.size > 0) + MPASS(fls(val[5]) <= S_SYNC_WR); sc->params.core_vdd = val[6]; param[0] = FW_PARAM_PFVF(IQFLINT_END); diff --git a/sys/dev/cxgbe/tom/t4_tom_l2t.c b/sys/dev/cxgbe/tom/t4_tom_l2t.c index c397196d9cca..ee442f023970 100644 --- a/sys/dev/cxgbe/tom/t4_tom_l2t.c +++ b/sys/dev/cxgbe/tom/t4_tom_l2t.c @@ -318,18 +318,23 @@ do_l2t_write_rpl2(struct sge_iq *iq, const struct rss_header *rss, { struct adapter *sc = iq->adapter; const struct cpl_l2t_write_rpl *rpl = (const void *)(rss + 1); - unsigned int tid = GET_TID(rpl); - unsigned int idx = tid % L2T_SIZE; + const u_int hwidx = GET_TID(rpl) & ~(F_SYNC_WR | V_TID_QID(M_TID_QID)); + const bool sync = GET_TID(rpl) & F_SYNC_WR; - if (__predict_false(rpl->status != CPL_ERR_NONE)) { - log(LOG_ERR, - "Unexpected L2T_WRITE_RPL (%u) for entry at hw_idx %u\n", - rpl->status, idx); + MPASS(iq->abs_id == G_TID_QID(GET_TID(rpl))); + + if (__predict_false(hwidx < sc->vres.l2t.start) || + __predict_false(hwidx >= sc->vres.l2t.start + sc->vres.l2t.size) || + __predict_false(rpl->status != CPL_ERR_NONE)) { + CH_ERR(sc, "%s: hwidx %u, rpl %u, sync %u; L2T st %u, sz %u\n", + __func__, hwidx, rpl->status, sync, sc->vres.l2t.start, + sc->vres.l2t.size); return (EINVAL); } - if (tid & F_SYNC_WR) { - struct l2t_entry *e = &sc->l2t->l2tab[idx - sc->vres.l2t.start]; + if (sync) { + const u_int idx = hwidx - sc->vres.l2t.start; + struct l2t_entry *e = &sc->l2t->l2tab[idx]; mtx_lock(&e->lock); if (e->state != L2T_STATE_SWITCHING) { From nobody Fri Jul 19 16:18:23 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQZbg4yRgz5Rv5h; Fri, 19 Jul 2024 16:18: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQZbg3pl2z53yk; Fri, 19 Jul 2024 16:18:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721405903; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=D5qyeVWPu7e3Xq1BXt73Z2kScpJ1eo/xLd5kxwSpFfw=; b=NnXSEo0jwSvCo4iDG7dZr81QOmKVIg5ctw9YIFU6yxnK1fulCoSQef6KFZ5FIRAScSzcal +wT8WAtwe21O+ymxVvM1lfIQ5f6ZouopomDxNSOt7zn2ZaSQ+cw0Ec6aXta9SdjcvJbQmz OHEj2tQwKQ3qQuQEKstcI+v0vZKpL8rtbqDw2S7HzqLJOC1U32AH8M9krg3Uj5vahS2NGN Vge+WkkCx9AZ8tQxYzmVTm75jqRI1AKwiOezMxn1xQGx2F0/tJbHai0FpvCP5PaY3hO/bj HYoHWHcCnNFAJo7hKy17wIx6Zxf26Whzaf+u78ahzOA7trJEDtUX/wckTbEDDQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721405903; a=rsa-sha256; cv=none; b=p+jyGIq7zvUvJvdHj8Ze8gWoaW3ZtMNwv3Xmnp6/7wmlDtu7Fb3X67Fpi1vnAq+fNnoJu6 nz/+JOBDD6ZU5s6hQQlOk1f+OzzqutLHgvDdPXMmYzcaHkt9dlBE0LvLAHnpTjM8deRbA9 /upMtAjWMCr600NU2heS6PGQbC/EzQvtHfToxdE0p877HDQclMWyEWB77UkQjhLZK4AQoT VLRjQtGssYr1lisuPF+0R8Mxv7g5WWi3egewG+G9s4Xr0wjvh5r2W172lK7yZGNfofvaQK 8LxRM3e34NQrdRXJSbesjmefYVgujMJAuF8nZbachbsE/hAHklMN0GfdwCE1Xg== 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=1721405903; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=D5qyeVWPu7e3Xq1BXt73Z2kScpJ1eo/xLd5kxwSpFfw=; b=mb46bSCuQOzoH9KuDY8x8Dm4QWO9wgAdi8+WYq09bujnzG5H0jlwkNt4HRb7qbiJDIvLqG YZrW6370GNzKn9P5D/JKWMFr4aa9ytFGJ1gypkvWAv0bHTWQRG1E9tm2lKxvQxO4mDzKa/ mF/WjADJIUYUsRy/69l05JIR2th29hzBaS3HxlQMq5eEJBTt8Z3elzESFc5pGYKlsSH/Pc 0MWzABHb/gAzVSszkguY5JLf31FDQr6fNDyc1pBtZyOjc3rXW9UvLSrx8k1jvuMXvpBmcd LbMhtsAgpX7YOFhRtVLCW0XKn6UcTr3F6AF4hzaF+CHmoZRc+F/ImZp6L+7QGg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQZbg3PkNzfsy; Fri, 19 Jul 2024 16:18:23 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JGINwm043579; Fri, 19 Jul 2024 16:18:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JGINg7043575; Fri, 19 Jul 2024 16:18:23 GMT (envelope-from git) Date: Fri, 19 Jul 2024 16:18:23 GMT Message-Id: <202407191618.46JGINg7043575@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Navdeep Parhar Subject: git: cf5e6370f15c - main - cxgbe(4): Changes to ULD list management. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: cf5e6370f15cffabbbf508083ba7d48ec8abfa79 Auto-Submitted: auto-generated The branch main has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=cf5e6370f15cffabbbf508083ba7d48ec8abfa79 commit cf5e6370f15cffabbbf508083ba7d48ec8abfa79 Author: Navdeep Parhar AuthorDate: 2024-07-06 20:43:17 +0000 Commit: Navdeep Parhar CommitDate: 2024-07-19 16:12:49 +0000 cxgbe(4): Changes to ULD list management. * Convert t4_uld_list to an array. There will be at most 3 items in the list and it's simpler to track them in an array with a fixed slot for each ULD. * There is no need to refcount ULDs so stop doing that. * Add uld_ prefix to all members of uld_info. * Rename async_event to uld_stop to match its actual purpose. Call it for all ULDs and not just ULD_IWARP. Reviewed by: jhb MFC after: 1 week Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D46029 --- sys/dev/cxgbe/cxgbei/cxgbei.c | 9 +- sys/dev/cxgbe/iw_cxgbe/device.c | 19 +++-- sys/dev/cxgbe/offload.h | 13 ++- sys/dev/cxgbe/t4_main.c | 177 +++++++++++++++++----------------------- sys/dev/cxgbe/tom/t4_tom.c | 9 +- 5 files changed, 97 insertions(+), 130 deletions(-) diff --git a/sys/dev/cxgbe/cxgbei/cxgbei.c b/sys/dev/cxgbe/cxgbei/cxgbei.c index 193d58f9eda4..04454a98e247 100644 --- a/sys/dev/cxgbe/cxgbei/cxgbei.c +++ b/sys/dev/cxgbe/cxgbei/cxgbei.c @@ -901,9 +901,8 @@ cxgbei_deactivate_all(struct adapter *sc, void *arg __unused) } static struct uld_info cxgbei_uld_info = { - .uld_id = ULD_ISCSI, - .activate = cxgbei_activate, - .deactivate = cxgbei_deactivate, + .uld_activate = cxgbei_activate, + .uld_deactivate = cxgbei_deactivate, }; static int @@ -916,7 +915,7 @@ cxgbei_mod_load(void) t4_register_cpl_handler(CPL_RX_ISCSI_DDP, do_rx_iscsi_ddp); t4_register_cpl_handler(CPL_RX_ISCSI_CMP, do_rx_iscsi_cmp); - rc = t4_register_uld(&cxgbei_uld_info); + rc = t4_register_uld(&cxgbei_uld_info, ULD_ISCSI); if (rc != 0) return (rc); @@ -931,7 +930,7 @@ cxgbei_mod_unload(void) t4_iterate(cxgbei_deactivate_all, NULL); - if (t4_unregister_uld(&cxgbei_uld_info) == EBUSY) + if (t4_unregister_uld(&cxgbei_uld_info, ULD_ISCSI) == EBUSY) return (EBUSY); t4_register_cpl_handler(CPL_ISCSI_HDR, NULL); diff --git a/sys/dev/cxgbe/iw_cxgbe/device.c b/sys/dev/cxgbe/iw_cxgbe/device.c index fa886766e383..28d6d0f2d00c 100644 --- a/sys/dev/cxgbe/iw_cxgbe/device.c +++ b/sys/dev/cxgbe/iw_cxgbe/device.c @@ -259,13 +259,12 @@ static int c4iw_mod_load(void); static int c4iw_mod_unload(void); static int c4iw_activate(struct adapter *); static int c4iw_deactivate(struct adapter *); -static void c4iw_async_event(struct adapter *); +static int c4iw_stop(struct adapter *); static struct uld_info c4iw_uld_info = { - .uld_id = ULD_IWARP, - .activate = c4iw_activate, - .deactivate = c4iw_deactivate, - .async_event = c4iw_async_event, + .uld_activate = c4iw_activate, + .uld_deactivate = c4iw_deactivate, + .uld_stop = c4iw_stop, }; static int @@ -326,8 +325,8 @@ c4iw_deactivate(struct adapter *sc) return (0); } -static void -c4iw_async_event(struct adapter *sc) +static int +c4iw_stop(struct adapter *sc) { struct c4iw_dev *iwsc = sc->iwarp_softc; @@ -341,6 +340,8 @@ c4iw_async_event(struct adapter *sc) event.device = &iwsc->ibdev; ib_dispatch_event(&event); } + + return (0); } static void @@ -379,7 +380,7 @@ c4iw_mod_load(void) if (rc != 0) return (rc); - rc = t4_register_uld(&c4iw_uld_info); + rc = t4_register_uld(&c4iw_uld_info, ULD_IWARP); if (rc != 0) { c4iw_cm_term(); return (rc); @@ -398,7 +399,7 @@ c4iw_mod_unload(void) c4iw_cm_term(); - if (t4_unregister_uld(&c4iw_uld_info) == EBUSY) + if (t4_unregister_uld(&c4iw_uld_info, ULD_IWARP) == EBUSY) return (EBUSY); return (0); diff --git a/sys/dev/cxgbe/offload.h b/sys/dev/cxgbe/offload.h index a8b243b764c8..a55d6f45cabf 100644 --- a/sys/dev/cxgbe/offload.h +++ b/sys/dev/cxgbe/offload.h @@ -209,12 +209,9 @@ enum { struct adapter; struct port_info; struct uld_info { - SLIST_ENTRY(uld_info) link; - int refcount; - int uld_id; - int (*activate)(struct adapter *); - int (*deactivate)(struct adapter *); - void (*async_event)(struct adapter *); + int (*uld_activate)(struct adapter *); + int (*uld_deactivate)(struct adapter *); + int (*uld_stop)(struct adapter *); }; struct tom_tunables { @@ -242,8 +239,8 @@ struct tls_tunables { }; #ifdef TCP_OFFLOAD -int t4_register_uld(struct uld_info *); -int t4_unregister_uld(struct uld_info *); +int t4_register_uld(struct uld_info *, int); +int t4_unregister_uld(struct uld_info *, int); int t4_activate_uld(struct adapter *, int); int t4_deactivate_uld(struct adapter *, int); int uld_active(struct adapter *, int); diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c index 11dd9e1d24a3..9ff56b93a0e6 100644 --- a/sys/dev/cxgbe/t4_main.c +++ b/sys/dev/cxgbe/t4_main.c @@ -263,7 +263,7 @@ static struct sx t4_list_lock; SLIST_HEAD(, adapter) t4_list; #ifdef TCP_OFFLOAD static struct sx t4_uld_list_lock; -SLIST_HEAD(, uld_info) t4_uld_list; +struct uld_info *t4_uld_list[ULD_MAX + 1]; #endif /* @@ -864,7 +864,7 @@ static int release_clip_addr(struct adapter *, struct t4_clip_addr *); #ifdef TCP_OFFLOAD static int toe_capability(struct vi_info *, bool); static int t4_deactivate_all_uld(struct adapter *); -static void t4_async_event(struct adapter *); +static void stop_all_uld(struct adapter *); #endif #ifdef KERN_TLS static int ktls_capability(struct adapter *, bool); @@ -3616,7 +3616,7 @@ fatal_error_task(void *arg, int pending) int rc; #ifdef TCP_OFFLOAD - t4_async_event(sc); + stop_all_uld(sc); #endif if (atomic_testandclear_int(&sc->error_flags, ilog2(ADAP_CIM_ERR))) { dump_cim_regs(sc); @@ -12400,82 +12400,61 @@ toe_capability(struct vi_info *vi, bool enable) * Add an upper layer driver to the global list. */ int -t4_register_uld(struct uld_info *ui) +t4_register_uld(struct uld_info *ui, int id) { - int rc = 0; - struct uld_info *u; + int rc; + if (id < 0 || id > ULD_MAX) + return (EINVAL); sx_xlock(&t4_uld_list_lock); - SLIST_FOREACH(u, &t4_uld_list, link) { - if (u->uld_id == ui->uld_id) { - rc = EEXIST; - goto done; - } + if (t4_uld_list[id] != NULL) + rc = EEXIST; + else { + t4_uld_list[id] = ui; + rc = 0; } - - SLIST_INSERT_HEAD(&t4_uld_list, ui, link); - ui->refcount = 0; -done: sx_xunlock(&t4_uld_list_lock); return (rc); } int -t4_unregister_uld(struct uld_info *ui) +t4_unregister_uld(struct uld_info *ui, int id) { - int rc = EINVAL; - struct uld_info *u; + if (id < 0 || id > ULD_MAX) + return (EINVAL); sx_xlock(&t4_uld_list_lock); - - SLIST_FOREACH(u, &t4_uld_list, link) { - if (u == ui) { - if (ui->refcount > 0) { - rc = EBUSY; - goto done; - } - - SLIST_REMOVE(&t4_uld_list, ui, uld_info, link); - rc = 0; - goto done; - } - } -done: + MPASS(t4_uld_list[id] == ui); + t4_uld_list[id] = NULL; sx_xunlock(&t4_uld_list_lock); - return (rc); + return (0); } int t4_activate_uld(struct adapter *sc, int id) { int rc; - struct uld_info *ui; ASSERT_SYNCHRONIZED_OP(sc); if (id < 0 || id > ULD_MAX) return (EINVAL); - rc = EAGAIN; /* kldoad the module with this ULD and try again. */ - - sx_slock(&t4_uld_list_lock); - SLIST_FOREACH(ui, &t4_uld_list, link) { - if (ui->uld_id == id) { - if (!(sc->flags & FULL_INIT_DONE)) { - rc = adapter_init(sc); - if (rc != 0) - break; - } - - rc = ui->activate(sc); - if (rc == 0) { - setbit(&sc->active_ulds, id); - ui->refcount++; - } - break; - } + /* Adapter needs to be initialized before any ULD can be activated. */ + if (!(sc->flags & FULL_INIT_DONE)) { + rc = adapter_init(sc); + if (rc != 0) + return (rc); } + sx_slock(&t4_uld_list_lock); + if (t4_uld_list[id] == NULL) + rc = EAGAIN; /* load the KLD with this ULD and try again. */ + else { + rc = t4_uld_list[id]->uld_activate(sc); + if (rc == 0) + setbit(&sc->active_ulds, id); + } sx_sunlock(&t4_uld_list_lock); return (rc); @@ -12485,27 +12464,20 @@ int t4_deactivate_uld(struct adapter *sc, int id) { int rc; - struct uld_info *ui; ASSERT_SYNCHRONIZED_OP(sc); if (id < 0 || id > ULD_MAX) return (EINVAL); - rc = ENXIO; sx_slock(&t4_uld_list_lock); - - SLIST_FOREACH(ui, &t4_uld_list, link) { - if (ui->uld_id == id) { - rc = ui->deactivate(sc); - if (rc == 0) { - clrbit(&sc->active_ulds, id); - ui->refcount--; - } - break; - } + if (t4_uld_list[id] == NULL) + rc = ENXIO; + else { + rc = t4_uld_list[id]->uld_deactivate(sc); + if (rc == 0) + clrbit(&sc->active_ulds, id); } - sx_sunlock(&t4_uld_list_lock); return (rc); @@ -12514,25 +12486,20 @@ t4_deactivate_uld(struct adapter *sc, int id) static int t4_deactivate_all_uld(struct adapter *sc) { - int rc; - struct uld_info *ui; + int i, rc; rc = begin_synchronized_op(sc, NULL, SLEEP_OK, "t4detuld"); if (rc != 0) return (ENXIO); - sx_slock(&t4_uld_list_lock); - - SLIST_FOREACH(ui, &t4_uld_list, link) { - if (isset(&sc->active_ulds, ui->uld_id)) { - rc = ui->deactivate(sc); - if (rc != 0) - break; - clrbit(&sc->active_ulds, ui->uld_id); - ui->refcount--; - } + for (i = 0; i <= ULD_MAX; i++) { + if (t4_uld_list[i] == NULL || !uld_active(sc, i)) + continue; + rc = t4_uld_list[i]->uld_deactivate(sc); + if (rc != 0) + break; + clrbit(&sc->active_ulds, i); } - sx_sunlock(&t4_uld_list_lock); end_synchronized_op(sc, 0); @@ -12540,30 +12507,30 @@ t4_deactivate_all_uld(struct adapter *sc) } static void -t4_async_event(struct adapter *sc) +stop_all_uld(struct adapter *sc) { - struct uld_info *ui; + int i; - if (begin_synchronized_op(sc, NULL, SLEEP_OK | INTR_OK, "t4async") != 0) + if (begin_synchronized_op(sc, NULL, SLEEP_OK | INTR_OK, "t4uldst") != 0) return; sx_slock(&t4_uld_list_lock); - SLIST_FOREACH(ui, &t4_uld_list, link) { - if (ui->uld_id == ULD_IWARP) { - ui->async_event(sc); - break; - } + for (i = 0; i <= ULD_MAX; i++) { + if (t4_uld_list[i] == NULL || !uld_active(sc, i) || + t4_uld_list[i]->uld_stop == NULL) + continue; + (void) t4_uld_list[i]->uld_stop(sc); } sx_sunlock(&t4_uld_list_lock); end_synchronized_op(sc, 0); } int -uld_active(struct adapter *sc, int uld_id) +uld_active(struct adapter *sc, int id) { - MPASS(uld_id >= 0 && uld_id <= ULD_MAX); + MPASS(id >= 0 && id <= ULD_MAX); - return (isset(&sc->active_ulds, uld_id)); + return (isset(&sc->active_ulds, id)); } #endif @@ -13111,7 +13078,6 @@ mod_event(module_t mod, int cmd, void *arg) callout_init(&fatal_callout, 1); #ifdef TCP_OFFLOAD sx_init(&t4_uld_list_lock, "T4/T5 ULDs"); - SLIST_INIT(&t4_uld_list); #endif #ifdef INET6 t4_clip_modload(); @@ -13140,9 +13106,20 @@ mod_event(module_t mod, int cmd, void *arg) case MOD_UNLOAD: sx_xlock(&mlu); if (--loaded == 0) { +#ifdef TCP_OFFLOAD + int i; +#endif int tries; taskqueue_free(reset_tq); + + tries = 0; + while (tries++ < 5 && t4_sge_extfree_refs() != 0) { + uprintf("%ju clusters with custom free routine " + "still is use.\n", t4_sge_extfree_refs()); + pause("t4unload", 2 * hz); + } + sx_slock(&t4_list_lock); if (!SLIST_EMPTY(&t4_list)) { rc = EBUSY; @@ -13151,20 +13128,14 @@ mod_event(module_t mod, int cmd, void *arg) } #ifdef TCP_OFFLOAD sx_slock(&t4_uld_list_lock); - if (!SLIST_EMPTY(&t4_uld_list)) { - rc = EBUSY; - sx_sunlock(&t4_uld_list_lock); - sx_sunlock(&t4_list_lock); - goto done_unload; - } -#endif - tries = 0; - while (tries++ < 5 && t4_sge_extfree_refs() != 0) { - uprintf("%ju clusters with custom free routine " - "still is use.\n", t4_sge_extfree_refs()); - pause("t4unload", 2 * hz); + for (i = 0; i <= ULD_MAX; i++) { + if (t4_uld_list[i] != NULL) { + rc = EBUSY; + sx_sunlock(&t4_uld_list_lock); + sx_sunlock(&t4_list_lock); + goto done_unload; + } } -#ifdef TCP_OFFLOAD sx_sunlock(&t4_uld_list_lock); #endif sx_sunlock(&t4_list_lock); diff --git a/sys/dev/cxgbe/tom/t4_tom.c b/sys/dev/cxgbe/tom/t4_tom.c index 645822b6f781..f9d8dcd706b7 100644 --- a/sys/dev/cxgbe/tom/t4_tom.c +++ b/sys/dev/cxgbe/tom/t4_tom.c @@ -91,9 +91,8 @@ static int t4_tom_activate(struct adapter *); static int t4_tom_deactivate(struct adapter *); static struct uld_info tom_uld_info = { - .uld_id = ULD_TOM, - .activate = t4_tom_activate, - .deactivate = t4_tom_deactivate, + .uld_activate = t4_tom_activate, + .uld_deactivate = t4_tom_deactivate, }; static void release_offload_resources(struct toepcb *); @@ -2013,7 +2012,7 @@ t4_tom_mod_load(void) toe6_protosw.pr_ctloutput = t4_ctloutput_tom; toe6_protosw.pr_aio_queue = t4_aio_queue_tom; - return (t4_register_uld(&tom_uld_info)); + return (t4_register_uld(&tom_uld_info, ULD_TOM)); } static void @@ -2034,7 +2033,7 @@ t4_tom_mod_unload(void) { t4_iterate(tom_uninit, NULL); - if (t4_unregister_uld(&tom_uld_info) == EBUSY) + if (t4_unregister_uld(&tom_uld_info, ULD_TOM) == EBUSY) return (EBUSY); t4_tls_mod_unload(); From nobody Fri Jul 19 17:07:40 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQbhY1mfqz5RyxD; Fri, 19 Jul 2024 17:07: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQbhX4tyHz596n; Fri, 19 Jul 2024 17:07:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721408860; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=aLoOq2wL7OGLh3uJ2HpfmAR9WZqcAo0SjDCSbIiOPH4=; b=UC0broSu9PF+5zGIaZnQs68J/X7jYpyfKwqMwwiQHA2P6C3Q5mkIcgxShP2npyU5a9A0+p TuJ/JZUxOQq1HL1SYAyMTvP2k08dx0OBzgYhLQaWM5wp6TsAyVLlbIq4v2NdENOie5P5aM 018n6/6IIUMgS2DIIRwd5npGROVpVj9sYbF9Uxuwhjiy/Dk2wjYtwibm9yA6sRG34LYZb3 BkTd14Gvc0eAJsSmhnr6+UCVA19K1Eg0nEWPnf+y865gg6eEIa1jW8ROmrAgTtLDbG4jmq hoqokZ7HbEYs+CmKTxCGP9OORik5SojHlUEcx2N5Ksu9+gihLRZ8uWvilwMEVA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721408860; a=rsa-sha256; cv=none; b=LCi107DOzZQdgjy+XWdJBGDQRnmpRDHkh7becBrct5S8ceXc8uefrXK8lC9XdJElTz/GXD azsIPKJnvPQgTnWe54xXIKUeH9Dke/xjWaEXfFv52Z09uOPHa9u769H7JMgBXf25CuMBR1 TuSb0biCfHqIXLpQrZ3YXntzONUsTybXiX1G60PktB8mSTS+QOLIABcaFfXWctSkF6GDTw Chs3/S9ljc1csaOeIPD7sMTvPj7vwiiMSlrMVYa9qblZSqMQYvvIYxzPIoL2+uvJhwp1Jp VO/RiY29RPQAjrPn33Zpko8oBFtylR6jxCOhLpiTF+lwZKfygrJ6AWNnAHReUg== 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=1721408860; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=aLoOq2wL7OGLh3uJ2HpfmAR9WZqcAo0SjDCSbIiOPH4=; b=KmNXuqMun30NTFTpSYCPQFP5xSku3InSjtw5fBssSSWrp5Y2RGupJW3ebF2R7kwetBn98M 9tUr+Qw3UXXfNuIPRTpmmFajHYiwNEmyUCLTIxBv9PyhdrXj/zNEz12LzdPU3joB5/V2hv iN5gz+N7clgokRP5W1SUj/EnckyK0JGP0rzgoQrX2JypYfR86caxpv7jVW8Y7tRhIOkoBA KRoQ1mi7snL4VrYPrDjly2jpAqUL+F4GtFTUCUm9XEqN1ZrF4NO/vqJVhxgEmI8z4uVDCI YI2RgPxQ6BE12KmFKe/e01s2neI6UvANV3o5Mo1+iQJKJa56D7XWt49DV4OJlQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQbhX4VNrzgbG; Fri, 19 Jul 2024 17:07:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JH7eO6027723; Fri, 19 Jul 2024 17:07:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JH7eLD027720; Fri, 19 Jul 2024 17:07:40 GMT (envelope-from git) Date: Fri, 19 Jul 2024 17:07:40 GMT Message-Id: <202407191707.46JH7eLD027720@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 680f40f38343 - main - stdatomic: Only use clang atomics if __clang__ is defined List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 680f40f38343de118d5b973129683804e496faaf Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=680f40f38343de118d5b973129683804e496faaf commit 680f40f38343de118d5b973129683804e496faaf Author: John Baldwin AuthorDate: 2024-07-19 17:01:07 +0000 Commit: John Baldwin CommitDate: 2024-07-19 17:05:52 +0000 stdatomic: Only use clang atomics if __clang__ is defined GCC 14 defines __has_extension(c_atomic) but does not support __c11_atomic_*, so require __clang__ for the CLANG_ATOMICS case. Reviewed by: imp, emaste Differential Revision: https://reviews.freebsd.org/D46001 --- sys/sys/stdatomic.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sys/sys/stdatomic.h b/sys/sys/stdatomic.h index e05606b1ead8..099097ea84a4 100644 --- a/sys/sys/stdatomic.h +++ b/sys/sys/stdatomic.h @@ -33,7 +33,8 @@ #include #include -#if __has_extension(c_atomic) || __has_extension(cxx_atomic) +#if (__has_extension(c_atomic) || __has_extension(cxx_atomic)) && \ + defined(__clang__) #define __CLANG_ATOMICS #elif __GNUC_PREREQ__(4, 7) #define __GNUC_ATOMICS From nobody Fri Jul 19 17:07:41 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQbhY6r9Lz5Rygx; Fri, 19 Jul 2024 17:07: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQbhY5dlyz58yn; Fri, 19 Jul 2024 17:07:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721408861; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=F7ZH/srApOwo4hSPiJ87MpKTbc/LH1orL4W7OoQZ1UI=; b=YPYSNOCLUQEoIWak+24xRmdazp82VlYYfmtZ5uGaSa9XKzXLAIsBgzLHUOnpwnF7fNRney H9wV877gl1nENCisLsDhSfbGNrSPcwp/6Nk7fljcdh35xTT7922dgLO9hBB7mYOEpKbcWa 01cRU2ybBGl/Yg6ZzDL2zL1kPk7dPgLbwi1Pz0tujx6uMVN7eop6tVxrb3tGnXaN8Lhqqe mUkuspColrKjMIczhZiD6XKhcY6lftW2JXbBL1xM+rVZO83JE7/vPRvO5dfZOUiDnH+KCP k+/L3zghIBXUJPijCqkGaSLrbiURIk1q96DeMcseVSueSO+5gbsbJUH7B+z3Mg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721408861; a=rsa-sha256; cv=none; b=pU/gu7mW12uQOzOTmhHLdnTdB1QnFpNDjX9lXhfOoCuDpWNHnlvTS+b5uiqMyX8fAjQcMd EmBA2AeA0LxKfro5V9EBUQ6W7QpDqrQzP5lNPrXXsiY0l4Tpi0ttuoTwKSGFEpOqcaeMZM aYOFKqegZAWlzCMJErZmpJ6HNvGD83j6i1QoayN+EML4h5a/5qi6Uy52GjUCGVJleS9a08 xkmifoWFzGEy1DF0EShy8nZ2yq8H40XDH7vV5lP1SeM23NQoUAEiTNFJqvTznFfhGRHKlz 0vwozwCj3IWDHidAttZBDKDCPl+Vduh9ipaBsSJvOTtMGAYslHOQz24Mdkkfnw== 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=1721408861; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=F7ZH/srApOwo4hSPiJ87MpKTbc/LH1orL4W7OoQZ1UI=; b=Jye0z3waQCun7zvknGFKizt2ZoBm4r575JnVrxEDMCfKRzcKWdWXofwpVxFuYwEGdPtC9h 7wwiLe0Lafe6lZqvxieXxIcn9mSjL5Q6H1Eq/S9OxfYQa7RTiIWeHfwZvRg/6n1g2BlAxf BGYMEJwBmdCTvJAk3zo2UUzpoOdAx2fwqIj9AWTjctuDjtezQb5ufUi07OWr2FS5Ej1lvS LXuiosCm9dMk2tmq9OZHneMuvJYnXkkzDMguPIktxcpINubwTQWlI7ALGDoJdpBEVS/TEz BpKrN432wX2f2wAs/rOzhQdDPoxSQB69JzLnkGrJpAO5HHOO5Dxqfkybzx0Vfg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQbhY572zzgn4; Fri, 19 Jul 2024 17:07:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JH7fLs027783; Fri, 19 Jul 2024 17:07:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JH7f21027780; Fri, 19 Jul 2024 17:07:41 GMT (envelope-from git) Date: Fri, 19 Jul 2024 17:07:41 GMT Message-Id: <202407191707.46JH7f21027780@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 5275d1ddb42d - main - libcasper: Consistently use item count as the first argument to calloc List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 5275d1ddb42dc70fb87925e59445059068c08271 Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=5275d1ddb42dc70fb87925e59445059068c08271 commit 5275d1ddb42dc70fb87925e59445059068c08271 Author: John Baldwin AuthorDate: 2024-07-19 17:01:40 +0000 Commit: John Baldwin CommitDate: 2024-07-19 17:05:58 +0000 libcasper: Consistently use item count as the first argument to calloc Reported by: GCC 14 -Wcalloc-transposed-args Reviewed by: rlibby, emaste Differential Revision: https://reviews.freebsd.org/D46005 --- lib/libcasper/services/cap_dns/cap_dns.c | 4 ++-- lib/libcasper/services/cap_net/cap_net.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/libcasper/services/cap_dns/cap_dns.c b/lib/libcasper/services/cap_dns/cap_dns.c index 8548715a6978..32cbf973ad45 100644 --- a/lib/libcasper/services/cap_dns/cap_dns.c +++ b/lib/libcasper/services/cap_dns/cap_dns.c @@ -85,7 +85,7 @@ hostent_unpack(const nvlist_t *nvl, struct hostent *hp) hp->h_length = (int)nvlist_get_number(nvl, "length"); nitems = (unsigned int)nvlist_get_number(nvl, "naliases"); - hp->h_aliases = calloc(sizeof(hp->h_aliases[0]), nitems + 1); + hp->h_aliases = calloc(nitems + 1, sizeof(hp->h_aliases[0])); if (hp->h_aliases == NULL) goto fail; for (ii = 0; ii < nitems; ii++) { @@ -99,7 +99,7 @@ hostent_unpack(const nvlist_t *nvl, struct hostent *hp) hp->h_aliases[ii] = NULL; nitems = (unsigned int)nvlist_get_number(nvl, "naddrs"); - hp->h_addr_list = calloc(sizeof(hp->h_addr_list[0]), nitems + 1); + hp->h_addr_list = calloc(nitems + 1, sizeof(hp->h_addr_list[0])); if (hp->h_addr_list == NULL) goto fail; for (ii = 0; ii < nitems; ii++) { diff --git a/lib/libcasper/services/cap_net/cap_net.c b/lib/libcasper/services/cap_net/cap_net.c index a8f039f81843..40d18319ae28 100644 --- a/lib/libcasper/services/cap_net/cap_net.c +++ b/lib/libcasper/services/cap_net/cap_net.c @@ -105,7 +105,7 @@ hostent_unpack(const nvlist_t *nvl, struct hostent *hp) hp->h_length = (int)nvlist_get_number(nvl, "length"); nitems = (unsigned int)nvlist_get_number(nvl, "naliases"); - hp->h_aliases = calloc(sizeof(hp->h_aliases[0]), nitems + 1); + hp->h_aliases = calloc(nitems + 1, sizeof(hp->h_aliases[0])); if (hp->h_aliases == NULL) goto fail; for (ii = 0; ii < nitems; ii++) { @@ -119,7 +119,7 @@ hostent_unpack(const nvlist_t *nvl, struct hostent *hp) hp->h_aliases[ii] = NULL; nitems = (unsigned int)nvlist_get_number(nvl, "naddrs"); - hp->h_addr_list = calloc(sizeof(hp->h_addr_list[0]), nitems + 1); + hp->h_addr_list = calloc(nitems + 1, sizeof(hp->h_addr_list[0])); if (hp->h_addr_list == NULL) goto fail; for (ii = 0; ii < nitems; ii++) { From nobody Fri Jul 19 17:07:42 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQbhb11Myz5RykV; Fri, 19 Jul 2024 17:07: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQbhZ6ZfDz58yq; Fri, 19 Jul 2024 17:07:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721408862; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=3QZqmAUg7NBxoSUxTzRpHe/06ig2uD6BYFbpw4SH3yk=; b=er0yOKchBIrJGixP1l6cH+8FNVqdFIglkyuopUrwkEzlSafkyVg0t77hamDk8umVRsj3qN gXN+jcV1ZFKT0/1K33NxQ2lL/fV2llSPw1mPucziihUggtsN5I1iD4dxn0FmaSca30dLJb nmjzKKKIXeTvk27ZzVTKVE7L0MGREJMp9ocQJ/KtdESZ3Zl6K3cz0+pxvep1z3NOx148KI wPrFpTldUnnzpNSkEe3T2QN0+VGj3t3s5+/DOf8/QN3dw67yi8kaP7jdjJ5yBVnQ/XTBi1 EElwgFbuNpW1C6SBauVebhwt4+rADXx+oZl98Swgc73+I0bTsoVAAbVdrfA8RQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721408862; a=rsa-sha256; cv=none; b=Wwhc49hD9M4zlTG7ywyQr5rfffRy0wG3Xv6WDe59SIhxc1zIBU/U0DLZDnc2YmL5bIZ4Hm uUe2z1va6+JhMzj/C76e3x9sCLFkGc9TCY1Brwiv2fAvLXdx89j+WdblPUrFYj4/qEEWD/ 6droCsoW+ac2gQIjLVpj3aebwVPPEoZY8n5VWQzFSPh3nATPBzC6Cy5OYzbUTAXAUsWUpH h00ASxQd+G+NT22XIk6uK3GKqYhdJW8mEqWbsxT8QeRfl9t3w294723p0SS0QNaLwZS8ur EZLwMI3f1Vllk6ZLDLkuujUTacwWIOVBXq+tBIDWBcJ/TEiSWs7OqJgjOTrIUg== 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=1721408862; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=3QZqmAUg7NBxoSUxTzRpHe/06ig2uD6BYFbpw4SH3yk=; b=lwtaJytoLKO3CbuHRFuQmU6uMiAfHHmUo7AQ0WK6Zjuyq4JLhB5O9XN0L0JoDsZNlVmoHH N84qygsYtx2AOkfx88E5J83NfHgK1NNfey40rvz3DuKGR4Q2TMANSkA2+UR/BjFLv5naG9 rZQtNw0KzYf029RGi/LXmlRBZm2Gb875rgq+xtfyy5cEOuPkDRKXueu4DxpBzWbzUT49pu pfwiKkfwc4+QG6nBWfhAPIVFmHK498ab5Usa+aHoI/VuNNjJWPOkOYNGLzavVokP7WCIhE HdAHMe9pDq6qK2deH68hFZbCIPVX7PFn0Y3jD2AVnmcXTlusH8fAUEbybP9naw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQbhZ6BcTzgbH; Fri, 19 Jul 2024 17:07:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JH7gNO027844; Fri, 19 Jul 2024 17:07:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JH7gDF027841; Fri, 19 Jul 2024 17:07:42 GMT (envelope-from git) Date: Fri, 19 Jul 2024 17:07:42 GMT Message-Id: <202407191707.46JH7gDF027841@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: bf3b889a5be1 - main - libgeom: Consistently use item count as the first argument to calloc List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: bf3b889a5be141f3abadcfc5a1d1cbdc50273d72 Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=bf3b889a5be141f3abadcfc5a1d1cbdc50273d72 commit bf3b889a5be141f3abadcfc5a1d1cbdc50273d72 Author: John Baldwin AuthorDate: 2024-07-19 17:02:05 +0000 Commit: John Baldwin CommitDate: 2024-07-19 17:06:03 +0000 libgeom: Consistently use item count as the first argument to calloc Reported by: GCC 14 -Wcalloc-transposed-args Reviewed by: rlibby, imp, emaste Differential Revision: https://reviews.freebsd.org/D46006 --- lib/libgeom/geom_xml2tree.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/libgeom/geom_xml2tree.c b/lib/libgeom/geom_xml2tree.c index 49cbb0385770..2d2c43e29e77 100644 --- a/lib/libgeom/geom_xml2tree.c +++ b/lib/libgeom/geom_xml2tree.c @@ -407,7 +407,7 @@ geom_xml2tree(struct gmesh *gmp, char *p) free(mt); return (error); } - gmp->lg_ident = calloc(sizeof *gmp->lg_ident, mt->nident + 1); + gmp->lg_ident = calloc(mt->nident + 1, sizeof(*gmp->lg_ident)); free(mt); if (gmp->lg_ident == NULL) return (ENOMEM); From nobody Fri Jul 19 17:07:43 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQbhc2Cnqz5Ryq9; Fri, 19 Jul 2024 17:07: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQbhc12dRz599d; Fri, 19 Jul 2024 17: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=1721408864; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=1iL4wUt93cP1xflFPpAo2QryrgRutkd728SKvKsdx+A=; b=UKhYpd05vkxSw/QzviAg8X74ntrO6kYLGFfQuDDxsMJbkUXOkipllpMgqgcStnjKyLpGaj vT2+UQI8CXGYd+pEXxdIWgmYw6vh01HMfRZVxsQxDpCzRUU3IjFERCafVDSG1bXx22mmYn 0k4RFdXF65pVPN1EDEgQSaHV4dP8Nrunii2LHYs6Ho7hNli7fj8pqOrIlmDpT9/gjKbxMR TjQA9o3UFciFZy4MK3Mst5rtOswlQQcNCNKnIeChsfqC9HuizNXTgNxbt7SdhIgjvgsesU u+ECkq9k1TMAVa6Rg3pjDtFwaQrUVh44VrdbJcH/P722r23LIb0RKYeML9et8g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721408864; a=rsa-sha256; cv=none; b=IfNmbDaIxd69Qh5y7774IPaXahzcwZ1wx0mc2mHVXzsiRcuk9wXoTraq+nyXqOuFjeRfjY YA6KL8jXiHtlQBFIfWwE8Dyt6NLbC8TeXimZJht1KUZgpK7hYtB592Mh58/+gLC94R+HHt OMlmDUAcJDJoxtVykiMAdVze3TfWfve7Fx/WIfoyRLUrge3PPiYbceI1PzRkrSXuGalS83 PNvcsGO0VlQgFgeNuqev/ZJHmbt/l34298yrdvDSdUD+bSj8fS73ckAam90ek13roWUL4H ekX30iaZRXFQJOieK51l+AdBGngup74xUzePGCAzpkaS/O2dXvxc9mF0Y6eONA== 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=1721408864; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=1iL4wUt93cP1xflFPpAo2QryrgRutkd728SKvKsdx+A=; b=mLPROCHueijk1Qecp3V9kSz8ob0gvRlWfr0vV3FwdTfHddZ/xMwL4zbBTvvyyAkjtUrM6L BpciK0XKVoE4krBYRRThmmjNzs+AgX3ilSD42RWTPUiOaYB+TpsQ5HrNi66HZTbsF2LWIe jrRxrIczZ3ZBARi1o0+O+3xrH7eLqu/lrv5agogxJjg1Q+w2HzMtvhgHxuzhTDjp6uPKMR GuUlGbTRBeMo8bWdYVK3wR50FbtkI4+dR1MiHmKFDm3Y1LDDt+5QTqadBuFIZtPr/Nj2Gl tY/BrUrTzeqMdObU1lJnABtpuwI+mMySItvxOSVGMA6abu4qv4uLN7tH+Tj5Kw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQbhc07v3zgPd; Fri, 19 Jul 2024 17:07:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JH7hhN027912; Fri, 19 Jul 2024 17:07:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JH7hY2027909; Fri, 19 Jul 2024 17:07:43 GMT (envelope-from git) Date: Fri, 19 Jul 2024 17:07:43 GMT Message-Id: <202407191707.46JH7hY2027909@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: b73445a32f8a - main - elftoolchain: Consistently use item count as the first argument to calloc List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: b73445a32f8a3648372c0042ef633fe61b38d135 Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=b73445a32f8a3648372c0042ef633fe61b38d135 commit b73445a32f8a3648372c0042ef633fe61b38d135 Author: John Baldwin AuthorDate: 2024-07-19 17:02:45 +0000 Commit: John Baldwin CommitDate: 2024-07-19 17:06:11 +0000 elftoolchain: Consistently use item count as the first argument to calloc Reported by: GCC 14 -Wcalloc-transposed-args Reviewed by: rlibby, emaste Differential Revision: https://reviews.freebsd.org/D46007 --- contrib/elftoolchain/libdwarf/libdwarf_init.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/elftoolchain/libdwarf/libdwarf_init.c b/contrib/elftoolchain/libdwarf/libdwarf_init.c index b85c87c59af0..95ed6147ba89 100644 --- a/contrib/elftoolchain/libdwarf/libdwarf_init.c +++ b/contrib/elftoolchain/libdwarf/libdwarf_init.c @@ -302,7 +302,7 @@ _dwarf_alloc(Dwarf_Debug *ret_dbg, int mode, Dwarf_Error *error) { Dwarf_Debug dbg; - if ((dbg = calloc(sizeof(struct _Dwarf_Debug), 1)) == NULL) { + if ((dbg = calloc(1, sizeof(struct _Dwarf_Debug))) == NULL) { DWARF_SET_ERROR(dbg, error, DW_DLE_MEMORY); return (DW_DLE_MEMORY); } From nobody Fri Jul 19 17:07:45 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQbhd2R0rz5RyxJ; Fri, 19 Jul 2024 17: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQbhd1cFKz59JX; Fri, 19 Jul 2024 17:07:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721408865; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VBwiIp8lA5woHwsh7XM1XMpjioIcbFZ9Jp8XJtFnm7w=; b=P3dktwt3FIQWMEvpq4YhbGo+YuB6G1JJ5XtGavO3R4N27FgsD5Nl7o1TCc+/PqXWdRH3wm /cUjjrc7/urZQI3PX1KxV1ody9VoDEereCtIejfKfXS+XRSGhz32Iy9sq6V31vltsiIN+/ 8Y183EXr2r5bvJKVG9W9gNDpB28iUtmQywn8EkkRqN3hO99NtNRpaGlQTCwzbpteawqViR sJ5W50KBIy9CwhpT/nGz9vfqkC7sOsEsUBJPCGQW+s91niwORe70wvkF9fVCBR46mvmZ3e PChjvDExLjAgUXt2M5lP/IQFfaIIov7pvsNM1NXm1+nQXdj7CHlsUlyY5qsaOA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721408865; a=rsa-sha256; cv=none; b=WBaOAod/E99ylzycz3zttPVFVF8u8cKC7LFAoE9qia9akEn4STnUEqPFV1h+L3TVjpBd44 sPnHLgtFebG2y3MqzHW7r/owLG9+s0ACn+I258yFcRBHogu0+TG80bZV6a/NS6liq9FCCa 6hq696w4SL9fMEdmCYNfP/xszUxE74VQjhG+WQy93LMnwaCpF7ZygoroK0UxpA14ypcRAZ pe9NtwfsWZdfZOLQO4xjEn/I1++Is3wUo3cWAbJo39enr/PxGkjf9IYVO52QIj6RLQtuvd TsZoNpIN4weZsIJEcTjtCTTMZG4kxH+iwbDb2/77yP3WlUjxjdOCPif9ssjfPw== 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=1721408865; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VBwiIp8lA5woHwsh7XM1XMpjioIcbFZ9Jp8XJtFnm7w=; b=RqccIh43dFqkGkn/pSlmMmsa7QEZySG7Vw0urRSDke80v3jYu6+wx1SYIRqJIhpjB2zpDN uEw4ilo3oq6ImufFtLcuQkuOMMrTjEH36S3CxN98eWnzS1bhMClMVBZvVpSWbpyUznGblr 8QDkWbf8tywzt9u0ODOj2zgGMNpQl7QVSKyi5Rci/16ZqpBUnc7SECPUQgZTlAY6QMCxvv EiuopLR/2Os2/a66WyNNiIjX3E8LjM7WpCCauUF/RUL+rMesYdYmDYYpJawGaf4M8jw8Ne hhhSnU3BmsNrmHMTNuV6RW3PVN8Ti9/TiyGyftyNwUAK5KkARdo8+D99L9mcvw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQbhd1BZKzgn5; Fri, 19 Jul 2024 17:07:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JH7jKM027973; Fri, 19 Jul 2024 17:07:45 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JH7jMU027970; Fri, 19 Jul 2024 17:07:45 GMT (envelope-from git) Date: Fri, 19 Jul 2024 17:07:45 GMT Message-Id: <202407191707.46JH7jMU027970@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 8aadd10a65b1 - main - lib80211: Consistently use item count as the first argument to calloc List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 8aadd10a65b11f18950118a10569233e1420ab45 Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=8aadd10a65b11f18950118a10569233e1420ab45 commit 8aadd10a65b11f18950118a10569233e1420ab45 Author: John Baldwin AuthorDate: 2024-07-19 17:03:19 +0000 Commit: John Baldwin CommitDate: 2024-07-19 17:06:16 +0000 lib80211: Consistently use item count as the first argument to calloc Reported by: GCC 14 -Wcalloc-transposed-args Reviewed by: rlibby, emaste Differential Revision: https://reviews.freebsd.org/D46008 --- lib/lib80211/lib80211_regdomain.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/lib80211/lib80211_regdomain.c b/lib/lib80211/lib80211_regdomain.c index 189d4661c78b..db353a69f4d9 100644 --- a/lib/lib80211/lib80211_regdomain.c +++ b/lib/lib80211/lib80211_regdomain.c @@ -441,7 +441,7 @@ lib80211_regdomain_readconfig(struct regdata *rdp, const void *p, size_t len) XML_ParserFree(mt->parser); /* setup the identifer table */ - rdp->ident = calloc(sizeof(struct ident), mt->nident + 1); + rdp->ident = calloc(mt->nident + 1, sizeof(struct ident)); if (rdp->ident == NULL) return ENOMEM; free(mt); From nobody Fri Jul 19 17:07:46 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQbhf3llrz5Ryrh; Fri, 19 Jul 2024 17:07: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQbhf2Hcgz59D2; Fri, 19 Jul 2024 17:07:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721408866; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ShRZt0ik8woeQlGTGpr8VFKgffgYK+hYm3Ir44/KjFQ=; b=UoY3l+X/LQoaK0u1LNmSMajixM5XmHjF/9MTX/vk8tpdD4Lft6BBic/cSrD6INbzeYCij3 6K59pCb3fGplh32ipy2pMHaGTIS/xIYXr/6a9Zaix3wqdawOFX1V4ddb7lyMYgC8nhb5M1 FN8Rv6KeV0AvsMFWKut/EX8mT6otSgWme0rHQggm2hFH8arkbWiA90RTltWV4qr1oG0ifT jdMn0v5ujd/H0zmMP1fhcjviy15RVFYnbaaUGGntYPMBoadmYtUW/GfkzF8gE0CklfC6N2 M/LSa9QSdY8rHagJzyynTL5jT9Ei6eCXJH+jrkL+l9QQrxbWQ503BhWi7g7Img== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721408866; a=rsa-sha256; cv=none; b=vcLPycj+rTmBXKzKZTBGcaShTc7embdRw+nAmIO1p6G7wgKiZW3t2ufXQT4E1GOsS9ldsP Efav2oBLirVHO/qW/yvnzofZ8NcU4ZN5ljmQIPwXvatGnRXmfTnlsh39yhB4381+tqdQ6d HUwqjNf89Lcu61zmf9wqayUdIWMO2453fBOgWPODFmPV5PgfC0Pf+f5GbKCNRBM6uwSYEI DskScAqMZTD9CfvFfZM/0lSHzjzHGIWrv0tLsARqVdkM5d0UrMVSfyRwR1kG8KFtMiA8Fm Hsw6p+EN6odu78hDG0WQ2UKgYqqzk118Gw+MbNaxxKzubEt6EeaFnYddjbe5Nw== 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=1721408866; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ShRZt0ik8woeQlGTGpr8VFKgffgYK+hYm3Ir44/KjFQ=; b=ZPase6OsFUQsR00+50ZvcWyKehXk1cq0L9fU92ggv388e66V9BA2fYV67oZAkQZRUGq61G TuJxsP1tzWrNHaIkEm75YoGMtr23aQgcTD4spY7SUM2eFfvU36z34UBNhSBBefJ9Ve7JeX b4S4z73XzwkPOkqqahjnz4aYybGg6S/t3b+/rf0ph1Ky/lYfQosSH87j5uzLBNRMaoD4oR 3+MI5iSE2s/MMLDf+qGX9l4mae527478VmZjMwZiQDhTU8GlGq+sCE3KRhBh7GmoggTQMB nn1Lcg0iYQbQNcrjzEjGQ4U6KDxQJrLx3UlRTSlPlKybqtrhvc86fonu4gOQHw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQbhf1vZrzgvg; Fri, 19 Jul 2024 17:07:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JH7k58028033; Fri, 19 Jul 2024 17:07:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JH7k8x028030; Fri, 19 Jul 2024 17:07:46 GMT (envelope-from git) Date: Fri, 19 Jul 2024 17:07:46 GMT Message-Id: <202407191707.46JH7k8x028030@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: e8e2ab3c5522 - main - md5: Consistently use item count as the first argument to calloc List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e8e2ab3c55228d66388a0b33de8c5ac4b3d6dbe9 Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=e8e2ab3c55228d66388a0b33de8c5ac4b3d6dbe9 commit e8e2ab3c55228d66388a0b33de8c5ac4b3d6dbe9 Author: John Baldwin AuthorDate: 2024-07-19 17:04:27 +0000 Commit: John Baldwin CommitDate: 2024-07-19 17:06:20 +0000 md5: Consistently use item count as the first argument to calloc Reported by: GCC 14 -Wcalloc-transposed-args Reviewed by: rlibby Differential Revision: https://reviews.freebsd.org/D46009 --- sbin/md5/md5.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sbin/md5/md5.c b/sbin/md5/md5.c index 70fc7cb7eef1..10ffae53c775 100644 --- a/sbin/md5/md5.c +++ b/sbin/md5/md5.c @@ -592,7 +592,7 @@ main(int argc, char *argv[]) while (argc--) gnu_check(*argv++); argc = 0; - argv = calloc(sizeof(char *), numrecs + 1); + argv = calloc(numrecs + 1, sizeof(char *)); for (rec = head; rec != NULL; rec = rec->next) { argv[argc] = rec->filename; argc++; From nobody Fri Jul 19 17:07:47 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQbhg5Tr9z5RykZ; Fri, 19 Jul 2024 17:07: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQbhg3kL4z59DL; Fri, 19 Jul 2024 17:07:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721408867; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=uJbYlUfxVE7+PnAWKe+or8XAJYwPzXQr3EkvQYNDcHw=; b=RHIeuWeW0bE7vReNgiNMum5xme0Xe0quwHbXnsvEwG2RmISg6MygZ3mi0dTBJz/BgdwgXM 5Zb3QKV8BiIGOKNxp7xaVqFxtMtH9fyR1wUBPyrQhfKf7bk4Ta8RP5Cgc7UQA9CTmZEVTM JxIeO4nybU4JaR7ghwIZzm1sTdSU4mxol9Gb2iqSuamJV5KoT3AnmG7pByOPDtNoFZTRcZ PbrQoLC/m1pv1xGxyG/+O73mo+ViFo+kPZjp2nK25sMLVwat5Iua1j/vN3Yp7Nks0jCR1B kZq8pDQYNVOaG8hNxpDsnLBRu80W//i2PVYHvvbTIaPg5G6DPIzE3nocFxa8aA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721408867; a=rsa-sha256; cv=none; b=FKH8Cfa0X9mkh4yYaok8kJ0/X7lgYTbwiTtihZgSafciV2wJxwSP1L4W7GsWdQA+TIx77T ykx+65JqMOenq3J0IAEI88ZJwv1iB9A2fAv/kRmx+xs1ec/IbieZO8GyKhlRXlHhAyzj2E 0AbZGRpiHYdvTHvDaUcjJB2Ut9XAEtudqKVQ62CmnFBaUJ1gw8SlHrA+t7sy10wK4a+w/7 eFkE6czhp3/fgxvFc/gPjkKrJyO3xUbhXCQGXHd+rQ6tGLtCajcWcOUSohMi/WETW6BFoY TI0LSAKAUekvtufxtonz7gZdJVMGl6LHKOIT5uFhmOGhuKGDndUsKBxcMCx0wQ== 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=1721408867; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=uJbYlUfxVE7+PnAWKe+or8XAJYwPzXQr3EkvQYNDcHw=; b=Kjw7oucI0LWoZC9nXDBsY8Aa/KYUGrOdeAscyLfa536M/o05Q+LPY1V9f5X1nqMjKiGbKW MQUj73KT7tUo0SBejRayjBbUokGPAv3suO/DRK5SGXZCYHg3mWkiKOJFE9pbaAlI8gDBhe FRtX0NIACeZO4fBqcQTPtCAVzP7Rt4wwFHvmgjg5fc2lrYGQOP6cVVUbP1Ns1usXZIBUF/ dBX83RmYQKP/6ROla64pi5QEQk8a3dS3o76mnHkqRaK8y4X7p+NV9ZKWmIhR8G541FNtls 4m+GNWj3fVeQclu8ki3+bcujO2y9oyDarjCToI7TnjW16053AXoEEp6nNA8JHQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQbhg3KXJzgqX; Fri, 19 Jul 2024 17:07:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JH7lHt028093; Fri, 19 Jul 2024 17:07:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JH7lRr028090; Fri, 19 Jul 2024 17:07:47 GMT (envelope-from git) Date: Fri, 19 Jul 2024 17:07:47 GMT Message-Id: <202407191707.46JH7lRr028090@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 6991cb36f52a - main - recoverdisk: Consistently use item count as the first argument to calloc List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 6991cb36f52a35043132f349a60748eeb382ff32 Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=6991cb36f52a35043132f349a60748eeb382ff32 commit 6991cb36f52a35043132f349a60748eeb382ff32 Author: John Baldwin AuthorDate: 2024-07-19 17:04:50 +0000 Commit: John Baldwin CommitDate: 2024-07-19 17:06:25 +0000 recoverdisk: Consistently use item count as the first argument to calloc Reported by: GCC 14 -Wcalloc-transposed-args Reviewed by: rlibby, imp, emaste Differential Revision: https://reviews.freebsd.org/D46010 --- sbin/recoverdisk/recoverdisk.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sbin/recoverdisk/recoverdisk.c b/sbin/recoverdisk/recoverdisk.c index 43b62fc142f3..91f42c904c52 100644 --- a/sbin/recoverdisk/recoverdisk.c +++ b/sbin/recoverdisk/recoverdisk.c @@ -82,7 +82,7 @@ report_good_read2(time_t now, size_t bytes, struct period_head *ph, time_t dt) pp = TAILQ_FIRST(ph); if (pp == NULL || pp->t1 < now) { - pp = calloc(sizeof *pp, 1L); + pp = calloc(1, sizeof(*pp)); assert(pp != NULL); pp->t0 = (now / dt) * dt; pp->t1 = (now / dt + 1) * dt; From nobody Fri Jul 19 17:07:48 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQbhj0QwHz5Ryn4; Fri, 19 Jul 2024 17:07: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQbhh4cQSz59MX; Fri, 19 Jul 2024 17:07:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721408868; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=v2UueTr1E0giCVeApgxMPYcRE3NYTuNu0Siv6Qq3SZU=; b=X6gpWjruNJ/1hlDcOA0eGvjZWhc7dGYHdDOm/0koIENEtfg2tkusrWGWOl3P6X/ctEKsSh 6To87oyH3jX/05rJsMFTta0P4DNrgtKQwFUu3rixyq/kHZmPV+S9YkE08m8v9VjLSfvriF Zr5IkxVTAwSv8SWQUOk6f4OWn09UMjCFjD8Qi7dbEkI4YObYHO3HZQSD4Hm8m/Oi5LDvSI gIWCJ7PUjyL1Z1PreT/LUxw7EICkLBbp86q9GBurJVpO7ajXqrQEhH5WWuorl7ablD8hU5 BbruLFU5EtnHUTr649IDnIDJnC9Y1lHm7Nl8VK5eQWJ1qQvIaXF5SZV2T2BnNA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721408868; a=rsa-sha256; cv=none; b=ghWis5nMK/kHvVYREv/GUbIZ9eK7Iwp7npStAOJ8hYELtuqGGUMR+udAo5L77Qol5t8iKC U5jCoXch1Ox0CR8axbP1up1iksuKQUyEqgQtBR+lb/W8qOXm+1q6jYtsLBErxEXFhlrE51 yfA8ZO4GFqSJ6n0j5E7lQIJoxmtpSZcdWyEFxa8aAhgoBkhqe7Zk6g5TZ/ojEvrlRrl0Wp 81X80RoAQQ384Z95DRDqbV3xinzYFgwHG0s4csARJNErQk4YnkDfWtas0yzC4mvuj0uOGH JS19UFXclwA1vQQ8kFXlPucxg2v9HSV3Jz6t1zWHOscGoioo1iaGjt1WZl1WNA== 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=1721408868; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=v2UueTr1E0giCVeApgxMPYcRE3NYTuNu0Siv6Qq3SZU=; b=ufDXFjB5w0U9OXwlmTgE5K6kv535lD2ybrFbZzYzJr77zmPDhaVFJ1oizHQwEnYSAfJWT7 1+e1AR0bIY59a70VETVKdj8OTb5DsFrca28tF5n358tDkZAQwE1AChBN2WLU8AqAMEbYcI I2ZRnklBKhQzfFv2e8W1ljW7gcQ4th74JCDZLB0DkoC+4J0Gty6aNiJr/CVqWPXWR+XQmr hhm5UAKafP9Wdw4dCkqFoE8Q/BMpffAB+D5fg/d6jDWLAyRnYAV/OAaJiz/txncui3Phxe yfGyJbppFF19XycHTy60CWe+nmwvtVo5SsAu+SNRB5GIiCLYv6r2imMIEgGdAw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQbhh4CY7zgn6; Fri, 19 Jul 2024 17:07:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JH7mgk028153; Fri, 19 Jul 2024 17:07:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JH7mVw028150; Fri, 19 Jul 2024 17:07:48 GMT (envelope-from git) Date: Fri, 19 Jul 2024 17:07:48 GMT Message-Id: <202407191707.46JH7mVw028150@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: a971c6045622 - main - ministat: Consistently use item count as the first argument to calloc List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: a971c60456223b22c0b3c557d712b36660dbcff9 Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=a971c60456223b22c0b3c557d712b36660dbcff9 commit a971c60456223b22c0b3c557d712b36660dbcff9 Author: John Baldwin AuthorDate: 2024-07-19 17:05:12 +0000 Commit: John Baldwin CommitDate: 2024-07-19 17:06:38 +0000 ministat: Consistently use item count as the first argument to calloc Reported by: GCC 14 -Wcalloc-transposed-args Reviewed by: rlibby, emaste Differential Revision: https://reviews.freebsd.org/D46011 --- usr.bin/ministat/ministat.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/usr.bin/ministat/ministat.c b/usr.bin/ministat/ministat.c index 6508ce3f2533..6967841a339f 100644 --- a/usr.bin/ministat/ministat.c +++ b/usr.bin/ministat/ministat.c @@ -152,7 +152,7 @@ NewSet(void) ds = calloc(1, sizeof *ds); assert(ds != NULL); ds->lpoints = 100000; - ds->points = calloc(sizeof *ds->points, ds->lpoints); + ds->points = calloc(ds->lpoints, sizeof(*ds->points)); assert(ds->points != NULL); ds->syy = NAN; return(ds); @@ -166,7 +166,7 @@ AddPoint(struct dataset *ds, double a) if (ds->n >= ds->lpoints) { dp = ds->points; ds->lpoints *= 4; - ds->points = calloc(sizeof *ds->points, ds->lpoints); + ds->points = calloc(ds->lpoints, sizeof(*ds->points)); assert(ds->points != NULL); memcpy(ds->points, dp, sizeof *dp * ds->n); free(dp); @@ -355,7 +355,7 @@ PlotSet(struct dataset *ds, int val) bar = 0; if (pl->bar == NULL) { - pl->bar = calloc(sizeof(char *), pl->num_datasets); + pl->bar = calloc(pl->num_datasets, sizeof(char *)); assert(pl->bar != NULL); } From nobody Fri Jul 19 17:07:49 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQbhk1HHnz5RyqG; Fri, 19 Jul 2024 17:07: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQbhj5qNRz598G; Fri, 19 Jul 2024 17:07:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721408869; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=wsbnhbWpgCJHFovdhBaFDXV9O+C7tGu41biufNEaTus=; b=NL4TifQ+xWbfem6CKYS6sovZGSH8E3y8RkE65CtqGo+Fw9EIxJNzZkeKXraivasraic1LS mPpGaJj7riFq8Zr2ML0R3Z5GzQxNcSHTrq84wAyQmX9IfJvjjxyl6Jd2K0holNhwdY9UiF /kv/rm3DCYUHxc86RhC86voCQ+sI/+ivswRupboyvtCVwEBOdnMyzjYtXzmvuCxjnreW3O Loupe7NnxqWHPfwBrpPHGeYHU7ERiKRy1KdTrAyvdI/SAu2PtxHSNdqUfWipvJZ+PIunJW FIbhpsm1QdU/rI8dPtrinsartIhAR2S36sMJo/LP5nB75H4V6kQvrQWxXqlYsQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721408869; a=rsa-sha256; cv=none; b=lNBqLQqbpVjFJgvnU6dYhcFAbrQZ7mKb0qYkkwjtheUsal31t7fbVnOmlFRWROX9PYH+MZ z1ZAik/f5vxbUkx+BALhrC3lD91wuaeHQnmTLjygPI4crDw3hKMtfqGQYVhtRJa+ouxJje sf5CSW1rnylNf8TCHyGKXyONeysnIgW4SVncOHLfShIgJ302MWPARHhX+C12Bjfvi0+bHf hstAkj0/clVL/CSq5d861SGMzAw3eoaDYSw+ASiHFfHJr/LQ8QWlaFpxjXas5QkY1iem85 eZmdLWGCZid2gVaXrukZ3fh1Y1SIjIzKFvzJO9ix5ZLQL0DF12Z+KP87nnXG8A== 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=1721408869; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=wsbnhbWpgCJHFovdhBaFDXV9O+C7tGu41biufNEaTus=; b=H9PkQxvXy4nxq0/2++qla68/kqWpj+FYQD6UCckGQuirJgdFXXCHh8YbZu8iM9Urx3grs/ dNi5jo7H8NXx+/Sea8z6oq3tVfFI8g59iWp8dMY/L1Ba+NavwseuEhxWnO9OZ/tNybvReZ JZpYjfatX6ioiTRyjC9lUck9RtVqu632wqNrFWLRJNVL58w5+HS4Uc7nUMaZmgqjv7Qtbj OmE9YETAnkH/CsaFD+c8mSzT677rhWplCdwGeWefUuwMp7NwXBmjRzULK2QIMUxHxmLDCY LG26xiEfqgXoqpxUMh88C4gQf1316SBAeWvHkZYT2AMVOYIX1yaAqCAnK5BN8w== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQbhj5Ql0zgvh; Fri, 19 Jul 2024 17:07:49 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JH7n0Z028213; Fri, 19 Jul 2024 17:07:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JH7nXJ028210; Fri, 19 Jul 2024 17:07:49 GMT (envelope-from git) Date: Fri, 19 Jul 2024 17:07:49 GMT Message-Id: <202407191707.46JH7nXJ028210@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 7cd0a4c85dbe - main - bsdinstall: Consistently use item count as the first argument to calloc List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 7cd0a4c85dbe5e8cd000f6b293ef2d579d22edfb Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=7cd0a4c85dbe5e8cd000f6b293ef2d579d22edfb commit 7cd0a4c85dbe5e8cd000f6b293ef2d579d22edfb Author: John Baldwin AuthorDate: 2024-07-19 17:07:00 +0000 Commit: John Baldwin CommitDate: 2024-07-19 17:07:00 +0000 bsdinstall: Consistently use item count as the first argument to calloc Reported by: GCC 14 -Wcalloc-transposed-args Reviewed by: rlibby, imp, emaste Differential Revision: https://reviews.freebsd.org/D46012 --- usr.sbin/bsdinstall/distfetch/distfetch.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/usr.sbin/bsdinstall/distfetch/distfetch.c b/usr.sbin/bsdinstall/distfetch/distfetch.c index c431e187799d..ddb8a8361d6b 100644 --- a/usr.sbin/bsdinstall/distfetch/distfetch.c +++ b/usr.sbin/bsdinstall/distfetch/distfetch.c @@ -130,8 +130,8 @@ fetch_files(int nfiles, char **urls) struct bsddialog_conf mgconf; /* Make the transfer list for mixedgauge */ - minilabel = calloc(sizeof(char *), nfiles); - miniperc = calloc(sizeof(int), nfiles); + minilabel = calloc(nfiles, sizeof(char *)); + miniperc = calloc(nfiles, sizeof(int)); if (minilabel == NULL || miniperc == NULL) errx(EXIT_FAILURE, "Error: distfetch minibars out of memory!"); From nobody Fri Jul 19 17:07:50 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQbhl2V3Pz5Ryrw; Fri, 19 Jul 2024 17:07: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQbhk75NZz59SX; Fri, 19 Jul 2024 17:07:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721408871; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=HwhiuRXn/p7D0jtXBMQPTWmwgpUdkLBWIZlINtIIcWs=; b=I1n01KZvulgHMFl939UyhloU9QTlb+cIPMZmZWJor5TT+bydKcvXysVpPDbEaJ3qvKO8mv VuvOApaD2/tGpGnSJtZ6JFzycCmWW85PEkx3kDZoZS12cN7oyfAO8FvqUWiM2waZVbh4Fl 3LBN70xJwrSWGNRHJLL7xBiyOFWvA0gSLEvJbvPIPUBELQKjZlEY8Q5zhTdkTwdlyONaX5 gRTsGRLRfovkHDQixb4pnCsLng7GNM1rWx3hE5nmhWl5xmT6FEvV9c39TJDQi7yS6uw6Xb 6pkbhIVu6b+X6FwsO4SOKqQoCAJTffuB9V9tntFYn/cX/6EefiY0SM8FUHPjfg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721408871; a=rsa-sha256; cv=none; b=jNqCdIVOU10H7ITnteeXz2BzW8Vh+1hhMlYRvmXe9zJCYErC4JVwo9jUTHCdrM07xYwMpB UtNVS4siPUkEbkIM4aZm842/eODmMVugSRd5GEsQ88cruZWjYWKsC3QzYWAQeRKxi8JHSp 1Iq48s85zxIAKGBP8A8+XpfvosY8CsL/o57Ikde9Tj7EISNvmESfVi7jHJqCG7yWKik6ra PBAnaT1LcHa7HnwDOHfx/lz77b8dAgZ2wsC5lAjrkFlLxopujVsCdpHW46TOcRuEQ8V/mT Sjh+H88mY3thkGQr9mOcsDagC8ceEk1yxToh55odQ0mlXaNwsPDJ/1TNCJxIig== 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=1721408871; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=HwhiuRXn/p7D0jtXBMQPTWmwgpUdkLBWIZlINtIIcWs=; b=RdAjzBJoFuoPYVputxXx4Y1OShXY6Z7io/lWHOYT7Xt9aIRHtOH9lrUeFCSmLgXDROpNu4 w8IgzToYWwBph3SUJOg5h1oSCDMNVEcgeUGah9SezSUVYAlXFjg6xXjjFqoiWnvktxqvB8 DwtwXIt1Xy5Z+xOy7v4perbY2zPT50Xl6LNuNLTaRQ4oupL2mkJVc4VrqnZZVPe/mXDbnc PvXorArUM7F7+JBNCFNxeR/CPCNiRdh/s2oSRnKTBEegm1phvBxxVmURBKTZuWYFftlbGV haBvm1QDR14I8ULaHEBGl0MyZ8NSNFAwJhCyFxiAFFVZXdU2KNRaP1y1zCW++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 4WQbhk6gpgzgn7; Fri, 19 Jul 2024 17:07:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JH7o0N028282; Fri, 19 Jul 2024 17:07:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JH7o40028279; Fri, 19 Jul 2024 17:07:50 GMT (envelope-from git) Date: Fri, 19 Jul 2024 17:07:50 GMT Message-Id: <202407191707.46JH7o40028279@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 2ba12978f674 - main - ctld: Consistently use item count as the first argument to calloc List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 2ba12978f67432a3f88b17704391d28e1fc0e788 Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=2ba12978f67432a3f88b17704391d28e1fc0e788 commit 2ba12978f67432a3f88b17704391d28e1fc0e788 Author: John Baldwin AuthorDate: 2024-07-19 17:07:22 +0000 Commit: John Baldwin CommitDate: 2024-07-19 17:07:22 +0000 ctld: Consistently use item count as the first argument to calloc Reported by: GCC 14 -Wcalloc-transposed-args Reviewed by: rlibby, imp, emaste Differential Revision: https://reviews.freebsd.org/D46013 --- usr.sbin/ctld/isns.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/usr.sbin/ctld/isns.c b/usr.sbin/ctld/isns.c index 71150a8ae06f..0b836324ff47 100644 --- a/usr.sbin/ctld/isns.c +++ b/usr.sbin/ctld/isns.c @@ -48,14 +48,14 @@ isns_req_alloc(void) { struct isns_req *req; - req = calloc(sizeof(struct isns_req), 1); + req = calloc(1, sizeof(struct isns_req)); if (req == NULL) { log_err(1, "calloc"); return (NULL); } req->ir_buflen = sizeof(struct isns_hdr); req->ir_usedlen = 0; - req->ir_buf = calloc(req->ir_buflen, 1); + req->ir_buf = calloc(1, req->ir_buflen); if (req->ir_buf == NULL) { free(req); log_err(1, "calloc"); From nobody Fri Jul 19 17:11:31 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQbmz5hNhz5S0FK; Fri, 19 Jul 2024 17:11: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQbmz2g8hz41DT; Fri, 19 Jul 2024 17:11:31 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721409091; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=wrtskWlyJqKDND24k80gcLmRnKNAcjDVbtU3J6y86B4=; b=UAEKoFjfZtAUrQCLfESMIxY014tbKZD+DDjuepCTR1exAsf46AwdldF8eCTamgCIWOmQ0o h8e2qSn3fTKbYnCY7fycnMjS754Phah+G8oMrA5av97UpfMzBKjdBTi3rm2qjfBjkaWU1W yAkBVEUObjTCT2lTsqnewxn7gM7hKt0b/BCNkLUA8ifqujxbXd8epHWMweSVmsAnYQ9fJf TH9Av1eKGJDYS0B8ELiRKY6pQLEkYwlsZ6RrDuuoeEBj84+qR1ibMQVL0cjbh0hrUV/hba sa+3HiLkKXPKDaf+dQkhxwiWk77xJB5ySNoUQcC85RVKDByPM41hl8JhZqABSA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721409091; a=rsa-sha256; cv=none; b=bxvYDUbPC/DDf8zi3T76c/oj3vaoNE1MgnWo9THJy39daw5PW/3ChAjQS8zpQIljtBjBV0 ah3rG/KsBml2DGHnyWxIckUDyYyWiF2BEabTLbzzynHnAXp1MBSatbYrsgJhVtmWpd5J7O yAsDVX0Jq1OWqvuSeiDZpmPLCM0tAFUWN98DRx50G9Y/j18dJ4W4qjX8G+BD4qgiW/dUCR SPgNWeW8FCWbCSkIt6GbyZJfPAKgVrnFWkUZw1f2oeQcl/7NlJHcldUIuhU6aAzFSZUiS1 +AW2dkz0d7fIDU22x226yr/eE7y1AXOoPOPkEJEDWwelpkOCJAuqDNaLqFSMAw== 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=1721409091; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=wrtskWlyJqKDND24k80gcLmRnKNAcjDVbtU3J6y86B4=; b=CD6ei0eABGJgcQnP1Lei4uaJWRZlFZVSeMAKdfw6sM6OwNlWnMuqb7kJbRO4YZnbAFaNT2 ocxIa/qRngwKTmF3XBKLO874dsxjH+9+mJbuoralSn4xdAp3fw6OnVCynrbAYbSnNaYbO2 ws656FhoxbkNEpjhEaXot6oDWL8TNBmTPSwXfr280ke9Ww2PZPw9aXUXNiRLso4/p3a/jn IU7OTN8pWPKfiNz97L1b3uVP1qAe/pjDapiD6COssmPoB9LubCEmfcRVIaBBc1bH/VZGoZ B1bXaXmzONwbqchMWQA7aD4QvRM+ah55zf+zOnLGnbfXFyEVs+KzJzBdJeSpyA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQbmz1yZ8zgqt; Fri, 19 Jul 2024 17:11:31 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JHBVTe044159; Fri, 19 Jul 2024 17:11:31 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JHBVdq044156; Fri, 19 Jul 2024 17:11:31 GMT (envelope-from git) Date: Fri, 19 Jul 2024 17:11:31 GMT Message-Id: <202407191711.46JHBVdq044156@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 9494dfe1b3fa - main - fwcontrol: Allocate full fw_asyreq structures passed to the kernel List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9494dfe1b3faf5c48abaa9be4ec87e4669963942 Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=9494dfe1b3faf5c48abaa9be4ec87e4669963942 commit 9494dfe1b3faf5c48abaa9be4ec87e4669963942 Author: John Baldwin AuthorDate: 2024-07-19 17:08:14 +0000 Commit: John Baldwin CommitDate: 2024-07-19 17:09:32 +0000 fwcontrol: Allocate full fw_asyreq structures passed to the kernel The FW_ASYREQ ioctl accepts a struct fw_asyreq object as its argument, meaning that the kernel always copies in the full structure in sys_ioctl before passing the request down to the driver. However, fwcontrol was allocating smaller objects that contained only the request header and a variable-sized payload. This means that the kernel copy in sys_ioctl was reading off the end of this buffer. On current architectures this happened to be ok, but it is UB. Instead, allocate a full structure. Reported by: GCC 14 -Walloc-size Reviewed by: rlibby, brooks Differential Revision: https://reviews.freebsd.org/D46014 --- usr.sbin/fwcontrol/fwcontrol.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/usr.sbin/fwcontrol/fwcontrol.c b/usr.sbin/fwcontrol/fwcontrol.c index 94478259606d..ce908341a42a 100644 --- a/usr.sbin/fwcontrol/fwcontrol.c +++ b/usr.sbin/fwcontrol/fwcontrol.c @@ -207,7 +207,7 @@ read_write_quad(int fd, struct fw_eui64 eui, u_int32_t addr_lo, int readmode, u_ struct fw_asyreq *asyreq; u_int32_t *qld, res; - asyreq = (struct fw_asyreq *)malloc(sizeof(struct fw_asyreq_t) + 16); + asyreq = malloc(sizeof(*asyreq)); if (asyreq == NULL) err(EX_SOFTWARE, "%s:asyreq malloc", __func__); asyreq->req.len = 16; @@ -262,7 +262,7 @@ send_phy_config(int fd, int root_node, int gap_count) { struct fw_asyreq *asyreq; - asyreq = (struct fw_asyreq *)malloc(sizeof(struct fw_asyreq_t) + 12); + asyreq = malloc(sizeof(*asyreq)); if (asyreq == NULL) err(EX_SOFTWARE, "%s:asyreq malloc", __func__); asyreq->req.len = 12; @@ -289,7 +289,7 @@ link_on(int fd, int node) { struct fw_asyreq *asyreq; - asyreq = (struct fw_asyreq *)malloc(sizeof(struct fw_asyreq_t) + 12); + asyreq = malloc(sizeof(*asyreq)); if (asyreq == NULL) err(EX_SOFTWARE, "%s:asyreq malloc", __func__); asyreq->req.len = 12; @@ -308,7 +308,7 @@ reset_start(int fd, int node) { struct fw_asyreq *asyreq; - asyreq = (struct fw_asyreq *)malloc(sizeof(struct fw_asyreq_t) + 16); + asyreq = malloc(sizeof(*asyreq)); if (asyreq == NULL) err(EX_SOFTWARE, "%s:asyreq malloc", __func__); asyreq->req.len = 16; From nobody Fri Jul 19 18:25:28 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQdQJ6lcqz5S4xb; Fri, 19 Jul 2024 18:25: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQdQJ6DtPz46XB; Fri, 19 Jul 2024 18:25:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721413528; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=R8bAgGEwTZdNAcsh6CPjQKkbL+kIF35+mmbOm9Nu2VI=; b=lwzyW5hOSdJ10zUL+r6d3MVTkYcIdooRObKJug93J/0jPbvhxxmmf0/7MRRrkvllcE6kn6 bVzrQTzjAGFB5t1+EYoJ7zXL12Adq3wjntQ8TuQX+/RoEFXoHclPoxh6CJBaDi2yJZH+rc TLqYTxks/bdRRInLCiLenbpeQDZYzc3Lp0jbwtfKUMMULrZqm9C4AWVk/AXTaVCGodJAIt /hQ6+jRv9j5+0l5UB7H1b1n0KkkapZ1OHwRZ6CpR1O8AK1DLRkTT52XLLBNN/RaLZstHn0 xXPKySvAt1x3DI9w6pwru/RHnWhlWV14qWWVTYpiWrwp80y0Ii2ai7lODvT/Lg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721413528; a=rsa-sha256; cv=none; b=PXejRf3FUqRaT4OTqnan056jwRjd+ajr1L4zy2fMgL7hNBIG3FuxxblbdaA0fgJrpTd8rn 47TScT7iIe3DePF4YodD9kBXzEhfogCD8+LnoSkWue6TJpaUMqCRFEpsJyP7/CrE1gKVRD eV8trHA+VKjr5v4Q/bstcJkCHe74TC35TjgA8Q7swyEo4+aAIGB27yvhW0aXLfDBWmFxz6 60374v9ZB/4K633ool7j1BP2sKvY9awtP2ijPka/Ksf7fWNTzdOSxrvIArDWisb/cPUbVf ET3rUrB50b6fOAcGYu+lEQQQL6seff+aKR52pZD6iwNnDRmcPLjGGnvvENBpoQ== 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=1721413528; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=R8bAgGEwTZdNAcsh6CPjQKkbL+kIF35+mmbOm9Nu2VI=; b=aeHvVcVgDFbA2G8/riOcnK8ujbH+6IK4jpcODUArea2JYhUXnCAbNF4BGomiNmqRhXmFQe xgKLfqIqPqOaYc7txVBvSufFoKXHtaXPlpsB7NiErJYQemO5j/tJEuQBal4he5PxqOY9uv cAGQVwryTY1xToSjqSmHUSwakfeOW0rpnUG+G22s/Dv+MNeKmTadE20eOEjpP/GgzaYkFd 9IkbRHY/f3mDGaf7pzPoM8iNvEXTO7psoh+gbdEX1pmwgmm92T4pZf3IMX5ekCWHY4gdT0 stAXSvh+i5hGMSKJVP7sHws/kDfu82H0BHStye7o8WoSksrMgat2gYU/5jiF6w== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQdQJ5jn6zk2j; Fri, 19 Jul 2024 18:25:28 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JIPSUV063154; Fri, 19 Jul 2024 18:25:28 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JIPS14063151; Fri, 19 Jul 2024 18:25:28 GMT (envelope-from git) Date: Fri, 19 Jul 2024 18:25:28 GMT Message-Id: <202407191825.46JIPS14063151@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Cy Schubert Subject: git: 66f360515d28 - main - rc.conf: Leap-seconds sources: Add IANA back List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cy X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 66f360515d2829d261c0ad7bd516e9dd18c2dd83 Auto-Submitted: auto-generated The branch main has been updated by cy: URL: https://cgit.FreeBSD.org/src/commit/?id=66f360515d2829d261c0ad7bd516e9dd18c2dd83 commit 66f360515d2829d261c0ad7bd516e9dd18c2dd83 Author: Cy Schubert AuthorDate: 2024-07-19 18:04:43 +0000 Commit: Cy Schubert CommitDate: 2024-07-19 18:24:31 +0000 rc.conf: Leap-seconds sources: Add IANA back 11da791920ba switched Leap-seconds source from IANA to IERS, as IERS is the canonoical source. The problem ist that IERS is not accessible from IPv6 only networks. To work around this we must add IANA back in order to provide IPv6-only users a source for leap-seconds fetch. PR: 279413 Fixes: 11da791920ba MFC after: 3 days --- libexec/rc/rc.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libexec/rc/rc.conf b/libexec/rc/rc.conf index 1ee1573bbdba..583d4fd2970e 100644 --- a/libexec/rc/rc.conf +++ b/libexec/rc/rc.conf @@ -420,7 +420,7 @@ ntp_src_leapfile="/etc/ntp/leap-seconds" # Initial source for ntpd leapfile ntp_db_leapfile="/var/db/ntpd.leap-seconds.list" # Canonical place to get the leap seconds from -ntp_leapfile_sources="https://hpiers.obspm.fr/iers/bul/bulc/ntp/leap-seconds.list" +ntp_leapfile_sources="https://hpiers.obspm.fr/iers/bul/bulc/ntp/leap-seconds.list https://data.iana.org/time-zones/tzdb/leap-seconds.list" # Source from which to fetch leapfile ntp_leapfile_fetch_opts="-mq" # Options to use for ntp leapfile fetch, # e.g. --no-verify-peer From nobody Fri Jul 19 19:23:02 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQfj06CS6z5QCCy; Fri, 19 Jul 2024 19:23:16 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQfj00dhcz4GM3; Fri, 19 Jul 2024 19:23:15 +0000 (UTC) (envelope-from kostikbel@gmail.com) Authentication-Results: mx1.freebsd.org; none Received: from tom.home (kib@localhost [127.0.0.1] (may be forged)) by kib.kiev.ua (8.18.1/8.18.1) with ESMTP id 46JJN3Ow016473; Fri, 19 Jul 2024 22:23:06 +0300 (EEST) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.10.3 kib.kiev.ua 46JJN3Ow016473 Received: (from kostik@localhost) by tom.home (8.18.1/8.18.1/Submit) id 46JJN2R2016472; Fri, 19 Jul 2024 22:23:02 +0300 (EEST) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Fri, 19 Jul 2024 22:23:02 +0300 From: Konstantin Belousov To: Kristof Provost Cc: src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Subject: Re: git: ef2a572bf6bd - main - ipsec_offload: kernel infrastructure Message-ID: References: <202407121125.46CBP8eo093121@gitrepo.freebsd.org> List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FORGED_GMAIL_RCVD,FREEMAIL_FROM, NML_ADSP_CUSTOM_MED autolearn=no autolearn_force=no version=4.0.1 X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on tom.home 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:6939, ipnet:2001:470::/32, country:US] X-Rspamd-Queue-Id: 4WQfj00dhcz4GM3 On Fri, Jul 19, 2024 at 04:26:43PM +0200, Kristof Provost wrote: > On 12 Jul 2024, at 13:25, Konstantin Belousov wrote: > > The branch main has been updated by kib: > > > > URL: https://cgit.FreeBSD.org/src/commit/?id=ef2a572bf6bdcac97ef29ce631d2f50f938e1ec8 > > > > commit ef2a572bf6bdcac97ef29ce631d2f50f938e1ec8 > > Author: Konstantin Belousov > > AuthorDate: 2021-08-22 19:38:04 +0000 > > Commit: Konstantin Belousov > > CommitDate: 2024-07-12 04:27:58 +0000 > > > > ipsec_offload: kernel infrastructure > > > > Inline IPSEC offload moves almost whole IPSEC processing from the > > CPU/MCU and possibly crypto accelerator, to the network card. > > > > The transmitted packet content is not touched by CPU during TX > > operations, kernel only does the required policy and security > > association lookups to find out that given flow is offloaded, and > > then > > packet is transmitted as plain text to the card. For driver > > convenience, > > a metadata is attached to the packet identifying SA which must > > process > > the packet. Card does encryption of the payload, padding, calculates > > authentication, and does the reformat according to the policy. > > > > Similarly, on receive, card does the decapsulation, decryption, and > > authentification. Kernel receives the identifier of SA that was > > used to process the packet, together with the plain-text packet. > > > > Overall, payload octets are only read or written by card DMA engine, > > removing a lot of memory subsystem overhead, and saving CPU time > > because > > IPSEC algos calculations are avoided. > > > > If driver declares support for inline IPSEC offload (with the > > IFCAP2_IPSEC_OFFLOAD capability set and registering method table > > struct > > if_ipsec_accel_methods), kernel offers the SPD and SAD to driver. > > Driver decides which policies and SAs can be offloaded based on > > hardware capacity, and acks/nacks each SA for given interface to > > kernel. Kernel needs to keep this information to make a decision to > > skip software processing on TX, and to assume processing already > > done > > on RX. This shadow SPD/SAD database of offloads is rooted from > > policies (struct secpolicy accel_ifps, struct ifp_handle_sp) and SAs > > (struct secasvar accel_ipfs, struct ifp_handle_sav). > > > > Some extensions to the PF_KEY socket allow to limit interfaces for > > which given SP/SA could be offloaded (proposed for offload). Also, > > additional statistics extensions allow to observe > > allocation/octet/use > > counters for specific SA. > > > > Since SPs and SAs are typically instantiated in non-sleepable > > context, > > while offloading them into card is expected to require costly async > > manipulations of the card state, calls to the driver for offload and > > termination are executed in the threaded taskqueue. It also solves > > the issue of allocating resources needed for the offload database. > > Neither ipf_handle_sp nor ipf_handle_sav do not add reference to the > > owning SP/SA, the offload must be terminated before last reference > > is > > dropped. ipsec_accel only adds transient references to ensure safe > > pointer ownership by taskqueue. > > > > Maintaining the SA counters for hardware-accelerated packets is the > > duty of the driver. The helper ipsec_accel_drv_sa_lifetime_update() > > is provided to hide accel infrastructure from drivers which would > > use > > expected callout to query hardware periodically for updates. > > > > Reviewed by: rscheff (transport, stack integration), np > > Sponsored by: NVIDIA networking > > Differential revision: https://reviews.freebsd.org/D44219 > > --- > > sys/conf/files | 2 + > > sys/conf/options | 1 + > > sys/modules/ipsec/Makefile | 5 +- > > sys/netipsec/ipsec.c | 17 + > > sys/netipsec/ipsec.h | 11 + > > sys/netipsec/ipsec_input.c | 11 + > > sys/netipsec/ipsec_offload.c | 1061 > > ++++++++++++++++++++++++++++++++++++++++++ > > sys/netipsec/ipsec_offload.h | 191 ++++++++ > > sys/netipsec/ipsec_output.c | 15 + > > sys/netipsec/ipsec_pcb.c | 38 +- > > sys/netipsec/key.c | 270 ++++++++++- > > sys/netipsec/key.h | 6 + > > sys/netipsec/key_debug.c | 5 + > > sys/netipsec/keydb.h | 14 + > > 14 files changed, 1628 insertions(+), 19 deletions(-) > > > Iā€™m seeing messages like `ipsec_accel_sa_install_newkey: spi 0x1001 flags > 0x40 seq 0` running the test suite now. > Are those stray debug printfs? Not stray, but also they should not be there by default indeed. https://reviews.freebsd.org/D46045 From nobody Fri Jul 19 19:31:52 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQfvB073gz5QCpS for ; Fri, 19 Jul 2024 19:32:06 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-pl1-x630.google.com (mail-pl1-x630.google.com [IPv6:2607:f8b0:4864:20::630]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "WR4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQfv944RFz4H5D for ; Fri, 19 Jul 2024 19:32:05 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-pl1-x630.google.com with SMTP id d9443c01a7336-1fa9ecfb321so18785025ad.0 for ; Fri, 19 Jul 2024 12:32:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20230601.gappssmtp.com; s=20230601; t=1721417524; x=1722022324; darn=freebsd.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=Mxf0zR/wNtg0SCPP5PJMEvxqy/dFOVQdJqMvlWz34is=; b=cFJGDFa3g29nWFmvNb8aIqsrlE4fqG8b7URTgdIxHoRO6JzHwbYkxWORuajb2SrNvf l5Vqf0OBzeyW8aeMk26FBxnYnQNaK876J+tWEB1dvjSoRpUwZQlUS8MGDF6l/pmqv/t0 vbduQPawJTflvAqRkXoEQAbY2dPbqZ125pjQ2Au8MgcElpx/V1RFUyIKG1Pa+teVW2N+ r/u2z0veUaDIvJSWUiGeVneJqxzJvwtWWV6Q/FzYxheTvWGIJQDpwJDQaXEoDpUy6Zt2 XZqnLmhF1CkZiWRaPJIONYEh8XroV+W4Vl3ZibuuHpDBxGVfw620hUaY6t1mK7CiuagC K2hQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721417524; x=1722022324; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=Mxf0zR/wNtg0SCPP5PJMEvxqy/dFOVQdJqMvlWz34is=; b=RX92mvksN4B4jtATACCppb4psMHr8He1SBcrjv20lSkBzVNVgtqBPyYxxk+mcfIstx zlHo8CNWgnHYi7kUgvzLNJwioHHJwn1Y1EGLOZbTsbizWE2tYXWBmJ+4CBqLznBRtbK0 g7CFpdH7ONFZGgq/rszod4FUDfyBMeqc/YUAxrqHRWkuSdhzj+nrspUyhX9BS2k1pIsB s1r4mawdpHI+OpdiKBsSkU83zfVDru7vMCVhdaEc8SpLhO97cyoPQL/WyZ+M+C0YgRS7 pfY1CBSx8LWCU6rmawpC+EK1ki3nUiwfcC43plI2JJWEJo9q8pwwqM8/iKbKrluksAOp lNIA== X-Forwarded-Encrypted: i=1; AJvYcCVzA44PeTm4GTk9X8fmkS/S5dut43mF9iuw0ylC39quWsCbE8d0MgVhcaxNSSgqtW1obyei6nHUYNDM17wqn2rrB1HhLFPVartyikhHbv2l X-Gm-Message-State: AOJu0YxhO9UpeoNbV13tvY9zasxNKR49QxuxDapOy0aDXCjz1c2FRArB VZTksTDPYVjKyTI/QCitXjiqZSEsYo3g2OnyKhAKyL7OThR9ROWuofo+D3kOQm3e14i4Ut/II2t EKJkX1PjPX7/wJlVR6ma5ElasHqXd+cYrns5jaA== X-Google-Smtp-Source: AGHT+IE6+3ZI3kzbqoYtlVbFpPzPCR481KhqAOJQChLyWZ+sJplqWVT7jH86tyCGCiPZ4SAgoasC84KxiL/5elYwaXI= X-Received: by 2002:a17:90b:23d2:b0:2c9:7cc8:8e33 with SMTP id 98e67ed59e1d1-2cb52691feamr7610299a91.13.1721417523621; Fri, 19 Jul 2024 12:32:03 -0700 (PDT) List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 References: <202407191825.46JIPS14063151@gitrepo.freebsd.org> In-Reply-To: <202407191825.46JIPS14063151@gitrepo.freebsd.org> From: Warner Losh Date: Fri, 19 Jul 2024 13:31:52 -0600 Message-ID: Subject: Re: git: 66f360515d28 - main - rc.conf: Leap-seconds sources: Add IANA back To: Cy Schubert Cc: src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Content-Type: multipart/alternative; boundary="000000000000018cd9061d9ec017" 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:15169, ipnet:2607:f8b0::/32, country:US] X-Rspamd-Queue-Id: 4WQfv944RFz4H5D --000000000000018cd9061d9ec017 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable There's risk to our IPv6 folks if we MFC this. This file is the old one still (and it took them 6 weeks to get the last one updated past its expiration date). The IERS one is up to date, expires Jun 2025. The IANA has a december expiration date finally, though we leared 3 weeks ago there's no leap in December, so that's why the IERS one was updated. So this is better than nothing, but we're setting ourselves up for a problem this December / January.... The last time this issue came up, I was kinda opposed to FreeBSD running this since IERS did. However, I either didn't know at the time, or didn't appreciate at the time the lack of IPv6 for this data source would be a problem. Since we have no other reliable source, maybe we need to stand up a FreeBSD mirror after all. So this is better than nothing, but we may need to do more. Warner On Fri, Jul 19, 2024 at 12:25=E2=80=AFPM Cy Schubert wrote= : > The branch main has been updated by cy: > > URL: > https://cgit.FreeBSD.org/src/commit/?id=3D66f360515d2829d261c0ad7bd516e9d= d18c2dd83 > > commit 66f360515d2829d261c0ad7bd516e9dd18c2dd83 > Author: Cy Schubert > AuthorDate: 2024-07-19 18:04:43 +0000 > Commit: Cy Schubert > CommitDate: 2024-07-19 18:24:31 +0000 > > rc.conf: Leap-seconds sources: Add IANA back > > 11da791920ba switched Leap-seconds source from IANA to IERS, as IERS > is the canonoical source. The problem ist that IERS is not accessible > from IPv6 only networks. To work around this we must add IANA back in > order to provide IPv6-only users a source for leap-seconds fetch. > > PR: 279413 > Fixes: 11da791920ba > MFC after: 3 days > --- > libexec/rc/rc.conf | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/libexec/rc/rc.conf b/libexec/rc/rc.conf > index 1ee1573bbdba..583d4fd2970e 100644 > --- a/libexec/rc/rc.conf > +++ b/libexec/rc/rc.conf > @@ -420,7 +420,7 @@ ntp_src_leapfile=3D"/etc/ntp/leap-seconds" > # Initial source for ntpd leapfile > ntp_db_leapfile=3D"/var/db/ntpd.leap-seconds.list" > # Canonical place to get the leap seconds > from > -ntp_leapfile_sources=3D" > https://hpiers.obspm.fr/iers/bul/bulc/ntp/leap-seconds.list" > +ntp_leapfile_sources=3D" > https://hpiers.obspm.fr/iers/bul/bulc/ntp/leap-seconds.list > https://data.iana.org/time-zones/tzdb/leap-seconds.list" > # Source from which to fetch leapfile > ntp_leapfile_fetch_opts=3D"-mq" # Options to use for ntp leapfile fetch= , > # e.g. --no-verify-peer > --000000000000018cd9061d9ec017 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
There's risk to our IPv6 folks=C2=A0if we MFC thi= s. This file is the old one still (and it took them 6 weeks to get the last= one updated past its expiration date).

The IERS o= ne is up to date, expires Jun 2025. The IANA has a december expiration date= finally, though we leared 3 weeks ago there's no leap in December, so = that's why the IERS one was updated.

So this i= s better than nothing, but we're setting ourselves up for a problem thi= s December / January....

The last time this issue = came up, I was kinda opposed to FreeBSD running this since IERS did. Howeve= r, I either didn't know at the time, or didn't appreciate at the ti= me the lack of IPv6 for this data source would be a problem. Since we have = no other reliable source, maybe we need to stand up a FreeBSD mirror after = all.

So this is better than nothing, but we may ne= ed to do more.

Warner

On Fri, Jul 19, 2024 at= 12:25=E2=80=AFPM Cy Schubert <cy@free= bsd.org> wrote:
The branch main has been updated by cy:

URL: https://cgit.= FreeBSD.org/src/commit/?id=3D66f360515d2829d261c0ad7bd516e9dd18c2dd83
commit 66f360515d2829d261c0ad7bd516e9dd18c2dd83
Author:=C2=A0 =C2=A0 =C2=A0Cy Schubert <cy@FreeBSD.org>
AuthorDate: 2024-07-19 18:04:43 +0000
Commit:=C2=A0 =C2=A0 =C2=A0Cy Schubert <cy@FreeBSD.org>
CommitDate: 2024-07-19 18:24:31 +0000

=C2=A0 =C2=A0 rc.conf: Leap-seconds sources: Add IANA back

=C2=A0 =C2=A0 11da791920ba switched Leap-seconds source from IANA to IERS, = as IERS
=C2=A0 =C2=A0 is the canonoical source. The problem ist that IERS is not ac= cessible
=C2=A0 =C2=A0 from IPv6 only networks. To work around this we must add IANA= back in
=C2=A0 =C2=A0 order to provide IPv6-only users a source for leap-seconds fe= tch.

=C2=A0 =C2=A0 PR:=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0279413
=C2=A0 =C2=A0 Fixes:=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 11da791920ba
=C2=A0 =C2=A0 MFC after:=C2=A0 =C2=A0 =C2=A0 3 days
---
=C2=A0libexec/rc/rc.conf | 2 +-
=C2=A01 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libexec/rc/rc.conf b/libexec/rc/rc.conf
index 1ee1573bbdba..583d4fd2970e 100644
--- a/libexec/rc/rc.conf
+++ b/libexec/rc/rc.conf
@@ -420,7 +420,7 @@ ntp_src_leapfile=3D"/etc/ntp/leap-seconds" =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 # Initial source for ntpd leapfile =C2=A0ntp_db_leapfile=3D"/var/db/ntpd.leap-seconds.list"
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 # Canonical place to get the leap se= conds from
-ntp_leapfile_sources=3D"https://hpi= ers.obspm.fr/iers/bul/bulc/ntp/leap-seconds.list"
+ntp_leapfile_sources=3D"https://hpi= ers.obspm.fr/iers/bul/bulc/ntp/leap-seconds.list https://data.iana.org/time-zones/tzdb/leap-seconds.list" =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 # Source from which to fetch leapfil= e
=C2=A0ntp_leapfile_fetch_opts=3D"-mq"=C2=A0 # Options to use for = ntp leapfile fetch,
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 # e.g. --no-verify-peer
--000000000000018cd9061d9ec017-- From nobody Fri Jul 19 21:06:55 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQj0b4vPzz5QMPs; Fri, 19 Jul 2024 21:06: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQj0b441Fz4Py8; Fri, 19 Jul 2024 21:06:55 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721423215; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VXyaHPO8PsFntp1aL3CNP/yfMyZjpo+qBSd+KcSiIO4=; b=nJNjtibvu0o/Q0eSQfOTRP5r3zaMzPvW51m41A0knr/rPSutx2Ps1nFcTHXV4UbIKF8mPq J4x0vqvfst84voimzYZGfJW+Yqklqqme/I+C6YGjMdlZtPpD8ChWzktTs1nMq4JsiUs4dX KXjlpQ7Ebfv0UDyIlxlWSj2pisbGJZKCSsXJOagcmuAbP0RRDUAn/z8yrXh68QSA2cokT0 Vw3m7LVbR1cNkZuouEY3oK2dXOkywgES0LgYRarj8OzsiBfma/QIR5oHpyp6ol4Uh4QxD2 eVf1R88Ck0aLC9wcvmPcgK90QoBUf3v2t8+UwfMRO5CJ2znznQnNPoGYTC9HaQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721423215; a=rsa-sha256; cv=none; b=CqDwTnyR/RRpusXMsOzSmcE7EkSuGRLbj/6yUxUIrBkoxkIx/9g0x/iUd4Jzwku0ephIn8 uo7+B4VcpAtrYpB1dj+Il/EqwP0T82jXaXE4ia545fNWOxPnHDc6wfZVZBNIA7c+2CK9j/ 9Dz0Undszqtn+sgyp4/rvJm+iXPAp+5d59/2a07gCXqHOcKMTIj1CjFjwxmuEITBNdisLk lOmnIEgqxv9r2sv1aD3Xo1OzC3gW2/dFCVxbbTuCUVQFL7rkbNOoTSFP6D9CR6QdGrmmoC iQR1h+pT8XAt4c6MUDtxapzgJm2WUh0UkB7AlOOwrfTJpXHVi7wRcRQ6IJeleg== 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=1721423215; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VXyaHPO8PsFntp1aL3CNP/yfMyZjpo+qBSd+KcSiIO4=; b=XcuTAei3mktXaGQFCEFfS3IA1UsuIzKKLJsK716h1oiq+/BnwX3GIbqaeBq0OuLONLKmC0 4Yj4o1NubCHeXWu6hN0zKOZLEZJjogbX4LTGT0yEmZ/5Bfovw2a3YMlgZEGtJkP0uOpXwQ t79cdi56QeHv9RFI0N2wSpMvMa5DYNXS+zvJ1ENcpKpBJhR/EV184L7aK2VN1eEjY39VGA 07f82oXP2a8UckSm32u4VDoapPVMzb0dY6BHK2+12I2fNton8vbHhlTjjFP7QYXDY1F1Sv EAccoJmTJXGHc6SgEyFynwDhdQKaZ0UfqPEp1qMttQXG6kYzL6WaF3/QAX1IqQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQj0b3gPVzp1l; Fri, 19 Jul 2024 21:06:55 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JL6tqd034330; Fri, 19 Jul 2024 21:06:55 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JL6tOD034327; Fri, 19 Jul 2024 21:06:55 GMT (envelope-from git) Date: Fri, 19 Jul 2024 21:06:55 GMT Message-Id: <202407192106.46JL6tOD034327@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: e0649a35a670 - main - libnvmf: Zero controller data template for I/O controllers List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e0649a35a670c4b625d1de289b3886d9b3c9654f Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=e0649a35a670c4b625d1de289b3886d9b3c9654f commit e0649a35a670c4b625d1de289b3886d9b3c9654f Author: John Baldwin AuthorDate: 2024-07-19 21:06:47 +0000 Commit: John Baldwin CommitDate: 2024-07-19 21:06:47 +0000 libnvmf: Zero controller data template for I/O controllers This prevents stack garbage from leaking into the cdata used for the userspace I/O controller in nvmfd(8). Sponsored by: Chelsio Communications --- lib/libnvmf/nvmf_controller.c | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/libnvmf/nvmf_controller.c b/lib/libnvmf/nvmf_controller.c index 554e5e769ded..0e0126040ee4 100644 --- a/lib/libnvmf/nvmf_controller.c +++ b/lib/libnvmf/nvmf_controller.c @@ -425,6 +425,7 @@ nvmf_init_io_controller_data(struct nvmf_qpair *qp, const char *serial, uname(&utsname); + memset(cdata, 0, sizeof(*cdata)); _nvmf_init_io_controller_data(qp->nq_cntlid, na->na_params.max_io_qsize, serial, utsname.sysname, utsname.release, subnqn, nn, ioccsz, sizeof(struct nvme_completion), cdata); From nobody Fri Jul 19 21:20:00 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQjHy0XJLz5QNtt for ; Fri, 19 Jul 2024 21:20:14 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-pj1-x1032.google.com (mail-pj1-x1032.google.com [IPv6:2607:f8b0:4864:20::1032]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "WR4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQjHx3LTvz4Qjf for ; Fri, 19 Jul 2024 21:20:13 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Authentication-Results: mx1.freebsd.org; dkim=pass header.d=bsdimp-com.20230601.gappssmtp.com header.s=20230601 header.b="rFzSwP+/"; dmarc=none; spf=none (mx1.freebsd.org: domain of wlosh@bsdimp.com has no SPF policy when checking 2607:f8b0:4864:20::1032) smtp.mailfrom=wlosh@bsdimp.com Received: by mail-pj1-x1032.google.com with SMTP id 98e67ed59e1d1-2cb55ff1007so1241651a91.0 for ; Fri, 19 Jul 2024 14:20:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20230601.gappssmtp.com; s=20230601; t=1721424012; x=1722028812; darn=freebsd.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=Z/VeZp87PqUAzCEtlovEoaD9mT3GdD5oZbMO3uWSSZ8=; b=rFzSwP+/Trqz1UCgKW4FRa+e7LdJwGD1J4Yqf1N9EOqPFP9RXJ0aVM5l69vNsDL9GX CMOpUfXgLG5eepknx6GLEVRkZaHx2btI6hKiPPs5Mmt04GLF0DWndjNYirayF8Bictdg FH9Tq1igOETw55ZM16ySXDwi8z/xCcP4903SaFe65Jv9OSU1LxcrQk8OAxPhOakj2FUp FetMYvaoX5+DtPVQk9+aqJwMLDhdHpn+qzH/jBZc8kBGy3WxXWQwVlcJV5kAdp4XP0qm n+bfSqzIVjcSVyK0RG3pnBevwWA0NmgDv/k8r/PnFSQkZZJ5VzTqPBfQVFYtmxBltFFa APcw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721424012; x=1722028812; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=Z/VeZp87PqUAzCEtlovEoaD9mT3GdD5oZbMO3uWSSZ8=; b=EkzEYJBZc5f7vXVlxGQq1Ll4zFL1VX/KJZeGE0Q0ohog/nQpvjG+xYGsnfJIXKk2Jp iFzCgzL80C7Q7OxvvOFVsew/V0PXTlLzM+03w0U9u6ZThKaHsisvn0xYRluq/hMvHqJR fByKJpdHGkeGv08ctzPBQKDCQbjt1sq/2HWNEQiK3q6K13DVC206YBrJV597fRsWCs45 NW0I7YCZQOMHyeUTNDT2isozcCezbMYKGfRbfMJkFMk4yQRApVhcUqN4MgSrGTs/orvL RPNY8puUOYoFQ5QD6GoCuC8s5QkemFhCwwzVUdJtjxP/0KHLkNvdBqOklytGgcClGOyc cjuw== X-Forwarded-Encrypted: i=1; AJvYcCXR92KSwDi6j1CcJMnCwsnjP8/lSJlTSEQz7qLWY2rVpEf9ODv80ja/CsUMXp+VC9cEK27jxdDED6c5poG2r6RD5I98lmctLXSM0iux3xS/ X-Gm-Message-State: AOJu0Yyy8DDJ8mtH0XqU8GqUamgUI34yWenRdFWPDRLfqrJr8rIUU3GJ 7eyhm0vfBKRYwzT2rvcxs/vp0T0hKuJSLHnQMYSeCVH7BNb2v+4FcHN7iyqAScJP4qFcN1Wq2M0 Is0i+4+rA1vAyAokp01D7jeXYOfv7pGiYMiKXuw== X-Google-Smtp-Source: AGHT+IGWnFDTbGMp7AXJPEXdiXdi33FdkhRO0Uv+v48rnKVrb8HrwoH1lOHxI0qgJWJLUsHUvxcN654HTs6j7cMlP0w= X-Received: by 2002:a17:90a:fa84:b0:2c2:d813:bffa with SMTP id 98e67ed59e1d1-2cd15feb69bmr927623a91.43.1721424011554; Fri, 19 Jul 2024 14:20:11 -0700 (PDT) List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 References: <202407061944.466JiiQ3026410@gitrepo.freebsd.org> In-Reply-To: From: Warner Losh Date: Fri, 19 Jul 2024 15:20:00 -0600 Message-ID: Subject: Re: git: 6677621bad00 - main - cdefs.h: Fallback to printf0 for __printf0like To: John Baldwin Cc: Warner Losh , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Content-Type: multipart/alternative; boundary="000000000000b78c8a061da0426b" X-Spamd-Bar: -- X-Spamd-Result: default: False [-2.61 / 15.00]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_SHORT(-0.61)[-0.605]; FORGED_SENDER(0.30)[imp@bsdimp.com,wlosh@bsdimp.com]; R_DKIM_ALLOW(-0.20)[bsdimp-com.20230601.gappssmtp.com:s=20230601]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; RCVD_COUNT_ONE(0.00)[1]; MIME_TRACE(0.00)[0:+,1:+,2:~]; ARC_NA(0.00)[]; TO_DN_SOME(0.00)[]; MISSING_XM_UA(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[2607:f8b0:4864:20::1032:from]; DMARC_NA(0.00)[bsdimp.com]; MLMMJ_DEST(0.00)[dev-commits-src-all@freebsd.org]; FROM_NEQ_ENVFROM(0.00)[imp@bsdimp.com,wlosh@bsdimp.com]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_FIVE(0.00)[5]; R_SPF_NA(0.00)[no SPF record]; PREVIOUSLY_DELIVERED(0.00)[dev-commits-src-all@freebsd.org]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCVD_TLS_LAST(0.00)[]; DKIM_TRACE(0.00)[bsdimp-com.20230601.gappssmtp.com:+] X-Rspamd-Queue-Id: 4WQjHx3LTvz4Qjf --000000000000b78c8a061da0426b Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Wed, Jul 10, 2024 at 12:19=E2=80=AFPM John Baldwin wro= te: > On 7/6/24 17:56, John Baldwin wrote: > > On 7/6/24 15:44, Warner Losh wrote: > >> The branch main has been updated by imp: > >> > >> URL: > https://cgit.FreeBSD.org/src/commit/?id=3D6677621bad00191dfec1b0a20ae1618= b92745d9b > >> > >> commit 6677621bad00191dfec1b0a20ae1618b92745d9b > >> Author: Warner Losh > >> AuthorDate: 2024-07-06 19:42:37 +0000 > >> Commit: Warner Losh > >> CommitDate: 2024-07-06 19:45:03 +0000 > >> > >> cdefs.h: Fallback to printf0 for __printf0like > >> > >> For some reason, my tests were fine with this like it was, but C= I > for > >> gcc12 and gcc13 is complaining. Revert to the old form until tha= t > can be > >> worked out why the mismatch. > >> > >> Fixes: 0b82dac337e7 > >> Sponsored by: Netflix > >> --- > >> sys/sys/cdefs.h | 7 +++++-- > >> 1 file changed, 5 insertions(+), 2 deletions(-) > >> > >> diff --git a/sys/sys/cdefs.h b/sys/sys/cdefs.h > >> index 6b861b1903f6..a56839d57c7a 100644 > >> --- a/sys/sys/cdefs.h > >> +++ b/sys/sys/cdefs.h > >> @@ -356,9 +356,12 @@ > >> * Clang has always had printf and printf0 as aliases. gcc 11.0 now > follows > >> * clang. So now this is an alias for __printflike, or nothing. In > the future > >> * _Nullable or _Nonnull will replace this. > >> + * XXX Except that doesn't work, so for now revert to printf0 for > clang and > >> + * the FreeBSD gcc until I can work this out. > >> */ > >> -#if defined(__clang__) || __GNUC_PREREQ__(11, 0) > >> -#define __printf0like(fmtarg, firstvararg) __printflike(fmtarg, > firstvararg) > >> +#if defined(__clang__) || (defined(__GNUC__) && defined > (__FreeBSD_cc_version)) > >> +#define __printf0like(fmtarg, firstvararg) \ > >> + __attribute__((__format__ (__printf0__, fmtarg, firstvararg))= ) > >> #else > >> #define __printf0like(fmtarg, firstvararg) > >> #endif > > > > It's because my patch for devel/freebsd-gcc{12,13} is kind of wrong. I > had a mismerge > > when updating the printf0 patch from gcc9 to gcc12 that ended up > re-adding the > > warn on NULL. I need to update the ports to remove that part of the > patch. I will > > probably leave printf0 working for now in the ports just as an alias fo= r > regular > > printf to give us some transition time. > > FYI, I have merged this fix to the ports, but not sure how we want to > manage doing > the patch to cdefs.h. I kind of think we should apply the change to > cdefs.h in > main in another week or so. I'm less certain of what to do for stable > branches. > I hadn't planned on merging this to stable branches. Is that your concern? Or something else? For building on the stable branch, we should be fine since we support a wider range of compilers anyway with the older cdefs.h file, and the new file will work with all supported stable branch compilers (though maybe not some of the gcc ones, I've not tested that at all). Also it's been just over a week, can I recommit this, or is more time needed? Warner --000000000000b78c8a061da0426b Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


=
On Wed, Jul 10, 2024 at 12:19=E2=80= =AFPM John Baldwin <jhb@freebsd.org> wrote:
On= 7/6/24 17:56, John Baldwin wrote:
> On 7/6/24 15:44, Warner Losh wrote:
>> The branch main has been updated by imp:
>>
>> URL:
http= s://cgit.FreeBSD.org/src/commit/?id=3D6677621bad00191dfec1b0a20ae1618b92745= d9b
>>
>> commit 6677621bad00191dfec1b0a20ae1618b92745d9b
>> Author:=C2=A0 =C2=A0 =C2=A0Warner Losh <imp@FreeBSD.org>
>> AuthorDate: 2024-07-06 19:42:37 +0000
>> Commit:=C2=A0 =C2=A0 =C2=A0Warner Losh <imp@FreeBSD.org>
>> CommitDate: 2024-07-06 19:45:03 +0000
>>
>>=C2=A0 =C2=A0 =C2=A0 =C2=A0cdefs.h: Fallback to printf0 for __print= f0like
>>=C2=A0 =C2=A0 =C2=A0 =C2=A0
>>=C2=A0 =C2=A0 =C2=A0 =C2=A0For some reason, my tests were fine with= this like it was, but CI for
>>=C2=A0 =C2=A0 =C2=A0 =C2=A0gcc12 and gcc13 is complaining. Revert t= o the old form until that can be
>>=C2=A0 =C2=A0 =C2=A0 =C2=A0worked out why the mismatch.
>>=C2=A0 =C2=A0 =C2=A0 =C2=A0
>>=C2=A0 =C2=A0 =C2=A0 =C2=A0Fixes: 0b82dac337e7
>>=C2=A0 =C2=A0 =C2=A0 =C2=A0Sponsored by:=C2=A0 =C2=A0 =C2=A0 =C2=A0= =C2=A0 =C2=A0Netflix
>> ---
>>=C2=A0 =C2=A0 sys/sys/cdefs.h | 7 +++++--
>>=C2=A0 =C2=A0 1 file changed, 5 insertions(+), 2 deletions(-)
>>
>> diff --git a/sys/sys/cdefs.h b/sys/sys/cdefs.h
>> index 6b861b1903f6..a56839d57c7a 100644
>> --- a/sys/sys/cdefs.h
>> +++ b/sys/sys/cdefs.h
>> @@ -356,9 +356,12 @@
>>=C2=A0 =C2=A0 =C2=A0* Clang has always had printf and printf0 as al= iases. gcc 11.0 now follows
>>=C2=A0 =C2=A0 =C2=A0* clang. So now this is an alias for __printfli= ke, or nothing. In the future
>>=C2=A0 =C2=A0 =C2=A0* _Nullable or _Nonnull will replace this.
>> + * XXX Except that doesn't work, so for now revert to printf0= for clang and
>> + * the FreeBSD gcc until I can work this out.
>>=C2=A0 =C2=A0 =C2=A0*/
>> -#if defined(__clang__) || __GNUC_PREREQ__(11, 0)
>> -#define=C2=A0 =C2=A0 =C2=A0__printf0like(fmtarg, firstvararg) __p= rintflike(fmtarg, firstvararg)
>> +#if defined(__clang__) || (defined(__GNUC__) && defined (= __FreeBSD_cc_version))
>> +#define=C2=A0 =C2=A0 =C2=A0__printf0like(fmtarg, firstvararg) \ >> +=C2=A0 =C2=A0 =C2=A0 =C2=A0 __attribute__((__format__ (__printf0_= _, fmtarg, firstvararg)))
>>=C2=A0 =C2=A0 #else
>>=C2=A0 =C2=A0 #define=C2=A0 =C2=A0__printf0like(fmtarg, firstvararg= )
>>=C2=A0 =C2=A0 #endif
>
> It's because my patch for devel/freebsd-gcc{12,13} is kind of wron= g.=C2=A0 I had a mismerge
> when updating the printf0 patch from gcc9 to gcc12 that ended up re-ad= ding the
> warn on NULL.=C2=A0 I need to update the ports to remove that part of = the patch.=C2=A0 I will
> probably leave printf0 working for now in the ports just as an alias f= or regular
> printf to give us some transition time.

FYI, I have merged this fix to the ports, but not sure how we want to manag= e doing
the patch to cdefs.h.=C2=A0 I kind of think we should apply the change to c= defs.h in
main in another week or so.=C2=A0 I'm less certain of what to do for st= able branches.

I hadn't planned on = merging this to stable branches. Is that your concern? Or something else?
For building on the stable branch, we should be fine since we supp= ort a wider range of
compilers anyway with the older cdefs.h file= , and the new file will work with all supported
stable branch com= pilers (though maybe not some of the gcc ones, I've not tested
that at all).

Also it's been just over a wee= k, can I recommit this, or is more time needed?

Wa= rner
--000000000000b78c8a061da0426b-- From nobody Fri Jul 19 21:50:04 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQjyj1yF7z5QRgd; Fri, 19 Jul 2024 21:50:21 +0000 (UTC) (envelope-from rlibby@gmail.com) Received: from mail-lf1-f54.google.com (mail-lf1-f54.google.com [209.85.167.54]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "WR4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQjyh3zzLz4TsL; Fri, 19 Jul 2024 21:50:20 +0000 (UTC) (envelope-from rlibby@gmail.com) Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=fail reason="SPF not aligned (relaxed), No valid DKIM" header.from=freebsd.org (policy=none); spf=pass (mx1.freebsd.org: domain of rlibby@gmail.com designates 209.85.167.54 as permitted sender) smtp.mailfrom=rlibby@gmail.com Received: by mail-lf1-f54.google.com with SMTP id 2adb3069b0e04-52e97e5a84bso3016238e87.2; Fri, 19 Jul 2024 14:50:20 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721425818; x=1722030618; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=jYH+OX0pk68BkCJWcbW2AMuQzc0ej9L/3ejjo6jLtS0=; b=Wxvis4Oj8vKtKS/zDZQxazH7oEaJN+X9ulANuN4IUt/1w10sBM8r9Ycjz/mKUYalLY SVYxz70kPuMZLTElr/Je/7Ld4C/9AhzJEMoN9BGsw0VohyvvApZJgIWZaYVwolDxF37+ ZL6m3m/HvBQM0K5bd3BZtJV4tB9mIK1s0bqYp3KUSO2KQQneAZvSeBVuhNjlTxra8Jnh vwr91Xtrt3HQIk4uiGYzq9h3s/6AWlEoynfPH3zn3mbJrsXh3S5XTou5ZzZiOkWU4+KW SPvOmpO/2X/nF1yxqeRwnqp4jZjp/feFSLlw+MgjX/Bg50toC47n/kmrVJTgGJPzxml0 Yb5A== X-Forwarded-Encrypted: i=1; AJvYcCVRcxVcgiACIOm5tXlcIAbNVnKp3AIdF/+lVOyR8somX7tEOUvRD9pSiRB/OeEBZRPGXrewxmeDyP+9H/rKu7fDZ71a6LrwjSDfHv4dqJe9Ilr2dNjKr+HqZlqHKRU4jDAHsPFFN/V96bnM2pdst0oTDQ== X-Gm-Message-State: AOJu0YwOyacrcBvcBM3OgpzYgSqyvlqlWD1040J0tra61GSItd2/L+Yl C4vtpN3gfmg4Jtm/AN8Kk8bFZ+82i/Omy5SrvH7j2AEj5Le57hQEBaQ3i4Ju X-Google-Smtp-Source: AGHT+IELMbcICJ+zZqzoOznvCuT1xuDeoMFvrJ5rbNO0IG1PaENv6e6NLLYjiLfPswtvtIVZzSrXvg== X-Received: by 2002:a05:6512:1597:b0:52e:9921:6dff with SMTP id 2adb3069b0e04-52ee53b7b7dmr7313664e87.26.1721425817435; Fri, 19 Jul 2024 14:50:17 -0700 (PDT) Received: from mail-lj1-f169.google.com (mail-lj1-f169.google.com. [209.85.208.169]) by smtp.gmail.com with ESMTPSA id 2adb3069b0e04-52ef5571ba1sm304554e87.199.2024.07.19.14.50.16 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 19 Jul 2024 14:50:16 -0700 (PDT) Received: by mail-lj1-f169.google.com with SMTP id 38308e7fff4ca-2eea8ea8bb0so45316451fa.1; Fri, 19 Jul 2024 14:50:16 -0700 (PDT) X-Forwarded-Encrypted: i=1; AJvYcCX4YiYMdzApC3x8QaRd3EaAoGL/2UskpHMOSU/NyI5QBpjqcKPBcX63d3XU1FXFNc/eX30jrp3PMwo2uFN0xo+JggCq3bfEFRvDr5C2jnfiJjmXH/sCAv/XEm0vojel6PuQOuGYxpkwjSos+x5niOvx1w== X-Received: by 2002:a2e:84ca:0:b0:2ee:8f3d:e68d with SMTP id 38308e7fff4ca-2ef1685d099mr7546321fa.44.1721425816630; Fri, 19 Jul 2024 14:50:16 -0700 (PDT) List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 References: <202407181319.46IDJdBj055008@gitrepo.freebsd.org> In-Reply-To: <202407181319.46IDJdBj055008@gitrepo.freebsd.org> From: Ryan Libby Date: Fri, 19 Jul 2024 14:50:04 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: git: 257e70f1d5ee - main - kyua: Add FreeBSD Jail execution environment support To: Mark Johnston Cc: src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spamd-Bar: - X-Spamd-Result: default: False [-1.17 / 15.00]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_MEDIUM(-0.92)[-0.924]; NEURAL_SPAM_SHORT(0.65)[0.654]; FORGED_SENDER(0.30)[rlibby@freebsd.org,rlibby@gmail.com]; R_SPF_ALLOW(-0.20)[+ip4:209.85.128.0/17]; MIME_GOOD(-0.10)[text/plain]; DMARC_POLICY_SOFTFAIL(0.10)[freebsd.org : SPF not aligned (relaxed), No valid DKIM,none]; RCVD_VIA_SMTP_AUTH(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[209.85.167.54:from,209.85.208.169:received]; ASN(0.00)[asn:15169, ipnet:209.85.128.0/17, country:US]; MIME_TRACE(0.00)[0:+]; FREEFALL_USER(0.00)[rlibby]; FREEMAIL_ENVFROM(0.00)[gmail.com]; TO_DN_SOME(0.00)[]; RWL_MAILSPIKE_POSSIBLE(0.00)[209.85.167.54:from]; R_DKIM_NA(0.00)[]; MLMMJ_DEST(0.00)[dev-commits-src-all@freebsd.org,dev-commits-src-main@freebsd.org]; FROM_NEQ_ENVFROM(0.00)[rlibby@freebsd.org,rlibby@gmail.com]; FROM_HAS_DN(0.00)[]; MISSING_XM_UA(0.00)[]; ARC_NA(0.00)[]; RCVD_TLS_LAST(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; RCVD_COUNT_THREE(0.00)[3]; RCPT_COUNT_THREE(0.00)[4] X-Rspamd-Queue-Id: 4WQjyh3zzLz4TsL On Thu, Jul 18, 2024 at 6:19=E2=80=AFAM Mark Johnston w= rote: > > The branch main has been updated by markj: > > URL: https://cgit.FreeBSD.org/src/commit/?id=3D257e70f1d5ee61037c8c59b116= 538d3b6b1427a2 > > commit 257e70f1d5ee61037c8c59b116538d3b6b1427a2 > Author: Igor Ostapenko > AuthorDate: 2024-07-16 18:41:12 +0000 > Commit: Mark Johnston > CommitDate: 2024-07-18 13:18:28 +0000 > > kyua: Add FreeBSD Jail execution environment support > > A new Kyua concept is added -- "execution environment". A test can be > configured to be run within a specific environment. The test case > lifecycle is extended respectively: > - execenv init (creates a jail or does nothing for default > execenv=3D"host") > - test exec > - cleanup exec (optional) > - execenv cleanup (removes a jail or does nothing for default > execenv=3D"host") > > The following new functionality is provided, from bottom to top: > > 1 ATF based tests > > - The new "execenv" metadata property can be set to explicitly ask fo= r > an execution environment: "host" or "jail". If it's not defined, as > all existing tests do, then it implicitly means "host". > > - The new "execenv.jail.params" metadata property can be optionally > defined to ask Kyua to use specific jail(8) parameters during creat= ion > of a temporary jail. An example is "vnet allow.raw_sockets". > > Kyua implicitly adds "children.max" to "execenv_jail_params" > parameters with the maximum possible value. A test case can overrid= e > it. > > 2 Kyuafile > > - The same new metadata properties can be defined on Kyuafile level: > "execenv" and "execenv_jail_params". > > - Note that historically ATF uses dotted style of metadata naming, wh= ile > Kyua uses underscore style. Hence "execenv.jail.params" vs. > "execenv_jail_params". > > 3 kyua.conf, kyua CLI > > - The new "execenvs" engine configuration variable can be set to a li= st > of execution environments to run only tests designed for. Tests of = not > listed environments are skipped. > > - By default, this variable lists all execution environments supporte= d > by a Kyua binary, e.g. execenvs=3D"host jail". > > - This variable can be changed via "kyua.conf" or via kyua CLI's "-v" > parameter. For example, "kyua -v execenvs=3Dhost test" will run onl= y > host-based tests and skip jail-based ones. > > - Current value of this variable can be examined with "kyua config". > > [markj] This feature has not landed upstream yet. > See the discussion in https://github.com/freebsd/kyua/pull/224 . > Having the ability to automatically jail tests allows many network te= sts > to run in parallel, giving a drastic speedup. So, let's import the > feature and start using it in main. > > Signed-off-by: Igor Ostapenko > Reviewed by: markj, kp > Tested by: markj, kp > MFC after: 3 months > Differential Revision: https://reviews.freebsd.org/D45865 > --- > contrib/kyua/AUTHORS | 1 + > contrib/kyua/cli/cmd_config_test.cpp | 12 +- > contrib/kyua/doc/kyua.conf.5.in | 13 +- > contrib/kyua/doc/kyuafile.5.in | 103 +++++++- > contrib/kyua/drivers/report_junit_test.cpp | 8 + > contrib/kyua/engine/atf.cpp | 11 +- > contrib/kyua/engine/atf_list.cpp | 4 + > contrib/kyua/engine/config.cpp | 18 ++ > contrib/kyua/engine/execenv/execenv.cpp | 74 ++++++ > contrib/kyua/engine/execenv/execenv.hpp | 149 +++++++++++ > contrib/kyua/engine/execenv/execenv_host.cpp | 52 ++++ > contrib/kyua/engine/execenv/execenv_host.hpp | 63 +++++ > contrib/kyua/engine/plain.cpp | 7 +- > contrib/kyua/engine/requirements.cpp | 33 +++ > contrib/kyua/engine/scheduler.cpp | 274 ++++++++++++++++= ++- > contrib/kyua/engine/scheduler.hpp | 1 + > contrib/kyua/engine/tap.cpp | 7 +- > contrib/kyua/examples/kyua.conf | 3 + > contrib/kyua/integration/cmd_config_test.sh | 2 + > contrib/kyua/integration/cmd_report_junit_test.sh | 8 + > contrib/kyua/integration/cmd_report_test.sh | 2 + > contrib/kyua/main.cpp | 3 + > contrib/kyua/model/metadata.cpp | 76 ++++++ > contrib/kyua/model/metadata.hpp | 5 + > contrib/kyua/model/metadata_test.cpp | 8 +- > contrib/kyua/model/test_case_test.cpp | 3 +- > contrib/kyua/model/test_program_test.cpp | 13 +- > contrib/kyua/os/freebsd/execenv_jail.cpp | 78 ++++++ > contrib/kyua/os/freebsd/execenv_jail.hpp | 65 +++++ > contrib/kyua/os/freebsd/execenv_jail_manager.cpp | 63 +++++ > contrib/kyua/os/freebsd/execenv_jail_manager.hpp | 54 ++++ > contrib/kyua/os/freebsd/execenv_jail_stub.cpp | 75 ++++++ > contrib/kyua/os/freebsd/main.cpp | 54 ++++ > contrib/kyua/os/freebsd/main.hpp | 41 +++ > contrib/kyua/os/freebsd/utils/jail.cpp | 306 ++++++++++++++++= ++++++ > contrib/kyua/os/freebsd/utils/jail.hpp | 64 +++++ > contrib/kyua/utils/config/nodes.ipp | 9 +- > contrib/kyua/utils/process/executor.cpp | 42 +++ > contrib/kyua/utils/process/executor.hpp | 1 + > usr.bin/kyua/Makefile | 15 +- > 40 files changed, 1792 insertions(+), 28 deletions(-) > This broke the gcc build: https://ci.freebsd.org/job/FreeBSD-main-amd64-gcc13_build/1307/ With several instances of error: 'noreturn' function does return [-Werror] >From my meta files: gcc13/usr/src/freebsd/amd64.amd64/usr.bin/kyua/engine_atf.o.meta:/usr/src/f= reebsd/contrib/kyua/engine/atf.cpp:199:1: error: 'noreturn' function does return [-Werror] gcc13/usr/src/freebsd/amd64.amd64/usr.bin/kyua/engine_atf.o.meta:/usr/src/f= reebsd/contrib/kyua/engine/atf.cpp:230:1: error: 'noreturn' function does return [-Werror] gcc13/usr/src/freebsd/amd64.amd64/usr.bin/kyua/engine_plain.o.meta:/usr/src= /freebsd/contrib/kyua/engine/plain.cpp:113:1: error: 'noreturn' function does return [-Werror] gcc13/usr/src/freebsd/amd64.amd64/usr.bin/kyua/engine_tap.o.meta:/usr/src/f= reebsd/contrib/kyua/engine/tap.cpp:160:1: error: 'noreturn' function does return [-Werror] I'm unsure if [[noreturn]] on a virtual method is defined in the way that this code apparently expects. Ryan From nobody Fri Jul 19 21:53:19 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQk286wLlz5QRvN; Fri, 19 Jul 2024 21:53:20 +0000 (UTC) (envelope-from brooks@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 "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQk285xxVz4VFH; Fri, 19 Jul 2024 21:53:20 +0000 (UTC) (envelope-from brooks@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721426000; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=dKc4IE25oGlL74JXvXt2vNJUHlE199Sg0Ir0/nx0oNI=; b=SRMuXimj3HaEhS5Clcs9UBZa86JMMlmU1tC3cHEGmC1Jup9innCAfZPjCXWHm/fkQniuRC MmrL08r6uMn2fAQhRoSyadvhXhroC3JvQre/0lkRSaaNka2DfZbYr1UTpUDXts/62TxLaT oiTMeeZyXTzXKjUok/jq54J76Qba6N1ps3xFA+w6o4ZkXwBDfruqCaJD7m0xEvjmE1DgCC Tze0EGa83cpLUy25qfjLEfd4wQxAfhHlD9sRskIDMnbFIRAbSsjbQh2LoVSPHmJpqybOGc 6smTsnWVBDVcf9pWU4eR2UB2Gb9ug/zJpwrYAmoNdGmNgcXUyV3xjeXk/VlTSA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721426000; a=rsa-sha256; cv=none; b=nNRO4a5OsNbR6nxnY7JCckTani1EmiHbDxiTF6vp7mvavRH7yXIq9RF9ilhXNgeV3cgAvH wAnz2dHa+Hq26M78ZXq1MOJUNhihkc2Sb2msEhfYm9T2u0HMZmLRiJw2HO8aBeDO6TkHMq 9+z97HlvFctSsH/4HhG0yIittu+TlGmc9ZMmrmqKQGoW0CYkYHpPXMsFFrnicGu50DQaNe 7v85OpXgPrUph+VY4D/aIkm4vYq3UVbOjcitmQP+JcFzFHk6ohZaCq255r7udu9tjGllSl F6rTr5J5NLisg7Ioa4XFzP8APOiUgomzlixMnu9CCE9ERsLWXsVk86MVpwDfnw== 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=1721426000; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=dKc4IE25oGlL74JXvXt2vNJUHlE199Sg0Ir0/nx0oNI=; b=tTctNCW93NiSRQcR+gyyooL1viGPWZp0tnbmwEMrfRwaDam3pXuT5et8S34G6klXNKjYZ3 /LV0xu4KLd76MW4K2E+n3hgJp2T9sIrsgs66SdzIk8V2eaPewzG1LqARYYYXmiIbbWtawr Ck9yUrdGOkR1EryXQk7Ebhc1Wlv05lVAs8B9EcqXBLNIdf0j1OUozNbKmbEItZNrTlHxZa Y2tslC8oIG3xJM47Udxqw+pbEvmhTKtthuRBrm6aVUO6qDLZHjLZMZXESUOXmSPE9l+8/A 16AUOprIAy15gfs6ullXFfFrPM6LKtOqViL0EHUm7jjixTzH5E5c42eqzVwblw== Received: from spindle.one-eyed-alien.net (spindle.one-eyed-alien.net [199.48.129.229]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: brooks/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 4WQk284zcTzGV4; Fri, 19 Jul 2024 21:53:20 +0000 (UTC) (envelope-from brooks@freebsd.org) Received: by spindle.one-eyed-alien.net (Postfix, from userid 3001) id C45763C019B; Fri, 19 Jul 2024 21:53:19 +0000 (UTC) Date: Fri, 19 Jul 2024 21:53:19 +0000 From: Brooks Davis To: Ryan Libby Cc: Mark Johnston , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Subject: Re: git: 257e70f1d5ee - main - kyua: Add FreeBSD Jail execution environment support Message-ID: References: <202407181319.46IDJdBj055008@gitrepo.freebsd.org> List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: On Fri, Jul 19, 2024 at 02:50:04PM -0700, Ryan Libby wrote: > On Thu, Jul 18, 2024 at 6:19???AM Mark Johnston wrote: > > > > The branch main has been updated by markj: > > > > URL: https://cgit.FreeBSD.org/src/commit/?id=257e70f1d5ee61037c8c59b116538d3b6b1427a2 > > > > commit 257e70f1d5ee61037c8c59b116538d3b6b1427a2 > > Author: Igor Ostapenko > > AuthorDate: 2024-07-16 18:41:12 +0000 > > Commit: Mark Johnston > > CommitDate: 2024-07-18 13:18:28 +0000 > > > > kyua: Add FreeBSD Jail execution environment support > > > > A new Kyua concept is added -- "execution environment". A test can be > > configured to be run within a specific environment. The test case > > lifecycle is extended respectively: > > - execenv init (creates a jail or does nothing for default > > execenv="host") > > - test exec > > - cleanup exec (optional) > > - execenv cleanup (removes a jail or does nothing for default > > execenv="host") > > > > The following new functionality is provided, from bottom to top: > > > > 1 ATF based tests > > > > - The new "execenv" metadata property can be set to explicitly ask for > > an execution environment: "host" or "jail". If it's not defined, as > > all existing tests do, then it implicitly means "host". > > > > - The new "execenv.jail.params" metadata property can be optionally > > defined to ask Kyua to use specific jail(8) parameters during creation > > of a temporary jail. An example is "vnet allow.raw_sockets". > > > > Kyua implicitly adds "children.max" to "execenv_jail_params" > > parameters with the maximum possible value. A test case can override > > it. > > > > 2 Kyuafile > > > > - The same new metadata properties can be defined on Kyuafile level: > > "execenv" and "execenv_jail_params". > > > > - Note that historically ATF uses dotted style of metadata naming, while > > Kyua uses underscore style. Hence "execenv.jail.params" vs. > > "execenv_jail_params". > > > > 3 kyua.conf, kyua CLI > > > > - The new "execenvs" engine configuration variable can be set to a list > > of execution environments to run only tests designed for. Tests of not > > listed environments are skipped. > > > > - By default, this variable lists all execution environments supported > > by a Kyua binary, e.g. execenvs="host jail". > > > > - This variable can be changed via "kyua.conf" or via kyua CLI's "-v" > > parameter. For example, "kyua -v execenvs=host test" will run only > > host-based tests and skip jail-based ones. > > > > - Current value of this variable can be examined with "kyua config". > > > > [markj] This feature has not landed upstream yet. > > See the discussion in https://github.com/freebsd/kyua/pull/224 . > > Having the ability to automatically jail tests allows many network tests > > to run in parallel, giving a drastic speedup. So, let's import the > > feature and start using it in main. > > > > Signed-off-by: Igor Ostapenko > > Reviewed by: markj, kp > > Tested by: markj, kp > > MFC after: 3 months > > Differential Revision: https://reviews.freebsd.org/D45865 > > --- > > contrib/kyua/AUTHORS | 1 + > > contrib/kyua/cli/cmd_config_test.cpp | 12 +- > > contrib/kyua/doc/kyua.conf.5.in | 13 +- > > contrib/kyua/doc/kyuafile.5.in | 103 +++++++- > > contrib/kyua/drivers/report_junit_test.cpp | 8 + > > contrib/kyua/engine/atf.cpp | 11 +- > > contrib/kyua/engine/atf_list.cpp | 4 + > > contrib/kyua/engine/config.cpp | 18 ++ > > contrib/kyua/engine/execenv/execenv.cpp | 74 ++++++ > > contrib/kyua/engine/execenv/execenv.hpp | 149 +++++++++++ > > contrib/kyua/engine/execenv/execenv_host.cpp | 52 ++++ > > contrib/kyua/engine/execenv/execenv_host.hpp | 63 +++++ > > contrib/kyua/engine/plain.cpp | 7 +- > > contrib/kyua/engine/requirements.cpp | 33 +++ > > contrib/kyua/engine/scheduler.cpp | 274 ++++++++++++++++++- > > contrib/kyua/engine/scheduler.hpp | 1 + > > contrib/kyua/engine/tap.cpp | 7 +- > > contrib/kyua/examples/kyua.conf | 3 + > > contrib/kyua/integration/cmd_config_test.sh | 2 + > > contrib/kyua/integration/cmd_report_junit_test.sh | 8 + > > contrib/kyua/integration/cmd_report_test.sh | 2 + > > contrib/kyua/main.cpp | 3 + > > contrib/kyua/model/metadata.cpp | 76 ++++++ > > contrib/kyua/model/metadata.hpp | 5 + > > contrib/kyua/model/metadata_test.cpp | 8 +- > > contrib/kyua/model/test_case_test.cpp | 3 +- > > contrib/kyua/model/test_program_test.cpp | 13 +- > > contrib/kyua/os/freebsd/execenv_jail.cpp | 78 ++++++ > > contrib/kyua/os/freebsd/execenv_jail.hpp | 65 +++++ > > contrib/kyua/os/freebsd/execenv_jail_manager.cpp | 63 +++++ > > contrib/kyua/os/freebsd/execenv_jail_manager.hpp | 54 ++++ > > contrib/kyua/os/freebsd/execenv_jail_stub.cpp | 75 ++++++ > > contrib/kyua/os/freebsd/main.cpp | 54 ++++ > > contrib/kyua/os/freebsd/main.hpp | 41 +++ > > contrib/kyua/os/freebsd/utils/jail.cpp | 306 ++++++++++++++++++++++ > > contrib/kyua/os/freebsd/utils/jail.hpp | 64 +++++ > > contrib/kyua/utils/config/nodes.ipp | 9 +- > > contrib/kyua/utils/process/executor.cpp | 42 +++ > > contrib/kyua/utils/process/executor.hpp | 1 + > > usr.bin/kyua/Makefile | 15 +- > > 40 files changed, 1792 insertions(+), 28 deletions(-) > > > > This broke the gcc build: > https://ci.freebsd.org/job/FreeBSD-main-amd64-gcc13_build/1307/ See https://reviews.freebsd.org/D46041 for a workaround. -- Brooks From nobody Fri Jul 19 23:28:14 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQm7f43yfz5Qb1L; Fri, 19 Jul 2024 23:28: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQm7f3XKsz4chr; Fri, 19 Jul 2024 23:28:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721431694; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=4pORcXUtcUOcwhI+tuL++ff4DWB5kXOs77Y4pVdS4PQ=; b=EWE0LYUrnXN369GSMCr5kD9s5MMctJiXqwxlwo2zIms882jgkWkptAwxNCewdfPsqQi0vV uV/djRCJAli1ceMN9JMKlDiJfuaOpZEDjmWQEc7XfCaCfl8I33UfLvcWahxtpig+Vsjm0R VJmD3l30W/QCT4tZeMvU5771AuvXZZi6uqjUcRw/376+4tl7vPGXbRWik6N53Gyoq6XIfa 2QH2wQnMenHY5BwkYs1cyPV++z3HiMQ7mNJMifnA/hDiLGzF4nWfdTGJrJNCzewEj/Dt8u ipITbtpl/SAEec2u3oDS05i8GZIkgn7st4id+3Viu+428qKlKN5VYxPQLF1Eqw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721431694; a=rsa-sha256; cv=none; b=bhMGydi7BzgKvaKOvaEJBoakPRR6mDa1N/1HAINH57t98nEhXprV4qiJZrcHd3wy+M3GJ0 l6YDK4syVvH3XABuG8K2IcR9kCvStnuIQfrk8Xa7NNfzMDq0cgBhmKPssyCHIftC8bceTz H7LyltrvDxeZkQBHppTZlM0uXRk1wWmd7HZcg2igJ4rRrvDDECkxeGusvLMkVNODxPpg8U z5VHHCzSJ34GR9cUe8nFhrkAKi1Z+cFlidn9KtmJAXj4vdSc+pYBEGFCB0HsLkoM6x7bRY m14Px1WuP9i5nKR+9fpWioCavWayTnV6pxY2QuP1JNL5vwdlMWmVjggSG34JdA== 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=1721431694; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=4pORcXUtcUOcwhI+tuL++ff4DWB5kXOs77Y4pVdS4PQ=; b=p2FhYQHkf0auhxeg2THz3kSzW8GYEyBG/EqMg7oQUvroEnsV4HmRRtjAzDHxp239/LBkfn zBhwlOEQYyZWTMUr4RUDHPj9HSh9IFhhv0ovjJqvyk7kKQ48AzdO7Qe7qC63WCLck61C6d PDqNbrKlErYt7czDeVDhh/O2+7+vHxJdhvrQ9jHHC+0bjGRF7TG10VF2W3IbI1jpw9XjmM A18cYN9v+mrOQa/5DMFQ2WBqtubivyzwWmoP9pa/Ydeg4chdCRRSHF2GEP+HR0RLJvi4dc SVjJtPiyrL4ZxQZj3lNpf7Q6UuczUULJxBkbhknvM64S/ihEpVBl8grtvZ/jDA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQm7f37fCzsSP; Fri, 19 Jul 2024 23:28:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46JNSEW4070915; Fri, 19 Jul 2024 23:28:14 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46JNSExY070912; Fri, 19 Jul 2024 23:28:14 GMT (envelope-from git) Date: Fri, 19 Jul 2024 23:28:14 GMT Message-Id: <202407192328.46JNSExY070912@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Brooks Davis Subject: git: 47fb5d2b13c5 - main - kyua: fix gcc builds List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: brooks X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 47fb5d2b13c5ca8e1a3b05ed223d62ea4b43b3e8 Auto-Submitted: auto-generated The branch main has been updated by brooks: URL: https://cgit.FreeBSD.org/src/commit/?id=47fb5d2b13c5ca8e1a3b05ed223d62ea4b43b3e8 commit 47fb5d2b13c5ca8e1a3b05ed223d62ea4b43b3e8 Author: Brooks Davis AuthorDate: 2024-07-19 23:24:35 +0000 Commit: Brooks Davis CommitDate: 2024-07-19 23:28:06 +0000 kyua: fix gcc builds For some reason execenv::exec() isn't successfully marked noreturn (rlibby reports that virtual functions can't be noreturn), but calling methods are so gcc rightly complains. Work around this by adding explicit __builtin_unreachable() calls. Reviewed by: imp, markj Fixes: 257e70f1d5ee kyua: Add FreeBSD Jail execution environment support Differential Revision: https://reviews.freebsd.org/D46041 --- contrib/kyua/engine/atf.cpp | 2 ++ contrib/kyua/engine/plain.cpp | 1 + contrib/kyua/engine/tap.cpp | 1 + 3 files changed, 4 insertions(+) diff --git a/contrib/kyua/engine/atf.cpp b/contrib/kyua/engine/atf.cpp index f6746dd2f29f..47f3bd2a1903 100644 --- a/contrib/kyua/engine/atf.cpp +++ b/contrib/kyua/engine/atf.cpp @@ -196,6 +196,7 @@ engine::atf_interface::exec_test(const model::test_program& test_program, auto e = execenv::get(test_program, test_case_name); e->init(); e->exec(args); + __builtin_unreachable(); } @@ -227,6 +228,7 @@ engine::atf_interface::exec_cleanup( auto e = execenv::get(test_program, test_case_name); e->exec(args); + __builtin_unreachable(); } diff --git a/contrib/kyua/engine/plain.cpp b/contrib/kyua/engine/plain.cpp index 9a2c63f8b663..0aba9b3fb6fa 100644 --- a/contrib/kyua/engine/plain.cpp +++ b/contrib/kyua/engine/plain.cpp @@ -110,6 +110,7 @@ engine::plain_interface::exec_test( auto e = execenv::get(test_program, test_case_name); e->init(); e->exec(args); + __builtin_unreachable(); } diff --git a/contrib/kyua/engine/tap.cpp b/contrib/kyua/engine/tap.cpp index ed35ba40433f..716212d18d02 100644 --- a/contrib/kyua/engine/tap.cpp +++ b/contrib/kyua/engine/tap.cpp @@ -157,6 +157,7 @@ engine::tap_interface::exec_test( auto e = execenv::get(test_program, test_case_name); e->init(); e->exec(args); + __builtin_unreachable(); } From nobody Sat Jul 20 00:32:25 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQnYj5lnQz5Qhp8; Sat, 20 Jul 2024 00:32: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQnYj4fbCz4kf5; Sat, 20 Jul 2024 00:32:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721435545; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=sxkp1erEjxtySUq+kaT9zHJVW7DZTht897aQJugqF2s=; b=X/7l/9fcRYS06PokIBZOMYOUVNzpSAZEg1zBJgI1ML7MwmEQ3RUEFpIYmybOXZTdo68SWK bfSj8VT0kaTVIxFDgNO7pOSEuuV1BSYjdoj0nrLIPpoV52kiNF1YdQUner+CDE+uvbKva1 Bte7rGtQDIGNE2QVF46RC6egO21tTLyGU+oWzXKJNZ2iMgZmuX4FCNyioc93ZYJ2LJ6h28 B795STqE4pEIbK8XZ6VxobmDQW5bMIj+fOcv+OXn3qbx/EJnOBdn+5S4TmWfsfjOd0Xa5E mS7g07uVR5MOayqd63ELF7IyXOLx7g1YPGxIB+k4hvHgyYblTN5KyHebyDgJBg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721435545; a=rsa-sha256; cv=none; b=ZJnLzCCb2x3B8CYS1hP1IuMmJwjMzbU2exaDmWma2hGF/iawEV+b9dfxu9T6wF794d268T 5umJcGfqSGKZEajbVJAH11Gcc/v25qj15RI9ktVpSRoiKSyaANE3lZYdvIa1VSBh9V2VI/ wudM9Q6Kohe/P/DfNoKAQ0IRTftLTeh1eHQb8VqEE9/+2jkyte/X7eWgHerQK1XCon0ECQ 7eKAx1NU2H/LeDZsQ8ygcrhdI15CPN5dgjZlrDmA47LTLGwloLG2zYQLFah6aOghiskv/1 ko5rvXEloni5N0aPFaXZ6a40FBgF835rfHGARG7+rmUJQCjRt4+UxqNmJAv/bw== 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=1721435545; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=sxkp1erEjxtySUq+kaT9zHJVW7DZTht897aQJugqF2s=; b=cBM3siXcbWM00OhkXIXcdK00tDokOYf2DHjb0RbDNP0b1iVFOwzFa0yS+RbOAgGVuHLxKU ZN2JNeJZanNsg9ZfBPRlaC2fOVg6ymCgmgUTCzWgTc0YYtnessPuXTplSHnMJEry0jmkO5 eN9knhn5XXx8NcTh8ceQ8OJhiw/MsAMJGlKLQy/gLZFYX0VqAv9e3Zf9nKh9d/hhhTj/Qc XnMflk3RrN3qFYT6Ep+VWfOWgNGhRD67eenmmO0dnUJnZdWHUCfa0n86Dse7BS6n2/1m+O 20B1baTSNuBYPiVNHY+TSCC+LzoqEntQnI/I6Rks558lsTNXm7z03aVqI7duiw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQnYj4Gf7zvHG; Sat, 20 Jul 2024 00:32:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46K0WPli088779; Sat, 20 Jul 2024 00:32:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46K0WPku088776; Sat, 20 Jul 2024 00:32:25 GMT (envelope-from git) Date: Sat, 20 Jul 2024 00:32:25 GMT Message-Id: <202407200032.46K0WPku088776@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: d15b7f50c73e - stable/13 - 13.4: update stable/13 to -PRERELEASE List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: d15b7f50c73e16c8f0706ca163c53da9af86ffe3 Auto-Submitted: auto-generated The branch stable/13 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=d15b7f50c73e16c8f0706ca163c53da9af86ffe3 commit d15b7f50c73e16c8f0706ca163c53da9af86ffe3 Author: Colin Percival AuthorDate: 2024-07-20 00:31:41 +0000 Commit: Colin Percival CommitDate: 2024-07-20 00:31:41 +0000 13.4: update stable/13 to -PRERELEASE This marks the start of the FreeBSD 13.4 release cycle; the stable/13 tree is now in "code slush". Developers are encouraged to prioritize fixing bugs (and/or merging bug fixes from HEAD) over new features at this time. Commit approval from re@ is not required but if new features introduce problems they may be removed from the release. Approved by: re (implicit) Sponsored by: Amazon --- sys/conf/newvers.sh | 4 ++-- usr.bin/yacc/config.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/conf/newvers.sh b/sys/conf/newvers.sh index bdda58fae469..cb4422125aea 100644 --- a/sys/conf/newvers.sh +++ b/sys/conf/newvers.sh @@ -52,8 +52,8 @@ # TYPE="FreeBSD" -REVISION="13.3" -BRANCH="STABLE" +REVISION="13.4" +BRANCH="PRERELEASE" if [ -n "${BRANCH_OVERRIDE}" ]; then BRANCH=${BRANCH_OVERRIDE} fi diff --git a/usr.bin/yacc/config.h b/usr.bin/yacc/config.h index a5e41906082b..d3b415df4366 100644 --- a/usr.bin/yacc/config.h +++ b/usr.bin/yacc/config.h @@ -86,7 +86,7 @@ #define STDC_HEADERS 1 /* Define to the system name. */ -#define SYSTEM_NAME "freebsd13.3" +#define SYSTEM_NAME "freebsd13.4" /* "Define to 1 if you want to use dbmalloc for testing." */ /* #undef USE_DBMALLOC */ From nobody Sat Jul 20 02:59:06 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQrpy5gVDz5Qxtt; Sat, 20 Jul 2024 02:59: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQrpy3Zhbz43BH; Sat, 20 Jul 2024 02:59:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721444346; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=YssqplutNgRt72tXtet9QfYu7Ko0FRSgOIXV9HoYa9M=; b=sbtRN/QigeqTnmJuX6YulRpsVA37EG5tjka2pk/WinkPui0Z1orIfXH0QH5Oj+mF0iIb72 eqymNl31mamt13gKWbFxMkjT5RhMvoOr06OkF0/8fP6YOxc8b2mr9VidAcaZLgrn8lbVVU yyD/CT8NuCsJ8Bg79hZAumbYbgjjvoLqlAX0gzT8689ve6AW/rfhCtpOLL6OBqlOpLpNtd nsa2BFzeseZrx7dgAXgjvIPlcKbKoAhBcfh4/mCnde2Zt2TprFsRJlV8ToCbpuPlmIoqOR CaY+s0eJIU+eXfJyj3gnkpV3m7O/N92YvUzjhE0knHUXYEJYBk7F1EkOPnGWZg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721444346; a=rsa-sha256; cv=none; b=sHvdtCNo9WsCs5nPpNeTkOxFXMna5cCmzKMzh+7HrKuEKMiQXM8p53ryYctzdfqNC5bYpX kmA1zrJpF83c1vLG+xufz0jQkCGvElDSK5Rbdd6DiqUiXI6+IY5qJ7B9idE8//4J6pjs6m csUZID1nDM+iLKoufOw26hFmoLjf/s3aHNbtfs+WYby9f266CAm7leftoQXLQyaUI3r43i 2IuJczXqscT0IHDo7wjf3l5KfeoiaDcxWXxbZxMy8ktIRuKumSJXZz9nK3RQnNbS01Ij2X tN124CZFr+VtiDugS0z0aEAng6qpAI/Bbt5Vf9Qbyad49RNjR6IwdUnZAK29Hw== 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=1721444346; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=YssqplutNgRt72tXtet9QfYu7Ko0FRSgOIXV9HoYa9M=; b=J1KPEpduiRkP4oex4xFcgcYBDTKzpAEbCQiBnqiotKJvvIOQlbg2FIEPnww85uIyvrlq4C vv0u3dBx7Xskv8sbrLM+pQiP6O1S0T6aBBl/rZHmF9MnLkLRgt0IMGOE9fb7F2qZgAMcrP LZAcI3gOhHq648c5Wu8LTPl/pGWr1K+M04H9NWzBXmQFKL5GAUDrXs0SCfEwhfklDyRP5H ab9QohegGC/7JJ2CzTpklnyE6JQOxEXjL/prcQFYM3RCaEpjs7FaiC0Dhgb209JTlAX8+Y 6G1QVbj8UQ82bB1SpSkJllNAkmyB9b7c1JvB6aqk1TeDQ9FkC3WcAheK/Ai+2A== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQrpy33z8zyVQ; Sat, 20 Jul 2024 02:59:06 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46K2x6g9024398; Sat, 20 Jul 2024 02:59:06 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46K2x6Vt024395; Sat, 20 Jul 2024 02:59:06 GMT (envelope-from git) Date: Sat, 20 Jul 2024 02:59:06 GMT Message-Id: <202407200259.46K2x6Vt024395@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: e82644e59ece - main - cam/iosched: Add a counter of I/Os that take too long List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e82644e59ece5cdc67250262508e81fa22deea90 Auto-Submitted: auto-generated The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=e82644e59ece5cdc67250262508e81fa22deea90 commit e82644e59ece5cdc67250262508e81fa22deea90 Author: Warner Losh AuthorDate: 2024-07-20 02:52:40 +0000 Commit: Warner Losh CommitDate: 2024-07-20 02:53:37 +0000 cam/iosched: Add a counter of I/Os that take too long Add kern.cam.DEV.UNIT.iosched.too_long (to count I/Os taking too long) and kern.cam.DEV.UNIT.bad_latency (to set this threshold, defaults to 500ms). Each class of I/O (read, write, trim) has its own counters and thresholds. Sponsored by: Netflix Reviewed by: jhb Differential Revision: https://reviews.freebsd.org/D46033 --- sys/cam/cam_iosched.c | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/sys/cam/cam_iosched.c b/sys/cam/cam_iosched.c index 471e6c355d69..022eb23cb621 100644 --- a/sys/cam/cam_iosched.c +++ b/sys/cam/cam_iosched.c @@ -271,6 +271,9 @@ struct iop_stats { sbintime_t emvar; sbintime_t sd; /* Last computed sd */ + uint64_t too_long; /* Number of I/Os greater than bad lat threshold */ + sbintime_t bad_latency; /* Latency threshold */ + uint32_t state_flags; #define IOP_RATE_LIMITED 1u @@ -856,6 +859,7 @@ cam_iosched_iop_stats_init(struct cam_iosched_softc *isc, struct iop_stats *ios) ios->total = 0; ios->ema = 0; ios->emvar = 0; + ios->bad_latency = SBT_1S / 2; /* Default to 500ms */ ios->softc = isc; cam_iosched_limiter_init(ios); } @@ -1046,6 +1050,15 @@ cam_iosched_iop_stats_sysctl_init(struct cam_iosched_softc *isc, struct iop_stat OID_AUTO, "errs", CTLFLAG_RD, &ios->errs, 0, "# of transactions completed with an error"); + SYSCTL_ADD_U64(ctx, n, + OID_AUTO, "too_long", CTLFLAG_RD, + &ios->too_long, 0, + "# of transactions completed took too long"); + SYSCTL_ADD_PROC(ctx, n, + OID_AUTO, "bad_latency", + CTLTYPE_STRING | CTLFLAG_RW | CTLFLAG_MPSAFE, + &ios->bad_latency, 0, cam_iosched_sbintime_sysctl, "A", + "Threshold for counting transactions that took too long (in us)"); SYSCTL_ADD_PROC(ctx, n, OID_AUTO, "limiter", @@ -1916,6 +1929,14 @@ cam_iosched_update(struct iop_stats *iop, sbintime_t sim_latency) sbintime_t y, deltasq, delta; int i; + /* + * Simple threshold: count the number of events that excede the + * configured threshold. + */ + if (sim_latency > iop->bad_latency) { + iop->too_long++; + } + /* * Keep counts for latency. We do it by power of two buckets. * This helps us spot outlier behavior obscured by averages. From nobody Sat Jul 20 02:59:07 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQrpz4k7gz5Qxjk; Sat, 20 Jul 2024 02:59: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQrpz3q0yz43BJ; Sat, 20 Jul 2024 02:59:07 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721444347; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ykcTW4rh9pXGay7pkBKzoNpyqIsfRYl99WN2Q9Xn7+w=; b=TOsgpxSJMr4BnRrGJyBnXazSrgvxd0+GPhj9i0lLRsSykPUg8Awf6OmhVd5a8BdM78n/Ch upRSMU/3NxSnwXJjt13cDNppI//1sC4IQx9qOpXoTHS28sRwR1vf+DrPwB2FzkNwzoDHP4 uVUDMbbeHUvR0vAnxj3qcfHVbf1lt4Jr8EJ75us7RiRaMStKHngjIaOmYjfimag2DCTCv2 zX7f8+ycT3Wy2Bzp8ps7bIsGHOOhX2qLfqfgf++98t/4QzoTcMcv76DS8+iOlN05Fw2z8n FNq9szSBP8LMRfj2iIx3w4EQafC16SXL/ko0I36K8Mi6sd08FYhhNoOPU6BrRg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721444347; a=rsa-sha256; cv=none; b=idS+LrvocIZX0SJVuD5VWAoPNa8ipuctZDNjZaPNvLN3r+cEFwACKhcgoNTb4RXvv05yZT beuy3kC1H62/ULj/3gdz8B1s2Sbcy6MbWHp8oR2OF+p6gO7oNJGLTbRUo+FqItNfpTdTj4 J28WsHn6HmQlP7qPeVVeLpZFLVa6b4flI8bxzDri+mW7h9acj3QJE5ywjM+eTGADR6oqA5 Qsy5mbwK4goPcXhaBCt7id4nksWNp9EQiCI4svN2M9Qy90HaCnGrRmRMQTVU2bFi/jeYUx tFWeGfTTGy42FoQL3UNteSSyWqYwNWJbI4uEwen79GOWGAclFh9jp+oRUgXj0w== 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=1721444347; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ykcTW4rh9pXGay7pkBKzoNpyqIsfRYl99WN2Q9Xn7+w=; b=dWnDJFOq+mO3hnGntvF4kgwCod3so662jhnHDyCRh3scv8T/lZIA2MIiu7s703eIE6Wrcw xI1Wr6/4q9/akuUmVDSLgyAUw3hOABxI+3NMkKL27oaeuE7b027grAkwQyhYcJoKBBoIjL wWrgtvM6Vs1Uj2sMtqHOzHBpAZJqU6z16rk1lfOCSd2wZIS4jHqogX75HFvFOHlU2PQA7b jr529pm8ttKqI9jlV5rukG15JehvMpN+JhChsHVXm597RwVaZni1c9nSk0oThRxuPYF8+n nKyL0zVgA0vNlEyzPKG8U9fVsdrBsEb3KnCm5hoOOvWxOYpxWa0oXhzovn2duQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQrpz3Qj8zyw6; Sat, 20 Jul 2024 02:59:07 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46K2x7Cd024459; Sat, 20 Jul 2024 02:59:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46K2x7sA024456; Sat, 20 Jul 2024 02:59:07 GMT (envelope-from git) Date: Sat, 20 Jul 2024 02:59:07 GMT Message-Id: <202407200259.46K2x7sA024456@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: 148c173485ee - main - cam/iosched: Pass the transaction down we're collecting stats for List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 148c173485eea8309e3c95db741686b3c71e83de Auto-Submitted: auto-generated The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=148c173485eea8309e3c95db741686b3c71e83de commit 148c173485eea8309e3c95db741686b3c71e83de Author: Warner Losh AuthorDate: 2024-07-20 02:52:50 +0000 Commit: Warner Losh CommitDate: 2024-07-20 02:53:37 +0000 cam/iosched: Pass the transaction down we're collecting stats for Pass the struct bio * down to the stats collection routines. This allows us to collect better stats and report more details. Sponsored by: Netflix Reviewed by: jhb Differential Revision: https://reviews.freebsd.org/D46034 --- sys/cam/cam_iosched.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/sys/cam/cam_iosched.c b/sys/cam/cam_iosched.c index 022eb23cb621..330d5ea22b61 100644 --- a/sys/cam/cam_iosched.c +++ b/sys/cam/cam_iosched.c @@ -758,7 +758,7 @@ cam_iosched_cl_maybe_steer(struct control_loop *clp) #ifdef CAM_IOSCHED_DYNAMIC static void cam_iosched_io_metric_update(struct cam_iosched_softc *isc, - sbintime_t sim_latency, int cmd, size_t size); + sbintime_t sim_latency, const struct bio *bp); #endif static inline bool @@ -1801,8 +1801,8 @@ cam_iosched_bio_complete(struct cam_iosched_softc *isc, struct bio *bp, sim_latency = cam_iosched_sbintime_t(done_ccb->ccb_h.qos.periph_data); - cam_iosched_io_metric_update(isc, sim_latency, - bp->bio_cmd, bp->bio_bcount); + cam_iosched_io_metric_update(isc, sim_latency, bp); + /* * Debugging code: allow callbacks to the periph driver when latency max * is exceeded. This can be useful for triggering external debugging actions. @@ -1924,7 +1924,8 @@ static sbintime_t latencies[LAT_BUCKETS - 1] = { }; static void -cam_iosched_update(struct iop_stats *iop, sbintime_t sim_latency) +cam_iosched_update(struct iop_stats *iop, sbintime_t sim_latency, + const struct bio *bp __unused) { sbintime_t y, deltasq, delta; int i; @@ -2014,18 +2015,17 @@ cam_iosched_update(struct iop_stats *iop, sbintime_t sim_latency) static void cam_iosched_io_metric_update(struct cam_iosched_softc *isc, - sbintime_t sim_latency, int cmd, size_t size) + sbintime_t sim_latency, const struct bio *bp) { - /* xxx Do we need to scale based on the size of the I/O ? */ - switch (cmd) { + switch (bp->bio_cmd) { case BIO_READ: - cam_iosched_update(&isc->read_stats, sim_latency); + cam_iosched_update(&isc->read_stats, sim_latency, bp); break; case BIO_WRITE: - cam_iosched_update(&isc->write_stats, sim_latency); + cam_iosched_update(&isc->write_stats, sim_latency, bp); break; case BIO_DELETE: - cam_iosched_update(&isc->trim_stats, sim_latency); + cam_iosched_update(&isc->trim_stats, sim_latency, bp); break; default: break; From nobody Sat Jul 20 02:59:08 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQrq06ms3z5QxxB; Sat, 20 Jul 2024 02:59: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQrq04tM4z433R; Sat, 20 Jul 2024 02:59:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721444348; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=dAOj9u/em+KgLrWBYgADkmtxXnNti42poIBJVy0qwNw=; b=Okt8SzR/o4LcDLBAyvBWugYTYbBN+yDBmFWDKCxD3/tvZhk7CmICjYRMLBImgc44XxYDs0 e9ddsahCBUOt5x03NZ50tS5+tdO9oxL/iyMzR1v5uaADw8/gBxicsFylaPd56WkCEStRXT lUfDC/kUwW8RMv7htqarXjmIagdL1lDrySvkULYqSHbScdd2GC8gY1Q+/JAgmOZcHt2DcF YG/dES/d2RuCvnmxMm6GLnu8WohPZUy+OI/VhkL9B/KZPkqzUJAQjaASrOQfe5jFOlQu63 fQFu29R/2AMD5von+L8uLRkrCSl9LAWxGKhUsQOLKznyvK9IQv+d2c6rbYI57Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721444348; a=rsa-sha256; cv=none; b=GQ6OlT6dHcxQG7eYOOfNWxnGkOEs6tkx2o6D+Jayd9I3fyIzuh/LEFdHT4pw39LKD833OX Uc1zqnvU3y7xzFKVFHtAX/cj31O5kG6Q7smEUlrAMJ1Lgj2/denk9YxFZ/aRQRflUpCO7O gqJt6w3NPGhCbjtB5ybRL/xSYGzTJEBBXIwCnSHlj4BVurnZBwsqMhueAFK0gklUubZ5Bt u5hTl4uPyFFdc5mCuyLaoflETy66b/FEJlDXqHTO2po6csanAaorUTthctDBZn9w0+tg7m wQso4YjH5Um8dy2rbIbupBANsfeyVZKjWVu1mEv8Y5PFgHVmEOC9PuIzHeO9Pw== 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=1721444348; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=dAOj9u/em+KgLrWBYgADkmtxXnNti42poIBJVy0qwNw=; b=cnJJ4MIoiZnPKHpuJFJPkNQi14h5yaqwQDAgiRBN4irZIrdzEzr3pcGId9SOGv7wdWjmyI DY8EBtjqH+enDS/TH3IEz+j8yKk6ueDAYhaj16gI4DKmRqUmc2O3um2UbJ6kJve+tI4P4v Xj7sesRj5CBnde/h9OMKgOAxZ+Azq+6guoTaynXsp2tEMzhMoxyBRiQa9dJAYZV/hPHhHL +qwBHB05AnKCo8iqNd704J6/V1fDn/6Tf6qabN5MSapUy4Wjdc/QlBstztvTfnGXFXmaZt suSIrDiuW1G8XdZL9jE/qbD/+HUClJVuXzqBoUtrE/6Gs10dLxfocRdlSOQRMQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQrq04VDlzySD; Sat, 20 Jul 2024 02:59:08 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46K2x8Xk024507; Sat, 20 Jul 2024 02:59:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46K2x8sA024504; Sat, 20 Jul 2024 02:59:08 GMT (envelope-from git) Date: Sat, 20 Jul 2024 02:59:08 GMT Message-Id: <202407200259.46K2x8sA024504@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: 6f1dd6071a91 - main - cam/iosched: Pass in the disk when initializing List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 6f1dd6071a9171b8d1472ba36f6045a7a10b622a Auto-Submitted: auto-generated The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=6f1dd6071a9171b8d1472ba36f6045a7a10b622a commit 6f1dd6071a9171b8d1472ba36f6045a7a10b622a Author: Warner Losh AuthorDate: 2024-07-20 02:53:01 +0000 Commit: Warner Losh CommitDate: 2024-07-20 02:53:37 +0000 cam/iosched: Pass in the disk when initializing The disk is nice to have at times, especially when you need the sector size. At present, the only plans for this are related to logging. Sponsored by: Netflix Reviewed by: jhb Differential Revision: https://reviews.freebsd.org/D46035 --- sys/cam/ata/ata_da.c | 19 ++++++++++--------- sys/cam/cam_iosched.c | 5 ++++- sys/cam/cam_iosched.h | 3 ++- sys/cam/nvme/nvme_da.c | 17 +++++++++-------- sys/cam/scsi/scsi_da.c | 16 ++++++++-------- 5 files changed, 33 insertions(+), 27 deletions(-) diff --git a/sys/cam/ata/ata_da.c b/sys/cam/ata/ata_da.c index 6e008cfc8d22..2c1183b74c1d 100644 --- a/sys/cam/ata/ata_da.c +++ b/sys/cam/ata/ata_da.c @@ -1834,13 +1834,6 @@ adaregister(struct cam_periph *periph, void *arg) announce_buf = softc->announce_temp; bzero(announce_buf, ADA_ANNOUNCETMP_SZ); - if (cam_iosched_init(&softc->cam_iosched, periph) != 0) { - printf("adaregister: Unable to probe new device. " - "Unable to allocate iosched memory\n"); - free(softc, M_DEVBUF); - return(CAM_REQ_CMP_ERR); - } - periph->softc = softc; xpt_path_inq(&softc->cpi, periph->path); @@ -1901,8 +1894,6 @@ adaregister(struct cam_periph *periph, void *arg) } else { softc->flags |= ADA_FLAG_ROTATING; } - cam_iosched_set_sort_queue(softc->cam_iosched, - (softc->flags & ADA_FLAG_ROTATING) ? -1 : 0); softc->disk = disk_alloc(); adasetgeom(softc, cgd); softc->disk->d_devstat = devstat_new_entry(periph->periph_name, @@ -1921,6 +1912,16 @@ adaregister(struct cam_periph *periph, void *arg) softc->disk->d_name = "ada"; softc->disk->d_drv1 = periph; softc->disk->d_unit = periph->unit_number; + + if (cam_iosched_init(&softc->cam_iosched, periph, softc->disk) != 0) { + printf("adaregister: Unable to probe new device. " + "Unable to allocate iosched memory\n"); + free(softc, M_DEVBUF); + return(CAM_REQ_CMP_ERR); + } + cam_iosched_set_sort_queue(softc->cam_iosched, + (softc->flags & ADA_FLAG_ROTATING) ? -1 : 0); + cam_periph_lock(periph); dp = &softc->params; diff --git a/sys/cam/cam_iosched.c b/sys/cam/cam_iosched.c index 330d5ea22b61..cfefc8098d18 100644 --- a/sys/cam/cam_iosched.c +++ b/sys/cam/cam_iosched.c @@ -314,6 +314,7 @@ struct control_loop { struct cam_iosched_softc { struct bio_queue_head bio_queue; struct bio_queue_head trim_queue; + const struct disk *disk; /* scheduler flags < 16, user flags >= 16 */ uint32_t flags; int sort_io_queue; @@ -1153,12 +1154,14 @@ cam_iosched_cl_sysctl_fini(struct control_loop *clp) * sizeof struct cam_iosched_softc. */ int -cam_iosched_init(struct cam_iosched_softc **iscp, struct cam_periph *periph) +cam_iosched_init(struct cam_iosched_softc **iscp, struct cam_periph *periph, + const struct disk *dp) { *iscp = malloc(sizeof(**iscp), M_CAMSCHED, M_NOWAIT | M_ZERO); if (*iscp == NULL) return ENOMEM; + (*iscp)->disk = dp; #ifdef CAM_IOSCHED_DYNAMIC if (iosched_debug) printf("CAM IOSCHEDULER Allocating entry at %p\n", *iscp); diff --git a/sys/cam/cam_iosched.h b/sys/cam/cam_iosched.h index c8e4341f5095..e1019c531579 100644 --- a/sys/cam/cam_iosched.h +++ b/sys/cam/cam_iosched.h @@ -80,7 +80,8 @@ cam_iosched_sbintime_t(uintptr_t delta) typedef void (*cam_iosched_latfcn_t)(void *, sbintime_t, struct bio *); -int cam_iosched_init(struct cam_iosched_softc **, struct cam_periph *periph); +int cam_iosched_init(struct cam_iosched_softc **, struct cam_periph *periph, + const struct disk *dp); void cam_iosched_fini(struct cam_iosched_softc *); void cam_iosched_sysctl_init(struct cam_iosched_softc *, struct sysctl_ctx_list *, struct sysctl_oid *); struct bio *cam_iosched_next_trim(struct cam_iosched_softc *isc); diff --git a/sys/cam/nvme/nvme_da.c b/sys/cam/nvme/nvme_da.c index 41c552e2780a..1a93ea71ba77 100644 --- a/sys/cam/nvme/nvme_da.c +++ b/sys/cam/nvme/nvme_da.c @@ -862,13 +862,6 @@ ndaregister(struct cam_periph *periph, void *arg) return(CAM_REQ_CMP_ERR); } - if (cam_iosched_init(&softc->cam_iosched, periph) != 0) { - printf("ndaregister: Unable to probe new device. " - "Unable to allocate iosched memory\n"); - free(softc, M_DEVBUF); - return(CAM_REQ_CMP_ERR); - } - /* ident_data parsing */ periph->softc = softc; @@ -891,7 +884,6 @@ ndaregister(struct cam_periph *periph, void *arg) quirks = softc->quirks; TUNABLE_INT_FETCH(announce_buf, &quirks); softc->quirks = quirks; - cam_iosched_set_sort_queue(softc->cam_iosched, 0); softc->disk = disk = disk_alloc(); disk->d_rotation_rate = DISK_RR_NON_ROTATING; disk->d_open = ndaopen; @@ -953,6 +945,15 @@ ndaregister(struct cam_periph *periph, void *arg) DEVSTAT_ALL_SUPPORTED, DEVSTAT_TYPE_DIRECT | XPORT_DEVSTAT_TYPE(cpi.transport), DEVSTAT_PRIORITY_DISK); + + if (cam_iosched_init(&softc->cam_iosched, periph, disk) != 0) { + printf("ndaregister: Unable to probe new device. " + "Unable to allocate iosched memory\n"); + free(softc, M_DEVBUF); + return(CAM_REQ_CMP_ERR); + } + cam_iosched_set_sort_queue(softc->cam_iosched, 0); + /* * Add alias for older nvd drives to ease transition. */ diff --git a/sys/cam/scsi/scsi_da.c b/sys/cam/scsi/scsi_da.c index 59745231bca5..4ecf8c35aca2 100644 --- a/sys/cam/scsi/scsi_da.c +++ b/sys/cam/scsi/scsi_da.c @@ -2804,13 +2804,6 @@ daregister(struct cam_periph *periph, void *arg) return(CAM_REQ_CMP_ERR); } - if (cam_iosched_init(&softc->cam_iosched, periph) != 0) { - printf("daregister: Unable to probe new device. " - "Unable to allocate iosched memory\n"); - free(softc, M_DEVBUF); - return(CAM_REQ_CMP_ERR); - } - LIST_INIT(&softc->pending_ccbs); softc->state = DA_STATE_PROBE_WP; bioq_init(&softc->delete_run_queue); @@ -2979,7 +2972,13 @@ daregister(struct cam_periph *periph, void *arg) softc->disk->d_hba_subdevice = cpi.hba_subdevice; snprintf(softc->disk->d_attachment, sizeof(softc->disk->d_attachment), "%s%d", cpi.dev_name, cpi.unit_number); - cam_periph_lock(periph); + + if (cam_iosched_init(&softc->cam_iosched, periph, softc->disk) != 0) { + printf("daregister: Unable to probe new device. " + "Unable to allocate iosched memory\n"); + free(softc, M_DEVBUF); + return(CAM_REQ_CMP_ERR); + } /* * Add async callbacks for events of interest. @@ -2988,6 +2987,7 @@ daregister(struct cam_periph *periph, void *arg) * fine without them and the only alternative * would be to not attach the device on failure. */ + cam_periph_lock(periph); xpt_register_async(AC_SENT_BDR | AC_BUS_RESET | AC_LOST_DEVICE | AC_ADVINFO_CHANGED | AC_SCSI_AEN | AC_UNIT_ATTENTION | AC_INQ_CHANGED, daasync, periph, periph->path); From nobody Sat Jul 20 02:59:10 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQrq45ZnXz5QxZ3; Sat, 20 Jul 2024 02:59: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQrq30BFdz4362; Sat, 20 Jul 2024 02:59:11 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721444351; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=bHA81zFaHwihW/riNVa8v1JJS1NwN/4BOgZTAq6Vsm4=; b=kqra7vrkEcZOsl87SeFgxY4X4CWscpzTMF23KsJ6a6EpSxk7gj2f34VSpO6Hj0SYsVoKNN 1jc34QcGBkt72K7XCTs4hH2tLaL1bc9+/XElxQgEorbxnz84Pc74aCvDXI6d7RfYr8pjWw MkRG1VVzUA88ci1+Tr9f3Ap2kQLyIt5YOZycBIcpva9IwOHjJMTZinC3LesQWMmJuBQ+iy QkCjWIdEpL9mgtFCiYuOWSqwQk/Se5sRddC02NmIe7KT8VmzclLogjIsVuB+7/Peg1eUE+ UnJ1P22nJi0yN24b1j0kxG4RR37n9zJ37ilQIV5U2LeKZcbUSSpWR1s9Ya4GFA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721444351; a=rsa-sha256; cv=none; b=flEJhVuXS/h7hTLR/HXofL7+tmTgrcv79yhQxwYB5guOx8Q9JfPb2fvcTd0oq744hua47B G7YaKuCGDjzGstSVOMs6QTHzwTMMjGv+vTIg7s/C4smIJT8vGltpnr/1UsUB6Bc14msMjF k3ch7yX85kQh3uU9goPrMyvGQwILcNOM++m+IGE4MKdWtidLnXf0xs58sxLw2jEBWX6TsC PxoV81VOO8Ag02zAYKFpHraeK/PrgRVbSNzrGFT+TaxJix50GeVMXptpGygCNqij9vZh45 aAucDDOH4xO1P/5QtRIe5uC/X6TuGQrlJvbpdYK65nnr8Dn0L6LojAi2e2BliA== 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=1721444351; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=bHA81zFaHwihW/riNVa8v1JJS1NwN/4BOgZTAq6Vsm4=; b=xHnCub5jWnTFX3hAFt5tiugQ/m5a/7vs3i6IESjAw6IQKRHAcSpcf/jf/B30L80bQnjSH/ llicnyZ0Ky8s+Kocf0or8UcDXxf7u1RIlt5m664x07N3eMLo8SEqrqgtsD8bEkTfVjn2He qhF9jzLZeCzN9Kb29VN8NBX3taZwOUemilp64BW3jJZjB92ycLncmHjQU5lWxY/cp4Io8X HyUXNqd1oXkVID96IZSXH0tvqtcaslw7EALuKAaIQ46i2118OGJdDhoVgCz/9mwpv5eeaS 2q4PRAuWm9aHoV7ijQCMJbG06fbE9OD4XHlhzVPEUYNlEA+Fr3Geg3TkP1Sepg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQrq26sw9zytQ; Sat, 20 Jul 2024 02:59:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46K2xAej024600; Sat, 20 Jul 2024 02:59:10 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46K2xAUc024597; Sat, 20 Jul 2024 02:59:10 GMT (envelope-from git) Date: Sat, 20 Jul 2024 02:59:10 GMT Message-Id: <202407200259.46K2xAUc024597@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: 9cbf3d618273 - main - cam/iosched: Make each periph driver provide schedule fnp List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9cbf3d618273e09cdc7e18e878b33b9305836ad8 Auto-Submitted: auto-generated The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=9cbf3d618273e09cdc7e18e878b33b9305836ad8 commit 9cbf3d618273e09cdc7e18e878b33b9305836ad8 Author: Warner Losh AuthorDate: 2024-07-20 02:53:17 +0000 Commit: Warner Losh CommitDate: 2024-07-20 02:53:37 +0000 cam/iosched: Make each periph driver provide schedule fnp When we init the iosched instance, require clients to provide a schedule function. We have almost, but not quite everything to know when it is safe to schedule new I/O. The periph drivers, however, have all the information, so make them do it when the I/O Scheduler needs to maybe schedule I/O for rate limiting, etc. and use it to do that. Sponsored by: Netflix Reviewed by: jhb Differential Revision: https://reviews.freebsd.org/D46038 --- sys/cam/ata/ata_da.c | 3 ++- sys/cam/cam_iosched.c | 6 ++++-- sys/cam/cam_iosched.h | 3 ++- sys/cam/nvme/nvme_da.c | 3 ++- sys/cam/scsi/scsi_da.c | 3 ++- 5 files changed, 12 insertions(+), 6 deletions(-) diff --git a/sys/cam/ata/ata_da.c b/sys/cam/ata/ata_da.c index 2c1183b74c1d..ae7cf14c8f8e 100644 --- a/sys/cam/ata/ata_da.c +++ b/sys/cam/ata/ata_da.c @@ -1913,7 +1913,8 @@ adaregister(struct cam_periph *periph, void *arg) softc->disk->d_drv1 = periph; softc->disk->d_unit = periph->unit_number; - if (cam_iosched_init(&softc->cam_iosched, periph, softc->disk) != 0) { + if (cam_iosched_init(&softc->cam_iosched, periph, softc->disk, + adaschedule) != 0) { printf("adaregister: Unable to probe new device. " "Unable to allocate iosched memory\n"); free(softc, M_DEVBUF); diff --git a/sys/cam/cam_iosched.c b/sys/cam/cam_iosched.c index 28b5375ae246..5f171e402ed2 100644 --- a/sys/cam/cam_iosched.c +++ b/sys/cam/cam_iosched.c @@ -315,6 +315,7 @@ struct cam_iosched_softc { struct bio_queue_head bio_queue; struct bio_queue_head trim_queue; const struct disk *disk; + cam_iosched_schedule_t schedfnc; /* scheduler flags < 16, user flags >= 16 */ uint32_t flags; int sort_io_queue; @@ -619,7 +620,7 @@ cam_iosched_ticker(void *arg) cam_iosched_limiter_tick(&isc->write_stats); cam_iosched_limiter_tick(&isc->trim_stats); - cam_iosched_schedule(isc, isc->periph); + isc->schedfnc(isc->periph); /* * isc->load is an EMA of the pending I/Os at each tick. The number of @@ -1155,13 +1156,14 @@ cam_iosched_cl_sysctl_fini(struct control_loop *clp) */ int cam_iosched_init(struct cam_iosched_softc **iscp, struct cam_periph *periph, - const struct disk *dp) + const struct disk *dp, cam_iosched_schedule_t schedfnc) { *iscp = malloc(sizeof(**iscp), M_CAMSCHED, M_NOWAIT | M_ZERO); if (*iscp == NULL) return ENOMEM; (*iscp)->disk = dp; + (*iscp)->schedfnc = schedfnc; #ifdef CAM_IOSCHED_DYNAMIC if (iosched_debug) printf("CAM IOSCHEDULER Allocating entry at %p\n", *iscp); diff --git a/sys/cam/cam_iosched.h b/sys/cam/cam_iosched.h index e1019c531579..54f9a7c02a25 100644 --- a/sys/cam/cam_iosched.h +++ b/sys/cam/cam_iosched.h @@ -79,9 +79,10 @@ cam_iosched_sbintime_t(uintptr_t delta) } typedef void (*cam_iosched_latfcn_t)(void *, sbintime_t, struct bio *); +typedef void (*cam_iosched_schedule_t)(struct cam_periph *periph); int cam_iosched_init(struct cam_iosched_softc **, struct cam_periph *periph, - const struct disk *dp); + const struct disk *dp, cam_iosched_schedule_t schedfnp); void cam_iosched_fini(struct cam_iosched_softc *); void cam_iosched_sysctl_init(struct cam_iosched_softc *, struct sysctl_ctx_list *, struct sysctl_oid *); struct bio *cam_iosched_next_trim(struct cam_iosched_softc *isc); diff --git a/sys/cam/nvme/nvme_da.c b/sys/cam/nvme/nvme_da.c index 1a93ea71ba77..1c0d5e8381d8 100644 --- a/sys/cam/nvme/nvme_da.c +++ b/sys/cam/nvme/nvme_da.c @@ -946,7 +946,8 @@ ndaregister(struct cam_periph *periph, void *arg) DEVSTAT_TYPE_DIRECT | XPORT_DEVSTAT_TYPE(cpi.transport), DEVSTAT_PRIORITY_DISK); - if (cam_iosched_init(&softc->cam_iosched, periph, disk) != 0) { + if (cam_iosched_init(&softc->cam_iosched, periph, disk, + ndaschedule) != 0) { printf("ndaregister: Unable to probe new device. " "Unable to allocate iosched memory\n"); free(softc, M_DEVBUF); diff --git a/sys/cam/scsi/scsi_da.c b/sys/cam/scsi/scsi_da.c index 4ecf8c35aca2..1a6df6171b66 100644 --- a/sys/cam/scsi/scsi_da.c +++ b/sys/cam/scsi/scsi_da.c @@ -2973,7 +2973,8 @@ daregister(struct cam_periph *periph, void *arg) snprintf(softc->disk->d_attachment, sizeof(softc->disk->d_attachment), "%s%d", cpi.dev_name, cpi.unit_number); - if (cam_iosched_init(&softc->cam_iosched, periph, softc->disk) != 0) { + if (cam_iosched_init(&softc->cam_iosched, periph, softc->disk, + daschedule) != 0) { printf("daregister: Unable to probe new device. " "Unable to allocate iosched memory\n"); free(softc, M_DEVBUF); From nobody Sat Jul 20 02:59:11 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQrq55S5Pz5QxxK; Sat, 20 Jul 2024 02:59: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQrq442V1z438m; Sat, 20 Jul 2024 02:59:12 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721444352; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=prHUlp6TLCbIick2noDkmoC5LdAv4w8/9m1ENF+ZdkM=; b=bOjSw1v8IzfaroDNHRlA/sEGk7x++5OoAsjeUs26GZ+xxoDln7iLlQ5aLGlk8GEQAYzFLL ddJz3unyxsk1Y7atLhVIWNXsQgdH5atsu/ZjbUXjdFrr8cEQapqjam7fij7FZNsTt+PZOF 5hTW1u+v00CSxbQqWcp+d6rOEmGiZwXCAKAIf3QbBlTVYz+UxR5OqhlbLr/Eed+P4xGpP3 01U2dh+sW6Ya57Bu1Qv4tgRJ2ywjr4gp2hClV4Gj+ItIGqpur0dhyxCiFRR5RcBAysKSko kLG4bzHfVkhrANmwUvN3tEd8gFdXWmNyK89+pj10/Pi9KDAgwD1h/rv2WjzM4Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721444352; a=rsa-sha256; cv=none; b=P//zVt8AZu8XFAuwOPDbt3qeZfOCC67gBU7lEGyfbA3Vsn1cYrZa3AW9Z/nd67kb60fNQA Fa9oaFLBz4doaPJxLaOlhnBBAJMAumaTuQ7J85nYB5oQKnjWfFaHHNkDIBZd2P4edQqi8t /zdZE69YEEQkaW5Oy5GgeEsO27rat1K0+xZeomnXp64bGWzb4bqwXPkX/99symIOYKqBA5 L6Y0G+g7ADcrEjcarlPG85WUpAzB/8WQddNwi9VAMRr3EWAyB0DkgPeC+WmtUrtNsQVdak 7SNCfACbI+kdcbT/a/UvMJhdmkG+4CWjoioMxnzhSj8Rth8av+vkg5zqM1N/LA== 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=1721444352; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=prHUlp6TLCbIick2noDkmoC5LdAv4w8/9m1ENF+ZdkM=; b=glqPw559ItTsLqniQjUL90PXeITuM+ABygR971xrZkpCsD3cAfJi2SyG62UTSg5jvkj3oI uA8HXK8FvTlfCPm3R723MnhLcHb72VslnyuKodJ1fNKSdu4+A2vanKZLSdX/ctFHiilLYV xz/ehAo3gE0NZgZ8z+S0JK/Sw6oi/UQ8SvYhR8CldYIQdfYNA/0JZuBnaFGUqunjUcClb5 R1WDmi3LXOWcBAUhseI5mdrFVTk4SF/i2wzyxcWKh1MVbUrvJiJzMQnTsjudTOLHo9w2ut SbPgqNSJLc4zn9vQ73czyj1O3ut/A6Q1shBZX1xVrGSYm6MhjUBNqOJxNwNpwQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQrq40JM2zyDN; Sat, 20 Jul 2024 02:59:12 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46K2xB8D024654; Sat, 20 Jul 2024 02:59:11 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46K2xBR4024651; Sat, 20 Jul 2024 02:59:11 GMT (envelope-from git) Date: Sat, 20 Jul 2024 02:59:11 GMT Message-Id: <202407200259.46K2xBR4024651@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: 9229b3105d88 - main - nvme: Fail passthrough commands right away in failed state. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9229b3105d88d44012f2c7f85344da42e857ba91 Auto-Submitted: auto-generated The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=9229b3105d88d44012f2c7f85344da42e857ba91 commit 9229b3105d88d44012f2c7f85344da42e857ba91 Author: Warner Losh AuthorDate: 2024-07-20 02:55:52 +0000 Commit: Warner Losh CommitDate: 2024-07-20 02:55:52 +0000 nvme: Fail passthrough commands right away in failed state. When the drive is failed, we can't send passthrough commands to the card, so fail them right away. Rearrange the comments to reflect the current failure paths in the driver. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D46048 --- sys/dev/nvme/nvme_qpair.c | 58 ++++++++++++++++++++--------------------------- 1 file changed, 24 insertions(+), 34 deletions(-) diff --git a/sys/dev/nvme/nvme_qpair.c b/sys/dev/nvme/nvme_qpair.c index 5be6c151bbea..9b3fe58c312c 100644 --- a/sys/dev/nvme/nvme_qpair.c +++ b/sys/dev/nvme/nvme_qpair.c @@ -1267,41 +1267,31 @@ _nvme_qpair_submit_request(struct nvme_qpair *qpair, struct nvme_request *req) tr = TAILQ_FIRST(&qpair->free_tr); req->qpair = qpair; - if (tr == NULL || qpair->recovery_state != RECOVERY_NONE) { - /* - * No tracker is available, or the qpair is disabled due to an - * in-progress controller-level reset. If we lose the race with - * recovery_state, then we may add an extra request to the queue - * which will be resubmitted later. We only set recovery_state - * to NONE with qpair->lock also held, so if we observe that the - * state is not NONE, we know it can't transition to NONE below - * when we've submitted the request to hardware. - * - * Also, as part of the failure process, we set recovery_state - * to RECOVERY_WAITING, so we check here to see if we've failed - * the controller. We set it before we call the qpair_fail - * functions, which take out the lock lock before messing with - * queued_req. Since we hold that lock, we know it's safe to - * either fail directly, or queue the failure should is_failed - * be stale. If we lose the race reading is_failed, then - * nvme_qpair_fail will fail the queued request. - */ + /* + * The controller has failed, so fail the request. Note, that this races + * the recovery / timeout code. Since we hold the qpair lock, we know + * it's safe to fail directly. is_failed is set when we fail the controller. + * It is only ever reset in the ioctl reset controller path, which is safe + * to race (for failed controllers, we make no guarantees about bringing + * it out of failed state relative to other commands). + */ + if (qpair->ctrlr->is_failed) { + nvme_qpair_manual_complete_request(qpair, req, + NVME_SCT_GENERIC, NVME_SC_ABORTED_BY_REQUEST); + return; + } - if (qpair->ctrlr->is_failed) { - /* - * The controller has failed, so fail the request. - */ - nvme_qpair_manual_complete_request(qpair, req, - NVME_SCT_GENERIC, NVME_SC_ABORTED_BY_REQUEST); - } else { - /* - * Put the request on the qpair's request queue to be - * processed when a tracker frees up via a command - * completion or when the controller reset is - * completed. - */ - STAILQ_INSERT_TAIL(&qpair->queued_req, req, stailq); - } + /* + * No tracker is available, or the qpair is disabled due to an + * in-progress controller-level reset. If we lose the race with + * recovery_state, then we may add an extra request to the queue which + * will be resubmitted later. We only set recovery_state to NONE with + * qpair->lock also held, so if we observe that the state is not NONE, + * we know it won't transition back to NONE without retrying queued + * request. + */ + if (tr == NULL || qpair->recovery_state != RECOVERY_NONE) { + STAILQ_INSERT_TAIL(&qpair->queued_req, req, stailq); return; } From nobody Sat Jul 20 02:59:13 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQrq55T6rz5QxxL; Sat, 20 Jul 2024 02:59: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQrq527CPz43Bt; Sat, 20 Jul 2024 02:59:13 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721444353; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=rKOA/s6wibUUdwbmzaiepVSlmbCPQ0Q2RHHWUTVveuA=; b=sCjdU9nKJV6rj3CpXh18CX44DOnvqQWTSB6kyADMbt2bxY8vBjCU3mWjALbw4Q99J6gTxg OyB3+0tnaQlRjL0y0kR3BGZlv1HTJ8bT6xCnMq9vXzQX7E6LpM+QIV9y6m9Qe4UIjF3u7B jcEW7mFR3y1XfctkoetbqPdJToocjyujt4koTrwCslwTktYpHpxxzIV5v8+s6BDc3Y2ctt 365GHETeK+uX3JWfDuNcxIBscatdKchjOqBhgxxSgDhBlM6Z2apMRnbrKCEFlKSr3FcgMJ teasXaG1l8r5iXYN7s2QPbC4vS9TaXIw1KSgSgR9Pmr2ZNosF0/injabHs2EYg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721444353; a=rsa-sha256; cv=none; b=vO3xojcbXSStXdtYn2VszP5awGOAH4K0XnwFjcQRtN7FwY07is9BdkcedeDATJGANomZsa D0xvt69C1X+P2VMNGPteRbCwjCN/D11sVZZqZyD+mcQjepA4IIqA+9S73aDBQVMtuA2Pk3 u8J7Lr9Fzz/35+hNZxEdZAdZD4BXlrZDcHJjwhZM8w7fgVfWnR2g/tVRa5GYoOL6aDJvi5 6AGENgx6JdGHSL0Az7PWHSD1fBYvUJ+kVuxtyIpDXDBo0EPL5At/wHQpdCH08NA3bxtbfV J2PRAWXQ4ed8XIIrNVMFbGFRKHiIdhcPRSIBaqpxNGZAtNROLBQgXmHsZeG/JA== 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=1721444353; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=rKOA/s6wibUUdwbmzaiepVSlmbCPQ0Q2RHHWUTVveuA=; b=iHBvFGkTTxI8SCQZbtsclfPwevKK+X3P4JEzqcMmitGReyPwI4ymu+0g1Pp7YNf3ec9OWp KWvRdjQDZeVWJumRQdj94pDeGScZzkqXBiLbrHMAWlj1AslP60NtiAB8vGWMqPu2IKIfeS z+0MGlj2FdNX2h1YB/v8gmVA8VMJplLAQZ5geDlt3xmqz8BZPhvblrAB8e7Igk0YuCll3J iZJ1QW2HovyrEPZUsZBqvgypWrcVjHn4pmzeLQpoY0jGNhO5bZ26OoEn8O9AnQ1S8RYReI Dy3TGju8CZDs6KCnLhOEGegW8fliLPWHnaGL1DDRBqdai/sTIbbnjBYS4WTnKA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQrq513GgzykR; Sat, 20 Jul 2024 02:59:13 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46K2xD7s024705; Sat, 20 Jul 2024 02:59:13 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46K2xDPs024702; Sat, 20 Jul 2024 02:59:13 GMT (envelope-from git) Date: Sat, 20 Jul 2024 02:59:13 GMT Message-Id: <202407200259.46K2xDPs024702@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: 123e29068ecf - main - nvme: widen nvme_qpair_manual_complete_request for better errors List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 123e29068ecf6d7c235061480967aadc153f68d4 Auto-Submitted: auto-generated The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=123e29068ecf6d7c235061480967aadc153f68d4 commit 123e29068ecf6d7c235061480967aadc153f68d4 Author: Warner Losh AuthorDate: 2024-07-20 02:56:04 +0000 Commit: Warner Losh CommitDate: 2024-07-20 02:56:04 +0000 nvme: widen nvme_qpair_manual_complete_request for better errors Make nvme_qpair_manual_complete_request take dnr as well as a print_on_error action. Make the status word computation common between it and nvme_qpair_manual_complete_tracker. And print the error when we are cancelling the I/O on failure, but not when we're filtering the I/O after we've failed. Make it private again to nvme_qpair.c. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D46049 --- sys/dev/nvme/nvme_private.h | 3 --- sys/dev/nvme/nvme_qpair.c | 37 +++++++++++++++++++++++-------------- 2 files changed, 23 insertions(+), 17 deletions(-) diff --git a/sys/dev/nvme/nvme_private.h b/sys/dev/nvme/nvme_private.h index 8415819ca20b..ff08f6581db5 100644 --- a/sys/dev/nvme/nvme_private.h +++ b/sys/dev/nvme/nvme_private.h @@ -417,9 +417,6 @@ void nvme_qpair_submit_request(struct nvme_qpair *qpair, struct nvme_request *req); void nvme_qpair_reset(struct nvme_qpair *qpair); void nvme_qpair_fail(struct nvme_qpair *qpair); -void nvme_qpair_manual_complete_request(struct nvme_qpair *qpair, - struct nvme_request *req, - uint32_t sct, uint32_t sc); void nvme_admin_qpair_enable(struct nvme_qpair *qpair); void nvme_admin_qpair_disable(struct nvme_qpair *qpair); diff --git a/sys/dev/nvme/nvme_qpair.c b/sys/dev/nvme/nvme_qpair.c index 9b3fe58c312c..755be993cee0 100644 --- a/sys/dev/nvme/nvme_qpair.c +++ b/sys/dev/nvme/nvme_qpair.c @@ -482,6 +482,20 @@ nvme_qpair_complete_tracker(struct nvme_tracker *tr, mtx_unlock(&qpair->lock); } +static uint32_t +nvme_qpair_make_status(uint32_t sct, uint32_t sc, uint32_t dnr) +{ + uint32_t status = 0; + + status |= NVMEF(NVME_STATUS_SCT, sct); + status |= NVMEF(NVME_STATUS_SC, sc); + status |= NVMEF(NVME_STATUS_DNR, dnr); + /* M=0 : this is artificial so no data in error log page */ + /* CRD=0 : this is artificial and no delayed retry support anyway */ + /* P=0 : phase not checked */ + return (status); +} + static void nvme_qpair_manual_complete_tracker( struct nvme_tracker *tr, uint32_t sct, uint32_t sc, uint32_t dnr, @@ -496,30 +510,24 @@ nvme_qpair_manual_complete_tracker( cpl.sqid = qpair->id; cpl.cid = tr->cid; - cpl.status |= NVMEF(NVME_STATUS_SCT, sct); - cpl.status |= NVMEF(NVME_STATUS_SC, sc); - cpl.status |= NVMEF(NVME_STATUS_DNR, dnr); - /* M=0 : this is artificial so no data in error log page */ - /* CRD=0 : this is artificial and no delayed retry support anyway */ - /* P=0 : phase not checked */ + cpl.status = nvme_qpair_make_status(sct, sc, dnr); nvme_qpair_complete_tracker(tr, &cpl, print_on_error); } -void +static void nvme_qpair_manual_complete_request(struct nvme_qpair *qpair, - struct nvme_request *req, uint32_t sct, uint32_t sc) + struct nvme_request *req, uint32_t sct, uint32_t sc, uint32_t dnr, + error_print_t print_on_error) { struct nvme_completion cpl; bool error; memset(&cpl, 0, sizeof(cpl)); cpl.sqid = qpair->id; - cpl.status |= NVMEF(NVME_STATUS_SCT, sct); - cpl.status |= NVMEF(NVME_STATUS_SC, sc); - + cpl.status = nvme_qpair_make_status(sct, sc, dnr); error = nvme_completion_is_error(&cpl); - if (error) { + if (error && print_on_error == ERROR_PRINT_ALL) { nvme_qpair_print_command(qpair, &req->cmd); nvme_qpair_print_completion(qpair, &cpl); } @@ -1277,7 +1285,8 @@ _nvme_qpair_submit_request(struct nvme_qpair *qpair, struct nvme_request *req) */ if (qpair->ctrlr->is_failed) { nvme_qpair_manual_complete_request(qpair, req, - NVME_SCT_GENERIC, NVME_SC_ABORTED_BY_REQUEST); + NVME_SCT_GENERIC, NVME_SC_ABORTED_BY_REQUEST, 1, + ERROR_PRINT_NONE); return; } @@ -1512,7 +1521,7 @@ nvme_qpair_fail(struct nvme_qpair *qpair) STAILQ_REMOVE_HEAD(&qpair->queued_req, stailq); mtx_unlock(&qpair->lock); nvme_qpair_manual_complete_request(qpair, req, NVME_SCT_GENERIC, - NVME_SC_ABORTED_BY_REQUEST); + NVME_SC_ABORTED_BY_REQUEST, 1, ERROR_PRINT_ALL); mtx_lock(&qpair->lock); } From nobody Sat Jul 20 04:22:47 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WQtgX1CtTz5R5wW; Sat, 20 Jul 2024 04:22: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WQtgX0c2yz4Fx9; Sat, 20 Jul 2024 04:22:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721449368; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VOvyiFQB0ucSwmJNf3H6/KFep0EaXXvXZhpTVrUby/E=; b=NEvwJTsdiysS19wnpFl3R091NoWvOg7tvhJSuhVZjmTv/C9lXqZqvk0BOWhVMcpDegr9on HFqmblHsNBMd3URg/mYKx+zbqVOr0Acuri7qu5yXvTHBr1yZ8ClgM1m9YhcwNQqOYIs0iv Ri493zStnH1uI/yqUZoTSBZqTFzwikCqtqWM9z8roTHfabvRL3IB6vU/TlLOlMnu9EXF5c 8CgJbR6lJk83e8oADEwPJCVNufwWKfkwtt7vVKzBBqDGmNckLZjHDh0KBZ/vZchDAmV+mb L80uuKJdQubXqqRz1JzlzQO/xtfWmoOxZtByHuoVlfP+pHcdP2SmYn53omM8oA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721449368; a=rsa-sha256; cv=none; b=YKmNioeyjA0spELtwQOaP3EYgC5df9nZqmRTpxRXqAd5L8VQxrZDNpXcyzP9AdHxmYrTv3 8erL8yDlZOB96aMPF2V7Ojgs5y/ekDwdbHOJKHux0dM8KfLjmqelGmCLOlBa8NWdYZpnK5 W+6PH8KIyrPN0i1K9teisemFDbryfK9TTqmxcXo0Wt4udKieG3KxPiXqWfRM2XYZrCCm0a I0CGeO9fLxr2iW69OLkc2Wa43safJoAHcZCQDDyk6+/4WPhVHXx/wMH6Zyl6Gd6uj1qupJ dohGFsmMDkNBTorX+4XRf4Qo9Rs9HsD95aSiAU8CWYaUQ1FNgy/GcZxDinqgcg== 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=1721449368; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VOvyiFQB0ucSwmJNf3H6/KFep0EaXXvXZhpTVrUby/E=; b=X2qDawHnoxja9haJOtRAkthLfe38NH4bF1SUx1YcREdEiQTuJdQDgLPqvN48+Eg8atVU6s +dPh0bFFLi0miVS6Suxp17Ef7Ul+cZbKfm48YdyXjXCSh/Zj/Fh/v1TQs40t8rRFU5OLXD Mh1u5OzYqKkG470HOawfYCoxba3Ur3VLNdaQ++gg06SZrQ297h+ZnC606EWLG+R48kj5Nc 4XWQKfwQ2X687ei+VHtWKWxx8sQQJ3/1k9ouVW7hdj62uDHRCTILu+qW9ZjV+H09elg3o5 92Z0HJl4oiByXvCufI3mzmqB/iiyKu4ORlKiw/JKua51F8l4jmsDFXSUCAiZjg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WQtgX0CfJz11q8; Sat, 20 Jul 2024 04:22:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46K4MlAq079424; Sat, 20 Jul 2024 04:22:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46K4Ml5C079421; Sat, 20 Jul 2024 04:22:47 GMT (envelope-from git) Date: Sat, 20 Jul 2024 04:22:47 GMT Message-Id: <202407200422.46K4Ml5C079421@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: 403cc016c07a - main - cam/iosched: Fix build List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 403cc016c07aada3ee0a578e484297df452b8bb3 Auto-Submitted: auto-generated The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=403cc016c07aada3ee0a578e484297df452b8bb3 commit 403cc016c07aada3ee0a578e484297df452b8bb3 Author: Warner Losh AuthorDate: 2024-07-20 04:16:59 +0000 Commit: Warner Losh CommitDate: 2024-07-20 04:16:59 +0000 cam/iosched: Fix build I was testing this in several trees, and this chunk was in the tree I tested. I didn't detect the mismerge before the commit... Fixes: 6f1dd6071a91 Sponsored by: Netflix --- sys/cam/cam_iosched.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sys/cam/cam_iosched.c b/sys/cam/cam_iosched.c index 5f171e402ed2..4f4a2b2cde55 100644 --- a/sys/cam/cam_iosched.c +++ b/sys/cam/cam_iosched.c @@ -48,6 +48,8 @@ #include +#include + static MALLOC_DEFINE(M_CAMSCHED, "CAM I/O Scheduler", "CAM I/O Scheduler buffers"); From nobody Sat Jul 20 08:53:55 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WR0hM6PJSz5RHKt; Sat, 20 Jul 2024 08: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WR0hM5n5jz4fsk; Sat, 20 Jul 2024 08: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=1721465635; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=IiIvc0o++3Y7NJ5AA6OgDeB0PN0q7AtgJSwrf+qRZIk=; b=dWYl4X635nvcqeJ0DdpizxE1F81p1mMjnCkwDSVOEZKSjmWwM6qBFz21WIFZdy+ltoVHiF KXHRo60nqQAi3VY2ve7mu76xUG43wp1A0WGl4d4+46a4z03nWyBaD5aiQ7zqHFv5xk7le7 eu+G0kJnZm7IoGrQXDDkMlO8o5LcsSXDM68x7+e00u7MouUjPHTl0w47ZKWYeGp4HhAdph DhiQ5kUEsfbspDWbwuJ0s0acq+1JG7edrHa0u+Xrm82hUN43cphASURw1GjCK2T2lQ/fib hIYt8wn772iymHtp0CjX2oiI+3BaN3uZU+GRNrU26c4EFRJE/yRUiNpc7zh9bw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721465635; a=rsa-sha256; cv=none; b=Xs1ToS5I8whTvIfAUNT/ZMXXOg89le1lg8do3VrQVIhgjWR+TWQLAsllwXeG/f/L5qWk7O Nr4lzRv+obPvzZe/+dnxdBGKGVm8BmlXh8fRJc4aC7J1i1MQEHpiRfUqJPxDQPZrI3P4bR 9X4cA7l1tQl7VNC0iTAqDhXlw8aEVXyq6EhzY4oGsYf5AO33cfSH9G3cNFvr6LRjXcr1+7 SMtasgdaWrXMt+64V9gxjq86seXI+crT0D7BBzhYqO1Nt1VP+6wXzkSTGcUFHhKK6z+TAs UJbRWVsf/nIpZHaRqnLi/l3k9Mt61ZFy1XfxAKcef8OshoW5UPCxJMjgsy3d8w== 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=1721465635; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=IiIvc0o++3Y7NJ5AA6OgDeB0PN0q7AtgJSwrf+qRZIk=; b=A1qS4kibfL/kWq/B2Tri4lfnRSV3kDrx0X7SLfwmMFzW7n4Vp/TcYI1h10grx2++1I7G38 pYcTQFKGeSIMOlxW8bLxQK5VvCGrZMizMdPp+T+Vvw++LpIJ7KLBQOtX1k+VKcqQUITxs3 IdqlMRi1mKjgmPSYj1nYMYf2reYAXsRigNicjikSwBriS3poJX47PC97ZRLIRAT39aew88 7okCaR34f69zzZkJ0z89OPpqwgeh37lAMiHabdaRxbS7Ljzfut0HRsJhNllkjj/DxyinYF Ls3zSxSZUTRIoW0oPjVEZPJ31qQvWgYaYmN+h+A6NRjfHFgMM/eCKZlcNCml9A== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WR0hM5L8Cz19D6; Sat, 20 Jul 2024 08:53:55 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46K8rtbm034954; Sat, 20 Jul 2024 08:53:55 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46K8rtPY034951; Sat, 20 Jul 2024 08:53:55 GMT (envelope-from git) Date: Sat, 20 Jul 2024 08:53:55 GMT Message-Id: <202407200853.46K8rtPY034951@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Peter Holm Subject: git: 00266393cc4b - main - stress2: Fix tests after the new default for newfs(8) is "SU" List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: pho X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 00266393cc4b15e064617e334b1697d98dd6a827 Auto-Submitted: auto-generated The branch main has been updated by pho: URL: https://cgit.FreeBSD.org/src/commit/?id=00266393cc4b15e064617e334b1697d98dd6a827 commit 00266393cc4b15e064617e334b1697d98dd6a827 Author: Peter Holm AuthorDate: 2024-07-20 08:52:29 +0000 Commit: Peter Holm CommitDate: 2024-07-20 08:52:29 +0000 stress2: Fix tests after the new default for newfs(8) is "SU" --- tools/test/stress2/misc/creat.sh | 1 + tools/test/stress2/misc/fsck10.sh | 1 + tools/test/stress2/misc/fsck11.sh | 1 + tools/test/stress2/misc/fsck13.sh | 1 + tools/test/stress2/misc/mkdir.sh | 1 + tools/test/stress2/misc/nullfs18.sh | 1 + tools/test/stress2/misc/perf.sh | 1 + tools/test/stress2/misc/softupdate.sh | 1 + tools/test/stress2/misc/symlink.sh | 1 + tools/test/stress2/misc/symlink2.sh | 1 + tools/test/stress2/misc/symlink5.sh | 1 + 11 files changed, 11 insertions(+) diff --git a/tools/test/stress2/misc/creat.sh b/tools/test/stress2/misc/creat.sh index 45f6b0f87301..1abab774ed7f 100755 --- a/tools/test/stress2/misc/creat.sh +++ b/tools/test/stress2/misc/creat.sh @@ -44,6 +44,7 @@ mdconfig -a -t swap -s 100m -u $mdstart [ $# -eq 1 ] && flags="$@" || flags="-Un" echo "newfs $flags /dev/md$mdstart" newfs $flags /dev/md$mdstart > /dev/null +[ "$flags" = "" ] && tunefs -n disable md$mdstart mount /dev/md$mdstart $mntpoint set +e diff --git a/tools/test/stress2/misc/fsck10.sh b/tools/test/stress2/misc/fsck10.sh index 30479e0dfebb..33ad35f65f11 100755 --- a/tools/test/stress2/misc/fsck10.sh +++ b/tools/test/stress2/misc/fsck10.sh @@ -67,6 +67,7 @@ backups=`newfs -N $newfs_flags md$u2 | grep -A1 "super-block backups" | \ tail -1 | sed 's/,//g'` echo "newfs $newfs_flags -n md$u2" newfs $newfs_flags -n md$u2 > /dev/null +[ "$newfs_flags" = "" ] && tunefs -n disable md$u2 set +e chk() { diff --git a/tools/test/stress2/misc/fsck11.sh b/tools/test/stress2/misc/fsck11.sh index 8019cc1f2656..de4cf2536dad 100755 --- a/tools/test/stress2/misc/fsck11.sh +++ b/tools/test/stress2/misc/fsck11.sh @@ -71,6 +71,7 @@ backups=`newfs -N $newfs_flags md$u2 | grep -A1 "super-block backups" | \ tail -1 | sed 's/,//g'` echo "newfs $newfs_flags -n md$u2" newfs $newfs_flags -n md$u2 > /dev/null +[ "$newfs_flags" = "" ] && tunefs -n disable md$u2 set +e chk() { diff --git a/tools/test/stress2/misc/fsck13.sh b/tools/test/stress2/misc/fsck13.sh index f279e0bae066..3b8dc64d12b9 100755 --- a/tools/test/stress2/misc/fsck13.sh +++ b/tools/test/stress2/misc/fsck13.sh @@ -78,6 +78,7 @@ backups=`newfs -N $flags md$u2 | grep -A1 "super-block backups" | \ tail -1 | sed 's/,//g'` echo "newfs $flags /dev/md$u2" newfs $flags md$u2 > /dev/null +[ "$newfs_flags" = "" ] && tunefs -n disable md$u2 mdconfig -d -u $u2 chk() { diff --git a/tools/test/stress2/misc/mkdir.sh b/tools/test/stress2/misc/mkdir.sh index 39cc828f0303..734b8994ad4e 100755 --- a/tools/test/stress2/misc/mkdir.sh +++ b/tools/test/stress2/misc/mkdir.sh @@ -44,6 +44,7 @@ mdconfig -a -t swap -s 100m -u $mdstart [ $# -eq 1 ] && flags="$@" || flags="-Un" echo "newfs $flags /dev/md$mdstart" newfs $flags /dev/md$mdstart > /dev/null +[ "$flags" = "" ] && tunefs -n disable md$mdstart mount /dev/md$mdstart $mntpoint set +e diff --git a/tools/test/stress2/misc/nullfs18.sh b/tools/test/stress2/misc/nullfs18.sh index b4414cbc3e3e..3936ea64c6a3 100755 --- a/tools/test/stress2/misc/nullfs18.sh +++ b/tools/test/stress2/misc/nullfs18.sh @@ -41,6 +41,7 @@ mdconfig -l | grep -q md$mdstart && mdconfig -d -u $mdstart mdconfig -a -t swap -s 2g -u $mdstart || exit 1 newfs -n md$mdstart > /dev/null +tunefs -n disable md$mdstart 2>/dev/null mount /dev/md$mdstart $mntpoint chmod 777 $mntpoint diff --git a/tools/test/stress2/misc/perf.sh b/tools/test/stress2/misc/perf.sh index 58f5bd67b756..de6c20028c59 100755 --- a/tools/test/stress2/misc/perf.sh +++ b/tools/test/stress2/misc/perf.sh @@ -84,6 +84,7 @@ tst() { s=0 for i in "" "-U" "-j"; do newfs $i /dev/md$mdstart > /dev/null 2>&1 + [ "$i" = "" ] && tunefs -n disable md$mdstart mount /dev/md$mdstart $mntpoint t1=`date +%s` diff --git a/tools/test/stress2/misc/softupdate.sh b/tools/test/stress2/misc/softupdate.sh index ecf7c5d04e9c..37f819579f83 100755 --- a/tools/test/stress2/misc/softupdate.sh +++ b/tools/test/stress2/misc/softupdate.sh @@ -47,6 +47,7 @@ mdconfig -a -t vnode -f $D -u $mdstart for mode in "" "-U"; do printf "newfs -O2 $mode /dev/md${mdstart}\n\n" newfs -O2 $mode /dev/md$mdstart > /dev/null 2>&1 + [ "$mode" = "" ] && tunefs -n disable md$mdstart mount /dev/md$mdstart $mntpoint for i in `jot 5`; do diff --git a/tools/test/stress2/misc/symlink.sh b/tools/test/stress2/misc/symlink.sh index 47257aa92a24..1d30636d6b25 100755 --- a/tools/test/stress2/misc/symlink.sh +++ b/tools/test/stress2/misc/symlink.sh @@ -71,6 +71,7 @@ tst() { s=0 for i in "" "-U" "-j"; do newfs $i /dev/md$mdstart > /dev/null 2>&1 + [ "$i" = "" ] && tunefs -n disable md$mdstart mount /dev/md$mdstart $mntpoint t1=`date +%s` diff --git a/tools/test/stress2/misc/symlink2.sh b/tools/test/stress2/misc/symlink2.sh index f13065badb4a..210702defe4a 100755 --- a/tools/test/stress2/misc/symlink2.sh +++ b/tools/test/stress2/misc/symlink2.sh @@ -53,6 +53,7 @@ for i in "" "-U"; do [ "$i" = "-U" -a "$newfs_flags" != "-U" ] && continue echo "newfs $i /dev/md$mdstart" newfs $i /dev/md$mdstart > /dev/null 2>&1 + [ "$i" = "" ] && tunefs -n disable md$mdstart mount /dev/md$mdstart $mntpoint mkdir $mntpoint/dir diff --git a/tools/test/stress2/misc/symlink5.sh b/tools/test/stress2/misc/symlink5.sh index 55f71e209791..9332f906a3e0 100755 --- a/tools/test/stress2/misc/symlink5.sh +++ b/tools/test/stress2/misc/symlink5.sh @@ -79,6 +79,7 @@ for i in "" "-U"; do t1=`date +%s` echo "newfs $i /dev/md$mdstart" newfs $i /dev/md$mdstart > /dev/null 2>&1 + [ "$i" = "" ] && tunefs -n disable md$mdstart mount /dev/md$mdstart $mntpoint tst; s=$? From nobody Sat Jul 20 14:44:28 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WR8Ss2MYxz5Rnsk; Sat, 20 Jul 2024 14:44: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WR8Ss1Vhnz4Lc6; Sat, 20 Jul 2024 14:44:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721486669; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6j7xZ4xx+CnOJklbI01ZWe5F/YTjy15zbsjgC00xBiU=; b=wOJw7TQeSkaEcIsyqKEfU+bpJcntWnNilyBeu4ekUR0SNAX0lena4rtn6oqzzaA+5A/4kV mPp5V0gwhBNnoNGzhFra1h6AznkwdsL6S8/Qe5z3xSyP9vfjGOvqQgEvglxKLKxK7fXGwn DjDv3rXl20PYm+DdTMHYOeHnxP4c8kPaYuWD0CTxLSOr62bLfYUmJGNl7hft4BpfBjQWL5 1WnpvELs/eJNQSr6/ERoJ6DqnCsxS9NIvWVsW2Umht4q2RGoqzXqOAnokZN/YsH7UU0lGZ C0pJKIABEwegboCSreJMP0WUjIpxR/f1FCZfmvEvlOsJoDSBwFB7sR+5gOdxrg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721486669; a=rsa-sha256; cv=none; b=bbZ9NQCSOhSCA+LpKbtDU76piVeIpWlG1CSNeGu1D1SbkctGbz5wjXs3FndtMh8MvQ53FB htm1FNU5Fnh0WEfq9GpHtudtrzXiOUi9QD6pyDebDTMMmK0cA4sTTX+6ufY1QLMk74nH/f Q+xWZCi2rk9c2q8dRw5nphfjG4aGZ6Bh9G5QOvjr09R5aNH8FF3fxS2DcHYhqGROydsD+T 9ssfPGBeYpBAgw0HBHLGDypmdWWZlSr2huhQGFJVHpGQ0lU5luNc647355QD/SG0ZHO+FB Zg0PvFVqEu8JmTbepJ1G50yIDjloYHo/kcf8pgTJnm7PSsbF5Vjwbr2kf0toBg== 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=1721486669; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6j7xZ4xx+CnOJklbI01ZWe5F/YTjy15zbsjgC00xBiU=; b=g3E9eyTuPsh49uYO1NOQ6FTOkQKRTrFgmlQsX7sLNpD/E+d2b7z4g8JuMSlyCSJs97fZeT POps6J+JNtIRL0Igxo3DwXsN0nox1KLZDROc22ymEBt3iMPWuSKWWY/USSWZ+yQ18mSsyz xiLEd2RDwx6o5ldl6JxkGFLkuRZGjVR4p5oa27ikGbZ2hJ1pVfJENS7QnRQ07Y7QsESLhu pHhsX6Dh8ZFjB33REFGSZBPamnK5Eg8/WsaHrI5mv+LLbGBEj5suWKyMnGo+YnB1sXPpKI waGgV3MI+kq69j9wNNP3cK3p6gil8pbXKNuau6K6X74XR3WYB9mmX29iaBqnxA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WR8Ss101szKLl; Sat, 20 Jul 2024 14:44:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46KEiTwS028169; Sat, 20 Jul 2024 14:44:29 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46KEiSSx028166; Sat, 20 Jul 2024 14:44:28 GMT (envelope-from git) Date: Sat, 20 Jul 2024 14:44:28 GMT Message-Id: <202407201444.46KEiSSx028166@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: 0d0999fe3137 - stable/14 - if_clone: Allow maxunit to be zero List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: zlei X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 0d0999fe313779ea51ef4178dff76bb572fdb09f Auto-Submitted: auto-generated The branch stable/14 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=0d0999fe313779ea51ef4178dff76bb572fdb09f commit 0d0999fe313779ea51ef4178dff76bb572fdb09f Author: Zhenlei Huang AuthorDate: 2024-07-03 13:14:08 +0000 Commit: Zhenlei Huang CommitDate: 2024-07-20 14:42:59 +0000 if_clone: Allow maxunit to be zero Some drivers, e.g. if_enc(4), only allow one instance to be created, but the KPI ifc_attach_cloner() treat zero value of maxunit as not limited, aka IF_MAXUNIT. Introduce a new flag IFC_F_LIMITUNIT to indicate that the requested maxunit is limited and should be respected. Consumers should use the new flag if there is an intended limit. Reviewed by: glebius MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D45757 (cherry picked from commit a2cac544a668d2834ed41986aca32b44b9819c89) --- sys/net/if_clone.c | 13 +++++++++---- sys/net/if_clone.h | 5 +++++ 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/sys/net/if_clone.c b/sys/net/if_clone.c index 5345d613f9d6..50ebed285d28 100644 --- a/sys/net/if_clone.c +++ b/sys/net/if_clone.c @@ -485,12 +485,13 @@ if_clone_alloc(const char *name, int maxunit) struct if_clone *ifc; KASSERT(name != NULL, ("%s: no name\n", __func__)); + MPASS(maxunit >= 0); ifc = malloc(sizeof(struct if_clone), M_CLONE, M_WAITOK | M_ZERO); strncpy(ifc->ifc_name, name, IFCLOSIZ-1); IF_CLONE_LOCK_INIT(ifc); IF_CLONE_ADDREF(ifc); - ifc->ifc_maxunit = maxunit ? maxunit : IF_MAXUNIT; + ifc->ifc_maxunit = maxunit; ifc->ifc_unrhdr = new_unrhdr(0, ifc->ifc_maxunit, &ifc->ifc_mtx); LIST_INIT(&ifc->ifc_iflist); @@ -523,12 +524,16 @@ if_clone_attach(struct if_clone *ifc) struct if_clone * ifc_attach_cloner(const char *name, struct if_clone_addreq *req) { + int maxunit; + struct if_clone *ifc; + if (req->create_f == NULL || req->destroy_f == NULL) return (NULL); if (strnlen(name, IFCLOSIZ) >= (IFCLOSIZ - 1)) return (NULL); - struct if_clone *ifc = if_clone_alloc(name, req->maxunit); + maxunit = (req->flags & IFC_F_LIMITUNIT) ? req->maxunit : IF_MAXUNIT; + ifc = if_clone_alloc(name, maxunit); ifc->ifc_match = req->match_f != NULL ? req->match_f : ifc_simple_match; ifc->ifc_create = req->create_f; ifc->ifc_destroy = req->destroy_f; @@ -586,7 +591,7 @@ if_clone_advanced(const char *name, u_int maxunit, ifc_match_t match, { struct if_clone *ifc; - ifc = if_clone_alloc(name, maxunit); + ifc = if_clone_alloc(name, maxunit ? maxunit : IF_MAXUNIT); ifc->ifc_match = match; ifc->ifc_create = ifc_advanced_create_wrapper; ifc->ifc_destroy = ifc_advanced_destroy_wrapper; @@ -631,7 +636,7 @@ if_clone_simple(const char *name, ifcs_create_t create, ifcs_destroy_t destroy, struct if_clone *ifc; u_int unit; - ifc = if_clone_alloc(name, 0); + ifc = if_clone_alloc(name, IF_MAXUNIT); ifc->ifc_match = ifc_simple_match; ifc->ifc_create = ifc_simple_create_wrapper; ifc->ifc_destroy = ifc_simple_destroy_wrapper; diff --git a/sys/net/if_clone.h b/sys/net/if_clone.h index d44f7021299c..86aa52c0ed25 100644 --- a/sys/net/if_clone.h +++ b/sys/net/if_clone.h @@ -103,6 +103,11 @@ struct if_clone_addreq_v2 { #define IFC_F_SYSSPACE 0x04 /* Cloner callback: params pointer is in kernel memory */ #define IFC_F_FORCE 0x08 /* Deletion flag: force interface deletion */ #define IFC_F_CREATE 0x10 /* Creation flag: indicate creation request */ +#define IFC_F_LIMITUNIT 0x20 /* Creation flag: the unit number is limited */ + +_Static_assert(offsetof(struct if_clone_addreq, destroy_f) == + offsetof(struct if_clone_addreq_v2, destroy_f), + "destroy_f in if_clone_addreq and if_clone_addreq_v2 are at different offset"); struct if_clone *ifc_attach_cloner(const char *name, struct if_clone_addreq *req); void ifc_detach_cloner(struct if_clone *ifc); From nobody Sat Jul 20 14:44:30 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WR8St3TnJz5RnZb; Sat, 20 Jul 2024 14:44: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WR8St2tKdz4Lww; Sat, 20 Jul 2024 14:44:30 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721486670; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=zesnpKGNI5R/3KR6xz0saYsJe9L9pnYl+DvprYA2Jm4=; b=EVxL7B6zGm4nsue1IJOnt94tUhUX+s9aoWw1r2IIdx/iSt9CK2HqE3iMsqZprXYIr6vMCe GZhwXjQbBbS7VjyOLDDgrmuWRyAKD6din+qNwTPACmSnYDWgS3Kp7vIN6OasSI8f0gVbms h2Z6EunnxRRtZfKQ7ge5CJ+09TEgFUdhWgHOZQJVKt1c65N8/U9ByWfh9WHG1+8zVNayhU 8dy/ag2u50uua8xkoQwYZCiqN2aTCshaaKH9ywkdIsEEjHQ3pdCmX1bIpAKktKw0nXFZjs JSudCOsfpQJYt7jkPgkSoB9VqG/nhTzxISw1YUwIy25+NWsHLgHcNx/++dq76Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721486670; a=rsa-sha256; cv=none; b=pytWUuUuLENCli6nLj53ECZGcnaUjzmMt8WlCpmq6cdyB4BB90Rzl5dPs/b2lEA37CT9Yp AYVDTYnn1Czy07NFfZmIdvN9sP6erXU87RTZrUGDNfAk5b4ybGN1eV5GH87Ydw59lA9tGm E7i/7YjQSJ9kIjtxrMoFZjeUYaiD8ee3eeshBbutVTtFYEpNj5MX2ZKv8q6CGBThd79Iwm Q2B/mxx4aK3Eh2lI4k1o6z3WPKug/GJsn4YTOF3kwrPbZbjU4Af5uAULqnfouHqkCwRM/s ufDIz7debwXDTfq9QNvJcMDzAU0JX+V8uzxd3d8aYfUxYuck6jcYdn92vp6Ojg== 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=1721486670; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=zesnpKGNI5R/3KR6xz0saYsJe9L9pnYl+DvprYA2Jm4=; b=wnJPl9GIr5FOr6FbW5asY7bRMjxM6XdkSgFjznNxmuq4Xb3mM9lThXjMkJrWSp2stN2/1n 8/QyPu2FiNPBFNy8FN+cFota0YmzHQ/oldrxgpgcKG8vHsDumElsPtFtTENjRIxzSevM37 MW6FpB21uKpNYWuzGIzCsth7RMZU1vQ0EmGA7dFeSRTWXnCBXMduslBNwegf1Ipq/4zQSs nhuJL8QDTeUY0Df+8i4oapOyIXvOlkacx/3tOjuh2JTC2zqzd6ee2352PnFnfgLIrGWteL f9tfIrZluRSnQL/+CNvmigAF3dvIqOadICQuynj3YJoUziCqEwZtTVApFCwNWA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WR8St1RnNzL2W; Sat, 20 Jul 2024 14:44:30 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46KEiUIU028230; Sat, 20 Jul 2024 14:44:30 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46KEiUAI028227; Sat, 20 Jul 2024 14:44:30 GMT (envelope-from git) Date: Sat, 20 Jul 2024 14:44:30 GMT Message-Id: <202407201444.46KEiUAI028227@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: ca735be05c59 - stable/14 - if_pflog: Limit the maximum unit via the new KPI List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: zlei X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: ca735be05c59f83e107213e41517bef1a5d10108 Auto-Submitted: auto-generated The branch stable/14 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=ca735be05c59f83e107213e41517bef1a5d10108 commit ca735be05c59f83e107213e41517bef1a5d10108 Author: Zhenlei Huang AuthorDate: 2024-07-03 13:14:09 +0000 Commit: Zhenlei Huang CommitDate: 2024-07-20 14:42:59 +0000 if_pflog: Limit the maximum unit via the new KPI The cloner has the ability to limit the maximum unit. Employ it to do that rather than roll our own. No functional change intended. Reviewed by: kp MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D45767 (cherry picked from commit 07d138afc7e5efee73368459dd047493713056cf) --- sys/netpfil/pf/if_pflog.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/sys/netpfil/pf/if_pflog.c b/sys/netpfil/pf/if_pflog.c index 53fe36343c75..b143aae1434a 100644 --- a/sys/netpfil/pf/if_pflog.c +++ b/sys/netpfil/pf/if_pflog.c @@ -105,14 +105,16 @@ VNET_DEFINE(struct ifnet *, pflogifs[PFLOGIFS_MAX]); /* for fast access */ static void pflogattach(int npflog __unused) { - int i; + int i; + for (i = 0; i < PFLOGIFS_MAX; i++) V_pflogifs[i] = NULL; struct if_clone_addreq req = { .create_f = pflog_clone_create, .destroy_f = pflog_clone_destroy, - .flags = IFC_F_AUTOUNIT, + .flags = IFC_F_AUTOUNIT | IFC_F_LIMITUNIT, + .maxunit = PFLOGIFS_MAX - 1, }; V_pflog_cloner = ifc_attach_cloner(pflogname, &req); struct ifc_data ifd = { .unit = 0 }; @@ -125,8 +127,7 @@ pflog_clone_create(struct if_clone *ifc, char *name, size_t maxlen, { struct ifnet *ifp; - if (ifd->unit >= PFLOGIFS_MAX) - return (EINVAL); + MPASS(ifd->unit < PFLOGIFS_MAX); ifp = if_alloc(IFT_PFLOG); if_initname(ifp, pflogname, ifd->unit); From nobody Sat Jul 20 14:57:24 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WR8lm2WBVz5RphT; Sat, 20 Jul 2024 14:57: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WR8lm20mmz4Mx3; Sat, 20 Jul 2024 14:57:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721487444; h=from:from:reply-to:subject:subject: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//RVQfloj695XF3Rwwjltcfqv4Z2Xn7sdYFehHBXAg=; b=QZPLGeB2u1lEj4qdQ3u/WCM2VImOIlY/dQn9Z4yv5RsJS9J03iCDBSUWb5ns6rBWOycJ5q UDYbCxWjVS/+7v73PVjUX/lc96zakSufIQkO8Waj29WX1qkjTU8srqaItDNziXP6IxIanI O26Ub08J82S2n+QhzFneptQmAKF0PCMuZltYhy3FwdKNazAk3I5/vejMKDkQoEvAl2SLId gK+e16In1j+rxtQF9TjozNwgeYp/KkXZDo0/PFkdGd8lmbyg4UZozwRaragozWiM1S0W0s tTZXL7LE79c314Yx+QuvBMWSuGzJhr0J5KvHFXhQZqOPfBwA9/ecstwuAyXQ2A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721487444; a=rsa-sha256; cv=none; b=RzT7hIA0qHf2MO25+hg52pTk53DscYU+XcaZeXE6JNiWswo0Ag9bctM/6AGx7ux3K5fye1 Y8gqGwzJfjNVVlNLfCx2zkj1sSHH+VkavChey4SWBkE5YAcdf9BAVF7YHEx6llTVzKC0ay 2GBuqJ8E73ORwJX3dBH/CBNLJtoSc7AJG5LWAziom8j9qsqeSuZYV2731OjIW9TZqD/3Bb kS1iaITIOz8oqN7M9oONzbQ2FCtFZu4mbBnB9y+XHg3HQhbjfiRCLa+6WkPmOY/hTvj0v5 BSnvDjVSz4aaczuW0i2b8W9Psf0Ea28vDwMrJWwqw1V+H9Og7Lbpkyv+XCLAgw== 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=1721487444; h=from:from:reply-to:subject:subject: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//RVQfloj695XF3Rwwjltcfqv4Z2Xn7sdYFehHBXAg=; b=yGD7x7qyZNmM/b/yVyMzR73aCNYQB+SGOStAp6R54wk1xftUNoOsG5AXn3SjepnvsQ70AL PSYxaB67n3cK4/AYaM7BEN9p9lPRuhj0wHLN46+O35DJjxu6u9z60Rddl7zIMbR41Lqnss OWbeR8tVGwCwF+3GxCA0cNHQE2jHdAlQuv8vtR4lvMIQTwTZyNqeUxOp5C3udGksi26wma VLniIomyC8gCPk6QblwG/lO4NhN1cWbDnDzrNPtAaiiLGodjzF7TtruiG4v8UortqwSrOz qd8nLaAQ4pTHazKGYYlorA8Fdzvn/fPDh6eQmLP6YNlJxwBZtmXHYcw3n2GTKA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WR8lm1YHSzLXb; Sat, 20 Jul 2024 14:57:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46KEvOa1045163; Sat, 20 Jul 2024 14:57:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46KEvOko045160; Sat, 20 Jul 2024 14:57:24 GMT (envelope-from git) Date: Sat, 20 Jul 2024 14:57:24 GMT Message-Id: <202407201457.46KEvOko045160@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: 9fd9ba30cc20 - stable/13 - ctladm: don't require the use of "-p" with "port -r", part 2 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: asomers X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 9fd9ba30cc20011c07435d6ac19ac08717fd5d0a Auto-Submitted: auto-generated The branch stable/13 has been updated by asomers: URL: https://cgit.FreeBSD.org/src/commit/?id=9fd9ba30cc20011c07435d6ac19ac08717fd5d0a commit 9fd9ba30cc20011c07435d6ac19ac08717fd5d0a Author: Alan Somers AuthorDate: 2024-07-04 20:32:24 +0000 Commit: Alan Somers CommitDate: 2024-07-20 14:56:36 +0000 ctladm: don't require the use of "-p" with "port -r", part 2 * Remove a now superfluous FALLTHROUGH hint * Don't specify "-p" with an empty argument in the tests Reported by: jhb (cherry picked from commit 7f50027321db3b08477f6236abded0297e9e5ed8) --- usr.sbin/ctladm/ctladm.c | 1 - usr.sbin/ctladm/tests/port.sh | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/usr.sbin/ctladm/ctladm.c b/usr.sbin/ctladm/ctladm.c index 194f0647fe7f..71f187df931e 100644 --- a/usr.sbin/ctladm/ctladm.c +++ b/usr.sbin/ctladm/ctladm.c @@ -575,7 +575,6 @@ cctl_port(int fd, int argc, char **argv, char *combinedopt) break; } case CCTL_PORT_MODE_REMOVE: - /* FALLTHROUGH */ case CCTL_PORT_MODE_CREATE: { bzero(&req, sizeof(req)); strlcpy(req.driver, driver, sizeof(req.driver)); diff --git a/usr.sbin/ctladm/tests/port.sh b/usr.sbin/ctladm/tests/port.sh index 633dec2fd273..a9ff609d3f4c 100644 --- a/usr.sbin/ctladm/tests/port.sh +++ b/usr.sbin/ctladm/tests/port.sh @@ -62,7 +62,7 @@ cleanup() { ;; "iscsi") TARGET=`awk '/target:/ {print $2}' port-create.txt` - ctladm port -r -d $driver -p "$PORTNUM" -O cfiscsi_portal_group_tag=$PGTAG -O cfiscsi_target=$TARGET + ctladm port -r -d $driver -O cfiscsi_portal_group_tag=$PGTAG -O cfiscsi_target=$TARGET ;; esac fi From nobody Sat Jul 20 15:50:58 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WR9xb0ZbHz5RtCQ; Sat, 20 Jul 2024 15:50: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WR9xZ2Scbz4RgC; Sat, 20 Jul 2024 15:50:58 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721490658; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=evO/UV4DttvPzxEmUyRQVLmdbPUZLVuzhnUL6BXS6RY=; b=ZiilPv2m93enp0dxa+4Sm7I1sztNUlIKM7lovirrT1W/AktsDLi2Ad9YHfu6au/w0HLBaF WBd7pYtpx7/ox3DO0HrQiB3k6F/x5XePPegGmzKZaxhm2hW9kt4LAEy6fejUWBPzco+Kpq DtDwhRQ02lMm42rxS7lf7Rdpzx3qfaAFyrK7Cr5FbU5hwG326a+9ImbJWTHJiGlJl+Q+8E s4rx5OrRQc/x4sERF6LVIKJPvDq20si58PM+iWWqxoY3J4hrBPvnRVOogc0wq9c20QYsUT id2NtM/6Crimik5RceO4+uSHcjBBjsW38dg3jBrHyZ83fenm/Z23fdnyANxevg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721490658; a=rsa-sha256; cv=none; b=CiTyRWLxVD2i/L6FnhaULTUALPb2tJjfY4vUd21aiJ2IrPvnJ/0J03ziDLFr6Jo28T+N1A WchB++HQW6pKVi7duNKhcHPzKUXIW3URv5yTrPvPgm/Y6MS5bEvsItgBEcISYJsOif/e19 4J8lAEJSkjir1dAMr6U6+1M+paX2QaIrFXS+xT/8UpXT+HZkuuS9h1+2esPNEfDbZcSs3Q 4bJsEVnGE5orY5jvnOu3czj2SlVFOrqoBdjp+Bsa58hC0E/2GZPpSx3ljIaeejVC1DqJRs l9xbGfh5QfwPQglnxBMPWbqWK3cxT0SrCPLSCHrf6OElwFHNoIdle75h1RbbqA== 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=1721490658; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=evO/UV4DttvPzxEmUyRQVLmdbPUZLVuzhnUL6BXS6RY=; b=silG5LsLDTMxe+k720WYrtnWkG1bxUGBAbT3/sJHvDMXHHWzzP0mxoQdD8Tj+nFeBAc3J4 0DtFdai3nMKZwbR00yZv5w9IaVHeL+cJF7HbbbwF5DJOPnT800vcQNDND3/WxyRb5ItmlC XArKYJ7i+yJwjEyjyV3JyffaHm1QLguTlFBqNpfauho+e3XZy11KPuzKtQbjUuOplw63so PSvgPLv1EOm8e9lu+F70nRWNbqH6vIR5ADjOXjfgfhh5rFQVDKGyeEQt2Ho0ha/TcHLIIc 5i9mUWcRNDfn/L7d1WTK8MyH15Vw5PHHXHseYTsid6yrb0P7USo/CC++oGaStA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WR9xZ24B5zN04; Sat, 20 Jul 2024 15:50:58 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46KFowPE038624; Sat, 20 Jul 2024 15:50:58 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46KFows8038621; Sat, 20 Jul 2024 15:50:58 GMT (envelope-from git) Date: Sat, 20 Jul 2024 15:50:58 GMT Message-Id: <202407201550.46KFows8038621@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: eaa3d34b6220 - main - cdefs.9: Update for C++ environments List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: eaa3d34b6220d8858eabc622165ec4db2cc75e96 Auto-Submitted: auto-generated The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=eaa3d34b6220d8858eabc622165ec4db2cc75e96 commit eaa3d34b6220d8858eabc622165ec4db2cc75e96 Author: Warner Losh AuthorDate: 2024-07-20 14:38:52 +0000 Commit: Warner Losh CommitDate: 2024-07-20 15:50:38 +0000 cdefs.9: Update for C++ environments We support all the C++ standards to some degree. However, pre C++11 standard support has been disappearing upstream, so also add a note about -pedantic-errors might not work for earlier standards. Add note about __cplusplus values. Sponsored by: Netflix --- share/man/man9/cdefs.9 | 43 +++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 41 insertions(+), 2 deletions(-) diff --git a/share/man/man9/cdefs.9 b/share/man/man9/cdefs.9 index 71b3e7fd4f81..dd45e3f61a9f 100644 --- a/share/man/man9/cdefs.9 +++ b/share/man/man9/cdefs.9 @@ -3,7 +3,7 @@ .\" .\" SPDX-License-Identifier: BSD-2-Clause .\" -.Dd July 18, 2024 +.Dd July 20, 2024 .Dt CDEFS 9 .Os .Sh NAME @@ -281,7 +281,7 @@ still uses these. supports a number C standard environments. Selection of the language dialect is a compiler-dependent command line option, though it is usually -.Fl cstd=XX +.Fl std=XX where XX is the standard to set for compiling, such as c89 or c23. .Fx provides a number of selection macros to control visibility of symbols. @@ -402,6 +402,45 @@ extensions are visible, 0 otherwise. .St -isoC-2011 Appendix K 3.7.4.1 extensions are visible, 0 otherwise. +.Sh Supported C++ Environments +.Fx +supports C++11 and newer standards fully. +.Bl -tag +.It ISO/IEC 14882:1998 ("C++98") +.Dv __cplusplus = 199711 +.Pp +The first standardized version of C++. +Unlike K \*(Am R support in C, compilers dropped support for versions of +the language prior to C++98. +.It ISO/IEC 14882:2003 ("C++03") +.Dv __cplusplus = 199711 +.Pp +Note, this is the same value as C++98. +C++03 did not define a new value for +.Dv __cplusplus . +There is no way, at compile time, to detect the difference. +The standard resolved a number of defect reports and slightly +expanded value initialization. +Most compilers support it the same as C++98. +.It ISO/IEC 14882:2011 ("C++11") +.Dv __cplusplus = 201103 +.It ISO/IEC 14882:2014 ("C++14") +.Dv __cplusplus = 201402 +.It ISO/IEC 14882:2017 ("C++17") +.Dv __cplusplus = 201703 +.It ISO/IEC 14882:2020 ("C++20") +.Dv __cplusplus = 202002 +.It ISO/IEC 14882:2023 ("C++23") +.Dv __cplusplus = 202302 +.El +.Pp +.Fx +uses llvm project's libc++. +However, they are removing support for C++ prior to C++11. +While programs can still build with earlier environments for now, these changes +mean that +.Fl pedantic-errors +cannot be reliably enabled for standards older than C++11. .Sh HISTORY .In sys/cdefs.h first appeared in From nobody Sat Jul 20 16:07:45 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRBJy320bz5Rvch; Sat, 20 Jul 2024 16:07: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRBJy2FrQz4T9W; Sat, 20 Jul 2024 16:07:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721491666; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=vglkEL0YangU6l90AG1Q4uLPkkU7QBsrzvt0889XNaM=; b=ySP1x6ueIIpNNnKSyNkq+5w3HiaoDwIFm6TNbcEA5/gM6L5y1kXhogzBbOd9jMMEymiwa0 aqBC1qTWAn6G6nnxusr7m8UfNW2RTY8XbSHdu1Ut3VCM7HhPMbdNG3NHfsBY9IQgnaSJc/ QTY1ZKmMY8jmwIqDYbzwEegBu4GCRL7Vn0PP1EfCTjT7A9jHrshceQQrwIREG5Eia3iEGH pj4xBDbZ1Bzp/vabqQ5AfpBK060jpWfZA12d6vIwP8u8kJRsmUFoCD0yJS7Dk6bp1pTGa+ f4+8lIoBdaRijyHJpg5Yj9eOnusq3ciMhuMgHl6RnDczk776AroGe7f3XUDxUQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721491666; a=rsa-sha256; cv=none; b=jPOvQ+JTkAbkSnHTx/5QW3T2Jo/rmycUt0bPoGnBoXNm34o0QNkxnotORJAJjoY59OguSr 9NKZotwbqZW5sEghVcU3dowU6rNOZqCQZl0XBOdk3z2mkgB2RtbD7DELy2cXILMApfa/jY jey5pbqbHvs2za4Bt1X/iVWTXOCdKHhC0Wkccqjhl7pYnEPP2m1iuVe7WZV8XPUodVHv9t zK3he+fheoORywaeY1Soln8p4Gt1ypzDQdQpUVcpMz02NrMJ8rEhrk6Reub/c5VzLwH1IY 0p6P7jFOUwDPYaS720tAJYe9rfRaVAftzeQx+eH8i20pjzRgxc8+hZt1lIIJVw== 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=1721491666; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=vglkEL0YangU6l90AG1Q4uLPkkU7QBsrzvt0889XNaM=; b=kw/ympVSRG4mF07EmuJq3k51sZC+AC1CW5o3vf5rfa5zNusxRiTgNV/R/Fn3U7EGBN3o6q 3OS6gqOwTu3XD/Uis6/XDZrfonzdph7wtMSWDMIMMuywtTbeXiw3M/v1cfwf7kXiEvsGz2 dWpmAZkGZKhSb/l1r4OkFmwZXn9OipGgCIN+I3Cg0xIaDCJO34H87HXP0XcSrwtNyAkYyb wmGZaeR3Y609Qr6m9+HaJe1d3AGu/0Divg8+9LBs7HVquK+ZWPLTZPob644pgd3VrTKNCI 9Y4v59/MkwNYaFd2OAmXrx97pRRmpzMhLUoYH7ZHduHTWdK8uRzqQosIebGGKg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRBJx6XbSzNPD; Sat, 20 Jul 2024 16:07:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46KG7jnd064319; Sat, 20 Jul 2024 16:07:45 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46KG7jro064316; Sat, 20 Jul 2024 16:07:45 GMT (envelope-from git) Date: Sat, 20 Jul 2024 16:07:45 GMT Message-Id: <202407201607.46KG7jro064316@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: 22cdafe197ac - stable/14 - cdefs.h: Don't define fallback for _Static_assert List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 22cdafe197ac960c5ce839ef6ec699b59f4b0080 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=22cdafe197ac960c5ce839ef6ec699b59f4b0080 commit 22cdafe197ac960c5ce839ef6ec699b59f4b0080 Author: Warner Losh AuthorDate: 2024-07-20 15:57:53 +0000 Commit: Warner Losh CommitDate: 2024-07-20 15:57:53 +0000 cdefs.h: Don't define fallback for _Static_assert Remove pre 4.6 code to define _Static_assert in terms of _COUNTER. We no longer need to support compilers this old (in fact support for all pre gcc 10 compilers has been removed in -current). This is a partial MFC of that work because removing this fixes a bug that's oft reported with -pedantic-errors and C++98 compilations. PR: 280382, 276738 Sponsored by: Netflix This is a direct commit to stable/14. --- sys/sys/cdefs.h | 9 --------- 1 file changed, 9 deletions(-) diff --git a/sys/sys/cdefs.h b/sys/sys/cdefs.h index 19b7d8fe427d..a52864c5db9d 100644 --- a/sys/sys/cdefs.h +++ b/sys/sys/cdefs.h @@ -277,15 +277,6 @@ #if (defined(__cplusplus) && __cplusplus >= 201103L) || \ __has_extension(cxx_static_assert) #define _Static_assert(x, y) static_assert(x, y) -#elif __GNUC_PREREQ__(4,6) && !defined(__cplusplus) -/* Nothing, gcc 4.6 and higher has _Static_assert built-in */ -#elif defined(__COUNTER__) -#define _Static_assert(x, y) __Static_assert(x, __COUNTER__) -#define __Static_assert(x, y) ___Static_assert(x, y) -#define ___Static_assert(x, y) typedef char __assert_ ## y[(x) ? 1 : -1] \ - __unused -#else -#define _Static_assert(x, y) struct __hack #endif #endif From nobody Sat Jul 20 16:12:35 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRBQW5dTNz5RvkB; Sat, 20 Jul 2024 16:12: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRBQW4spqz4TvJ; Sat, 20 Jul 2024 16:12:35 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721491955; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=i/B25EZWHoJwrRm3znQNzCZHPzKXk/wm+DZAgVcCCJc=; b=hVOfYOInxbjxeIFp1awwTX8Hb1H3tt1MzyvZr/FZrdCnTIM6MKcyhF7mbdFKYM+sFFMY5S 3XqdZmTF8JGVM8F6ZVyz20m/7PdLe8Z9bcatN0rgMnEwueP1EqZ+gxojUkAER5LUAboMkm /8BYUAYoSoJ27IhFGkzJhViZG7gc+d65FDaP9BjLpzUXsZm+O/zKjn6Li2PaXPyM3T0dM+ PcbLEqzW5qAPelHOEB8h4+J78sUV2Z98tNK7H7rWGtjiMG/6mtYpMDdjuFMn0CL8kxsxTx t4uZnVojReNRZy26xwsEGjBhDAboX0BkBu/EEq/96Ill+o7LgAt49KSPECfibA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721491955; a=rsa-sha256; cv=none; b=NSEDPmWP4kwwzV6JVHfSRhTwzi5vWv/faQI9wqwVnS1Xd0Xm0MKMYEDIR1fx2kxS5cfpr/ /YiHH98YXs754vOATsnZABdGQbJsRvwlShYqS7q3OGlLkxdzV9wtdZlavBhhncnLuhJDxU 5ObXkBRyTPyrZYJsuQ6ZKWEGzrmWcRirqGMGGVrY+RmDLHZj00cJR7IEQGT1gF8TF3AE10 XcIupWdPKB4abjpeLjUrGl7NnrRL5Hr5UKcbMRla8LwFNaBEaRQ1oZMUzf4ISuM4XV40TI pu5pg2IH0zdUoHQ6Xh9KIAr4ApLnBQb2MpKJBZw1R3sgJtVfHwGpIsMqviW4OA== 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=1721491955; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=i/B25EZWHoJwrRm3znQNzCZHPzKXk/wm+DZAgVcCCJc=; b=SxfCS2/3l6eXi0uiuPD9f1V7I0Q+wR26aps0mOpcnHXxY1xxxByPp7qXInxfo8iQNm1/oC MceFctfQoPHlFOlpfONlWw600idpKkNIV1vULH5MuaxUoqTq6z6reDSPMV0b80ag8UiSRQ Thx26gy/jdz/9eD62MfBMeFinjcE3e381d2KdEPg9j9bowEdrHkT0KW5Ezx7lDK6E1i03t /TNaT1aZGJ6W24+wdsCVKzSFtdZdj5FeDCqt/FOB08Yz/+gr2n95yDuUd5ln1aUbC3N5GZ hRpj5jrj9i72WgjR/cy6jRJvMwwpMDnTsDAqPqnslCuAgZqnoF/baihZrIGC0Q== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRBQW4TYBzNrm; Sat, 20 Jul 2024 16:12:35 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46KGCZDV080115; Sat, 20 Jul 2024 16:12:35 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46KGCZOx080112; Sat, 20 Jul 2024 16:12:35 GMT (envelope-from git) Date: Sat, 20 Jul 2024 16:12:35 GMT Message-Id: <202407201612.46KGCZOx080112@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: d3de5c5b4529 - stable/13 - cdefs.h: Don't define fallback for _Static_assert List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: d3de5c5b45293d15f8b87f2e529318dd99988d4c Auto-Submitted: auto-generated The branch stable/13 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=d3de5c5b45293d15f8b87f2e529318dd99988d4c commit d3de5c5b45293d15f8b87f2e529318dd99988d4c Author: Warner Losh AuthorDate: 2024-07-20 15:57:53 +0000 Commit: Warner Losh CommitDate: 2024-07-20 16:11:49 +0000 cdefs.h: Don't define fallback for _Static_assert Remove pre 4.6 code to define _Static_assert in terms of _COUNTER. We no longer need to support compilers this old (in fact support for all pre gcc 10 compilers has been removed in -current). This is a partial MFC of that work because removing this fixes a bug that's oft reported with -pedantic-errors and C++98 compilations. PR: 280382, 276738 Sponsored by: Netflix This is a direct commit to stable/14. (cherry picked from commit 22cdafe197ac960c5ce839ef6ec699b59f4b0080) --- sys/sys/cdefs.h | 9 --------- 1 file changed, 9 deletions(-) diff --git a/sys/sys/cdefs.h b/sys/sys/cdefs.h index d9e1c476f1ef..080ae0912210 100644 --- a/sys/sys/cdefs.h +++ b/sys/sys/cdefs.h @@ -278,15 +278,6 @@ #if (defined(__cplusplus) && __cplusplus >= 201103L) || \ __has_extension(cxx_static_assert) #define _Static_assert(x, y) static_assert(x, y) -#elif __GNUC_PREREQ__(4,6) && !defined(__cplusplus) -/* Nothing, gcc 4.6 and higher has _Static_assert built-in */ -#elif defined(__COUNTER__) -#define _Static_assert(x, y) __Static_assert(x, __COUNTER__) -#define __Static_assert(x, y) ___Static_assert(x, y) -#define ___Static_assert(x, y) typedef char __assert_ ## y[(x) ? 1 : -1] \ - __unused -#else -#define _Static_assert(x, y) struct __hack #endif #endif From nobody Sat Jul 20 16:15:11 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRBTW62g0z5Rw4T; Sat, 20 Jul 2024 16:15: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRBTW5Dx2z4V9n; Sat, 20 Jul 2024 16:15:11 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721492111; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=o0qfXZjP3ZdaBNWWeYJLfMA67EVKVT/fxOjpl2UspFY=; b=ZYPAaSqhbuKOryDl4cBTFUDjdbVFyQS4Maj9spAYU8uiCDtR+MIFMge99rxTvKqgCMLcRv 0n4xE3BRCI+k3jokX96Ab5u49LR8pFM2xulUYgzjSYbcM+q3qEJ7RuhlY254HoetuqRkwH 3FG2LOqBYP7BQlyoq0gqRdgXAS4TOf6ilCaCPYAC2Xc1IyWdfOdVtRhLC4sB2Vd4eZK2Ao dpnXMSfZPn3NnS2TXtkkDzBPMSZOrHNCZZNTVEC0DHudCBtuB8qWbIHa/mQDEqBS1Fc3+T 1F7TPKhKqgrpC0msOWOW+kzm/Mf4IpBph6B1J0oPeuv9ARSbmohWBoxIl/jSNA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721492111; a=rsa-sha256; cv=none; b=x8bZMkiK9hga5rX4kejuBUo5mShT2RmDBRVh7PwCWYoufG2VOdpuOQqac0EO674LermcwR Ogf4HUWLOAIHXFWzfDW1CR9BGIWJCCnYnguZ0Lu7ru0ICNK2HKH4jfj8bJEXUlg0IoxK/0 KskVVrhnt/wWxBUPxj6cqyPP6H5PgKFp5zOeUnEa3Nb39jB6YTpc5cYQQOokZuvCF9HaLL XfBOZBsXV4icj93e2vWnDq99xTsdNXoFcHzvxbSbbP+iJDYpp9RsHPlbH+EuJr5ezp70wA XOErQwbmpwJU35BcjEeTbrtnR0DydiQGHOMmpfwip+kbzKRKzJnxYT/ROFdJMQ== 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=1721492111; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=o0qfXZjP3ZdaBNWWeYJLfMA67EVKVT/fxOjpl2UspFY=; b=j3UzTIdXGI82nAT6kXaX1H8ga86GIZIEkr1hU561T84Yj4Ddb8RmZhrgw1UCsX1zOSbTN1 HQcqgcMgNO+CFi7PyVLR9UIJePWLOpHnSKdgYLZHNwwKiDnLpzCaaBfqWK+Y8DFKcB7wH5 4AnAiJizPweTf2pb/yeaDYLVW9xJT+fhcmrqRioup+QSnbxNGQb0qgOBM7Y33nsiolz2iL iAblKRfNpl45AGFC0+DiXM3/W+m7dqKejGqDPHhuqqSUY9fyAHRB8kJGyxbrnzUU6NzTch /HMEkgzh37z7FRb3i20wIcFWI2K1ukl1iaHPuJunJ/Rq9BJLgwrA+gLDZP4V4g== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRBTW4qMmzNZY; Sat, 20 Jul 2024 16:15:11 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46KGFB2n080647; Sat, 20 Jul 2024 16:15:11 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46KGFBtJ080644; Sat, 20 Jul 2024 16:15:11 GMT (envelope-from git) Date: Sat, 20 Jul 2024 16:15:11 GMT Message-Id: <202407201615.46KGFBtJ080644@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ryan Libby Subject: git: 90818083d795 - main - ipf: correct size limit in snprintf List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: rlibby X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 90818083d795a9c06feca54f32fa6d35c200e1a2 Auto-Submitted: auto-generated The branch main has been updated by rlibby: URL: https://cgit.FreeBSD.org/src/commit/?id=90818083d795a9c06feca54f32fa6d35c200e1a2 commit 90818083d795a9c06feca54f32fa6d35c200e1a2 Author: Ryan Libby AuthorDate: 2024-07-20 16:14:57 +0000 Commit: Ryan Libby CommitDate: 2024-07-20 16:14:57 +0000 ipf: correct size limit in snprintf Reported by: GCC -Wsizeof-pointer-memaccess Reviewed by: zlei Differential Revision: https://reviews.freebsd.org/D45899 --- sbin/ipf/common/lexer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sbin/ipf/common/lexer.c b/sbin/ipf/common/lexer.c index d1980765ef93..56ac3586af6e 100644 --- a/sbin/ipf/common/lexer.c +++ b/sbin/ipf/common/lexer.c @@ -449,7 +449,7 @@ buildipv6: oc = c; if (prior == YY_NUMBER && c == ':') { - snprintf(s, sizeof(s), "%d", priornum); + snprintf(s, sizeof(ipv6buf), "%d", priornum); s += strlen(s); } From nobody Sat Jul 20 16:47:58 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRCCM1SZkz5RyJX; Sat, 20 Jul 2024 16:47: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRCCM0hhjz4Wrk; Sat, 20 Jul 2024 16:47:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721494079; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=AJjvF+hL1CnNZgKJDe8ssn60uCudg8YAn1+zA20I79s=; b=IvE0YfUmmPNgEBWyAbc2veQ1r3fuX7SZdq/Z2cvbkNfHiKCOAvjlf2dQYNKVzWYj8yasW/ yGCSQJEKfPSoYP3shp8WiqHQrbQCKrBTLVWumnjSjofFQ8OKcSzdoTpjiZZ+By1aZW/smo b9G2Mv/0z1Kc4JgNIB4T4diPFENEEGGJ70J5WFzZCni3p5LfrITaUgQoGF0XfBMDJ1Bd1U NeYijGI2/xF70xstyN1aAPzbQ9shSPAkzX4u8xIgfUBYJBXD8EYYmBn9Db9fIFMP+FFUy4 /O+Wrokt8a8BhU1mkZdZDprK0V4vh5Wp8d1rS+CRe0bm0UeZCGMlmtLxQzzgYg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721494079; a=rsa-sha256; cv=none; b=rS8Ww23l7WwUvweNww3Z4mIqh3pptyHmdJxTUm6uFYFVpsk7NxdyjMgmKQwFFbutGgNBle sVSv/ZWk0VzTtkll2WRYtgO82UHQGikmBqoSr/aFvg1c8bHceyEd+b3jZUKRoQGMmHYUcP /zjCycT/cYKY7F6uh3pcihF5O7bJio2Ox8YMiBGaP7Fl3+dhcF2BgMgF6ATaonwJ1wrZZa woVSkDEyjz9GyV3sevlimvNCXuIValv08b8asZ3snDLZDGItepYHkG3qIyKoaOzEYqA07A FV0AIkdqEj9el2gSQx8+/R+K3gQBmpHn7DVEs1Ev2NQhtJ/CRDwWZpFWEw6erQ== 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=1721494079; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=AJjvF+hL1CnNZgKJDe8ssn60uCudg8YAn1+zA20I79s=; b=xvAOQjzeIKzPLC7lzS0flDKTaAYdUE5jbdHACo8ZgleC2fk4Q1k6hDXh25FMjd0Ccygv0F yyZUQjFKp1yCmlS8ebP+PHzB34hzDr713BK6pTZUcMiOSdQHb+45E8K0KC9lwqa35QoDS3 /7td7oJduBR9v8YFTF0BRJhEoNnRS+4iIzz3PTqMVLBOaDrg0tG1HiRiuKejsMm01WSATd kp4VlMXzPvo1WCozQUrX68//hMWtLUW4NIoO1gRjEVZxYHynTGqDgBDjLur+WJ1yjoXl4Q QYtD2KeadNJFuquuM0u2OQlrn/k/w1eugwUl7YosDgeA0jRYbjclpXDq/HFd6A== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRCCM09hJzPdZ; Sat, 20 Jul 2024 16:47:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46KGlwa4031338; Sat, 20 Jul 2024 16:47:58 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46KGlwZ5031335; Sat, 20 Jul 2024 16:47:58 GMT (envelope-from git) Date: Sat, 20 Jul 2024 16:47:58 GMT Message-Id: <202407201647.46KGlwZ5031335@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: 29020ea39d6c - stable/14 - development.7/FILES: add CONTRIBUTING + git-arc.sh List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 29020ea39d6c55983dfa49b3c2928acdd851c1d3 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=29020ea39d6c55983dfa49b3c2928acdd851c1d3 commit 29020ea39d6c55983dfa49b3c2928acdd851c1d3 Author: Alexander Ziaee AuthorDate: 2024-06-18 11:02:42 +0000 Commit: Warner Losh CommitDate: 2024-07-20 16:46:52 +0000 development.7/FILES: add CONTRIBUTING + git-arc.sh MFC after: 3 days Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/1300 (cherry picked from commit c2c6f08c8b47cfda79529e0a1016b8f7803c0ec8) --- share/man/man7/development.7 | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/share/man/man7/development.7 b/share/man/man7/development.7 index 0eb5377bd07b..c12ab2b885a3 100644 --- a/share/man/man7/development.7 +++ b/share/man/man7/development.7 @@ -21,7 +21,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd November 1, 2022 +.Dd July 7, 2024 .Dt DEVELOPMENT 7 .Os .Sh NAME @@ -116,7 +116,14 @@ build and test status of CURRENT and STABLE branches, the continuous integration system is at: .Pp .Lk https://ci.FreeBSD.org -.Pp +.Sh FILES +.Bl -compact -tag -width "/usr/src/tools/tools/git/git-arc.sh" +.It Pa /usr/src/CONTRIBUTING.md +.Fx +contribution guidelines +.It Pa /usr/src/tools/tools/git/git-arc.sh +Phabricator review tooling +.El .Sh EXAMPLES Check out the CURRENT branch, build it, and install, overwriting the current system: From nobody Sat Jul 20 16:48:00 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRCCN3263z5RyDG; Sat, 20 Jul 2024 16:48: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRCCN0xXLz4XD2; Sat, 20 Jul 2024 16:48:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721494080; h=from:from:reply-to:subject:subject: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+gbsbUOKT4tAJS8FMLRXy8ST+TQdWmxlb2Khf9/6cc=; b=VbVhtl600Ev8/CfZ/yk1NIYCV+0G5MEDOYdoDNdezCFrjKdHDqIdfQ8Xv7u3xav9pWcVge 7vTjbV3VObw7NusLKzeujRlEmMoEBu/+WSbzhukZKIyt832cLmJmXGLo8Jhk7wE/ntz/iE KT91K4eFkcziJJQbaGj+Ue31vDcdlQJKRlRHDDG5uvNFpxt+fByJIkKnzgsO7Dyj+FxgIn g+C8LhPH1W2J4Cdg/VcE4uTxV6BYNC4MaMfXaQlNo+U9ZBYeo83TZqrwn73DFdtKGDDsfW C6v/mrnCAaUXkGFk5Sf62RGnWzbo+yE1r1dqNN869v7JHjuVTH9RfZhYNOXbwg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721494080; a=rsa-sha256; cv=none; b=nUbuwwGmhOis6/A6b4fi328yaWJID6gsojw3y3ANClyURdn18EWjT6+2ZDKNBFRPJ2gmzI 56maHD7H3hSaYyUY5cibnLrk2lvSBdhBQclqf/pM2ZeCriIwdvjejIwZD21E9J9dp6kiEW AWWauoM7blt5sUfNpFV3Ttl8INWgsPrrwFS+nCFRXodWzC8fZqaA9NmX0u4DRQugR5UroC gmdZpI2sP/hMVY022Qh+vcjkAEJaMYU03S4xYC8YiABw3O8Bedfc5OeXokUM4gmaSk9QYq Zo/yOMv8bYH3drrSqdmS2qYdpZdLy9TtmQtLhvqe2Clmawh3BOzO8PwomHOwGQ== 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=1721494080; h=from:from:reply-to:subject:subject: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+gbsbUOKT4tAJS8FMLRXy8ST+TQdWmxlb2Khf9/6cc=; b=Uvu66q0jqGheTHYCS9KS4j9zRMKUrZ16+T3CFt8b+Gq6S+aM5BBj7Fbtr3dIKDri/vzgz0 1qliSbtjOtmySW/1dBuF/PRcHPxlRoscNwc5U2RuUYmO4OXLb+TLLspppq9dgYRZbWUxwq MrNqYsWv4lenEhOcubZajeTeNSyLfntP3CcCte85e4JK3BbqM2wccgFdTF9GXbOvqy4X7Y KUns0AT2S1aQv5fhQV1Ap4+FDnoBykPAnXrAni7t1Y+7vStBXcN3v9qXR24LpuYKLRqKTA W+50fLLuWfgKNx3kpbxxdne7gBllpCsW/WMSYV/J2tY7VwCdyvJxVqVk/UEPpg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRCCN0XvVzPK4; Sat, 20 Jul 2024 16:48:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46KGm0GD031389; Sat, 20 Jul 2024 16:48:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46KGm0UW031386; Sat, 20 Jul 2024 16:48:00 GMT (envelope-from git) Date: Sat, 20 Jul 2024 16:48:00 GMT Message-Id: <202407201648.46KGm0UW031386@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: 735f676b91a5 - stable/14 - kbcontrol.1+kbdmap.1: improve manual descriptions List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 735f676b91a5c8cebecc26672927e28880629876 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=735f676b91a5c8cebecc26672927e28880629876 commit 735f676b91a5c8cebecc26672927e28880629876 Author: Alexander Ziaee AuthorDate: 2024-06-04 07:49:43 +0000 Commit: Warner Losh CommitDate: 2024-07-20 16:47:11 +0000 kbcontrol.1+kbdmap.1: improve manual descriptions Update the man page descriptions so that apropos {console,keyboard} finds more relevant man pages. MFC after: 3 days Reviewed by: imp, emase Pull Request: https://github.com/freebsd/freebsd-src/pull/1275 (cherry picked from commit 580dc180c7ebd84a4aee27938a5f4a62520ac5d9) --- usr.sbin/kbdcontrol/kbdcontrol.1 | 10 +++++----- usr.sbin/kbdmap/kbdmap.1 | 7 +++++-- 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/usr.sbin/kbdcontrol/kbdcontrol.1 b/usr.sbin/kbdcontrol/kbdcontrol.1 index 0b984547a122..34126c718ed9 100644 --- a/usr.sbin/kbdcontrol/kbdcontrol.1 +++ b/usr.sbin/kbdcontrol/kbdcontrol.1 @@ -1,5 +1,7 @@ +.\"- +.\" SPDX-License-Identifer: BSD-2-Clause .\" -.\" kbdcontrol - a utility for manipulating the syscons or vt keyboard driver section +.\" kbdcontrol - syscons or vt keyboard driver configuration utility .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions @@ -10,14 +12,12 @@ .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" -.\" @(#)kbdcontrol.1 -.\" -.Dd March 16, 2016 +.Dd July 7, 2024 .Dt KBDCONTROL 1 .Os .Sh NAME .Nm kbdcontrol -.Nd keyboard control and configuration utility +.Nd system video console keyboard control/configuration utility .Sh SYNOPSIS .Nm .Op Fl dFKix diff --git a/usr.sbin/kbdmap/kbdmap.1 b/usr.sbin/kbdmap/kbdmap.1 index 4c7f01d84745..002d8b2b9773 100644 --- a/usr.sbin/kbdmap/kbdmap.1 +++ b/usr.sbin/kbdmap/kbdmap.1 @@ -1,3 +1,6 @@ +.\"- +.\" SPDX-License-Identifier: BSD-2-Clause +.\" .\" Copyright (c) March 1995 Wolfram Schneider . Berlin. .\" All rights reserved. .\" @@ -21,13 +24,13 @@ .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. -.Dd July 3, 2002 +.Dd July 7, 2024 .Dt KBDMAP 1 .Os .Sh NAME .Nm kbdmap , .Nm vidfont -.Nd front end for syscons and vt +.Nd system video console keyboard map/font dialog utilities .Sh SYNOPSIS .Nm .Op Fl K From nobody Sat Jul 20 16:48:01 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRCCP5y7bz5RxpP; Sat, 20 Jul 2024 16:48: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRCCP2VH0z4X9x; Sat, 20 Jul 2024 16:48:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721494081; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=0inNqts2DURClpjEpQq9pmIQc+bQ44W0rk3ISy4mu8U=; b=dZWK+seL2odDEHg037Xzmv+Hp/8VI1y6UTodG3IlhGbwTuPrtNtH7eQFRWwyYd92JSePth xEYtm3oWVLZngEJprcsn/pASZTtGjU2GyktA/KmCTqPzb0usJ7BB4Psy9whieeRi78dDeG 70uUYifks8lEhYUk35iY5JdhqxaqRInVO/AzPmysMFTTeNe5frcSQQRVMj8yuiL+wDLe76 qfpnDXYY4OpBBh75uRodZtQUTOoapzb1lrLG/ujGgijtoRAlnO8vV4xJRX7H0bG5FDZREp G9K28vFccBC3kRP3b19aZRn+lIOyIxva+mNCj1V5dj4Pyd57AtQe3dSfeILBCw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721494081; a=rsa-sha256; cv=none; b=nnKWmNMnFiZaeVVoeiy/tAsur+61CqMoTz6osE0f2MMaiCsBt2NfQRCB5s0UjJ/0qItpHj 2waNAFtgz42WbPwn7BuQahCwt0B67ILVOXfRTmjqh9W7Rbw9MOOvsJqzbQERNpkWnNq5Nk HVQUbKLGvcodDd5gPwVW/EAIGmn4FOon+rolValM0m30RVNOKxYueuvHpq0Nb76HBiyk5G oGjAFrgYrlGQ9tPKlxJQhH7OtkbDCrZWEur83ip3R9X0fHUh1Mg1VefhPdkQBcCHf7sLwt 9VB5gLxLP2LtgG9VEYmQXO9JTtF6oR2tmqS2MLmHgCHsc4tjtz5a6rXhslI/BQ== 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=1721494081; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=0inNqts2DURClpjEpQq9pmIQc+bQ44W0rk3ISy4mu8U=; b=k/Uupg9Cgx/x/YdlVr8e1qSW3kB4QkCQdJ3dScoMJJnhipVv36otmQnaqhjQa/BvP5USb+ Zg/w/5abYhccbBdNuggwD/KeQ5LOZA6e1wXqgMOhy1SJXCP0YTp4M90UzcH4RJmKie6+ZT Hy8DsxA+wCwaKJU4aGtzypTu8BvJZDx1bvOW9GhvERlQMxiE0QqNtX9Q1fEyBo8LO5sb90 SCI+3iF33qvsqCFB79riOGa+nSK0Y/zcCywT0aWyi2vOanrxNEYZcSYQdvyQXpe6vIqyMv wUM0vkumQZExg2+rle6v5OBDH2264s5VveXqbU7r0D0eCKB2C5X+wkd2G8XvIQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRCCP1rhlzPK5; Sat, 20 Jul 2024 16:48:01 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46KGm1vl031437; Sat, 20 Jul 2024 16:48:01 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46KGm1D8031434; Sat, 20 Jul 2024 16:48:01 GMT (envelope-from git) Date: Sat, 20 Jul 2024 16:48:01 GMT Message-Id: <202407201648.46KGm1D8031434@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: 95c280792505 - stable/14 - manuals/description: system video console utilitys List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 95c2807925052f6a0938ac51757ef6a97a340835 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=95c2807925052f6a0938ac51757ef6a97a340835 commit 95c2807925052f6a0938ac51757ef6a97a340835 Author: Alexander Ziaee AuthorDate: 2024-06-04 09:03:41 +0000 Commit: Warner Losh CommitDate: 2024-07-20 16:47:26 +0000 manuals/description: system video console utilitys Update the man page descriptions so that apropos are more consistent for console related man pages. Motive: apropos results: clarify consistently MFC after: 3 days Reviewed by: emaste, imp Pull Request: https://github.com/freebsd/freebsd-src/pull/1275 (cherry picked from commit de2ab11ff955faa32bfffe5b2401b444a7c138f2) --- sbin/conscontrol/conscontrol.8 | 6 ++++-- share/man/man4/vt.4 | 7 +++++-- usr.sbin/moused/moused.8 | 7 +++++-- usr.sbin/vidcontrol/vidcontrol.1 | 8 ++++---- 4 files changed, 18 insertions(+), 10 deletions(-) diff --git a/sbin/conscontrol/conscontrol.8 b/sbin/conscontrol/conscontrol.8 index 54c89d5e5c1b..c11a1f7db5d9 100644 --- a/sbin/conscontrol/conscontrol.8 +++ b/sbin/conscontrol/conscontrol.8 @@ -1,3 +1,5 @@ +.\"- +.\" SPDX-License-Identifer: BSD-2-Clause .\" .\" Copyright (c) 2001 Jonathan Lemon .\" All rights reserved. @@ -23,12 +25,12 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd April 14, 2011 +.Dd July 7, 2024 .Dt CONSCONTROL 8 .Os .Sh NAME .Nm conscontrol -.Nd control physical console devices +.Nd control physical system video console devices .Sh SYNOPSIS .Nm .Op Cm list diff --git a/share/man/man4/vt.4 b/share/man/man4/vt.4 index 81eafb6fae6a..0523f990f57e 100644 --- a/share/man/man4/vt.4 +++ b/share/man/man4/vt.4 @@ -1,3 +1,6 @@ +.\"- +.\" SPDX-License-Identifier: BSD-2-Clause +.\" .\" Copyright (c) 2014 Warren Block .\" All rights reserved. .\" @@ -22,12 +25,12 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd May 24, 2024 +.Dd July 7, 2024 .Dt "VT" 4 .Os .Sh NAME .Nm vt -.Nd virtual terminal console driver +.Nd virtual terminal system video console driver .Sh SYNOPSIS .Cd "options TERMINAL_KERN_ATTR=_attribute_" .Cd "options TERMINAL_NORM_ATTR=_attribute_" diff --git a/usr.sbin/moused/moused.8 b/usr.sbin/moused/moused.8 index 9eeb48547866..cd5d8ddde339 100644 --- a/usr.sbin/moused/moused.8 +++ b/usr.sbin/moused/moused.8 @@ -1,3 +1,6 @@ +.\"- +.\" SPDX-License-Identifier: BSD-4-Clause +.\" .\" Copyright (c) 1996 .\" Mike Pritchard . All rights reserved. .\" @@ -28,12 +31,12 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd May 15, 2008 +.Dd July 7, 2024 .Dt MOUSED 8 .Os .Sh NAME .Nm moused -.Nd pass mouse data to the console driver +.Nd pass mouse data to the system video console driver .Sh SYNOPSIS .Nm .Op Fl DPRacdfs diff --git a/usr.sbin/vidcontrol/vidcontrol.1 b/usr.sbin/vidcontrol/vidcontrol.1 index 1d0f437476ee..09855df6b60f 100644 --- a/usr.sbin/vidcontrol/vidcontrol.1 +++ b/usr.sbin/vidcontrol/vidcontrol.1 @@ -1,3 +1,5 @@ +.\"- +.\" SPDX-License-Identifier: BSD-2-Clause .\" .\" vidcontrol - a utility for manipulating the syscons or vt video driver .\" @@ -10,14 +12,12 @@ .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" -.\" @(#)vidcontrol.1 -.\" -.Dd April 6, 2022 +.Dd July 7, 2024 .Dt VIDCONTROL 1 .Os .Sh NAME .Nm vidcontrol -.Nd system console control and configuration utility +.Nd system video console control and configuration utility .Sh SYNOPSIS .Nm .Op Fl CdHLPpx From nobody Sat Jul 20 16:48:02 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRCCQ5DMTz5RyGx; Sat, 20 Jul 2024 16:48: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRCCQ3QZMz4XBB; Sat, 20 Jul 2024 16:48:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721494082; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=9Pl+c96bL7hjmQsZ86G58QIs+qUZwNDpQH2vJpfEMtg=; b=Svf+s4ymHk14tQXh9ypDUJW720HqV0/e3G1t9DR0H74aZFpjdX20FMzZSgZGnVsNNvQIqN jDb6Enesir/D36aGclxrvA1+qvBkvJiMXVi9rxbmInUlK6iVQEu6JfOE9vm6kM5tTo6mns UPCHLfs+O8sJGgXEL3+GGk8b6DY7skZNgb/MhlQSjXSJ3BdSUOAJyZ43RIx7hik6FPY7Kr c52IeWyi1eaBmHo1faWT1NyIgwN6frkqi3JbQJQVCjYT3QjQD+9JEutliBdpUZYl4lm07p u39r2IiLST/gc3HrK4eMBAxj7eF+W2oym9NIfg9v1eSJn2Wc73On3Vwu5Xj/xw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721494082; a=rsa-sha256; cv=none; b=PZqfm4IqKt2nYcffJPvNsHABy9VZwl/cQ1VdCM+Vke3U/+TRxwZtDtlkq2H4PPKNqk+KE9 A0RrjHEcYCOyG/nt3WxZ2EJxD+irnmT4yHPJq3RNeuE+uL20DmuEtoibFVIfvvdMgAbUkB Kt1KJlrbW5/ZRfdtEdbJFeHGbA6/uE3zWZJyI7bl5emAXPnpkwVv9fxTdRzXUXTd4NOQ2O PjrdtLkTimPv0Chw3SR5+WM5Jfi76PRDpnh8h/hyB2DMXUMf+EbZniDXbFebeRDgULG/Mb jTRMb6q4XMYmfNci48k/+EsYmxxJPVSbwwI4irK7AmKc7TaTnqDwWcljtMaa5Q== 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=1721494082; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=9Pl+c96bL7hjmQsZ86G58QIs+qUZwNDpQH2vJpfEMtg=; b=BJH536TgZ4QYsdIwAUD5s5RrSgay4hiwi9wXY/FosbFh81AmvMhk5ACJ4na6bUgZpjiTIB 9+O35+YM4ODjhZ5b1xhlVM+OH5/7b6RFyE/a3SrlQ014f8wAbRIXV0l5JKXBxhUmoJEbHP 1XXFudkjeuEi3GotHmElzhIOs6dyRzyhuSIiCLfeJ510m3E6UAxJxb8izbCmPJa7REUlkR vTPyu8t4/nQN+uY4Adbo6GBpsO6J8DJ1NNyGD6X9sPUyq1ZThzZ5yKkUjRwKftyI8dTtn9 MqWq1Kid3mVSAmRdPQefRzdXCbWWkrbTLb/epy04owSEYLl8ykqOH40X8caXUQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRCCQ2mwqzPMN; Sat, 20 Jul 2024 16:48:02 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46KGm2sY031478; Sat, 20 Jul 2024 16:48:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46KGm2Iw031475; Sat, 20 Jul 2024 16:48:02 GMT (envelope-from git) Date: Sat, 20 Jul 2024 16:48:02 GMT Message-Id: <202407201648.46KGm2Iw031475@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: 18606111ec5b - stable/14 - networking.7: remove confusing caveat List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 18606111ec5b2b78dbf933ddb1e9bfd477a0b896 Auto-Submitted: auto-generated The branch stable/14 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=18606111ec5b2b78dbf933ddb1e9bfd477a0b896 commit 18606111ec5b2b78dbf933ddb1e9bfd477a0b896 Author: Alexander Ziaee AuthorDate: 2024-07-05 00:50:25 +0000 Commit: Warner Losh CommitDate: 2024-07-20 16:47:28 +0000 networking.7: remove confusing caveat + service routing restart breaks on dhcp + change my copyright from inbox to home Fixes: 75eda009 MFC after: 3 days Reported by: Graham Perrin, zlei Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/1316 (cherry picked from commit c55f56de9da11e11ee950993afe8b8575d8daa56) --- share/man/man7/networking.7 | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/share/man/man7/networking.7 b/share/man/man7/networking.7 index 869812c05a9b..03e80793e98d 100644 --- a/share/man/man7/networking.7 +++ b/share/man/man7/networking.7 @@ -1,7 +1,7 @@ .\"- .\" SPDX-License-Identifier: BSD-2-Clause .\" -.\" Copyright (c) 2024 Alexander Ziaee +.\" Copyright (c) 2024 Alexander Ziaee. Ohio. .\" .Dd April 17, 2024 .Dt "NETWORKING" 7 @@ -92,10 +92,3 @@ will need to be escaped for commonly using .Ql \e , see the manual page for your shell for more details. -.Pp -Currently -.Ql Ic service netif restart -does not restart routing. -A common workaround is to issue -.Ql Ic service netif restart && service routing restart -instead. From nobody Sat Jul 20 19:42:40 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRH4w3ZvBz5N2fQ for ; Sat, 20 Jul 2024 19:42: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRH4w32hwz4tNj; Sat, 20 Jul 2024 19:42:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721504560; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=7jTJ1r7iRfFMKfHsntJCdHTzQg/9anoFFijf5BgQSA0=; b=D5+lbCZVmSOC5pJFM7uSn4yIunzQbF+3kmpWfvq68MyVj8T0gitkAdTcQAwoB8wqiJpqOp iwHDrrB8ZoKLHv16a9E1kcxcdZ+GVCO1QO8WO00ChfKSeGF+C/JaJdbW3nNYOz3j9iAsOo hhXY+qs/G6iCYarP9QuXvn5NTPWOCIyy/jgJP43bVwNAHDRRbQckBNlrPMD8H6nIkh5iZz Yt7qBo2JvmyJQ3NWWfuQqw4dFoZv6iJj0FN+aXRDWzGD++9GeGewO1JPpfI6sI8PefOLRS bPk8WLmYRONWPcwwn8A5AUjvUrWlXHYPQCbkvYE0ncQaTofGEvicSCJ7sOHXtw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721504560; a=rsa-sha256; cv=none; b=V4NdkMQr4JGw5qvfI1Wfb3BCmN/Ap5fyqyzcTB3VoXYQc1pvDoilF4Nigw+t5O1uPgqZjx Yr6uBZOV3HUrmatp2IuNCbdSDgK5WXmOvXRQzSygoag/r9PctXraodlW4mXDziayMaWtJQ TKAEjXIahc8uakqYC2gKyLr8QqTA8RbtZxqfCRJlIOk+kfm98zRtsF0LNek3yjKGesYnpc C32rbsnWBAjkv+YZ6KMci2i89+c1/LEh0Y/MWahSz76z//Hh2YJxkDhumw1YqM+dnJ0bxq SJ+rkkazxYo2Jajjk+ukRRfA8Ou+3AOIZs5WVxO+CXKJNTGCcEz74YWfJtx2rw== 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=1721504560; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=7jTJ1r7iRfFMKfHsntJCdHTzQg/9anoFFijf5BgQSA0=; b=SkqQOThOofGcFeL7VZqtNJIW8j9COLkk6Djilfx1fPJMvL2Op3Xtb+Z1/ZL8ejPUGYcmPS 2TDlDLnApbPr3b74WTVM2AYydlcJoil4e9bnMlh5RstmZsU9lCuZ3oOrqVwenCLMccxiVs d8LQ/TnBu4vYyQ9MRELUe4U2A8DcN19NAMQ33xsnKgtNYCLWU4q4ne+mEInPH6iXtWmyNz aNF0t5AZZyOz6Sl5cvikfTYg08Is0k+kxIQ90iilDNvgU1xFe525a08bi/dMh/vlpb2trz bJvmoL3NDY92zAs6hvBRu6NJXApIpRnAwSpXpn14oJGtvoNvi7RhImJywjL3Qw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRH4w2DJ7zT6x; Sat, 20 Jul 2024 19:42:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46KJgeY3034452; Sat, 20 Jul 2024 19:42:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46KJgeQl034451; Sat, 20 Jul 2024 19:42:40 GMT (envelope-from git) Date: Sat, 20 Jul 2024 19:42:40 GMT Message-Id: <202407201942.46KJgeQl034451@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org From: "Simon J. Gerraty" Subject: git: dbb5be7f0745..84691af93185 - vendor/NetBSD/bmake - vendor branch updated List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: sjg X-Git-Repository: src X-Git-Refname: refs/heads/vendor/NetBSD/bmake X-Git-Reftype: branch X-Git-Commit: 84691af93185c692058ba55fa81a04103f5bf71b X-Git-Oldrev: dbb5be7f07456d02ce444484c683b130439acb45 X-Git-Newrev: 84691af93185c692058ba55fa81a04103f5bf71b Auto-Submitted: auto-generated The branch vendor/NetBSD/bmake has been updated by sjg: URL: https://cgit.FreeBSD.org/src/log/?id=dbb5be7f0745..84691af93185 84691af93185 Import bmake-20240711 From nobody Sat Jul 20 19:42:40 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRH4w3pgtz5N2l5 for ; Sat, 20 Jul 2024 19:42: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRH4w3HlWz4tQv; Sat, 20 Jul 2024 19:42:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721504560; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=NW1yo45O0mGd7jwjKRMrg1sefJvyqexzMYi2s3BI/Xo=; b=AEAK1qc6tzfdlNDpdo6ncsrawJvbrz8cpHW+bC7b01PMJxRsq9EsPpjJWusYBgGRryk3EB HOnwjshTDzUgexdVcquyhlZ07xrelgL85/0RgDhb4j7skILcTAKwmeb5hQAOcTywqnvwCm SzELkScuCJo7m55BJevcrHMS0AzLCnVeIDfyehVe/QbmBr+m5YlTtpjI/YO/aR7BzVz1IB NBNTjJHAMGwxz+VUEBwptjOE3in9OlRv+CahdXIenLfy/UjsNTbq7asbkDvZ8v3S5xfJ+r qeLT+VDQiJblbT6MOanzBWJXOwPBwmarfgILIwLxEbPynk2LOS3oDTptthnKAA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721504560; a=rsa-sha256; cv=none; b=oAwjNbl/3dr1AWLBqkgSUPfDH0yIESU/KHcG8bP5qCSqtIR8eYRTR38+8iEb5+ZmmGfsgB 4u5bmXeKePQObPOxorXNGxs+GIPuOQmnVBfk/FnPeKu1tMXI0d5KGiUCaC1wzQ1FQA8gpW Ogn+jI2GghjCKVAALmtH45QFj8B0jPz9iiATyspebcI3oEMwBd+Rob/m4uoHlNuiwH/qdM Kb2OLah7ulH2zIf/AwrrPkqbXcAGi6AONi0O6XQV/b+OauPm4MmroGqdPRuwIsyjROtJXN CSXqBQRL65Bmfw6PLaPEeQ4giDCGAvEfiC/xB1vFRr8t6Xahe+2SZH2vESoyeQ== 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=1721504560; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=NW1yo45O0mGd7jwjKRMrg1sefJvyqexzMYi2s3BI/Xo=; b=rZHHmLQmQ6L0Ani0yszKaZb9Rm093VSetJpWFN5qhZyBEho2p7iSupL8QYwhN3NmzISm7A Cda9EFSrkV8iXQz4QgFcXJu8BQaXvIsGASPUKKnmvUV+c90dlVOPmd+I7YfoKnA8vd+q+w 9dPM/WtcsOlyk366RmMaRhgUYZkGhm1NEL7xIpbwiAlknQXC3wbdVmU5yO1p+paJLj4/8a zSIUdFbXoVi2A1/faMkteRZYKZVX1emn6ZTNdFovXsSsy6i1DuAQewl3llJu/XYXUJ1jS3 JMZNFGI7ZsiqQnF6k1tkFhw/P8RI/6Avb3vdWuVxyJvOOom2IDtP1Wf2kvtOcQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRH4w2tqHzVWW; Sat, 20 Jul 2024 19:42:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46KJgeUe034471; Sat, 20 Jul 2024 19:42:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46KJgedV034470; Sat, 20 Jul 2024 19:42:40 GMT (envelope-from git) Date: Sat, 20 Jul 2024 19:42:40 GMT Message-Id: <202407201942.46KJgedV034470@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org From: "Simon J. Gerraty" Subject: git: 0b99c8b804e7 - Create tag vendor/NetBSD/bmake/20240711 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: sjg X-Git-Repository: src X-Git-Refname: refs/tags/vendor/NetBSD/bmake/20240711 X-Git-Reftype: annotated tag X-Git-Commit: 0b99c8b804e74f76b687abd1befb943230097ce4 Auto-Submitted: auto-generated The annotated tag vendor/NetBSD/bmake/20240711 has been created by sjg: URL: https://cgit.FreeBSD.org/src/tag/?h=vendor/NetBSD/bmake/20240711 tag vendor/NetBSD/bmake/20240711 Tagger: Simon J. Gerraty TaggerDate: 2024-07-20 19:42:07 +0000 Tag bmake/20240711 commit 84691af93185c692058ba55fa81a04103f5bf71b Author: Simon J. Gerraty AuthorDate: 2024-07-20 19:41:55 +0000 Commit: Simon J. Gerraty CommitDate: 2024-07-20 19:41:55 +0000 Import bmake-20240711 Intersting/relevant changes since bmake-20240625 ChangeLog since bmake-20240625 2024-07-13 Simon J Gerraty * cleanup redundant differences from NetBSD make o parse.c: no longer uses mmap o var.c: check __STDC_VERSION__ not __STDC__ 2024-07-12 Simon J Gerraty * Apply some patches from NetBSD pkgsrc to reduce divergence o meta.c: requires sys/select.h if available o var.c: ensure SIZE_MAX has a value o util.c: ensure SA_RESTART is defined * configure.in: use *ksh* rather than just *ksh to match ksh shell specification. * unit-tests/Makefile: expand BROKEN_TESTS for ksh and mksh in particular 2024-07-11 Simon J Gerraty * VERSION (_MAKE_VERSION): 20240711 Merge with NetBSD make, pick up o compat.c: allow Compat_RunCommand to also handle very long commands by writing to a temp file when needed. o main.c: extract the temp file logic recently added to Cmd_Exec to Cmd_Argv so it can be leveraged by Compat_RunCommand. 2024-07-09 Simon J Gerraty * VERSION (_MAKE_VERSION): 20240709 Merge with NetBSD make, pick up o error out on parse/evaluation errors in shell commands o var.c: error out on syntax errors in ':M' and ':N' modifiers 2024-07-07 Simon J Gerraty * VERSION (_MAKE_VERSION): 20240707 Merge with NetBSD make, pick up o only generate code for cleanup functions in CLEANUP mode o hash.c: don't track hash table chain lengths during lookup unless debugging o main.c: move initialization of variable scopes to targ.c o var.c: remove Var_End as it is now unnecessary 2024-07-06 Simon J Gerraty * VERSION (_MAKE_VERSION): 20240706 Merge with NetBSD make, pick up o reduce lint comments about ARGSUSED o cond.c: error out on conditions containing the operators '&' and '|' o str.c: error out on a matching malformed matching pattern '[[' o var.c: in error messages, distinguish parsing from evaluating in error messages for anonymous variables, log the value error out on unclosed expressions during parse time 2024-07-04 Simon J Gerraty * VERSION (_MAKE_VERSION): 20240704 Merge with NetBSD make, pick up o add more context information to error messages o main.c: on error, print the targets to be made add detailed exit status to message for failed sub-commands o var.c: error out on the "Bad modifier" error message 2024-07-01 Simon J Gerraty * VERSION (_MAKE_VERSION): 20240701 Merge with NetBSD make, pick up o var.c: add :tt for Title case 2024-06-30 Simon J Gerraty * configure.in: 20240630 further refine check for whether TZ=Europe/Berlin works * VERSION (_MAKE_VERSION): 20240630 Merge with NetBSD make, pick up o job.c: reduce use of UNCONST o main.c: add detailed exit status to message for failed sub-commands o var.c: error out on some more syntax errors add more context to "returned non-zero status" message From nobody Sat Jul 20 19:46:54 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRH9x2mnCz5N32j; Sat, 20 Jul 2024 19:47: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRH9w6vfNz4tbt; Sat, 20 Jul 2024 19:47:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721504820; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=GiIKlBXLSjBYjbMgCqUj0p6nRgLHY4NcrivGUw1DFoI=; b=ctyFTmQfR7qSKCDp/54i2wfvAjRy0zbH7igkl8YkbaJdP9+x/P9MKDwr47PkvsfeR2Ji0v i0K+d3gtQxZpUlI2jKrASf5GfcSk+C6H5mCO7UYcKnJ0maoOfTDlQNkRM+mhgmNsKL16bT RlVIANzxLFG0sgZolF2WcAqng9tvxTisZFNYx4kRPKvcBQCG3jMo3dWZGOIoezStisHLy2 2DCtSQNLGUYM5xSgDGAfSZT1Ia7of8VEhkQ92cw2Jd0nPdP4FlyIVvqg3+zlD4tmov98SE JwBrLzeeBtbOXWl4yvmGYv/JtCjheUMKaUjOxdwH3Ci/RhVzWHeiK+mnga06pw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721504820; a=rsa-sha256; cv=none; b=WCbLExc53+diSmcLkMrMOUahUBpYTKnIpfyXUgJwpzU2p9eOBokICkj/aR9ES7pVEpSnKm vcq4nwE6QAKsuWbQSd3R9FMYAujrU2nscaTxZuo6dswnd5wHrBGCVdgTWy9iusvop2F4Rf ZRuCGI3A/WUwSBklh6pBvArhNZC083km0CEDifPrbMg+CUfMRFynEjuN6ydUEEbsSEvYeh 6syzDpsYWtXg6DdweeEUOdzUNYfn4rgy5FAMgUA9xEkxxxgopoYopsaap/l4pfzOYtjwxX j+MPTeaOkEznAtQv7Ca/qTWofaBa8PkLARXFL3ByDnB9mL9QYByfkIeMDcdo7w== 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=1721504820; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=GiIKlBXLSjBYjbMgCqUj0p6nRgLHY4NcrivGUw1DFoI=; b=kbIZghc2rLJjesONGsevF98waYgSvRjXnf4Oph3xlXQ0CHlZ2rZW99BklH3KidbhgRtKTn wG1jNtYHlK33BehOXPPs/Ex31ugopyCBdzHyjrmmnbsrDv7zRH05WQiBlV16aetduSJtmC YVS+c0olFSU3xuY8zqmkTMYhidJcXU9mFxvVxyGrMrCch6z/JhR4P0RfXc9Xn9fz+DWKlX bg6GYyZQteaXzZD2cONvpWXeLr1NjuPAxlBJsJ/Ls+YqRsEacCP68zOnEqsMvpdHbir6be E3Kj50TI2d3UAYctt0Ifgy0fCSMdGC/jVi5pwL089aVU/HzALLDeHMq/BhfUgw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRH9w6Nw7zT6y; Sat, 20 Jul 2024 19:47:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46KJl0xx035190; Sat, 20 Jul 2024 19:47:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46KJksmC035161; Sat, 20 Jul 2024 19:46:54 GMT (envelope-from git) Date: Sat, 20 Jul 2024 19:46:54 GMT Message-Id: <202407201946.46KJksmC035161@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: "Simon J. Gerraty" Subject: git: 226192822cdd - main - Merge bmake-20240711 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: sjg X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 226192822cddc30cacecd55bccb48f39c653058c Auto-Submitted: auto-generated The branch main has been updated by sjg: URL: https://cgit.FreeBSD.org/src/commit/?id=226192822cddc30cacecd55bccb48f39c653058c commit 226192822cddc30cacecd55bccb48f39c653058c Merge: 90818083d795 84691af93185 Author: Simon J. Gerraty AuthorDate: 2024-07-20 19:43:11 +0000 Commit: Simon J. Gerraty CommitDate: 2024-07-20 19:45:48 +0000 Merge bmake-20240711 Merge commit '84691af93185c692058ba55fa81a04103f5bf71b' contrib/bmake/ChangeLog | 83 ++ contrib/bmake/FILES | 2 + contrib/bmake/VERSION | 2 +- contrib/bmake/arch.c | 10 +- contrib/bmake/bmake.1 | 7 +- contrib/bmake/bmake.cat1 | 73 +- contrib/bmake/compat.c | 28 +- contrib/bmake/cond.c | 8 +- contrib/bmake/config.h.in | 137 +- contrib/bmake/configure | 1338 +++++++++++--------- contrib/bmake/configure.in | 13 +- contrib/bmake/dir.c | 8 +- contrib/bmake/dir.h | 4 +- contrib/bmake/hash.c | 33 +- contrib/bmake/hash.h | 5 +- contrib/bmake/job.c | 18 +- contrib/bmake/job.h | 6 +- contrib/bmake/main.c | 127 +- contrib/bmake/make.1 | 7 +- contrib/bmake/make.h | 20 +- contrib/bmake/meta.c | 3 + contrib/bmake/mk/install-mk | 0 contrib/bmake/parse.c | 31 +- contrib/bmake/str.c | 12 +- contrib/bmake/str.h | 4 +- contrib/bmake/suff.c | 9 +- contrib/bmake/targ.c | 15 +- contrib/bmake/unit-tests/Makefile | 32 +- contrib/bmake/unit-tests/cmd-errors-jobs.exp | 6 +- contrib/bmake/unit-tests/cmd-errors-jobs.mk | 17 +- contrib/bmake/unit-tests/cmd-errors-lint.exp | 4 +- contrib/bmake/unit-tests/cmd-errors-lint.mk | 23 +- contrib/bmake/unit-tests/cmd-errors.exp | 6 +- contrib/bmake/unit-tests/cmd-errors.mk | 21 +- contrib/bmake/unit-tests/compat-error.exp | 2 +- contrib/bmake/unit-tests/cond-cmp-numeric.exp | 2 +- contrib/bmake/unit-tests/cond-func-defined.exp | 2 +- contrib/bmake/unit-tests/cond-func.exp | 12 +- contrib/bmake/unit-tests/cond-func.mk | 13 +- contrib/bmake/unit-tests/cond-late.exp | 5 +- contrib/bmake/unit-tests/cond-late.mk | 14 +- contrib/bmake/unit-tests/cond-op-and.exp | 12 +- contrib/bmake/unit-tests/cond-op-and.mk | 27 +- contrib/bmake/unit-tests/cond-op-not.exp | 2 +- contrib/bmake/unit-tests/cond-op-or.exp | 12 +- contrib/bmake/unit-tests/cond-op-or.mk | 53 +- contrib/bmake/unit-tests/cond-op-parentheses.exp | 2 +- contrib/bmake/unit-tests/cond-op.exp | 2 +- contrib/bmake/unit-tests/cond-short.exp | 2 +- contrib/bmake/unit-tests/cond-token-number.exp | 2 +- contrib/bmake/unit-tests/cond-token-string.exp | 4 +- contrib/bmake/unit-tests/cond-token-string.mk | 4 +- contrib/bmake/unit-tests/dep-op-missing.exp | 1 + contrib/bmake/unit-tests/dep-percent.exp | 2 +- contrib/bmake/unit-tests/dep-var.exp | 2 +- contrib/bmake/unit-tests/dep.exp | 2 +- contrib/bmake/unit-tests/depsrc-ignore.exp | 2 +- .../unit-tests/deptgt-begin-fail-indirect.exp | 2 +- contrib/bmake/unit-tests/deptgt-begin-fail.exp | 2 +- .../bmake/unit-tests/deptgt-delete_on_error.exp | 14 +- contrib/bmake/unit-tests/deptgt-end-fail-all.exp | 2 +- .../bmake/unit-tests/deptgt-end-fail-indirect.exp | 2 +- contrib/bmake/unit-tests/deptgt-end-fail.exp | 30 +- contrib/bmake/unit-tests/deptgt-error.exp | 2 +- contrib/bmake/unit-tests/deptgt-ignore.exp | 2 +- contrib/bmake/unit-tests/deptgt-path-suffix.exp | 2 +- contrib/bmake/unit-tests/deptgt.exp | 5 +- contrib/bmake/unit-tests/deptgt.mk | 21 +- contrib/bmake/unit-tests/directive-dinclude.exp | 3 +- contrib/bmake/unit-tests/directive-elif.exp | 2 +- contrib/bmake/unit-tests/directive-else.exp | 2 +- .../bmake/unit-tests/directive-export-gmake.exp | 1 + contrib/bmake/unit-tests/directive-for-break.exp | 1 + contrib/bmake/unit-tests/directive-for-errors.exp | 16 +- contrib/bmake/unit-tests/directive-for-errors.mk | 18 +- contrib/bmake/unit-tests/directive-for-escape.exp | 114 +- contrib/bmake/unit-tests/directive-for-escape.mk | 96 +- .../unit-tests/directive-for-generating-endif.exp | 5 +- contrib/bmake/unit-tests/directive-for-if.exp | 5 +- contrib/bmake/unit-tests/directive-for-null.exp | 3 +- contrib/bmake/unit-tests/directive-for.exp | 42 +- contrib/bmake/unit-tests/directive-for.mk | 42 +- .../bmake/unit-tests/directive-hyphen-include.exp | 3 +- contrib/bmake/unit-tests/directive-ifmake.exp | 2 +- .../bmake/unit-tests/directive-include-fatal.exp | 2 +- contrib/bmake/unit-tests/directive-include.exp | 4 +- contrib/bmake/unit-tests/directive-include.mk | 4 +- contrib/bmake/unit-tests/directive-info.exp | 2 +- contrib/bmake/unit-tests/directive-sinclude.exp | 3 +- contrib/bmake/unit-tests/directive-undef.exp | 4 +- contrib/bmake/unit-tests/directive-undef.mk | 4 +- .../bmake/unit-tests/directive-unexport-env.exp | 2 +- contrib/bmake/unit-tests/directive-warning.exp | 2 +- contrib/bmake/unit-tests/directive.exp | 2 +- contrib/bmake/unit-tests/doterror.exp | 2 +- .../bmake/unit-tests/jobs-empty-commands-error.exp | 2 +- contrib/bmake/unit-tests/jobs-error-indirect.exp | 4 +- .../bmake/unit-tests/jobs-error-nested-make.exp | 6 +- contrib/bmake/unit-tests/jobs-error-nested.exp | 8 +- contrib/bmake/unit-tests/lint.exp | 2 +- contrib/bmake/unit-tests/moderrs.exp | 110 +- contrib/bmake/unit-tests/moderrs.mk | 78 +- contrib/bmake/unit-tests/opt-debug-errors-jobs.exp | 12 +- contrib/bmake/unit-tests/opt-debug-errors.exp | 2 +- contrib/bmake/unit-tests/opt-debug-file.exp | 8 +- contrib/bmake/unit-tests/opt-debug-file.mk | 15 +- contrib/bmake/unit-tests/opt-debug-graph2.exp | 2 +- contrib/bmake/unit-tests/opt-debug-graph3.exp | 2 +- contrib/bmake/unit-tests/opt-debug-hash.exp | 4 +- contrib/bmake/unit-tests/opt-debug-lint.exp | 6 +- contrib/bmake/unit-tests/opt-debug-lint.mk | 8 +- contrib/bmake/unit-tests/opt-file.exp | 3 +- .../bmake/unit-tests/opt-keep-going-indirect.exp | 8 +- .../bmake/unit-tests/opt-keep-going-multiple.exp | 2 +- contrib/bmake/unit-tests/opt-keep-going.exp | 2 +- .../bmake/unit-tests/opt-warnings-as-errors.exp | 2 +- contrib/bmake/unit-tests/opt.exp | 2 +- contrib/bmake/unit-tests/parse.exp | 2 +- contrib/bmake/unit-tests/posix.exp | 2 +- contrib/bmake/unit-tests/sh-jobs.exp | 2 +- contrib/bmake/unit-tests/suff-add-later.exp | 2 +- contrib/bmake/unit-tests/suff-clear-regular.exp | 2 +- contrib/bmake/unit-tests/suff-clear-single.exp | 2 +- contrib/bmake/unit-tests/suff-main-several.exp | 2 +- contrib/bmake/unit-tests/suff-self.exp | 2 +- .../bmake/unit-tests/suff-transform-endless.exp | 2 +- contrib/bmake/unit-tests/suff-transform-expand.exp | 2 +- contrib/bmake/unit-tests/suff-transform-select.exp | 2 +- contrib/bmake/unit-tests/suff-use.exp | 2 +- contrib/bmake/unit-tests/use-inference.exp | 2 +- contrib/bmake/unit-tests/var-eval-short.exp | 4 +- contrib/bmake/unit-tests/var-eval-short.mk | 4 +- contrib/bmake/unit-tests/var-op-assign.exp | 2 +- contrib/bmake/unit-tests/var-op-expand.exp | 6 +- contrib/bmake/unit-tests/var-op-expand.mk | 6 +- contrib/bmake/unit-tests/var-op-shell.exp | 6 +- contrib/bmake/unit-tests/var-op-shell.mk | 16 +- contrib/bmake/unit-tests/var-recursive.exp | 5 +- contrib/bmake/unit-tests/vardebug.exp | 2 +- contrib/bmake/unit-tests/vardebug.mk | 4 +- contrib/bmake/unit-tests/varmisc.exp | 8 +- contrib/bmake/unit-tests/varmisc.mk | 13 +- contrib/bmake/unit-tests/varmod-assign-shell.exp | 12 +- contrib/bmake/unit-tests/varmod-assign-shell.mk | 18 +- contrib/bmake/unit-tests/varmod-assign.exp | 12 +- contrib/bmake/unit-tests/varmod-assign.mk | 7 +- contrib/bmake/unit-tests/varmod-edge.exp | 33 +- contrib/bmake/unit-tests/varmod-edge.mk | 231 ++-- contrib/bmake/unit-tests/varmod-gmtime.exp | 12 +- contrib/bmake/unit-tests/varmod-gmtime.mk | 12 +- contrib/bmake/unit-tests/varmod-hash.exp | 8 +- contrib/bmake/unit-tests/varmod-ifelse.exp | 52 +- contrib/bmake/unit-tests/varmod-ifelse.mk | 22 +- contrib/bmake/unit-tests/varmod-indirect.exp | 8 +- contrib/bmake/unit-tests/varmod-indirect.mk | 10 +- contrib/bmake/unit-tests/varmod-localtime.exp | 12 +- contrib/bmake/unit-tests/varmod-localtime.mk | 12 +- contrib/bmake/unit-tests/varmod-loop-delete.exp | 4 +- contrib/bmake/unit-tests/varmod-loop-delete.mk | 4 +- contrib/bmake/unit-tests/varmod-loop-varname.exp | 10 +- contrib/bmake/unit-tests/varmod-loop-varname.mk | 10 +- contrib/bmake/unit-tests/varmod-match-escape.exp | 10 +- contrib/bmake/unit-tests/varmod-match-escape.mk | 8 +- contrib/bmake/unit-tests/varmod-match.exp | 20 +- contrib/bmake/unit-tests/varmod-match.mk | 22 +- contrib/bmake/unit-tests/varmod-mtime.exp | 12 +- contrib/bmake/unit-tests/varmod-mtime.mk | 14 +- contrib/bmake/unit-tests/varmod-order.exp | 48 +- contrib/bmake/unit-tests/varmod-order.mk | 32 +- contrib/bmake/unit-tests/varmod-range.exp | 12 +- contrib/bmake/unit-tests/varmod-range.mk | 12 +- contrib/bmake/unit-tests/varmod-select-words.exp | 26 +- contrib/bmake/unit-tests/varmod-shell.exp | 14 +- contrib/bmake/unit-tests/varmod-shell.mk | 14 +- contrib/bmake/unit-tests/varmod-subst-regex.exp | 30 +- contrib/bmake/unit-tests/varmod-subst.exp | 4 +- contrib/bmake/unit-tests/varmod-sun-shell.exp | 16 +- contrib/bmake/unit-tests/varmod-sun-shell.mk | 14 +- contrib/bmake/unit-tests/varmod-sysv.exp | 10 +- contrib/bmake/unit-tests/varmod-sysv.mk | 10 +- contrib/bmake/unit-tests/varmod-to-separator.exp | 44 +- contrib/bmake/unit-tests/varmod-to-separator.mk | 23 +- contrib/bmake/unit-tests/varmod-to-title.exp | 1 + contrib/bmake/unit-tests/varmod-to-title.mk | 31 + contrib/bmake/unit-tests/varmod.exp | 54 +- contrib/bmake/unit-tests/varmod.mk | 38 +- contrib/bmake/unit-tests/varname-dot-newline.exp | 5 +- .../varname-make_print_var_on_error-jobs.exp | 2 +- .../unit-tests/varname-make_print_var_on_error.exp | 2 +- contrib/bmake/unit-tests/varname.exp | 2 +- contrib/bmake/unit-tests/varparse-errors.exp | 44 +- contrib/bmake/unit-tests/varparse-errors.mk | 26 +- contrib/bmake/util.c | 6 +- contrib/bmake/var.c | 165 +-- usr.bin/bmake/Makefile.config | 2 +- usr.bin/bmake/config.h | 141 ++- usr.bin/bmake/unit-tests/Makefile | 32 +- 197 files changed, 2564 insertions(+), 2024 deletions(-) diff --cc contrib/bmake/mk/install-mk index bb150e3041a3,bb150e3041a3..bb150e3041a3 mode 100644,100755..100755 --- a/contrib/bmake/mk/install-mk +++ b/contrib/bmake/mk/install-mk diff --cc contrib/bmake/unit-tests/varmod-to-title.exp index 000000000000,39a9383953dd..39a9383953dd mode 000000,100644..100644 --- a/contrib/bmake/unit-tests/varmod-to-title.exp +++ b/contrib/bmake/unit-tests/varmod-to-title.exp diff --cc contrib/bmake/unit-tests/varmod-to-title.mk index 000000000000,f99e5441a8fb..f99e5441a8fb mode 000000,100644..100644 --- a/contrib/bmake/unit-tests/varmod-to-title.mk +++ b/contrib/bmake/unit-tests/varmod-to-title.mk diff --cc usr.bin/bmake/Makefile.config index 1d9a6a2880ea,000000000000..75ceb4a50e15 mode 100644,000000..100644 --- a/usr.bin/bmake/Makefile.config +++ b/usr.bin/bmake/Makefile.config @@@ -1,28 -1,0 +1,28 @@@ +# This is a generated file, do NOT edit! +# See contrib/bmake/bsd.after-import.mk +# + +SRCTOP?= ${.CURDIR:H:H} + +# things set by configure + - _MAKE_VERSION?=20240625 ++_MAKE_VERSION?=20240711 + +prefix?= /usr +srcdir= ${SRCTOP}/contrib/bmake +CC?= cc +MAKE_OS?= +DEFAULT_SYS_PATH?= .../share/mk:/usr/share/mk + +EGREP = egrep +CPPFLAGS+= +CFLAGS+= ${CPPFLAGS} -DHAVE_CONFIG_H +LDFLAGS+= +LIBOBJS+= ${LIBOBJDIR}stresep$U.o +LDADD+= +USE_META?= yes +USE_FILEMON?= dev +FILEMON_H?= /usr/include/dev/filemon/filemon.h +BMAKE_PATH_MAX?= 1024 +# used if MAXPATHLEN not defined +CPPFLAGS+= -DBMAKE_PATH_MAX=${BMAKE_PATH_MAX} diff --cc usr.bin/bmake/config.h index 3ca313216962,000000000000..33aed8f160c8 mode 100644,000000..100644 --- a/usr.bin/bmake/config.h +++ b/usr.bin/bmake/config.h @@@ -1,448 -1,0 +1,449 @@@ +/* config.h. Generated from config.h.in by configure. */ +/* config.h.in. Generated from configure.in by autoheader. */ + +/* Define if building universal (internal helper macro) */ +/* #undef AC_APPLE_UNIVERSAL_BUILD */ + +/* Path of default shell */ +/* #undef DEFSHELL_CUSTOM */ + +/* Shell spec to use by default */ +/* #undef DEFSHELL_INDEX */ + +/* Path of default shell */ +/* #undef DEFSHELL_PATH */ + +/* Define to 1 if you have the header file. */ +#define HAVE_AR_H 1 + - /* Define to 1 if you have the declaration of `sys_siglist', and to 0 if you ++/* Define to 1 if you have the declaration of 'sys_siglist', and to 0 if you + don't. */ +#define HAVE_DECL_SYS_SIGLIST 1 + - /* Define to 1 if you have the header file, and it defines `DIR'. ++/* Define to 1 if you have the header file, and it defines 'DIR'. + */ +#define HAVE_DIRENT_H 1 + - /* Define to 1 if you have the `dirname' function. */ ++/* Define to 1 if you have the 'dirname' function. */ +#define HAVE_DIRNAME 1 + - /* Define to 1 if you don't have `vprintf' but do have `_doprnt.' */ ++/* Define to 1 if you don't have 'vprintf' but do have '_doprnt.' */ +/* #undef HAVE_DOPRNT */ + - /* Define to 1 if you have the `err' function. */ ++/* Define to 1 if you have the 'err' function. */ +#define HAVE_ERR 1 + - /* Define to 1 if you have the `errx' function. */ ++/* Define to 1 if you have the 'errx' function. */ +#define HAVE_ERRX 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_ERR_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_FCNTL_H 1 + - /* Define to 1 if you have the `fork' function. */ ++/* Define to 1 if you have the 'fork' function. */ +#define HAVE_FORK 1 + - /* Define to 1 if you have the `getcwd' function. */ ++/* Define to 1 if you have the 'getcwd' function. */ +#define HAVE_GETCWD 1 + - /* Define to 1 if you have the `getenv' function. */ ++/* Define to 1 if you have the 'getenv' function. */ +#define HAVE_GETENV 1 + - /* Define to 1 if you have the `getopt' function. */ ++/* Define to 1 if you have the 'getopt' function. */ +#define HAVE_GETOPT 1 + - /* Define to 1 if you have the `getwd' function. */ ++/* Define to 1 if you have the 'getwd' function. */ +#define HAVE_GETWD 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_INTTYPES_H 1 + - /* Define to 1 if you have the `killpg' function. */ ++/* Define to 1 if you have the 'killpg' function. */ +#define HAVE_KILLPG 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_LIBGEN_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_LIMITS_H 1 + - /* Define to 1 if the system has the type `long long int'. */ ++/* Define to 1 if the system has the type 'long long int'. */ +#define HAVE_LONG_LONG_INT 1 + +/* Define to 1 if you have the header file. */ +/* #undef HAVE_MINIX_CONFIG_H */ + - /* Define to 1 if you have the `mmap' function. */ - #define HAVE_MMAP 1 - - /* Define to 1 if you have the header file, and it defines `DIR'. */ ++/* Define to 1 if you have the header file, and it defines 'DIR'. */ +/* #undef HAVE_NDIR_H */ + +/* Define to 1 if you have the header file. */ +#define HAVE_PATHS_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_POLL_H 1 + - /* Define to 1 if you have the `putenv' function. */ ++/* Define to 1 if you have the 'putenv' function. */ +#define HAVE_PUTENV 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_RANLIB_H 1 + - /* Define to 1 if you have the `realpath' function. */ ++/* Define to 1 if you have the 'realpath' function. */ +#define HAVE_REALPATH 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_REGEX_H 1 + - /* Define to 1 if you have the `select' function. */ ++/* Define to 1 if you have the 'select' function. */ +#define HAVE_SELECT 1 + - /* Define to 1 if you have the `setenv' function. */ ++/* Define to 1 if you have the 'setenv' function. */ +#define HAVE_SETENV 1 + - /* Define to 1 if you have the `setpgid' function. */ ++/* Define to 1 if you have the 'setpgid' function. */ +#define HAVE_SETPGID 1 + - /* Define to 1 if you have the `setrlimit' function. */ ++/* Define to 1 if you have the 'setrlimit' function. */ +#define HAVE_SETRLIMIT 1 + - /* Define to 1 if you have the `setsid' function. */ ++/* Define to 1 if you have the 'setsid' function. */ +#define HAVE_SETSID 1 + - /* Define to 1 if you have the `sigaction' function. */ ++/* Define to 1 if you have the 'sigaction' function. */ +#define HAVE_SIGACTION 1 + - /* Define to 1 if you have the `sigaddset' function. */ ++/* Define to 1 if you have the 'sigaddset' function. */ +#define HAVE_SIGADDSET 1 + - /* Define to 1 if you have the `sigpending' function. */ ++/* Define to 1 if you have the 'sigpending' function. */ +#define HAVE_SIGPENDING 1 + - /* Define to 1 if you have the `sigprocmask' function. */ ++/* Define to 1 if you have the 'sigprocmask' function. */ +#define HAVE_SIGPROCMASK 1 + - /* Define to 1 if you have the `sigsetmask' function. */ ++/* Define to 1 if you have the 'sigsetmask' function. */ +#define HAVE_SIGSETMASK 1 + - /* Define to 1 if you have the `sigsuspend' function. */ ++/* Define to 1 if you have the 'sigsuspend' function. */ +#define HAVE_SIGSUSPEND 1 + - /* Define to 1 if you have the `sigvec' function. */ ++/* Define to 1 if you have the 'sigvec' function. */ +#define HAVE_SIGVEC 1 + - /* Define to 1 if the system has the type `sig_atomic_t'. */ ++/* Define to 1 if the system has the type 'sig_atomic_t'. */ +#define HAVE_SIG_ATOMIC_T 1 + - /* Define to 1 if you have the `snprintf' function. */ ++/* Define to 1 if you have the 'snprintf' function. */ +#define HAVE_SNPRINTF 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_STDINT_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_STDIO_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_STDLIB_H 1 + - /* Define to 1 if you have the `strerror' function. */ ++/* Define to 1 if you have the 'strerror' function. */ +#define HAVE_STRERROR 1 + - /* Define to 1 if you have the `stresep' function. */ ++/* Define to 1 if you have the 'stresep' function. */ +/* #undef HAVE_STRESEP */ + - /* Define to 1 if you have the `strftime' function. */ ++/* Define to 1 if you have the 'strftime' function. */ +#define HAVE_STRFTIME 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 `strlcpy' function. */ ++/* Define to 1 if you have the 'strlcpy' function. */ +#define HAVE_STRLCPY 1 + - /* Define to 1 if you have the `strsep' function. */ ++/* Define to 1 if you have the 'strsep' function. */ +#define HAVE_STRSEP 1 + - /* Define to 1 if you have the `strtod' function. */ ++/* Define to 1 if you have the 'strtod' function. */ +#define HAVE_STRTOD 1 + - /* Define to 1 if you have the `strtol' function. */ ++/* Define to 1 if you have the 'strtol' function. */ +#define HAVE_STRTOL 1 + - /* Define to 1 if you have the `strtoll' function. */ ++/* Define to 1 if you have the 'strtoll' function. */ +#define HAVE_STRTOLL 1 + - /* Define to 1 if you have the `strtoul' function. */ ++/* Define to 1 if you have the 'strtoul' function. */ +#define HAVE_STRTOUL 1 + - /* Define to 1 if you have the `sysctl' function. */ ++/* Define to 1 if you have the 'sysctl' function. */ +#define HAVE_SYSCTL 1 + - /* Define to 1 if you have the header file, and it defines `DIR'. ++/* Define to 1 if you have the header file, and it defines 'DIR'. + */ +/* #undef HAVE_SYS_DIR_H */ + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_MMAN_H 1 + - /* Define to 1 if you have the header file, and it defines `DIR'. ++/* Define to 1 if you have the header file, and it defines 'DIR'. + */ +/* #undef HAVE_SYS_NDIR_H */ + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_PARAM_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_SELECT_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_SOCKET_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_STAT_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_SYSCTL_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_TIME_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_TYPES_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_UIO_H 1 + +/* Define to 1 if you have that is POSIX.1 compatible. */ +#define HAVE_SYS_WAIT_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_UNISTD_H 1 + - /* Define to 1 if you have the `unsetenv' function. */ ++/* Define to 1 if you have the 'unsetenv' function. */ +#define HAVE_UNSETENV 1 + - /* Define to 1 if the system has the type `unsigned long long int'. */ ++/* Define to 1 if the system has the type 'unsigned long long int'. */ +#define HAVE_UNSIGNED_LONG_LONG_INT 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_UTIME_H 1 + - /* Define to 1 if you have the `vfork' function. */ ++/* Define to 1 if you have the 'vfork' function. */ +#define HAVE_VFORK 1 + +/* Define to 1 if you have the header file. */ +/* #undef HAVE_VFORK_H */ + - /* Define to 1 if you have the `vprintf' function. */ ++/* Define to 1 if you have the 'vprintf' function. */ +#define HAVE_VPRINTF 1 + - /* Define to 1 if you have the `vsnprintf' function. */ ++/* Define to 1 if you have the 'vsnprintf' function. */ +#define HAVE_VSNPRINTF 1 + - /* Define to 1 if you have the `wait3' function. */ ++/* Define to 1 if you have the 'wait3' function. */ +#define HAVE_WAIT3 1 + - /* Define to 1 if you have the `wait4' function. */ ++/* Define to 1 if you have the 'wait4' function. */ +#define HAVE_WAIT4 1 + - /* Define to 1 if you have the `waitpid' function. */ ++/* Define to 1 if you have the 'waitpid' function. */ +#define HAVE_WAITPID 1 + - /* Define to 1 if you have the `warn' function. */ ++/* Define to 1 if you have the 'warn' function. */ +#define HAVE_WARN 1 + - /* Define to 1 if you have the `warnx' function. */ ++/* Define to 1 if you have the 'warnx' function. */ +#define HAVE_WARNX 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_WCHAR_H 1 + - /* Define to 1 if `fork' works. */ ++/* Define to 1 if 'fork' works. */ +#define HAVE_WORKING_FORK 1 + - /* Define to 1 if `vfork' works. */ ++/* Define to 1 if 'vfork' works. */ +#define HAVE_WORKING_VFORK 1 + +/* define if your compiler has __attribute__ */ +#define HAVE___ATTRIBUTE__ 1 + +/* Define to the address where bug reports for this package should be sent. */ +#define PACKAGE_BUGREPORT "sjg@NetBSD.org" + +/* Define to the full name of this package. */ +#define PACKAGE_NAME "bmake" + +/* Define to the full name and version of this package. */ - #define PACKAGE_STRING "bmake 20240314" ++#define PACKAGE_STRING "bmake 20240711" + +/* Define to the one symbol short name of this package. */ +#define PACKAGE_TARNAME "bmake" + +/* Define to the home page for this package. */ +#define PACKAGE_URL "" + +/* Define to the version of this package. */ - #define PACKAGE_VERSION "20240314" ++#define PACKAGE_VERSION "20240711" + - /* Define to 1 if the `S_IS*' macros in do not work properly. */ ++/* Define to 1 if the 'S_IS*' macros in do not work properly. */ +/* #undef STAT_MACROS_BROKEN */ + - /* Define to 1 if all of the C90 standard headers exist (not just the ones ++/* Define to 1 if all of the C89 standard headers exist (not just the ones + required in a freestanding environment). This macro is provided for + backward compatibility; new code need not use it. */ +#define STDC_HEADERS 1 + - /* Define to 1 if your declares `struct tm'. */ ++/* Define to 1 if your declares 'struct tm'. */ +/* #undef TM_IN_SYS_TIME */ + - /* Enable extensions on AIX 3, Interix. */ ++/* Enable extensions on AIX, Interix, z/OS. */ +#ifndef _ALL_SOURCE +# define _ALL_SOURCE 1 +#endif +/* Enable general extensions on macOS. */ +#ifndef _DARWIN_C_SOURCE +# define _DARWIN_C_SOURCE 1 +#endif +/* Enable general extensions on Solaris. */ +#ifndef __EXTENSIONS__ +# define __EXTENSIONS__ 1 +#endif +/* Enable GNU extensions on systems that have them. */ +#ifndef _GNU_SOURCE +# define _GNU_SOURCE 1 +#endif +/* Enable X/Open compliant socket functions that do not require linking + with -lxnet on HP-UX 11.11. */ +#ifndef _HPUX_ALT_XOPEN_SOCKET_API +# define _HPUX_ALT_XOPEN_SOCKET_API 1 +#endif +/* Identify the host operating system as Minix. + This macro does not affect the system headers' behavior. + A future release of Autoconf may stop defining this macro. */ +#ifndef _MINIX +/* # undef _MINIX */ +#endif +/* Enable general extensions on NetBSD. + Enable NetBSD compatibility extensions on Minix. */ +#ifndef _NETBSD_SOURCE +# define _NETBSD_SOURCE 1 +#endif +/* Enable OpenBSD compatibility extensions on NetBSD. + Oddly enough, this does nothing on OpenBSD. */ +#ifndef _OPENBSD_SOURCE +# define _OPENBSD_SOURCE 1 +#endif +/* Define to 1 if needed for POSIX-compatible behavior. */ +#ifndef _POSIX_SOURCE +/* # undef _POSIX_SOURCE */ +#endif +/* Define to 2 if needed for POSIX-compatible behavior. */ +#ifndef _POSIX_1_SOURCE +/* # undef _POSIX_1_SOURCE */ +#endif +/* Enable POSIX-compatible threading on Solaris. */ +#ifndef _POSIX_PTHREAD_SEMANTICS +# define _POSIX_PTHREAD_SEMANTICS 1 +#endif +/* Enable extensions specified by ISO/IEC TS 18661-5:2014. */ +#ifndef __STDC_WANT_IEC_60559_ATTRIBS_EXT__ +# define __STDC_WANT_IEC_60559_ATTRIBS_EXT__ 1 +#endif +/* Enable extensions specified by ISO/IEC TS 18661-1:2014. */ +#ifndef __STDC_WANT_IEC_60559_BFP_EXT__ +# define __STDC_WANT_IEC_60559_BFP_EXT__ 1 +#endif +/* Enable extensions specified by ISO/IEC TS 18661-2:2015. */ +#ifndef __STDC_WANT_IEC_60559_DFP_EXT__ +# define __STDC_WANT_IEC_60559_DFP_EXT__ 1 +#endif ++/* Enable extensions specified by C23 Annex F. */ ++#ifndef __STDC_WANT_IEC_60559_EXT__ ++# define __STDC_WANT_IEC_60559_EXT__ 1 ++#endif +/* Enable extensions specified by ISO/IEC TS 18661-4:2015. */ +#ifndef __STDC_WANT_IEC_60559_FUNCS_EXT__ +# define __STDC_WANT_IEC_60559_FUNCS_EXT__ 1 +#endif - /* Enable extensions specified by ISO/IEC TS 18661-3:2015. */ ++/* Enable extensions specified by C23 Annex H and ISO/IEC TS 18661-3:2015. */ +#ifndef __STDC_WANT_IEC_60559_TYPES_EXT__ +# define __STDC_WANT_IEC_60559_TYPES_EXT__ 1 +#endif +/* Enable extensions specified by ISO/IEC TR 24731-2:2010. */ +#ifndef __STDC_WANT_LIB_EXT2__ +# define __STDC_WANT_LIB_EXT2__ 1 +#endif +/* Enable extensions specified by ISO/IEC 24747:2009. */ +#ifndef __STDC_WANT_MATH_SPEC_FUNCS__ +# define __STDC_WANT_MATH_SPEC_FUNCS__ 1 +#endif +/* Enable extensions on HP NonStop. */ +#ifndef _TANDEM_SOURCE +# define _TANDEM_SOURCE 1 +#endif +/* Enable X/Open extensions. Define to 500 only if necessary + to make mbstate_t available. */ +#ifndef _XOPEN_SOURCE +/* # undef _XOPEN_SOURCE */ +#endif + + +/* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most + significant byte first (like Motorola and SPARC, unlike Intel). */ +#if defined AC_APPLE_UNIVERSAL_BUILD +# if defined __BIG_ENDIAN__ +# define WORDS_BIGENDIAN 1 +# endif +#else +# ifndef WORDS_BIGENDIAN +/* # undef WORDS_BIGENDIAN */ +# endif +#endif + +/* Define for Solaris 2.5.1 so the uint32_t typedef from , + , or is not used. If the typedef were allowed, the + #define below would cause a syntax error. */ +/* #undef _UINT32_T */ + +/* C99 function name */ +/* #undef __func__ */ + - /* Define to empty if `const' does not conform to ANSI C. */ ++/* Define to empty if 'const' does not conform to ANSI C. */ +/* #undef const */ + - /* Define to `__inline__' or `__inline' if that's what the C compiler ++/* Define to '__inline__' or '__inline' if that's what the C compiler + calls it, or to nothing if 'inline' is not supported under any name. */ +#ifndef __cplusplus +/* #undef inline */ +#endif + +/* Define to the type of a signed integer type of width exactly 64 bits if + such a type exists and the standard includes do not define it. */ +/* #undef int64_t */ + - /* Define to `int' if does not define. */ ++/* Define to 'int' if does not define. */ +/* #undef mode_t */ + - /* Define to `long int' if does not define. */ ++/* Define to 'long int' if does not define. */ +/* #undef off_t */ + +/* Define as a signed integer type capable of holding a process identifier. */ +/* #undef pid_t */ + +/* type that signal handlers can safely frob */ +/* #undef sig_atomic_t */ + - /* Define to `unsigned int' if does not define. */ ++/* Define as 'unsigned int' if doesn't define. */ +/* #undef size_t */ + +/* Define to the type of an unsigned integer type of width exactly 32 bits if + such a type exists and the standard includes do not define it. */ +/* #undef uint32_t */ + - /* Define as `fork' if `vfork' does not work. */ ++/* Define as 'fork' if 'vfork' does not work. */ +/* #undef vfork */ diff --cc usr.bin/bmake/unit-tests/Makefile index 20e1b1cf94ee,000000000000..d70c0f87e459 mode 100644,000000..100644 --- a/usr.bin/bmake/unit-tests/Makefile +++ b/usr.bin/bmake/unit-tests/Makefile @@@ -1,893 -1,0 +1,911 @@@ +# This is a generated file, do NOT edit! +# See contrib/bmake/bsd.after-import.mk +# - # $Id: Makefile,v 1.219 2024/06/01 16:14:47 sjg Exp $ ++# $Id: Makefile,v 1.224 2024/07/13 05:27:35 sjg Exp $ +# - # $NetBSD: Makefile,v 1.347 2024/06/01 15:54:40 sjg Exp $ ++# $NetBSD: Makefile,v 1.350 2024/07/07 09:37:00 rillig Exp $ +# +# Unit tests for make(1) +# +# The main targets are: +# +# all: +# run all the tests +# test: +# run 'all', and compare to expected results +# accept: +# move generated output to expected results +# +# Settable variables +# +# TEST_MAKE +# The make program to be tested. +# +# +# Adding a test case +# +# Each feature should get its own set of tests in its own suitably +# named makefile (*.mk), with its own set of expected results (*.exp), +# and it should be added to the TESTS list. +# + +.MAIN: all + +# we use these below but we might be an older make +.MAKE.OS?= ${uname -s:L:sh} +.MAKE.UID?= ${id -u:L:sh} + +# for many tests we need a TMPDIR that will not collide +# with other users. +.if ${.OBJDIR} != ${.CURDIR} +# easy +TMPDIR:= ${.OBJDIR}/tmp +.elif defined(TMPDIR) +TMPDIR:= ${TMPDIR}/uid${.MAKE.UID} +.else +TMPDIR:= /tmp/uid${.MAKE.UID} +.endif +# make sure it exists +.if !exist(${TMPDIR}) +_!= mkdir -p ${TMPDIR} +.endif + +# Each test is in a sub-makefile. +# Keep the list sorted. +# Any test that is commented out must be ignored in +# src/tests/usr.bin/make/t_make.sh as well. +#TESTS+= archive +#TESTS+= archive-suffix +TESTS+= cmd-errors +TESTS+= cmd-errors-jobs +TESTS+= cmd-errors-lint +TESTS+= cmd-interrupt +TESTS+= cmdline +TESTS+= cmdline-redirect-stdin +TESTS+= cmdline-undefined +TESTS+= comment +TESTS+= compat-error +TESTS+= cond-cmp-numeric +TESTS+= cond-cmp-numeric-eq +TESTS+= cond-cmp-numeric-ge +TESTS+= cond-cmp-numeric-gt +TESTS+= cond-cmp-numeric-le +TESTS+= cond-cmp-numeric-lt +TESTS+= cond-cmp-numeric-ne +TESTS+= cond-cmp-string +TESTS+= cond-cmp-unary +TESTS+= cond-eof +TESTS+= cond-func +TESTS+= cond-func-commands +TESTS+= cond-func-defined +TESTS+= cond-func-empty +TESTS+= cond-func-exists +TESTS+= cond-func-make +TESTS+= cond-func-make-main +TESTS+= cond-func-target +TESTS+= cond-late +TESTS+= cond-op +TESTS+= cond-op-and +TESTS+= cond-op-and-lint +TESTS+= cond-op-not +TESTS+= cond-op-or +TESTS+= cond-op-or-lint +TESTS+= cond-op-parentheses +TESTS+= cond-short +TESTS+= cond-token-number +TESTS+= cond-token-plain +TESTS+= cond-token-string +TESTS+= cond-token-var +TESTS+= cond-undef-lint +TESTS+= counter +TESTS+= counter-append +TESTS+= dep +TESTS+= dep-colon +TESTS+= dep-colon-bug-cross-file +TESTS+= dep-double-colon +TESTS+= dep-double-colon-indep +TESTS+= dep-duplicate +TESTS+= dep-exclam +TESTS+= dep-none +TESTS+= dep-op-missing +TESTS+= dep-percent +TESTS+= dep-var +TESTS+= dep-wildcards +TESTS+= depsrc +TESTS+= depsrc-end +TESTS+= depsrc-exec +TESTS+= depsrc-ignore +TESTS+= depsrc-made +TESTS+= depsrc-make +TESTS+= depsrc-meta +TESTS+= depsrc-nometa +TESTS+= depsrc-nometa_cmp +TESTS+= depsrc-nopath +TESTS+= depsrc-notmain +TESTS+= depsrc-optional +TESTS+= depsrc-phony +TESTS+= depsrc-precious +TESTS+= depsrc-recursive +TESTS+= depsrc-silent +TESTS+= depsrc-use +TESTS+= depsrc-usebefore +TESTS+= depsrc-usebefore-double-colon +TESTS+= depsrc-wait +TESTS+= deptgt +TESTS+= deptgt-begin +TESTS+= deptgt-begin-fail +TESTS+= deptgt-begin-fail-indirect +TESTS+= deptgt-default +TESTS+= deptgt-delete_on_error +TESTS+= deptgt-end +TESTS+= deptgt-end-fail +TESTS+= deptgt-end-fail-all +TESTS+= deptgt-end-fail-indirect +TESTS+= deptgt-end-jobs +TESTS+= deptgt-error +TESTS+= deptgt-ignore +TESTS+= deptgt-interrupt +TESTS+= deptgt-main +TESTS+= deptgt-makeflags +TESTS+= deptgt-no_parallel +TESTS+= deptgt-nopath +TESTS+= deptgt-notparallel +TESTS+= deptgt-objdir +TESTS+= deptgt-order +TESTS+= deptgt-path +TESTS+= deptgt-path-suffix +TESTS+= deptgt-phony +TESTS+= deptgt-posix +TESTS+= deptgt-precious +TESTS+= deptgt-shell +TESTS+= deptgt-silent +TESTS+= deptgt-silent-jobs +TESTS+= deptgt-stale +TESTS+= deptgt-suffixes +TESTS+= dir +TESTS+= dir-expand-path +TESTS+= directive +TESTS+= directive-dinclude +TESTS+= directive-elif +TESTS+= directive-elifdef +TESTS+= directive-elifmake +TESTS+= directive-elifndef +TESTS+= directive-elifnmake +TESTS+= directive-else +TESTS+= directive-endfor +TESTS+= directive-endif +TESTS+= directive-error +TESTS+= directive-export +TESTS+= directive-export-env +TESTS+= directive-export-impl +TESTS+= directive-export-gmake +TESTS+= directive-export-literal +TESTS+= directive-for +TESTS+= directive-for-break +TESTS+= directive-for-empty +TESTS+= directive-for-errors +TESTS+= directive-for-escape +TESTS+= directive-for-generating-endif +TESTS+= directive-for-if +TESTS+= directive-for-lines *** 726 LINES SKIPPED *** From nobody Sat Jul 20 19:59:27 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRHSH5p1zz5N3w6; Sat, 20 Jul 2024 19:59: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRHSH46M1z4vTW; Sat, 20 Jul 2024 19:59:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721505567; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=h48uvjk67IQKYFTfsM2Rz4rH2rxxQNYbLdCIVe5E674=; b=Y6hVHEN7LYquJP5k6VLSHCm7og/t/wMg3M6RgXWQJn3UxjKZlhl9uzr9Zhw6Do19i9yOGN sC7NuznyWMjH5yzmQvuCGfTiklpQmtknsjmFU2Qqa9cSwoPwh2RLzYI63LVkFMhBUUc+ly NVTMiaSNi6QSNfga8v6F2LTzf8wr6hkcuzk0jvF9kLbfnlhOIn3U1IQGnoOvu7i0tzlExz 1lTLAGa4YkkZTd/N6QdxVCnz5/ZNEjkAj4Fo/seI1W1tubcNcOjMPTlLw5wFvJCBYpra3v iqcHTSZpBhvzlss+DxBX2jkIEzH2spp/I/jQp0vTCG96ivVErW6Pxo09s873kQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721505567; a=rsa-sha256; cv=none; b=xNrtLVNrxvj1zDTs7S2n4HRPHCF46qGbQRc+HZLrAdxQd0GjDSk8NvjbrUYR2AOPTR+jkt ssA4mDS+aoyZLGhel3ZmISLCKXX212KvpVZcDUoaQCnbzdqZmasNvbV6QYDJMosk6BZjeQ eFF/kX3tyRwfdzBLydAeEt3atJuPmavWafqSBGdbbf2ceEBGholEjrSLc+Sz7KchO/hFxY Hf9MM8Pj9QJchzZq1rUNpj3h8VORObqoikh9jM40Qkfd3DA8KPidZAFOc3NuLe4/JM2sTc sdKQlFNzmmVGkC+llWGiiL5+X7aXbnb8tZq5Nuc9MajaoJVZnGnGZy+crFNEhw== 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=1721505567; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=h48uvjk67IQKYFTfsM2Rz4rH2rxxQNYbLdCIVe5E674=; b=vRul/h+yb2W9kOzyX8jeHkD6XmKcQxc8PwKbpX+EoXUZ33FodEfxlYQhLaCZKTdLcjU1lz CwlGD5l1rgFj8eE8KEwxCsV55Ua+4+gD33H/8GZNUYsrdbbs/x1nixeU8OlpagLD1TJBJM RR7ItOwWGxGxzqzSZHy/tUM/ee2RtCAAHycgoJCVepvi3wJj9R3+nCgfcRO1VK7N6TRF7H nCAWr8dji51SeyuT/tNl++SPFEm3r+IFMxfNlGZ8Sbf29IWLYde84bfDjy2bLV/EPiQY2A fQd94yUs3nf8pFAyim4dj4Ykhzj0CeHhLmu/P1pbuR8QvSN1ctFSDjHA7h7wvA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRHSH3FXDzVkZ; Sat, 20 Jul 2024 19:59:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46KJxRJK052608; Sat, 20 Jul 2024 19:59:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46KJxRlN052605; Sat, 20 Jul 2024 19:59:27 GMT (envelope-from git) Date: Sat, 20 Jul 2024 19:59:27 GMT Message-Id: <202407201959.46KJxRlN052605@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: d3795c1d72f0 - main - cam/iosched: Use better malloc idiom List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: d3795c1d72f042c86efebdaa9ae790f64ef79f47 Auto-Submitted: auto-generated The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=d3795c1d72f042c86efebdaa9ae790f64ef79f47 commit d3795c1d72f042c86efebdaa9ae790f64ef79f47 Author: Warner Losh AuthorDate: 2024-07-20 19:58:04 +0000 Commit: Warner Losh CommitDate: 2024-07-20 19:59:18 +0000 cam/iosched: Use better malloc idiom Allocate to a simple poiter, use that everywhere, then return it at the end. The code looks cleaner. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D46043 --- sys/cam/cam_iosched.c | 46 ++++++++++++++++++++++++---------------------- 1 file changed, 24 insertions(+), 22 deletions(-) diff --git a/sys/cam/cam_iosched.c b/sys/cam/cam_iosched.c index 4f4a2b2cde55..15e98b7cb39d 100644 --- a/sys/cam/cam_iosched.c +++ b/sys/cam/cam_iosched.c @@ -1160,37 +1160,39 @@ int cam_iosched_init(struct cam_iosched_softc **iscp, struct cam_periph *periph, const struct disk *dp, cam_iosched_schedule_t schedfnc) { + struct cam_iosched_softc *isc; - *iscp = malloc(sizeof(**iscp), M_CAMSCHED, M_NOWAIT | M_ZERO); - if (*iscp == NULL) + isc = malloc(sizeof(*isc), M_CAMSCHED, M_NOWAIT | M_ZERO); + if (isc == NULL) return ENOMEM; - (*iscp)->disk = dp; - (*iscp)->schedfnc = schedfnc; + isc->disk = dp; + isc->schedfnc = schedfnc; #ifdef CAM_IOSCHED_DYNAMIC if (iosched_debug) - printf("CAM IOSCHEDULER Allocating entry at %p\n", *iscp); + printf("CAM IOSCHEDULER Allocating entry at %p\n", isc); #endif - (*iscp)->sort_io_queue = -1; - bioq_init(&(*iscp)->bio_queue); - bioq_init(&(*iscp)->trim_queue); + isc->sort_io_queue = -1; + bioq_init(&isc->bio_queue); + bioq_init(&isc->trim_queue); #ifdef CAM_IOSCHED_DYNAMIC if (do_dynamic_iosched) { - bioq_init(&(*iscp)->write_queue); - (*iscp)->read_bias = default_read_bias; - (*iscp)->current_read_bias = 0; - (*iscp)->quanta = min(hz, 200); - cam_iosched_iop_stats_init(*iscp, &(*iscp)->read_stats); - cam_iosched_iop_stats_init(*iscp, &(*iscp)->write_stats); - cam_iosched_iop_stats_init(*iscp, &(*iscp)->trim_stats); - (*iscp)->trim_stats.max = 1; /* Trims are special: one at a time for now */ - (*iscp)->last_time = sbinuptime(); - callout_init_mtx(&(*iscp)->ticker, cam_periph_mtx(periph), 0); - (*iscp)->periph = periph; - cam_iosched_cl_init(&(*iscp)->cl, *iscp); - callout_reset(&(*iscp)->ticker, hz / (*iscp)->quanta, cam_iosched_ticker, *iscp); - (*iscp)->flags |= CAM_IOSCHED_FLAG_CALLOUT_ACTIVE; + bioq_init(&isc->write_queue); + isc->read_bias = default_read_bias; + isc->current_read_bias = 0; + isc->quanta = min(hz, 200); + cam_iosched_iop_stats_init(isc, &isc->read_stats); + cam_iosched_iop_stats_init(isc, &isc->write_stats); + cam_iosched_iop_stats_init(isc, &isc->trim_stats); + isc->trim_stats.max = 1; /* Trims are special: one at a time for now */ + isc->last_time = sbinuptime(); + callout_init_mtx(&isc->ticker, cam_periph_mtx(periph), 0); + isc->periph = periph; + cam_iosched_cl_init(&isc->cl, isc); + callout_reset(&isc->ticker, hz / isc->quanta, cam_iosched_ticker, isc); + isc->flags |= CAM_IOSCHED_FLAG_CALLOUT_ACTIVE; } #endif + *iscp = isc; return 0; } From nobody Sun Jul 21 01:56:50 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRRNf3QM8z5QdP9; Sun, 21 Jul 2024 01:56: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRRNf30cqz4CYJ; Sun, 21 Jul 2024 01:56:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721527010; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=UCVWzjw1jZufK4xcdb67zeq85vE/X8jVPJuBjRdGuDc=; b=O6t/2t+Aoeq3EB2k+9ryFji3qoZX8isAQi984uBxbZK5RlvJWRaLHn5GOdZ9Q5+1Goat+l pBl+l+Y6lgcYh0Ayr2DqnYsrzfZ9Kwd8DPXBQQpif01CkSKfi2NcRaFyOCmGZ78uLYyyGu BncRserkI0vL6dMaoJAe2yUtMoAMz3P3MrGk9sydKUl0mO62VqevydxoLiJ2jGV+S5FMFF MfT9Dol8K3zd39DUwne418lnn94IIHEi9Yk/VxB2BGGKOgraEHIXCwlojbC/Y2OZzrLZDN bv9BKTePyvXjJKQ2glJ1ftrH3ckJECGRiU4tGvmxfuNs5r1/6O/kR+yo9S9ngw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721527010; a=rsa-sha256; cv=none; b=pXQfQIxTlpD+rHoN9hUJEPkdWu3I6Am4K1FR0+kCxM1Pxf8IzF3zXwvNFwxtJmS3V1vvXS ytVCO7UAvqnLstUMQjYdPIgE8uYRTdE2eOb1a3PMVQfiqU5HV/STJ+e6s2LDRUgJLms34T 7Ehcsd/OkST9ryplAEBHXM12aAmt4EOT7Zy7ri1Ze6l41xybX3Q52qLcnUzOLv7lpIRV/q DukbJHLFIfQs8wYHml2Jml2aaUC3j18hBdW7fgpg8sgvrqVn17783SUnFJLoFOLP2rrxcb a1uYKTqzepWUrkqnAD2hwBH2RpKEg/nAw+B5jGvLAXQajh5ycNeLP8YWQCsnOw== 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=1721527010; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=UCVWzjw1jZufK4xcdb67zeq85vE/X8jVPJuBjRdGuDc=; b=r8Y71TGLtNxJaElIh/G0ISapDm7NiP+2ev65brtk07O9c/wlVcNJL9SmyMFFRNj3wlwAN+ 4dULdo0vuLyRSrF6sg/LhEm9/bEUvUCcXTGovOy6fEa+bwTGTHiJCt912ljVZu7FIYiYTb 7zeH8dYiz/Jv7MShKuw0VnsTQ48bwuEu0NeiIS9obxlzC0Fryz+qnxyQLvZLDk2aDJqZO3 l+P9geQ05ZHTEn8yAlvxL48BUny1c8PojlRdYjMLz8wH93nRptci5GDWBuIVWC0dbrDF8J qzhWsLK83vpIKb08pyNf975cmPPBhAIjPqhjcJyqyN4aFCAHBVpqZ73C4V8Dtw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRRNf2bb9zgrN; Sun, 21 Jul 2024 01:56:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46L1uoNb059823; Sun, 21 Jul 2024 01:56:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46L1uos7059820; Sun, 21 Jul 2024 01:56:50 GMT (envelope-from git) Date: Sun, 21 Jul 2024 01:56:50 GMT Message-Id: <202407210156.46L1uos7059820@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Cy Schubert Subject: git: 04b4dcf04fc3 - main - leap-seconds: Update to leap-seconds 3960057600 obtained from IERS List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cy X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 04b4dcf04fc345b29b78e5061768091648b8ee2a Auto-Submitted: auto-generated The branch main has been updated by cy: URL: https://cgit.FreeBSD.org/src/commit/?id=04b4dcf04fc345b29b78e5061768091648b8ee2a commit 04b4dcf04fc345b29b78e5061768091648b8ee2a Author: Cy Schubert AuthorDate: 2024-07-21 01:41:09 +0000 Commit: Cy Schubert CommitDate: 2024-07-21 01:55:41 +0000 leap-seconds: Update to leap-seconds 3960057600 obtained from IERS IERS is the canonical source of leap-seconds. IANA, NIST and USNO obtain their leap-second updates from IERS. This resolves an issue for IPv6-only hosts as IERS is not accessible via IPv6, requiring IPv6-only host to rely on some other source, above. From this point forward we should fetch the file from IERS, the organization responsible for deciding when to insert leap-seconds. PR: 279413 Obtained from: https://hpiers.obspm.fr/iers/bul/bulc/ntp/leap-seconds.list Discussed with: imp MFC after: 1 day --- usr.sbin/ntp/ntpd/leap-seconds | 373 +++++++++++++---------------------------- 1 file changed, 119 insertions(+), 254 deletions(-) diff --git a/usr.sbin/ntp/ntpd/leap-seconds b/usr.sbin/ntp/ntpd/leap-seconds index c5a95aa51799..da0efc8c8566 100644 --- a/usr.sbin/ntp/ntpd/leap-seconds +++ b/usr.sbin/ntp/ntpd/leap-seconds @@ -1,255 +1,120 @@ +# ATOMIC TIME +# Coordinated Universal Time (UTC) is the reference time scale derived +# from The "Temps Atomique International" (TAI) calculated by the Bureau +# International des Poids et Mesures (BIPM) using a worldwide network of atomic +# clocks. UTC differs from TAI by an integer number of seconds; it is the basis +# of all activities in the world. # -# In the following text, the symbol '#' introduces -# a comment, which continues from that symbol until -# the end of the line. A plain comment line has a -# whitespace character following the comment indicator. -# There are also special comment lines defined below. -# A special comment will always have a non-whitespace -# character in column 2. -# -# A blank line should be ignored. -# -# The following table shows the corrections that must -# be applied to compute International Atomic Time (TAI) -# from the Coordinated Universal Time (UTC) values that -# are transmitted by almost all time services. -# -# The first column shows an epoch as a number of seconds -# since 1 January 1900, 00:00:00 (1900.0 is also used to -# indicate the same epoch.) Both of these time stamp formats -# ignore the complexities of the time scales that were -# used before the current definition of UTC at the start -# of 1972. (See note 3 below.) -# The second column shows the number of seconds that -# must be added to UTC to compute TAI for any timestamp -# at or after that epoch. The value on each line is -# valid from the indicated initial instant until the -# epoch given on the next one or indefinitely into the -# future if there is no next line. -# (The comment on each line shows the representation of -# the corresponding initial epoch in the usual -# day-month-year format. The epoch always begins at -# 00:00:00 UTC on the indicated day. See Note 5 below.) -# -# Important notes: -# -# 1. Coordinated Universal Time (UTC) is often referred to -# as Greenwich Mean Time (GMT). The GMT time scale is no -# longer used, and the use of GMT to designate UTC is -# discouraged. -# -# 2. The UTC time scale is realized by many national -# laboratories and timing centers. Each laboratory -# identifies its realization with its name: Thus -# UTC(NIST), UTC(USNO), etc. The differences among -# these different realizations are typically on the -# order of a few nanoseconds (i.e., 0.000 000 00x s) -# and can be ignored for many purposes. These differences -# are tabulated in Circular T, which is published monthly -# by the International Bureau of Weights and Measures -# (BIPM). See www.bipm.org for more information. -# -# 3. The current definition of the relationship between UTC -# and TAI dates from 1 January 1972. A number of different -# time scales were in use before that epoch, and it can be -# quite difficult to compute precise timestamps and time -# intervals in those "prehistoric" days. For more information, -# consult: -# -# The Explanatory Supplement to the Astronomical -# Ephemeris. -# or -# Terry Quinn, "The BIPM and the Accurate Measurement -# of Time," Proc. of the IEEE, Vol. 79, pp. 894-905, -# July, 1991. -# reprinted in: -# Christine Hackman and Donald B Sullivan (eds.) -# Time and Frequency Measurement -# American Association of Physics Teachers (1996) -# , pp. 75-86 -# -# 4. The decision to insert a leap second into UTC is currently -# the responsibility of the International Earth Rotation and -# Reference Systems Service. (The name was changed from the -# International Earth Rotation Service, but the acronym IERS -# is still used.) -# -# Leap seconds are announced by the IERS in its Bulletin C. -# -# See www.iers.org for more details. -# -# Every national laboratory and timing center uses the -# data from the BIPM and the IERS to construct UTC(lab), -# their local realization of UTC. -# -# Although the definition also includes the possibility -# of dropping seconds ("negative" leap seconds), this has -# never been done and is unlikely to be necessary in the -# foreseeable future. -# -# 5. If your system keeps time as the number of seconds since -# some epoch (e.g., NTP timestamps), then the algorithm for -# assigning a UTC time stamp to an event that happens during a positive -# leap second is not well defined. The official name of that leap -# second is 23:59:60, but there is no way of representing that time -# in these systems. -# Many systems of this type effectively stop the system clock for -# one second during the leap second and use a time that is equivalent -# to 23:59:59 UTC twice. For these systems, the corresponding TAI -# timestamp would be obtained by advancing to the next entry in the -# following table when the time equivalent to 23:59:59 UTC -# is used for the second time. Thus the leap second which -# occurred on 30 June 1972 at 23:59:59 UTC would have TAI -# timestamps computed as follows: -# -# ... -# 30 June 1972 23:59:59 (2287785599, first time): TAI= UTC + 10 seconds -# 30 June 1972 23:59:60 (2287785599,second time): TAI= UTC + 11 seconds -# 1 July 1972 00:00:00 (2287785600) TAI= UTC + 11 seconds -# ... -# -# If your system realizes the leap second by repeating 00:00:00 UTC twice -# (this is possible but not usual), then the advance to the next entry -# in the table must occur the second time that a time equivalent to -# 00:00:00 UTC is used. Thus, using the same example as above: -# -# ... -# 30 June 1972 23:59:59 (2287785599): TAI= UTC + 10 seconds -# 30 June 1972 23:59:60 (2287785600, first time): TAI= UTC + 10 seconds -# 1 July 1972 00:00:00 (2287785600,second time): TAI= UTC + 11 seconds -# ... -# -# in both cases the use of timestamps based on TAI produces a smooth -# time scale with no discontinuity in the time interval. However, -# although the long-term behavior of the time scale is correct in both -# methods, the second method is technically not correct because it adds -# the extra second to the wrong day. -# -# This complexity would not be needed for negative leap seconds (if they -# are ever used). The UTC time would skip 23:59:59 and advance from -# 23:59:58 to 00:00:00 in that case. The TAI offset would decrease by -# 1 second at the same instant. This is a much easier situation to deal -# with, since the difficulty of unambiguously representing the epoch -# during the leap second does not arise. -# -# Some systems implement leap seconds by amortizing the leap second -# over the last few minutes of the day. The frequency of the local -# clock is decreased (or increased) to realize the positive (or -# negative) leap second. This method removes the time step described -# above. Although the long-term behavior of the time scale is correct -# in this case, this method introduces an error during the adjustment -# period both in time and in frequency with respect to the official -# definition of UTC. -# -# Questions or comments to: -# Judah Levine -# Time and Frequency Division -# NIST -# Boulder, Colorado -# Judah.Levine@nist.gov -# -# Last Update of leap second values: 8 July 2016 -# -# The following line shows this last update date in NTP timestamp -# format. This is the date on which the most recent change to -# the leap second data was added to the file. This line can -# be identified by the unique pair of characters in the first two -# columns as shown below. -# -#$ 3676924800 -# -# The NTP timestamps are in units of seconds since the NTP epoch, -# which is 1 January 1900, 00:00:00. The Modified Julian Day number -# corresponding to the NTP time stamp, X, can be computed as -# -# X/86400 + 15020 -# -# where the first term converts seconds to days and the second -# term adds the MJD corresponding to the time origin defined above. -# The integer portion of the result is the integer MJD for that -# day, and any remainder is the time of day, expressed as the -# fraction of the day since 0 hours UTC. The conversion from day -# fraction to seconds or to hours, minutes, and seconds may involve -# rounding or truncation, depending on the method used in the -# computation. -# -# The data in this file will be updated periodically as new leap -# seconds are announced. In addition to being entered on the line -# above, the update time (in NTP format) will be added to the basic -# file name leap-seconds to form the name leap-seconds.. -# In addition, the generic name leap-seconds.list will always point to -# the most recent version of the file. -# -# This update procedure will be performed only when a new leap second -# is announced. -# -# The following entry specifies the expiration date of the data -# in this file in units of seconds since the origin at the instant -# 1 January 1900, 00:00:00. This expiration date will be changed -# at least twice per year whether or not a new leap second is -# announced. These semi-annual changes will be made no later -# than 1 June and 1 December of each year to indicate what -# action (if any) is to be taken on 30 June and 31 December, -# respectively. (These are the customary effective dates for new -# leap seconds.) This expiration date will be identified by a -# unique pair of characters in columns 1 and 2 as shown below. -# In the unlikely event that a leap second is announced with an -# effective date other than 30 June or 31 December, then this -# file will be edited to include that leap second as soon as it is -# announced or at least one month before the effective date -# (whichever is later). -# If an announcement by the IERS specifies that no leap second is -# scheduled, then only the expiration date of the file will -# be advanced to show that the information in the file is still -# current -- the update time stamp, the data and the name of the file -# will not change. -# -# Updated through IERS Bulletin C67 -# File expires on: 28 December 2024 -# -#@ 3944332800 -# -2272060800 10 # 1 Jan 1972 -2287785600 11 # 1 Jul 1972 -2303683200 12 # 1 Jan 1973 -2335219200 13 # 1 Jan 1974 -2366755200 14 # 1 Jan 1975 -2398291200 15 # 1 Jan 1976 -2429913600 16 # 1 Jan 1977 -2461449600 17 # 1 Jan 1978 -2492985600 18 # 1 Jan 1979 -2524521600 19 # 1 Jan 1980 -2571782400 20 # 1 Jul 1981 -2603318400 21 # 1 Jul 1982 -2634854400 22 # 1 Jul 1983 -2698012800 23 # 1 Jul 1985 -2776982400 24 # 1 Jan 1988 -2840140800 25 # 1 Jan 1990 -2871676800 26 # 1 Jan 1991 -2918937600 27 # 1 Jul 1992 -2950473600 28 # 1 Jul 1993 -2982009600 29 # 1 Jul 1994 -3029443200 30 # 1 Jan 1996 -3076704000 31 # 1 Jul 1997 -3124137600 32 # 1 Jan 1999 -3345062400 33 # 1 Jan 2006 -3439756800 34 # 1 Jan 2009 -3550089600 35 # 1 Jul 2012 -3644697600 36 # 1 Jul 2015 -3692217600 37 # 1 Jan 2017 -# -# the following special comment contains the -# hash value of the data in this file computed -# use the secure hash algorithm as specified -# by FIPS 180-1. See the files in ~/pub/sha for -# the details of how this hash value is -# computed. Note that the hash computation -# ignores comments and whitespace characters -# in data lines. It includes the NTP values -# of both the last modification time and the -# expiration time of the file, but not the -# white space on those lines. -# the hash line is also ignored in the -# computation. -# -#h 199a9d45 3f630d2f e47cb9cc c2f0fa47 96932227 +# +# ASTRONOMICAL TIME (UT1) is the time scale based on the rate of rotation of the earth. +# It is now mainly derived from Very Long Baseline Interferometry (VLBI). The various +# irregular fluctuations progressively detected in the rotation rate of the Earth led +# in 1972 to the replacement of UT1 by UTC as the reference time scale. +# +# +# LEAP SECOND +# Atomic clocks are more stable than the rate of the earth's rotation since the latter +# undergoes a full range of geophysical perturbations at various time scales: lunisolar +# and core-mantle torques, atmospheric and oceanic effects, etc. +# Leap seconds are needed to keep the two time scales in agreement, i.e. UT1-UTC smaller +# than 0.9 seconds. Therefore, when necessary a "leap second" is applied to UTC. +# Since the adoption of this system in 1972 it has been necessary to add a number of seconds to UTC, +# firstly due to the initial choice of the value of the second (1/86400 mean solar day of +# the year 1820) and secondly to the general slowing down of the Earth's rotation. It is +# theoretically possible to have a negative leap second (a second removed from UTC), but so far, +# all leap seconds have been positive (a second has been added to UTC). Based on what we know about +# the earth's rotation, it is unlikely that we will ever have a negative leap second. +# +# +# HISTORY +# The first leap second was added on June 30, 1972. Until the year 2000, it was necessary in average to add a +# leap second at a rate of 1 to 2 years. Since the year 2000 leap seconds are introduced with an +# average interval of 3 to 4 years due to the acceleration of the Earth's rotation speed. +# +# +# RESPONSIBILITY OF THE DECISION TO INTRODUCE A LEAP SECOND IN UTC +# The decision to introduce a leap second in UTC is the responsibility of the Earth Orientation Center of +# the International Earth Rotation and reference System Service (IERS). This center is located at Paris +# Observatory. According to international agreements, leap seconds should be scheduled only for certain dates: +# first preference is given to the end of December and June, and second preference at the end of March +# and September. Since the introduction of leap seconds in 1972, only dates in June and December were used. +# +# Questions or comments to: +# Christian Bizouard: christian.bizouard@obspm.fr +# Earth orientation Center of the IERS +# Paris Observatory, France +# +# +# +# COPYRIGHT STATUS OF THIS FILE +# This file is in the public domain. +# +# +# VALIDITY OF THE FILE +# It is important to express the validity of the file. These next two dates are +# given in units of seconds since 1900.0. +# +# 1) Last update of the file. +# +# Updated through IERS Bulletin C (https://hpiers.obspm.fr/iers/bul/bulc/bulletinc.dat) +# +# The following line shows the last update of this file in NTP timestamp: +# +#$ 3929093563 +# +# 2) Expiration date of the file given on a semi-annual basis: last June or last December +# +# File expires on 28 June 2025 +# +# Expire date in NTP timestamp: +# +#@ 3960057600 +# +# +# LIST OF LEAP SECONDS +# NTP timestamp (X parameter) is the number of seconds since 1900.0 +# +# MJD: The Modified Julian Day number. MJD = X/86400 + 15020 +# +# DTAI: The difference DTAI= TAI-UTC in units of seconds +# It is the quantity to add to UTC to get the time in TAI +# +# Day Month Year : epoch in clear +# +#NTP Time DTAI Day Month Year +# +2272060800 10 # 1 Jan 1972 +2287785600 11 # 1 Jul 1972 +2303683200 12 # 1 Jan 1973 +2335219200 13 # 1 Jan 1974 +2366755200 14 # 1 Jan 1975 +2398291200 15 # 1 Jan 1976 +2429913600 16 # 1 Jan 1977 +2461449600 17 # 1 Jan 1978 +2492985600 18 # 1 Jan 1979 +2524521600 19 # 1 Jan 1980 +2571782400 20 # 1 Jul 1981 +2603318400 21 # 1 Jul 1982 +2634854400 22 # 1 Jul 1983 +2698012800 23 # 1 Jul 1985 +2776982400 24 # 1 Jan 1988 +2840140800 25 # 1 Jan 1990 +2871676800 26 # 1 Jan 1991 +2918937600 27 # 1 Jul 1992 +2950473600 28 # 1 Jul 1993 +2982009600 29 # 1 Jul 1994 +3029443200 30 # 1 Jan 1996 +3076704000 31 # 1 Jul 1997 +3124137600 32 # 1 Jan 1999 +3345062400 33 # 1 Jan 2006 +3439756800 34 # 1 Jan 2009 +3550089600 35 # 1 Jul 2012 +3644697600 36 # 1 Jul 2015 +3692217600 37 # 1 Jan 2017 +# +# A hash code has been generated to be able to verify the integrity +# of this file. For more information about using this hash code, +# please see the readme file in the 'source' directory : +# https://hpiers.obspm.fr/iers/bul/bulc/ntp/sources/README +# +#h be738595 57b0cf1b b0218343 fb77062f 5a775e7 From nobody Sun Jul 21 04:18:08 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRVWh3ms7z5QtLL; Sun, 21 Jul 2024 04:18: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRVWh3Fcvz4NgL; Sun, 21 Jul 2024 04:18:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721535488; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=3VH6cNrx1+vnmuBK62LPPK5+hZFJ4ubkKhNv4nonoo8=; b=NHwmEtTK4iJXY9Iiow46zs08sHYy/eSb5xBUZ43kv67izp1EAmbiKP9ISIaF6wv4RDaJiy 9kGA1cfepOrRUa1DDgP3sQSbe1tj/reWoXkvl2PEl9mR6GVEcASTlU8Yci0J6Me0lE1E8s WWtyVj1qaGaIofBp5FlJyfza6MKJL1bAeJXderF4SHyVsoXKHbbeUTrIrzfgP6rmfBj1Ar 0By6O/nnAC6YnukaoYcbD5fiWpwFiy+WATwfrEMr/EuBZrXq6LS11Doaybj4Gyg7NMeJWS WlSQyO3Fff3KxuVPDlycTxL4jJLd8es4h0mBa5dB99FOjrTWuaJAefZU9yyCOQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721535488; a=rsa-sha256; cv=none; b=x4R3U6jFAj5KBr8kxea/ySb6LEln+5AZ5YhT+aCMgSE+xgpXZQxGnkG+i3nDe0qOvA3iir 5e3dpQJImPgjBJleK2na2/KvQAZoBcO0bMnHkwl0EHh9WdbAZBmlauIiLhGArK6I57+eHb en76oE5CAf+/hMZE4S4pEZhGy5KD0qKC1hZmd3xm6f6djJd+jesCB58LGPKaFHha6KiuHB 2gvK1aIXoLTcDa2rJhmZJkOvQUI+1pc+Kr7ucvijh0usM2FqmKbztJgd8WZ8d6Xw2FdBWw LSioHBbxAepxCkSHxFqf+Kl8xT8ForyPC56qUsKGlDnHs0n/OiiS0BDpJHOqOw== 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=1721535488; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=3VH6cNrx1+vnmuBK62LPPK5+hZFJ4ubkKhNv4nonoo8=; b=fje0bGz+ZJQoJdygaqadWhdhgipF0p/h/GntiuqwgKbJX0CQkn69taxBtGUEWJOoVGII67 us0YfvFjtBEdHcTCdOb1xkYp8EmQ4btDuA+YPYBjSUxUYrAMmvwxBDQj59PE6jqwe0Nfmv PtZLulqmjQ88HxiKKSledcmyFRx95ptID/9o9ZTbiwVKwicUV6pkoNUNpeu8kFSo8jWgYN S3kB5wOcfUxUy7WLd9ViNqpAdthsvYuuV4xeJUetTiBMAbGXLYAEbWc6bpdNtdm5EFrlV/ SCXPF+pc1bkFIds7pNjVKEL/paXwuICUYDrfiMlyQvd9oR1esluxe/5H2/n1fg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRVWh2rnYzlcT; Sun, 21 Jul 2024 04:18:08 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46L4I8gj099700; Sun, 21 Jul 2024 04:18:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46L4I891099697; Sun, 21 Jul 2024 04:18:08 GMT (envelope-from git) Date: Sun, 21 Jul 2024 04:18:08 GMT Message-Id: <202407210418.46L4I891099697@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kyle Evans Subject: git: 9a3f7fb46c93 - main - include: ssp: fix last bare `inline` List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kevans X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9a3f7fb46c93eb0142a7c32bff3dbda2cd29196e Auto-Submitted: auto-generated The branch main has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=9a3f7fb46c93eb0142a7c32bff3dbda2cd29196e commit 9a3f7fb46c93eb0142a7c32bff3dbda2cd29196e Author: Kyle Evans AuthorDate: 2024-07-21 04:16:24 +0000 Commit: Kyle Evans CommitDate: 2024-07-21 04:17:55 +0000 include: ssp: fix last bare `inline` This was missed in b8730c11a39 ("include: ssp: fix the build [...]"), but also had a bare `inline` in use. Swap it over to __ssp_inline as well. Reported by: netchild Sponsored by: Klara, Inc. Sponsored by: Stormshield --- include/ssp/wchar.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/ssp/wchar.h b/include/ssp/wchar.h index 48fc56f9d243..bbc84d379e56 100644 --- a/include/ssp/wchar.h +++ b/include/ssp/wchar.h @@ -31,7 +31,7 @@ #if __SSP_FORTIFY_LEVEL > 0 -static inline int +__ssp_inline int __ssp_wchar_overlap(const void *leftp, const void *rightp, size_t len) { From nobody Sun Jul 21 05:25:22 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRX1G4sjKz5R0Nx; Sun, 21 Jul 2024 05: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRX1G47NZz4T1h; Sun, 21 Jul 2024 05:25:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721539522; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=NGiqP0RN93bs3nW1v03o5W5jeMbcXn2V72P/5w+WJt0=; b=vSQoDblNYS9jwPWcIOvv3yLMZUUgLicx7FUFgktX+ryqmFygxOQAlto6Rz4sQrppueH+H3 MsWyvLYrb9L/HZTCcHRyMjRxgkYWYkWaHmDsKK+bdiuOp/7BHPZ2fP3wumWdZURykqTY2m ms8HVPlD3/vZ1L0fDfWCo4YpB7DFAtso+qkj+/5tFDYjq/K1bin4vnypMGVT+DU5Wsys3l dgAcDAJdyuaokycc+CYRaAd3UPaTh51wNKli05GNMNC18pm1mNhQaXrgU5TzV9RPlpm3Jr n5acUbayzYEcE6ALETEHboXidtGGNonuXde01M5PxRVUJEbDkrSjXAw2TRgBNQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721539522; a=rsa-sha256; cv=none; b=lBp7fQQiq8ziXeJcNwVWgmVutSeydA9JYoim+H9OHwY9FLN9J0QlTYX38vuKb4V75YQ/dt sPAahGyysEB0wCNhCalF2RU6oqlaudq4XFfc1tJNWYC1dp2784aPzAkr//26656/r9xeP8 4SR0LniTNwezUCt2mrINZhBf7eNNCHngmHIw0+sGUJPnnNSh7JTcr5/PwWb1VjJXmTqky7 sSl+wzg0OjpE+PFPdOU9O58MUaoGD+9cIyIL+VzlhIRgge22DhLXyGtQ8y3KQKzB/IuHbz 1VDK2ALMwm/ZFhu9QBWctpsqb1rXYyFIeEiR1yYAo9GYDNTPFImrFwfhQUdsvQ== 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=1721539522; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=NGiqP0RN93bs3nW1v03o5W5jeMbcXn2V72P/5w+WJt0=; b=huMkwqYZw21AOHPammCJacq+j0r4jBUQzNLev+pEmuqJicPMqUXEbORK/GAQleL9MkML3p SG42YxRhRmcOUkGpVq6tqNdJzHH0mPqRttzLhG7vM1xnDmeMu25R8NWsEueiEeqGLTe170 4zeyKYSydQz4dNvL3c7lERRGgxIzpDnvnaxEb/CK25pNyF8QLUhKUjblbyIBAOiH6nKIJh oFuzNnfrHLJ2TileuduEw3DAGsW9D3xZ3xA4Hv+MFmVNGYAA+I7oSRmT5ztPeQJx1tZ5Ue FlSCffCdrbDeVF77wdDaPVpqGw10GoY58BVbkzcpcJPgQOpmXOw+kOM+lgLOGg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRX1G3b87zncS; Sun, 21 Jul 2024 05:25:22 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46L5PMWZ017261; Sun, 21 Jul 2024 05:25:22 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46L5PMH2017258; Sun, 21 Jul 2024 05:25:22 GMT (envelope-from git) Date: Sun, 21 Jul 2024 05:25:22 GMT Message-Id: <202407210525.46L5PMH2017258@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: 2e57144df7e1 - stable/13 - stand: module: unlink the entire tail when dependencies fail to load List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kevans X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 2e57144df7e1f8d9ed91a75f96ff2b8affc1c601 Auto-Submitted: auto-generated The branch stable/13 has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=2e57144df7e1f8d9ed91a75f96ff2b8affc1c601 commit 2e57144df7e1f8d9ed91a75f96ff2b8affc1c601 Author: Kyle Evans AuthorDate: 2024-06-25 20:31:50 +0000 Commit: Kyle Evans CommitDate: 2024-07-21 05:25:07 +0000 stand: module: unlink the entire tail when dependencies fail to load Assume you have loader configured to load linux64, which has a dependency on both linux_common and mqueuefs but neither the kernel nor kernel config in question have the mqueuefs module included. When the load command for linux64 fails to find mqueuefs, it will free both linux64 and linux_common as they were loaded first, but only linux64 gets removed from the module list. As a result, future traversals hit an easy use-after-free with linux_common. Fix it so that we unlink the entire tail of the list. Anything after the initially loaded module is, by definition, a dependency on the loaded module while we're still in the load command, so we can just discard the entire tail. If linux_common were loaded before linux64, it should not move to a position during this load where it would suddenly be missing from the view presented to the kernel. Reported by: philip Reviewed by: imp, philip, tsoome (cherry picked from commit 3da568710fde08251996c117b87bedb326dedb57) --- stand/common/module.c | 31 ++++++++++++++++++++++++++----- 1 file changed, 26 insertions(+), 5 deletions(-) diff --git a/stand/common/module.c b/stand/common/module.c index b4a53701ffba..699be7bf4feb 100644 --- a/stand/common/module.c +++ b/stand/common/module.c @@ -65,6 +65,7 @@ static char *mod_searchmodule(char *name, struct mod_depend *verinfo); static char * mod_searchmodule_pnpinfo(const char *bus, const char *pnpinfo); static void file_insert_tail(struct preloaded_file *mp); static void file_remove(struct preloaded_file *fp); +static void file_remove_tail(struct preloaded_file *fp); struct file_metadata* metadata_next(struct file_metadata *base_mp, int type); static void moduledir_readhints(struct moduledir *mdp); static void moduledir_rebuild(void); @@ -958,7 +959,7 @@ mod_loadkld(const char *kldname, int argc, char *argv[]) file_insert_tail(fp); /* Add to the list of loaded files */ if (file_load_dependencies(fp) != 0) { err = ENOENT; - file_remove(fp); + file_remove_tail(fp); loadaddr = loadaddr_saved; fp = NULL; break; @@ -1719,25 +1720,45 @@ file_insert_tail(struct preloaded_file *fp) * Remove module from the chain */ static void -file_remove(struct preloaded_file *fp) +file_remove_impl(struct preloaded_file *fp, bool keep_tail) { - struct preloaded_file *cm; + struct preloaded_file *cm, *next; if (preloaded_files == NULL) return; + if (keep_tail) + next = fp->f_next; + else + next = NULL; + if (preloaded_files == fp) { - preloaded_files = fp->f_next; + preloaded_files = next; return; } + for (cm = preloaded_files; cm->f_next != NULL; cm = cm->f_next) { if (cm->f_next == fp) { - cm->f_next = fp->f_next; + cm->f_next = next; return; } } } +static void +file_remove(struct preloaded_file *fp) +{ + + file_remove_impl(fp, true); +} + +static void +file_remove_tail(struct preloaded_file *fp) +{ + + file_remove_impl(fp, false); +} + static char * moduledir_fullpath(struct moduledir *mdp, const char *fname) { From nobody Sun Jul 21 05:25:23 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRX1H5v9qz5R0Yy; Sun, 21 Jul 2024 05: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRX1H4zppz4ShF; Sun, 21 Jul 2024 05: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=1721539523; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=JvpIBAdx3FhNBCrGB0lL0BmPWMxea0QmQ7IYvxI6c6o=; b=w0ZmryIP1Lj8IJZLk/o+5EqACWUSvmhlkcVvWnT0oOpGjyRI7RA41RF3LVVpg03Hn1oK8e 1Nw096KTd/3mc5YwpRmHVDpYb/Hpa8SioyiFtV4njtLhBPmmrZByaQiJ4mZEte5A6lWMwx SqvUknLZ9CrfrsnFi1OSjksp41AUJKcvFoCWcxIJl85rb8EWY25MocEPBZKHPlraxhdHNV YxwEG0S3fx0wM88JjKpYIjKAkGcdmIjPbkx+13l8VEowKy/SVVXl+cqDf6OsIyj65GVaGr iBt3KXjNsoCEZn1avwvEEClPnp9YnfPb15dZMtC4HBCynLpEQYnVoKOH82dC6A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721539523; a=rsa-sha256; cv=none; b=uCgyilVqJ0EfkkWfsDertLQVsi3rMisCFUY/l/yjf+eiaLFm8b+Pt1hPeKw7BaOpMvOJoy vF1/1HTyohr6uPoYJtXqPvLGp+tQMKU6RiN0LqA2yRDLbzmEwVquJXrpYgEN3/eRjqbk0F LCUgmIFCvqQEcWbjpJZtMRgoyLSYSEi+FDGkKbQe7SLPvG0EvxZVGojZBYAfY2A4vV4qc1 d3il9PUDlAJHpsxy56wdoI2PzdFmhmn+CacGLrq5e32lWl93ivSHHSj/0/EIA7Jb6K8fJR QTDM6FUIBIj0Q0Cr7WXyiFTMqWW99ISYMoju4b0y/lp8zZHG1T7aUtYv3P/2ag== 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=1721539523; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=JvpIBAdx3FhNBCrGB0lL0BmPWMxea0QmQ7IYvxI6c6o=; b=tvPx9RkltvrAVPoLJ/eHUQ8RmJIqJI3Fl2YP+NV2zkivGcRtAjwgejGw2il8bBe5To3FV2 yrlpKB6ygxxEclMVdRBG2GFfASWCoB2RH5l+GsSfZ2vdPWO38THvQKIpnewdO9ViKruV8n ynD/LBozguKEa2c4Y5TwV/Ag7iZU+D+oLQzkjfeTSfKPkfqAwMYxm9L8vqMa21iCoQzS4B Q7KEBCIaSZbrUg/eMO0z9b8Z82BKK/45Qj3uJ0YzX6ijODNX189zgv3Jck9UIMGRW6jmef eUyE32Ne6xEg5I/LKG9j65Pj4ApO+c3cfrWPeJh4azEFbV9GdrxigsW5eDRDAg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRX1H4b5hznKv; Sun, 21 Jul 2024 05:25:23 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46L5PNBc017318; Sun, 21 Jul 2024 05:25:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46L5PNXq017315; Sun, 21 Jul 2024 05:25:23 GMT (envelope-from git) Date: Sun, 21 Jul 2024 05:25:23 GMT Message-Id: <202407210525.46L5PNXq017315@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: 98e1ee23857c - stable/13 - kern: zero out stack buffer after copying out random bits List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kevans X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 98e1ee23857cf858a66dff23b39f80ede00d2311 Auto-Submitted: auto-generated The branch stable/13 has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=98e1ee23857cf858a66dff23b39f80ede00d2311 commit 98e1ee23857cf858a66dff23b39f80ede00d2311 Author: Kyle Evans AuthorDate: 2024-07-15 20:17:47 +0000 Commit: Kyle Evans CommitDate: 2024-07-21 05:25:12 +0000 kern: zero out stack buffer after copying out random bits The kern.arandom sysctl handler uses an intermediate buffer on the stack to hold random data that it subsequently copies out to the sysctl request. Err on the side of caution and zero out the stack buffer after we're done with it to avoid a potential entropy leak later on. Reviewed by: cem, emaste, markj (cherry picked from commit 5862c891bb7c588aa00538d85eb26ffe77d3f709) --- sys/kern/kern_mib.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/sys/kern/kern_mib.c b/sys/kern/kern_mib.c index c9056503925f..aa4798a5a956 100644 --- a/sys/kern/kern_mib.c +++ b/sys/kern/kern_mib.c @@ -182,10 +182,14 @@ sysctl_kern_arnd(SYSCTL_HANDLER_ARGS) { char buf[256]; size_t len; + int error; len = MIN(req->oldlen, sizeof(buf)); read_random(buf, len); - return (SYSCTL_OUT(req, buf, len)); + + error = SYSCTL_OUT(req, buf, len); + explicit_bzero(buf, len); + return (error); } SYSCTL_PROC(_kern, KERN_ARND, arandom, From nobody Sun Jul 21 05:25:28 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRX1N5fvyz5R0WY; Sun, 21 Jul 2024 05:25: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRX1N4SBDz4SjG; Sun, 21 Jul 2024 05:25:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721539528; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=mBd5kcEej1dSbK0oSpDdF4tTYptuOCAA+MdzxdRe7tM=; b=NlJtJ9Av1NzmxjLbGi+/4IUdShRDVJKH7ghlmWO7hxqIpc2i8KxVFToU/CGJfU9xP3WQdm H02Xf5Wcb+2Xvsz1Z9ZTkyPT8C2jgyfAO79SoWd+zAo2cVt4948uqdPL1lWjL6Mqki3ROC vtdjrA7NU7Dl+nNRXxrjS6ZRsYVpqnTgD6sUCHudkH3MCP86VXW0uLOFQRTAzYBS8QH0n+ TQH/y9ge34586kI/1YSmbMXhHAkP8iBZUYjfcsKRz+UAzd9adcH6gIvYO0ORP1fyHSx14b IPKhyvJORIlfhRhR/TTWSb8594Nb6N0UnkL8d6BRfIRU//8xUmvN+/42A4nwGg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721539528; a=rsa-sha256; cv=none; b=antoIDmq+df8x6a+lZuNsOd9ErWqB9O7EmQ7X1+wNvEihiScR/dBi/27jTMHSIt2GewZnd lCanqYu+5GlJTMhoes8DK4FO9KgX5oItCUIij6DMyx4OPGLXy5oAUDgg+nwCzNNtTPz/Hu woZQKo/22M3R/94Dg7F9DNxLGsC548/zlXNz7v22LmqUhKpD0UCR5z/DglI0qrnjFmly3x RJBLgOWWNqAyHOlzq2K4PeTg9fZwJbpjcTREzV96V5somx+Tqtxbp8W1UmYcLIXUoeufXl Xs5eONR6jU8RyWOkfvC+hc5jrWcaYH1y/b0cclMqy4bwCzyZbiq6vjtajK161Q== 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=1721539528; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=mBd5kcEej1dSbK0oSpDdF4tTYptuOCAA+MdzxdRe7tM=; b=h4pS357CKD+3yg5ZLicDUa7dzzSHzMNEO04xWMj30n+et2p5aZ12+t0WNYtSy07TTDwbnK eS7Ndnr9whem8dnNwWeCKyHmXDhx47ojs+1DV3A8E0wyWc11cmwFK61Vsc6FRye+48mn2A J1i2cDBCwIxu5xPbjmmizYEzzIHSKkv0cL/Xp82JvQGX73YVoKWn0QbFO8un8qLr2doy3U Fm1jPlWIupKncJZp6Ymfvl1muFj8fc7CSU3RvQchTL8KX9mfgz9LQ+cTP5ceIyYgBSXmtW mGPprtcuwdPwSpxLS5szP/ONgkMu8vyBHCSdF5G+o+xamd/pMNYYA/yNbz5UIg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRX1N3qGwzn8h; Sun, 21 Jul 2024 05:25:28 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46L5PSC4017484; Sun, 21 Jul 2024 05:25:28 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46L5PSVF017481; Sun, 21 Jul 2024 05:25:28 GMT (envelope-from git) Date: Sun, 21 Jul 2024 05:25:28 GMT Message-Id: <202407210525.46L5PSVF017481@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: f29a2ea5b44d - stable/14 - stand: module: unlink the entire tail when dependencies fail to load List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kevans X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: f29a2ea5b44d79957c2568fa0181877c7556c7f3 Auto-Submitted: auto-generated The branch stable/14 has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=f29a2ea5b44d79957c2568fa0181877c7556c7f3 commit f29a2ea5b44d79957c2568fa0181877c7556c7f3 Author: Kyle Evans AuthorDate: 2024-06-25 20:31:50 +0000 Commit: Kyle Evans CommitDate: 2024-07-21 05:24:50 +0000 stand: module: unlink the entire tail when dependencies fail to load Assume you have loader configured to load linux64, which has a dependency on both linux_common and mqueuefs but neither the kernel nor kernel config in question have the mqueuefs module included. When the load command for linux64 fails to find mqueuefs, it will free both linux64 and linux_common as they were loaded first, but only linux64 gets removed from the module list. As a result, future traversals hit an easy use-after-free with linux_common. Fix it so that we unlink the entire tail of the list. Anything after the initially loaded module is, by definition, a dependency on the loaded module while we're still in the load command, so we can just discard the entire tail. If linux_common were loaded before linux64, it should not move to a position during this load where it would suddenly be missing from the view presented to the kernel. Reported by: philip Reviewed by: imp, philip, tsoome (cherry picked from commit 3da568710fde08251996c117b87bedb326dedb57) --- stand/common/module.c | 31 ++++++++++++++++++++++++++----- 1 file changed, 26 insertions(+), 5 deletions(-) diff --git a/stand/common/module.c b/stand/common/module.c index 832a8eb4988d..29228f0de22a 100644 --- a/stand/common/module.c +++ b/stand/common/module.c @@ -64,6 +64,7 @@ static char *mod_searchmodule(char *name, struct mod_depend *verinfo); static char * mod_searchmodule_pnpinfo(const char *bus, const char *pnpinfo); static void file_insert_tail(struct preloaded_file *mp); static void file_remove(struct preloaded_file *fp); +static void file_remove_tail(struct preloaded_file *fp); struct file_metadata* metadata_next(struct file_metadata *base_mp, int type); static void moduledir_readhints(struct moduledir *mdp); static void moduledir_rebuild(void); @@ -876,7 +877,7 @@ mod_loadkld(const char *kldname, int argc, char *argv[]) file_insert_tail(fp); /* Add to the list of loaded files */ if (file_load_dependencies(fp) != 0) { err = ENOENT; - file_remove(fp); + file_remove_tail(fp); loadaddr = loadaddr_saved; fp = NULL; break; @@ -1637,25 +1638,45 @@ file_insert_tail(struct preloaded_file *fp) * Remove module from the chain */ static void -file_remove(struct preloaded_file *fp) +file_remove_impl(struct preloaded_file *fp, bool keep_tail) { - struct preloaded_file *cm; + struct preloaded_file *cm, *next; if (preloaded_files == NULL) return; + if (keep_tail) + next = fp->f_next; + else + next = NULL; + if (preloaded_files == fp) { - preloaded_files = fp->f_next; + preloaded_files = next; return; } + for (cm = preloaded_files; cm->f_next != NULL; cm = cm->f_next) { if (cm->f_next == fp) { - cm->f_next = fp->f_next; + cm->f_next = next; return; } } } +static void +file_remove(struct preloaded_file *fp) +{ + + file_remove_impl(fp, true); +} + +static void +file_remove_tail(struct preloaded_file *fp) +{ + + file_remove_impl(fp, false); +} + static char * moduledir_fullpath(struct moduledir *mdp, const char *fname) { From nobody Sun Jul 21 05:25:29 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRX1Q0Zwtz5R0bn; Sun, 21 Jul 2024 05:25: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRX1P5Hv9z4Sxp; Sun, 21 Jul 2024 05:25:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721539529; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6ydTIC9hzRzW/FXLxu0m1c2aUXnDvB2j87212DwGNak=; b=TQuW2hQk7EPE1HgaTgmgjVKQKtt3w96tIwt++RIuPXC7xuplC9VsPg+niUsubVcfyMbWbX bNvIKtZhICTzUTy4mcuiMd6CGNrWNJX7yx8ez/8i1Z4T42vG/kB36FbXNubB7jufzOIDj9 ZBvgLStIrxupD2igy9nI7eISdvF//OqpmoRHuBnxR0Dm17zd2ZPbo7ShfWWOAmg4dSeymQ 2iw3oTKQLDMk2exNHhqlS/Z8NxGctRudwDKBmeWNiLQXrzHKbWNKDpYvxmN6hab3DK49Vo sMieLxHFuOiM+2fYGwcTUwX2ubtCA9ioQWA4NxcyqRfDsImdSMyuW9ocFg/gDg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721539529; a=rsa-sha256; cv=none; b=q4swCPFEWeVtJbAprn3xb6rchjALEcxUgS1fayiZZyQeBLBtrkbrX4KlS3E6CbW1g4SPJ3 3rHYpqQ4bfNnDmyDO2N9jxpLE0vxWdo2aCX06CiT9XbQJ6k11D5YmDZEddM7be0qKaJ233 fGwyD5aMmNN0DdpniDPWLqBVoYbOIJ60YWkjzXpjlY/cm3xG5dkwCv6KT54HnxhuxJmQlS A6KcvOcE1P8M5CMmxqMW1Af07uytl3oYjNjpkwPZHW8BeQlcFu+eNuO/czLpWLu4n4kMbo LlBAbW5jUdW0s72I8/wjuk/UDtqUc95cLDlGqhx3RLI+qo2jxZGgOvM4UlS9vg== 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=1721539529; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6ydTIC9hzRzW/FXLxu0m1c2aUXnDvB2j87212DwGNak=; b=AdxTN76qRl3YTmUdjycWD8y6IFOZnz9R9J9mnjSo2s/T9Vi4pI3OzvVZHUQpSFYGFJW1CS bSQcXNb4KPOj29mK3KAVbXnNQrpvkO42Q6Tl6fl2uMST06EMjHQ1pxzzgfX8D4hU55Ehhk BDbk8gS+iZFH6DP8NDJ7CUwAgSE5zt9QVgXNzcB+HenCczfEo9C5gPMr5jRuoEAKxmYW12 v6Vr7P1us3J9cjd1S5VXg1fWNdtNatRmaEGeszXaux1Ke0ZlJZX36tTrNKoGgvRlbPaPzP npa/tnuKliZvLINwX7GMPJ7xFz+wCrIYuB6CZ51RWKoQuEIGrNI+GZ0wT98mNw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRX1P4sRZzn3D; Sun, 21 Jul 2024 05:25:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46L5PTbk017541; Sun, 21 Jul 2024 05:25:29 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46L5PT7O017538; Sun, 21 Jul 2024 05:25:29 GMT (envelope-from git) Date: Sun, 21 Jul 2024 05:25:29 GMT Message-Id: <202407210525.46L5PT7O017538@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: 1eb62930e736 - stable/14 - kern: zero out stack buffer after copying out random bits List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kevans X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 1eb62930e73689ce8e9cc68cf6f5cdc337c56bf3 Auto-Submitted: auto-generated The branch stable/14 has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=1eb62930e73689ce8e9cc68cf6f5cdc337c56bf3 commit 1eb62930e73689ce8e9cc68cf6f5cdc337c56bf3 Author: Kyle Evans AuthorDate: 2024-07-15 20:17:47 +0000 Commit: Kyle Evans CommitDate: 2024-07-21 05:24:55 +0000 kern: zero out stack buffer after copying out random bits The kern.arandom sysctl handler uses an intermediate buffer on the stack to hold random data that it subsequently copies out to the sysctl request. Err on the side of caution and zero out the stack buffer after we're done with it to avoid a potential entropy leak later on. Reviewed by: cem, emaste, markj (cherry picked from commit 5862c891bb7c588aa00538d85eb26ffe77d3f709) --- sys/kern/kern_mib.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/sys/kern/kern_mib.c b/sys/kern/kern_mib.c index 7d2a9e7f8474..8ce09a47ef58 100644 --- a/sys/kern/kern_mib.c +++ b/sys/kern/kern_mib.c @@ -182,10 +182,14 @@ sysctl_kern_arnd(SYSCTL_HANDLER_ARGS) { char buf[256]; size_t len; + int error; len = MIN(req->oldlen, sizeof(buf)); read_random(buf, len); - return (SYSCTL_OUT(req, buf, len)); + + error = SYSCTL_OUT(req, buf, len); + explicit_bzero(buf, len); + return (error); } SYSCTL_PROC(_kern, KERN_ARND, arandom, From nobody Sun Jul 21 08:51:16 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRcZr3hM8z5R4TW; Sun, 21 Jul 2024 08:51: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRcZr2v58z4lWF; Sun, 21 Jul 2024 08:51:16 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721551876; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=8C70p4CMoE9GEX32lKBUEHPBOxG3tsP8DDWBssZDA70=; b=gf/rUjTjL0m3DvrnOC1+BG0R3g0R7P8CEAqaIoYdqqquGxG6U59n8fmEPz47k9b89H5UMX JHJyzArnTk3Y1esY86/ibtd+9Qj2yQmACZbxo87oAyeJWkYSBJCkWWc7961RHIrWhfqyLK eafSyF97Hj3h3DfCiyf2JAEQOhs1+fXDqRJR77tsXIVIqF41/kYLE0io9ZIiWe3OeSf9Un 6rWzyppv3cgo/CTcfeftH0b4hF1ASPmKhei7QuY649vFUljQm7NEiaNDBcnElcAT+5qBer qcIDEOQKdkps5tlNHcFPQf6MlThwWZSeQZnOTMLLPnv2SA9XWybOVItAO9L/Iw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721551876; a=rsa-sha256; cv=none; b=OMXTojcZwlUKOE5NG3PZwL7JRQCreL8KiEQ+S+382mo2sEKFR2PpJAXOMioz6khVnVZ0/p qlnpNgWLPxcZOaTN+vL5rDw0RfIec3EWtgWwXjAV3fu2WlL2lcpEVX76Nj0WYojFGz8uYW 1pU5jCda0P3WrCKdyvT59HJSnyVlGtLGrGrCt2Lg8xRdEGFENNEWEeNuQH8gPYRNgMl931 BHm/h5YnXebRGRNm+Ny9mN8DZlZ2G6drM7kSM+XgKVUEqkPMHKh7zkJtpYKx4I40nkkA+f jdhQh3HBbAw9AVzG7Z0Y5mC3vU8DqEWlJ0Pwde1ZRB+JTAcEN97Lm6iqKvbLxA== 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=1721551876; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=8C70p4CMoE9GEX32lKBUEHPBOxG3tsP8DDWBssZDA70=; b=ZmSe48BXWiSpJSrMG/KnxgmPtDWp6euxmRcWjSm+MnkRYGAt1lMo4eTHA/qR0MOySoKrB2 DWTCdBAT3yCxMOhQEQlls15PxttQItUi5vUIWtVQjNPMP9fch0F/PWWnjwWSuetPYcZcGE iEl8X6B5D6pb6gPTBWQjNAPCE5DfhOs2pHQF3iT6LG2uncpd/WM2MB3maJb4crinl1F9Lj evaabNnbSDw0104Gi66oEy84pM4uSQO/g18ua6D+iQLSKb3jjgnWOqzg32uVQtJpQeAULy Pk3SznbYMriN7fmx6lYWRh4r8NQJsZgfJjC7qBEU3Gpc8TTPPQenJCKlPwfXwQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRcZr2R9Bzsw0; Sun, 21 Jul 2024 08:51:16 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46L8pGIf071226; Sun, 21 Jul 2024 08:51:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46L8pGdX071223; Sun, 21 Jul 2024 08:51:16 GMT (envelope-from git) Date: Sun, 21 Jul 2024 08:51:16 GMT Message-Id: <202407210851.46L8pGdX071223@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: 8c405f08c099 - stable/14 - amd64 pmap_allocpte_nosleep(): fix indent List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 8c405f08c0993945d668dba8bacf025da8303c68 Auto-Submitted: auto-generated The branch stable/14 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=8c405f08c0993945d668dba8bacf025da8303c68 commit 8c405f08c0993945d668dba8bacf025da8303c68 Author: Konstantin Belousov AuthorDate: 2024-07-13 04:05:36 +0000 Commit: Konstantin Belousov CommitDate: 2024-07-21 08:50:29 +0000 amd64 pmap_allocpte_nosleep(): fix indent (cherry picked from commit 616dd88a2e68c1243e4c8b57e883742937a61af0) --- sys/amd64/amd64/pmap.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/amd64/amd64/pmap.c b/sys/amd64/amd64/pmap.c index d6e9713f215a..50a52d89db85 100644 --- a/sys/amd64/amd64/pmap.c +++ b/sys/amd64/amd64/pmap.c @@ -4758,8 +4758,8 @@ pmap_allocpte_nosleep(pmap_t pmap, vm_pindex_t ptepindex, struct rwlock **lockp, } if ((*pdp & PG_V) == 0) { /* Have to allocate a new pd, recurse */ - if (pmap_allocpte_nosleep(pmap, pmap_pdpe_pindex(va), - lockp, va) == NULL) { + if (pmap_allocpte_nosleep(pmap, pmap_pdpe_pindex(va), + lockp, va) == NULL) { pmap_allocpte_free_unref(pmap, va, pmap_pml4e(pmap, va)); pmap_free_pt_page(pmap, m, true); From nobody Sun Jul 21 08:51:17 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRcZs4pK8z5R4gQ; Sun, 21 Jul 2024 08:51: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRcZs3Y74z4lWG; Sun, 21 Jul 2024 08:51:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721551877; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=N4dFkmws7SiVyXqy4ieDXJG4w8GIqlGLUoOviYL0NBE=; b=Go5ZwCwtf+FnFeiZnuKgefZ3rBo20Spi/H5x/OzTO8Tt+8uBNMRxrL8oTKcHdKzIJijDT9 aF9bMozpqdS4JFV2l8bYInKUMmrx9MR7x7fS6nNre4dgNkJAKT/rC5tchlMVODuXOW1Z2Y LBnhVXxqi+r9UeWBlXVY+YtPQQ45KPoKXeR1+UqFHJN/dsBQv7PXhXw8P3Db+ej43FYG09 +F1JGLvDdSklMHzfsZuVSzItVnE4LSAHljdQGfMUxrEOkOujI+A9jgj5pInbdlfLf4B+Z4 6JdhFYQAhkuVNzSeIts7xN7wgWkGYdsUJv4S+kM8BTHxFKJEGCvhdMylNzlvbA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721551877; a=rsa-sha256; cv=none; b=eFvQECU5h4yFBs6z4tuJtISoKdgIOedxSEIPiQH0+b2DDkvqXy0asqzBWMOzhBQBJ7+7tR NRObeGeeRnq09fQGKn1MRXEH7Cmk+m1KEf0s+AO8wzyT+uHDHZo+FwA7K2RTx6SDtB+YgQ AixwZKCMvVzLP20pkJ4lV5NKEF3E02mhMgzR5qgLtaXNFC+fXRen4R9PK3g+KZ1N8BtyTH wTr+Z3XxNABNgLFOXdD7Mrbbtka44PWZijCeS8qRrZGHzc+8FDHohmPK7T6kGm/+9M8XS7 29yqbRXJTZZMp7mRo3p7FVnJFEWGjQmpfZaQXsv3TTfdYjyj75+zdL3K0vrePg== 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=1721551877; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=N4dFkmws7SiVyXqy4ieDXJG4w8GIqlGLUoOviYL0NBE=; b=T5kY80Oo7XYeKcm8SdGNWWj8qFTX9ALPgvT01mykJ3AGo4tjzxo4Zjkyc8icljLUX0JrPK Fl9L0zLQ7qnmEaX0R3i+++xl13NTbKiey3s8TExhl68mfV9a7rDMa9L4Z5kiYVcZ6Eu/Ze gFP2+38py82wR8sr0YL02oSGe9PZCNZvzBZ3tkDprAjg4XPaaGSDzGHITB7LRBobPx77nI lGmzivO2+TnK6YuFMmyu/fyaViQsR03G2DiegkB2NlNNSZUb8mJmQKVEE/Tiv8f7KyuI85 qoH3ZB4XgI9HXBYAqeBNxknugqpalfPa9BI43ugnRX6PDIL6sjy0DcD3TGc2ng== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRcZs38j1ztV1; Sun, 21 Jul 2024 08:51:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46L8pHcD071271; Sun, 21 Jul 2024 08:51:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46L8pHfd071268; Sun, 21 Jul 2024 08:51:17 GMT (envelope-from git) Date: Sun, 21 Jul 2024 08:51:17 GMT Message-Id: <202407210851.46L8pHfd071268@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: 010f09a7b16c - stable/14 - amd64 pmap_allocpte_nosleep(): stop testing tautological condition List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 010f09a7b16c2799d23161ba819a67f309318ef6 Auto-Submitted: auto-generated The branch stable/14 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=010f09a7b16c2799d23161ba819a67f309318ef6 commit 010f09a7b16c2799d23161ba819a67f309318ef6 Author: Konstantin Belousov AuthorDate: 2024-07-13 04:07:18 +0000 Commit: Konstantin Belousov CommitDate: 2024-07-21 08:50:29 +0000 amd64 pmap_allocpte_nosleep(): stop testing tautological condition (cherry picked from commit 10a6ae0ddffb1de842a0ba6a6ca29786de6d3bfd) --- sys/amd64/amd64/pmap.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/sys/amd64/amd64/pmap.c b/sys/amd64/amd64/pmap.c index 50a52d89db85..0d364dec7c82 100644 --- a/sys/amd64/amd64/pmap.c +++ b/sys/amd64/amd64/pmap.c @@ -4704,8 +4704,8 @@ pmap_allocpte_nosleep(pmap_t pmap, vm_pindex_t ptepindex, struct rwlock **lockp, *pml5 = VM_PAGE_TO_PHYS(m) | PG_U | PG_RW | PG_V | PG_A | PG_M; if (pmap->pm_pmltopu != NULL && pml5index < NUPML5E) { - if (pmap->pm_ucr3 != PMAP_NO_CR3) - *pml5 |= pg_nx; + MPASS(pmap->pm_ucr3 != PMAP_NO_CR3); + *pml5 |= pg_nx; pml5u = &pmap->pm_pmltopu[pml5index]; *pml5u = VM_PAGE_TO_PHYS(m) | PG_U | PG_RW | PG_V | @@ -4725,6 +4725,8 @@ pmap_allocpte_nosleep(pmap_t pmap, vm_pindex_t ptepindex, struct rwlock **lockp, if (!pmap_is_la57(pmap) && pmap->pm_pmltopu != NULL && pml4index < NUPML4E) { + MPASS(pmap->pm_ucr3 != PMAP_NO_CR3); + /* * PTI: Make all user-space mappings in the * kernel-mode page table no-execute so that @@ -4732,8 +4734,7 @@ pmap_allocpte_nosleep(pmap_t pmap, vm_pindex_t ptepindex, struct rwlock **lockp, * the kernel-mode page table active on return * to user space. */ - if (pmap->pm_ucr3 != PMAP_NO_CR3) - *pml4 |= pg_nx; + *pml4 |= pg_nx; pml4u = &pmap->pm_pmltopu[pml4index]; *pml4u = VM_PAGE_TO_PHYS(m) | PG_U | PG_RW | PG_V | From nobody Sun Jul 21 08:51:18 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRcZv0fZsz5R4gV; Sun, 21 Jul 2024 08:51: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRcZt56y2z4lT8; Sun, 21 Jul 2024 08:51:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721551878; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=/pJR9zZvv72CSjHnz2FrC2nexmUrz18Ml0c5k97at/A=; b=b4pA5jd78EhFnGMbJFX9zTkG/3Y/aXnk5M165DX/iDGaa9j/gf1iOErx8CVC520o7DoL1h cDwnu6JSAVQoVottYM1SjfyXa5Izn6UBM+ypyfDL/cJtr6Msi2ib3+zMQ4vv+bpfXCCNgX HfRdaKvZJLh+8FuM9U7zcvSjm3Iicz8wkUvmIXBkwblbKCjKXkXpQB6fSEOkU4ZPQUIrb4 PPEhw3gLxFE8Ij494Pzo+Qh1clhvQb9/GKHYzP8pw9rzQuse7+kV0IeL8chZn6MWKaZ7aO RiVnml/oS7AUrXp63blihy75Tumc3+e7sYL/CJUP+RgW9EbbhnPubE6zsyc9tg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721551878; a=rsa-sha256; cv=none; b=TkuqnegTYD71fi8UU2kUr2MuvgpO6YhAZQAJ5Bg01uM/8OSu3c0kyTbCdLke7M/GWL5Tth VIZdZrJw41hTLxKsmJGV4b10vzt4Dm1CNitCNJ+zMk7Bith4YdIuraq8o/BO3IIyOKdzw5 vGLEksypx93WG8fG26dTVwPZhbsyRPNh0rg3qKQRbI1PDEe0ScovjBKjsO/NBfOyyaKLCP AIapJRk06g1qnhL51TnfbFn7/HgL0HlK+Ez4be38mFEnkAG9a+SdpN7R9xbrD1uZrMbQwq wnDMOg0aaijj9vKtroerr8YdfJAunFRqWPjliH4Uq8ipr7nOT8OVb/FGHPidsw== 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=1721551878; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=/pJR9zZvv72CSjHnz2FrC2nexmUrz18Ml0c5k97at/A=; b=NgAByDa0DRusStOKYabBwnXUe+5HlF0p5fS5EHvCShayfe6QBNAxnagyvp/GxF9EmiOeF3 wZ9En0vm4QyA8nGkd4+r0dw5gKD7fGo4ZdyMGFC05oZtWQV1HpO2wz2aXGSCVg5HsNV0P2 BJvNheeHzzZxdwIsqZ/YF+ynbUyyUfU/PoTUg9NQA1PyfC7IWpVUb0H+KYIEZSbDZnYRyB nkNRFuU+OuqDC8rFHpD/Fva0crdJj8DNPnfHHyndZ9fOXEZTK/u8ytJnuAr8EpAc+z35kC CufoF+HxAJzFpzmU7BF8gHmXNQY7IFTop3N9t95mrcsYw8yY2ZxwEgMu9njkTw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRcZt4PxhztGf; Sun, 21 Jul 2024 08:51:18 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46L8pIk3071317; Sun, 21 Jul 2024 08:51:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46L8pIla071314; Sun, 21 Jul 2024 08:51:18 GMT (envelope-from git) Date: Sun, 21 Jul 2024 08:51:18 GMT Message-Id: <202407210851.46L8pIla071314@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: 049a256e9aa7 - stable/14 - vm_page: add vm_page_clearref() helper List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 049a256e9aa7b37487a6538d8c5763db6ec7a658 Auto-Submitted: auto-generated The branch stable/14 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=049a256e9aa7b37487a6538d8c5763db6ec7a658 commit 049a256e9aa7b37487a6538d8c5763db6ec7a658 Author: Konstantin Belousov AuthorDate: 2024-07-08 17:45:33 +0000 Commit: Konstantin Belousov CommitDate: 2024-07-21 08:50:29 +0000 vm_page: add vm_page_clearref() helper (cherry picked from commit 45cde0e439188589ca2511f6fd76829cbf68267e) --- sys/vm/vm_page.h | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/sys/vm/vm_page.h b/sys/vm/vm_page.h index c9773f27d195..a1df6f736aee 100644 --- a/sys/vm/vm_page.h +++ b/sys/vm/vm_page.h @@ -949,6 +949,17 @@ vm_page_in_laundry(vm_page_t m) return (queue == PQ_LAUNDRY || queue == PQ_UNSWAPPABLE); } +static inline void +vm_page_clearref(vm_page_t m) +{ + u_int r; + + r = m->ref_count; + while (atomic_fcmpset_int(&m->ref_count, &r, r & (VPRC_BLOCKED | + VPRC_OBJREF)) == 0) + ; +} + /* * vm_page_drop: * From nobody Sun Jul 21 08:51:19 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRcZv735Kz5R4Wg; Sun, 21 Jul 2024 08:51: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRcZv5Jfvz4lTJ; Sun, 21 Jul 2024 08:51:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721551879; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=RLJV7/L4FEor+2LoE1quZL/+s8TV02zdLOcHL0YKQsQ=; b=p7dZnUA84THCsi6u2AkCZQEfPaBfby6m1jy5flhKWrT1znSaaOIg0MBfL0s58Z+gClxdma 4DOtEJhcZROokwTWsElwA1KBwBpSdF3cl7hg5nHPHxxAyemh6Onqz9L4CGkZbdBvpt14sX V80LVoo3awcd9dDea0EVncFl4yNUxwa0SQhyaYW0e2RupEZwf7g4Haf1PXa7VUi81mqCSG oJk2h9BLQvE4i0nE9IiWdrn398UAs6eSl2Cg4/p4YNhPEqJ46hR60tpYeR9IWquZ2JUP5l Yhn1ja0kUZHSFC2R3BDtqf6yatdsInzdwjqokfXxYvwEE9b1U9njaZ0UFoJDhg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721551879; a=rsa-sha256; cv=none; b=q8MPRmS2y+tV1so8/Pg58ZftecS18Cb5lYrEy4aJg73WyTsD/KET1X8WWSMJ5OE7/VaU/A nmgSTgYL24Cqg717eKFX7HPhmBfM+lBwI5z0CZ71gY+JpDPhKGetT/fF77l2XLrNy0S0An gVAqkGg/ZpNTOEKMyQ1KY9o6R0lJWqwMxlcg4oU2YCfbzJN4AkorF0L2Y4Id+glLs+2MLC OkiH9Kr5qQ5OW7nDpVJ/aEFMVb0nm6CjMefMYrDJPA+oAg/qwMYc8JM9eNRZ0q8hduU0GD 4T4dWLUKnLr1hGJOotBYJpHc6OSaAcYUW/43byOkF5jCC4zbExop+e54u0v6OQ== 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=1721551879; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=RLJV7/L4FEor+2LoE1quZL/+s8TV02zdLOcHL0YKQsQ=; b=vAX9csPI6Lwh29q/DhKx1pN194AF12YZddd7K789noMZotGvhPSB8pDyFSktyGUy5MRE+F wmmzBva2kQrTH09EWQ3Xg8Ujpyzv+WO9dL90dmhrTrVGcCdGKxFUC9sRCfk/4S8ew36qhc p8xrFOnRAFuiUweubM5wrRstz5TeXf5rx/0jHz00M1TEHFzDr7bGNbyvxsRe+5nqFsrF/F AiTvv5fCxaBCZkwx/dYx1Ft7eHDIPTqoYpqS/WffdrdmhkxMvZ/Om9EezNX5YuyzHweWIr a7ShFaneJ+Gsy+YZ+q/gtmfl8wr1RKMDPVocuo34xYyVXYlxK9weEkbTgdjTYg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRcZv4nmwzst9; Sun, 21 Jul 2024 08:51:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46L8pJpE071365; Sun, 21 Jul 2024 08:51:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46L8pJHE071362; Sun, 21 Jul 2024 08:51:19 GMT (envelope-from git) Date: Sun, 21 Jul 2024 08:51:19 GMT Message-Id: <202407210851.46L8pJHE071362@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: 240ddb304ff3 - stable/14 - DMAR pagetables pages: handle ref_count special references List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 240ddb304ff327e831f75f8ae27f2e0220211b90 Auto-Submitted: auto-generated The branch stable/14 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=240ddb304ff327e831f75f8ae27f2e0220211b90 commit 240ddb304ff327e831f75f8ae27f2e0220211b90 Author: Konstantin Belousov AuthorDate: 2024-07-07 23:26:57 +0000 Commit: Konstantin Belousov CommitDate: 2024-07-21 08:50:29 +0000 DMAR pagetables pages: handle ref_count special references (cherry picked from commit 7773023b72de19c6c9a47fd04ac955ec52773f0f) --- sys/x86/iommu/intel_idpgtbl.c | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) diff --git a/sys/x86/iommu/intel_idpgtbl.c b/sys/x86/iommu/intel_idpgtbl.c index 82cac8bb2d39..deee50858dd2 100644 --- a/sys/x86/iommu/intel_idpgtbl.c +++ b/sys/x86/iommu/intel_idpgtbl.c @@ -48,6 +48,7 @@ #include #include #include +#include #include #include #include @@ -391,7 +392,7 @@ retry: * pte write and clean while the lock is * dropped. */ - m->ref_count++; + vm_page_wire(m); sfp = NULL; ptep = domain_pgtbl_map_pte(domain, base, lvl - 1, @@ -399,7 +400,7 @@ retry: if (ptep == NULL) { KASSERT(m->pindex != 0, ("loosing root page %p", domain)); - m->ref_count--; + vm_page_unwire_noq(m); iommu_pgfree(domain->pgtbl_obj, m->pindex, flags); return (NULL); @@ -407,8 +408,8 @@ retry: dmar_pte_store(&ptep->pte, DMAR_PTE_R | DMAR_PTE_W | VM_PAGE_TO_PHYS(m)); dmar_flush_pte_to_ram(domain->dmar, ptep); - sf_buf_page(sfp)->ref_count += 1; - m->ref_count--; + vm_page_wire(sf_buf_page(sfp)); + vm_page_unwire_noq(m); iommu_unmap_pgtbl(sfp); /* Only executed once. */ goto retry; @@ -487,7 +488,7 @@ domain_map_buf_locked(struct dmar_domain *domain, iommu_gaddr_t base, dmar_pte_store(&pte->pte, VM_PAGE_TO_PHYS(ma[pi]) | pflags | (superpage ? DMAR_PTE_SP : 0)); dmar_flush_pte_to_ram(domain->dmar, pte); - sf_buf_page(sf)->ref_count += 1; + vm_page_wire(sf_buf_page(sf)); } if (sf != NULL) iommu_unmap_pgtbl(sf); @@ -593,8 +594,7 @@ domain_unmap_clear_pte(struct dmar_domain *domain, iommu_gaddr_t base, int lvl, iommu_unmap_pgtbl(*sf); *sf = NULL; } - m->ref_count--; - if (m->ref_count != 0) + if (!vm_page_unwire_noq(m)) return; KASSERT(lvl != 0, ("lost reference (lvl) on root pg domain %p base %jx lvl %d", @@ -710,7 +710,7 @@ domain_alloc_pgtbl(struct dmar_domain *domain) m = iommu_pgalloc(domain->pgtbl_obj, 0, IOMMU_PGF_WAITOK | IOMMU_PGF_ZERO | IOMMU_PGF_OBJL); /* No implicit free of the top level page table page. */ - m->ref_count = 1; + vm_page_wire(m); DMAR_DOMAIN_PGUNLOCK(domain); DMAR_LOCK(domain->dmar); domain->iodom.flags |= IOMMU_DOMAIN_PGTBL_INITED; @@ -742,8 +742,10 @@ domain_free_pgtbl(struct dmar_domain *domain) /* Obliterate ref_counts */ VM_OBJECT_ASSERT_WLOCKED(obj); - for (m = vm_page_lookup(obj, 0); m != NULL; m = vm_page_next(m)) - m->ref_count = 0; + for (m = vm_page_lookup(obj, 0); m != NULL; m = vm_page_next(m)) { + vm_page_clearref(m); + vm_wire_sub(1); + } VM_OBJECT_WUNLOCK(obj); vm_object_deallocate(obj); } From nobody Sun Jul 21 08:51:56 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRcbd0mbcz5R4mc; Sun, 21 Jul 2024 08:51: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRcbd0Gb9z4mmw; Sun, 21 Jul 2024 08:51:57 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721551917; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ZoH3NCgFSpli4tGNZuy+rGtt02Po9cavXhtVeWSHpbo=; b=J2ps21Hzq+DjmrLnXeSVICPVAyen11GmtQAhJQRkAhQ4F5/A7oIhoqVierUOZCCOMacHEM EBzaLNvr4MNwnlnjpbQzdnciI7I+5INHfLzOZ5YPqlMJ13uIfe1Z1F93F2bgS4RU973wTM cII7gaQLMb2MK7h8YOi5/gPjrhs5Shg3awuZ5BebeEbxGvisCleUBSYq+c8Rw3igXyjwIq rp2V+apYt5PBZoOGxurBwctDTVyj2tydQoLPclcpR4yREFJcj1UmEGAFaZjcOCWPqVKw4+ CnQjwFlsggxF6cG+Kum4GanMMYVgiNQND3P2MzqxHaSPY/JSePKcRgzNHps3pQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721551917; a=rsa-sha256; cv=none; b=FSj3A9mjEf3UCYsGXi7EXs3VUtDlqWPFu88E7OHyIGdIaEWQQo/mNyRNRInx1wZkSNRgNG 4EBF0N3um3ni8yZ8TegHwQ68Su/AqwjyUX1O0PxNQ/npLcg3aT7+lo/63maglOhriJjah1 kl2qA6klJkerp/GOlHxXOIW9pEZeNIIikRvbaI61yKevZPtOwgU3AL3chy2wY0tr4kzmmd dO20DxHjKmVSAcSwjcPWXwcgvSV6Ooc2/bs5phzd834lAzk+6Qzvl9rzsbdjPa3h7GAWaP MeI2Vzd2kY/iGeW+DY837NQpCsxe9RxUtKNH9VML1RvfMRXw9uB8p8mqZNiHqw== 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=1721551917; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ZoH3NCgFSpli4tGNZuy+rGtt02Po9cavXhtVeWSHpbo=; b=Ny67kOEcQiCZo9/5Ff0CHn3ljeJv1Bk4Vi5k3fbeFhDUFFKVY9UxXvxLAEVQfuPvieoEND oT7IZ4fvFIsn39n6OpmezCVmuUin4PtYUeaWrwMXwj/ItM2t/49wKM38zRMWgSmRrIxut8 /iJmjUH1ZCWl3QPII8hrTW+OZvJHwPRl+jaooJL/4vW5ZxvJsJEo1WQJWEfQxNdlHGtK2l XYGPjiWQ/8lHpRyiR9qP1auC6si2gViIytF6kbsjKwpuMMijc/nzfsk0RST23pFCC8vFX3 ptat3hPFOKDBFKmLl/qmDhwwJk7arqHDfJ5lPavNVY1zm3vNmCannFx1kTMdfQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRcbc6srNztGs; Sun, 21 Jul 2024 08:51:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46L8pu9T072662; Sun, 21 Jul 2024 08:51:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46L8pu8L072659; Sun, 21 Jul 2024 08:51:56 GMT (envelope-from git) Date: Sun, 21 Jul 2024 08:51:56 GMT Message-Id: <202407210851.46L8pu8L072659@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: 35f498434322 - main - sockstat(1): tolerate situation where file info cannot be fetched List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 35f4984343229545881a324a00cdbb3980d675ce Auto-Submitted: auto-generated The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=35f4984343229545881a324a00cdbb3980d675ce commit 35f4984343229545881a324a00cdbb3980d675ce Author: Konstantin Belousov AuthorDate: 2024-07-20 00:30:55 +0000 Commit: Konstantin Belousov CommitDate: 2024-07-21 08:51:42 +0000 sockstat(1): tolerate situation where file info cannot be fetched Either due to a race, or to the privilege restrictions, it is not guaranteed that kern.files returned file information for all pcbs read from net.inet..pcblist. In this case the file rbtree does not return the matching file by data address, and code must avoid dereferencing NULL. PR: 279875 Reviewed by: asomers Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D46050 --- usr.bin/sockstat/sockstat.c | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/usr.bin/sockstat/sockstat.c b/usr.bin/sockstat/sockstat.c index 73b1f00a4481..5eac327ca184 100644 --- a/usr.bin/sockstat/sockstat.c +++ b/usr.bin/sockstat/sockstat.c @@ -1164,8 +1164,11 @@ displaysock(struct sock *s, int pos) f = RB_FIND(files_t, &ftree, &(struct file){ .xf_data = p->socket }); - pos += xprintf("[%lu %d]", - (u_long)f->xf_pid, f->xf_fd); + if (f != NULL) { + pos += xprintf("[%lu %d]", + (u_long)f->xf_pid, + f->xf_fd); + } } else pos += printaddr(&p->laddr->address); } @@ -1183,9 +1186,12 @@ displaysock(struct sock *s, int pos) f = RB_FIND(files_t, &ftree, &(struct file){ .xf_data = p->socket }); - pos += xprintf("%s[%lu %d]", - fref ? "" : ",", - (u_long)f->xf_pid, f->xf_fd); + if (f != NULL) { + pos += xprintf("%s[%lu %d]", + fref ? "" : ",", + (u_long)f->xf_pid, + f->xf_fd); + } ref = p->faddr->nextref; fref = false; } From nobody Sun Jul 21 08:53:44 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRcdh3tXxz5R52Y; Sun, 21 Jul 2024 08: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRcdh3MHzz4npD; Sun, 21 Jul 2024 08: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=1721552024; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=AQCm/v38yurgfa0i2lPNvv1X4sDE0rs7jyi1ZwEAYus=; b=tRFK6/Gx94gn6Bj/y/otoiJj11mHN8tfaLo9r5ZtIziXAdtP6jzv66dIUPzqcV5r/FmteO 1qkSpUyK1KEPtXN9ebsJ+y+8uI2hXA9nPzAn5v2st4QGp2Y8iEXWUDns6MRnxGI04y7/aj elTBH0o4kuoAMTn48vFSJqG4xGBFkj2ZZuqxhitDJfAYeJO0k8QEGyd60ox30uXhUr/Qmu Vo4qkeXipLI0SPVp6H8gn90aC9C7RcLxEDz9Wa8ZugpNBpeLsDDi+bmOrZ456/AgZLBAXI k4B3LLt98NmIkkhBl6+ceZWV8g0nSmxqUmEdl9E/H9Tztlsj6xaladMk2Qy3cg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721552024; a=rsa-sha256; cv=none; b=Iyxtbq37/FTx5q5agYIEe+DL2muGHhp9ghUl6Jd3Jp9l6X5NYX/enTa8WKg1qe1XXIFPzV fZV/9EWRA3W95bdFcw9YFl8O8aZQGbLwizYwxVjLMbUE0U4ssDbExKHJ3UMy9coEa8BtiV E4dhcaaFxoPb5lYZmE6GEl35i/q5tIoB6eekY84LUbefAEiEOi3EzSDLzbbQZxuBdtyD+t f61C7ORtsJQNTZeg4w7huZ5yL6QcpOPfVztUTMFIPuPf3iU2hd7Q9oxrKKGzIHW0jZcnFB dfAyOiYpfwTjV0gPjW2nz0wFs46HiXr+YWrqTG9GSiLmW9G1arS5JuXWORXbrQ== 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=1721552024; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=AQCm/v38yurgfa0i2lPNvv1X4sDE0rs7jyi1ZwEAYus=; b=reU1q53yVNCshCPgWdKBsDBMaeL+BERJ5y8mnOqo2oms/e6cs2YgiAOBm6aA7GrfZxVxRW Z8bj5LtAdtsi6iU6Hx7GfyuxqIXA5o9ubNmW/kURmxdC6qEwJlENRbnSBjbjzJ2wPDFJzT 30LJZi49cZ8nnYlvRcKWADm/nFRL1AQUWfUrwCzpq0JvMEG9YNSHj/jztjgwH+isn77Ovv IdwaasPqIQTXKmlNezsacljoEI+nMoeiPcbe5icil1eEp1Bb+org3zDhzq0wqXQV3/rijb GdqgpQ61hCm8RdrPfjQ9ZBlZJoXEIgeZHnTJ9ucZA6dXemzStvoS+s4QUNLKLQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRcdh2xN5ztkM; Sun, 21 Jul 2024 08:53:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46L8rio8074989; Sun, 21 Jul 2024 08:53:44 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46L8riTg074986; Sun, 21 Jul 2024 08:53:44 GMT (envelope-from git) Date: Sun, 21 Jul 2024 08:53:44 GMT Message-Id: <202407210853.46L8riTg074986@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: eb0fdc77533d - main - netinet/ipsec.h: remove unneeded "extern"s List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: eb0fdc77533db88d309a73f67f19222843597267 Auto-Submitted: auto-generated The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=eb0fdc77533db88d309a73f67f19222843597267 commit eb0fdc77533db88d309a73f67f19222843597267 Author: Konstantin Belousov AuthorDate: 2024-07-19 19:11:42 +0000 Commit: Konstantin Belousov CommitDate: 2024-07-21 08:53:19 +0000 netinet/ipsec.h: remove unneeded "extern"s Reviewed by: kp Sponsored by: NVIDIA networking Differential revision: https://reviews.freebsd.org/D46045 --- sys/netipsec/ipsec.h | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/sys/netipsec/ipsec.h b/sys/netipsec/ipsec.h index 55cc0839eab9..dfb334601331 100644 --- a/sys/netipsec/ipsec.h +++ b/sys/netipsec/ipsec.h @@ -353,19 +353,19 @@ int ipsec4_process_packet(struct ifnet *, struct mbuf *, struct secpolicy *, int ipsec_process_done(struct mbuf *, struct secpolicy *, struct secasvar *, u_int); -extern void m_checkalignment(const char* where, struct mbuf *m0, - int off, int len); -extern struct mbuf *m_makespace(struct mbuf *m0, int skip, int hlen, int *off); -extern caddr_t m_pad(struct mbuf *m, int n); -extern int m_striphdr(struct mbuf *m, int skip, int hlen); +void m_checkalignment(const char* where, struct mbuf *m0, + int off, int len); +struct mbuf *m_makespace(struct mbuf *m0, int skip, int hlen, int *off); +caddr_t m_pad(struct mbuf *m, int n); +int m_striphdr(struct mbuf *m, int skip, int hlen); #endif /* _KERNEL */ #ifndef _KERNEL -extern caddr_t ipsec_set_policy(const char *, int); -extern int ipsec_get_policylen(c_caddr_t); -extern char *ipsec_dump_policy(c_caddr_t, const char *); -extern const char *ipsec_strerror(void); +caddr_t ipsec_set_policy(const char *, int); +int ipsec_get_policylen(c_caddr_t); +char *ipsec_dump_policy(c_caddr_t, const char *); +const char *ipsec_strerror(void); #endif /* ! KERNEL */ From nobody Sun Jul 21 08:53:45 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRcdj4pPXz5R4xm; Sun, 21 Jul 2024 08:53: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRcdj3y1Qz4njP; Sun, 21 Jul 2024 08:53:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721552025; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=gxSM0JndpPI4w03fnpPIxfugHlTmATNm//royrZeIQ4=; b=PWJeHNPNbgOkduW6insubUjAJZpxM+fCl7aQiwKqFmS/dFulVaiZ8vCoFt59NdiQyl9yqa D4rLN8YU6OxZ0GH9unGdXQEzkYxbJZPjRVZFvZ+NYOKef+QAlRWB4YXLFYnIKyheWTqF1W UIzMvQc61aglLOM5pS97SIXGioG/DzOtEhzd64WxrdJexQnAjKHGYw/Yuzkq2g5ogh0un8 XRhfMFyp4YcE4TRz7fo4CZovs2B7lwkfMOPEeBvOebmytntUlcvyYG6OWM08PX20nAKLIu GKEMf++N4lRyh8ZIm+Bk995fq2+WrlpY69GExiWh/taVnf7wBD4m/oZvX8ZgRQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721552025; a=rsa-sha256; cv=none; b=fG6BStdtEK6YczdVYNwN3hTJEjviv/R+B+IpyVHlEqfulTsMa7KvBNEU1Qm6k++8hWEPHL T30cqdNKlPI3WaW76ra1JmQ5zPvQfW9VAVJspI4unK5lrVtdJO9sX1H8lSQ+SGgWNe0ZPW 3P/+Tr0yOawQYp6722KAkWTDzDyi+NtK+8hHLHt4WT844Lp/x0/8hf6HMYFAkavcH1aoqg uymPgqQxGrGz2cH5huFpG2XtGVDWoRg874z3+GsidNaMJ1XMJyC3QnmSCHDAzOBGrEmFZn AnvXJ1km5VtzuIozIT+bZAOh0QpN1aNdQUoThYST5EmgMzRVOMPj/XT9RHpNTw== 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=1721552025; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=gxSM0JndpPI4w03fnpPIxfugHlTmATNm//royrZeIQ4=; b=pMB0srnOnSPAmlUPG3dkvfkRAtjrlnensVO972WGslRy5dDrUgq5GfTQCnowz6Jbh2B8HH 4cFVOMd4p/pOMkjntH05mnWwz0ZdMsf2ZoFHkrm+7KEhbbaMdzJXOWetrjWsuuhuJgo7qO 3R0mO2wXQcjHQJtWZhxzi+NdNIJthAvZ2nkYAQmfI3+YWl0x5tdW4eNMGCYfD5JQ3VVbdk 2957u5ChKU23+1vOHajiXvGaRVsGyeuS/Z6jNxNUoO/nqwo3wWa5Q9ppM+Z/6YOnXEHhem 1kUPxETFQt9J1a3zQj0Fn6k92Fv5HbfFnPbC5mMQ71McInZkeuzvUyHNtBLXFQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRcdj3YRrztdg; Sun, 21 Jul 2024 08:53:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46L8rjg1075047; Sun, 21 Jul 2024 08:53:45 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46L8rjvE075044; Sun, 21 Jul 2024 08:53:45 GMT (envelope-from git) Date: Sun, 21 Jul 2024 08:53:45 GMT Message-Id: <202407210853.46L8rjvE075044@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: 6023bd1d52b6 - main - netipsec: move declaration of the sysctl net.inet{,6}.ipsec nodes to header List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 6023bd1d52b6b928927f9d2c0e3017687b29a731 Auto-Submitted: auto-generated The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=6023bd1d52b6b928927f9d2c0e3017687b29a731 commit 6023bd1d52b6b928927f9d2c0e3017687b29a731 Author: Konstantin Belousov AuthorDate: 2024-07-19 19:14:41 +0000 Commit: Konstantin Belousov CommitDate: 2024-07-21 08:53:19 +0000 netipsec: move declaration of the sysctl net.inet{,6}.ipsec nodes to header Reviewed by: kp Sponsored by: NVIDIA networking Differential revision: https://reviews.freebsd.org/D46045 --- sys/netipsec/ipsec.c | 4 ---- sys/netipsec/ipsec.h | 4 ++++ 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/sys/netipsec/ipsec.c b/sys/netipsec/ipsec.c index e22a3872d48d..9b18cedc7a80 100644 --- a/sys/netipsec/ipsec.c +++ b/sys/netipsec/ipsec.c @@ -172,8 +172,6 @@ VNET_DEFINE(int, natt_cksum_policy) = 0; FEATURE(ipsec, "Internet Protocol Security (IPsec)"); FEATURE(ipsec_natt, "UDP Encapsulation of IPsec ESP Packets ('NAT-T')"); -SYSCTL_DECL(_net_inet_ipsec); - /* net.inet.ipsec */ SYSCTL_PROC(_net_inet_ipsec, IPSECCTL_DEF_POLICY, def_policy, CTLTYPE_INT | CTLFLAG_VNET | CTLFLAG_RW | CTLFLAG_NEEDGIANT, @@ -257,8 +255,6 @@ VNET_DEFINE(int, ip6_ipsec_ecn) = 0; /* ECN ignore(-1)/forbidden(0)/allowed(1) * VNET_DEFINE_STATIC(int, ip6_filtertunnel) = 0; #define V_ip6_filtertunnel VNET(ip6_filtertunnel) -SYSCTL_DECL(_net_inet6_ipsec6); - /* net.inet6.ipsec6 */ SYSCTL_PROC(_net_inet6_ipsec6, IPSECCTL_DEF_POLICY, def_policy, CTLTYPE_INT | CTLFLAG_VNET | CTLFLAG_RW | CTLFLAG_NEEDGIANT, diff --git a/sys/netipsec/ipsec.h b/sys/netipsec/ipsec.h index dfb334601331..749813518092 100644 --- a/sys/netipsec/ipsec.h +++ b/sys/netipsec/ipsec.h @@ -46,6 +46,7 @@ #include #include #include +#include #define IPSEC_ASSERT(_c,_m) KASSERT(_c, _m) @@ -359,6 +360,9 @@ struct mbuf *m_makespace(struct mbuf *m0, int skip, int hlen, int *off); caddr_t m_pad(struct mbuf *m, int n); int m_striphdr(struct mbuf *m, int skip, int hlen); +SYSCTL_DECL(_net_inet_ipsec); +SYSCTL_DECL(_net_inet6_ipsec6); + #endif /* _KERNEL */ #ifndef _KERNEL From nobody Sun Jul 21 08:53:46 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRcdk5SQwz5R50N; Sun, 21 Jul 2024 08:53: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRcdk4gF8z4nXp; Sun, 21 Jul 2024 08:53:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721552026; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=wTMc5kByKm8nz6JeVjYpKcbK1dtjFAteOFWRTOH/g4c=; b=NroHZ1bC9wcHkk2LnIQ0olYgG12cUmTZ14o/O4pUT10GAwwZ7+sBjYw9ytBB7qcCF3ptK2 bPFYYkTkM4N5nNHbWbUb1YxCHRLuhQ/cHYtrSoDpYaTMpgaXnkcLfYSrBOOU5Q7cEQTFS3 qxPEjBJYNKQc1Z+/u3hH5MzgTFezsHfavQvCDRBrqaBXoOD+7FDkT+oUUAKgm6sqOvTYFU NTgq0+8pqO5vhCcXJSLjDKWCfYoBpbBEft91bQKyXBkM53zN36ur/PkxG+Po9vCduVzcGn OJJFdX28Cy6y+zGRJUhPObH2G70NcFoZoZyeoXt96/dEM6LOAOlFPgcpgCjuXA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721552026; a=rsa-sha256; cv=none; b=OSj0twtVjCQCvZglzAyjPRuN72eKz4+Av/0V4dNVVLU7kMGfuKGKIXboof2O/lzcMLVcIG YU9k1nBI6Lt7Enf3ESr4Xnj+NYS4jorTB+I/Hr03Ogwjt46uXmdFNmbWIndNC9ikMeE90Z 719g8ECrtJY8PSFAI5LA0rzX6aaEc6FXM+hnsmeDDDsFYk9NT4ANWyxvc00kkVJIXzI49a ommdQCbfMfsxvTk+/ne+XZtCdCQfWx43QVRsXIOWhESWSmXfn5xmtB2LLrAOLlFhCKQia+ VRoJLxtsqpniHlsmRWYYJKfdRhTJDwOIBgK3xoFsb4RZxQPAAL90WID1fAp0jA== 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=1721552026; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=wTMc5kByKm8nz6JeVjYpKcbK1dtjFAteOFWRTOH/g4c=; b=Tx/aLXxa9X3//B/ZixP6wYl+E7W9Y95B8nGvWlE4bnChqO4PTTE4a6+JwkOyIabHfXM0lB cbj0Id8SoCJIAkeHIvAvXMXhmtbzEJOhS5u4geMHsbkUwIAe7l3qeJ1ryaxAMRaCSv/ZTF JVXsIgWNckHcAUgFdShPXnW+VX8giT7w886fvl2CzNgzytAo8HA7EHDZ6FFECJjiNSDIU5 30u7tGzDgEEa6j6qF0VQs6C7Et626cYPl2wri9rg5prigeZU/GCyrQ0LBTgVNgwHragmVL F4CW77LQ6rUbo6gGIQGCrE2Zz3sjEllq/EGTfra5TcBXUYB0fKJBh9//qkGWpQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRcdk4FT7zswT; Sun, 21 Jul 2024 08:53:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46L8rkRd075105; Sun, 21 Jul 2024 08:53:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46L8rkoh075102; Sun, 21 Jul 2024 08:53:46 GMT (envelope-from git) Date: Sun, 21 Jul 2024 08:53:46 GMT Message-Id: <202407210853.46L8rkoh075102@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: 9a7096ff547d - main - ipsec_offload: hide SA/SP offload lifecycle prints under verbose sysctl List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9a7096ff547de2b5a09c5a4683853568e08c2f8a Auto-Submitted: auto-generated The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=9a7096ff547de2b5a09c5a4683853568e08c2f8a commit 9a7096ff547de2b5a09c5a4683853568e08c2f8a Author: Konstantin Belousov AuthorDate: 2024-07-19 19:15:35 +0000 Commit: Konstantin Belousov CommitDate: 2024-07-21 08:53:19 +0000 ipsec_offload: hide SA/SP offload lifecycle prints under verbose sysctl Reported and reviewed by: kp Discussed with: np Sponsored by: NVIDIA networking Differential revision: https://reviews.freebsd.org/D46045 --- sys/netipsec/ipsec_offload.c | 58 +++++++++++++++++++++++++++++++------------- 1 file changed, 41 insertions(+), 17 deletions(-) diff --git a/sys/netipsec/ipsec_offload.c b/sys/netipsec/ipsec_offload.c index 48082830b88b..8ccae7a94f2a 100644 --- a/sys/netipsec/ipsec_offload.c +++ b/sys/netipsec/ipsec_offload.c @@ -35,9 +35,12 @@ #include #include #include +#include #include #include +#include + #include #include #include @@ -190,6 +193,27 @@ ipsec_accel_fini(void *arg) SYSUNINIT(ipsec_accel_fini, SI_SUB_VNET_DONE, SI_ORDER_ANY, ipsec_accel_fini, NULL); +SYSCTL_NODE(_net_inet_ipsec, OID_AUTO, offload, CTLFLAG_RW | CTLFLAG_MPSAFE, 0, + ""); + +static bool ipsec_offload_verbose = false; +SYSCTL_BOOL(_net_inet_ipsec_offload, OID_AUTO, verbose, CTLFLAG_RW, + &ipsec_offload_verbose, 0, + "Verbose SA/SP offload install and deinstall"); + +static void +dprintf(const char *fmt, ...) +{ + va_list ap; + + if (!ipsec_offload_verbose) + return; + + va_start(ap, fmt); + vprintf(fmt, ap); + va_end(ap); +} + static void ipsec_accel_alloc_forget_tq(struct secasvar *sav) { @@ -209,7 +233,7 @@ ipsec_accel_sa_install_match(if_t ifp, void *arg) if ((ifp->if_capenable2 & IFCAP2_BIT(IFCAP2_IPSEC_OFFLOAD)) == 0) return (false); if (ifp->if_ipsec_accel_m->if_sa_newkey == NULL) { - printf("driver bug ifp %s if_sa_newkey NULL\n", + dprintf("driver bug ifp %s if_sa_newkey NULL\n", if_name(ifp)); return (false); } @@ -226,7 +250,7 @@ ipsec_accel_sa_newkey_cb(if_t ifp, void *arg) tq = arg; - printf("ipsec_accel_sa_newkey_act: ifp %s h %p spi %#x " + dprintf("ipsec_accel_sa_newkey_act: ifp %s h %p spi %#x " "flags %#x seq %d\n", if_name(ifp), ifp->if_ipsec_accel_m->if_sa_newkey, be32toh(tq->sav->spi), tq->sav->flags, tq->sav->seq); @@ -240,7 +264,7 @@ ipsec_accel_sa_newkey_cb(if_t ifp, void *arg) } if (drv_spi == -1) { /* XXXKIB */ - printf("ipsec_accel_sa_install_newkey: cannot alloc " + dprintf("ipsec_accel_sa_install_newkey: cannot alloc " "drv_spi if %s spi %#x\n", if_name(ifp), be32toh(tq->sav->spi)); return (ENOMEM); @@ -249,14 +273,14 @@ ipsec_accel_sa_newkey_cb(if_t ifp, void *arg) drv_spi, &priv); if (error != 0) { if (error == EOPNOTSUPP) { - printf("ipsec_accel_sa_newkey: driver " + dprintf("ipsec_accel_sa_newkey: driver " "refused sa if %s spi %#x\n", if_name(ifp), be32toh(tq->sav->spi)); error = ipsec_accel_handle_sav(tq->sav, ifp, drv_spi, priv, IFP_HS_REJECTED, NULL); /* XXXKIB */ } else { - printf("ipsec_accel_sa_newkey: driver " + dprintf("ipsec_accel_sa_newkey: driver " "error %d if %s spi %#x\n", error, if_name(ifp), be32toh(tq->sav->spi)); /* XXXKIB */ @@ -266,7 +290,7 @@ ipsec_accel_sa_newkey_cb(if_t ifp, void *arg) drv_spi, priv, IFP_HS_HANDLED, NULL); if (error != 0) { /* XXXKIB */ - printf("ipsec_accel_sa_newkey: handle_sav " + dprintf("ipsec_accel_sa_newkey: handle_sav " "err %d if %s spi %#x\n", error, if_name(ifp), be32toh(tq->sav->spi)); } @@ -324,13 +348,13 @@ ipsec_accel_sa_newkey_impl(struct secasvar *sav) SADB_KEY_ACCEL_DEINST)) != 0) return; - printf( + dprintf( "ipsec_accel_sa_install_newkey: spi %#x flags %#x seq %d\n", be32toh(sav->spi), sav->flags, sav->seq); tq = malloc(sizeof(*tq), M_TEMP, M_NOWAIT); if (tq == NULL) { - printf("ipsec_accel_sa_install_newkey: no memory for tq, " + dprintf("ipsec_accel_sa_install_newkey: no memory for tq, " "spi %#x\n", be32toh(sav->spi)); /* XXXKIB */ return; @@ -403,7 +427,7 @@ ipsec_accel_forget_handle_sav(struct ifp_handle_sav *i, bool freesav) sav = i->sav; if ((i->flags & (IFP_HS_HANDLED | IFP_HS_REJECTED)) == IFP_HS_HANDLED) { - printf("sa deinstall %s %p spi %#x ifl %#x\n", + dprintf("sa deinstall %s %p spi %#x ifl %#x\n", if_name(ifp), sav, be32toh(sav->spi), i->flags); ifp->if_ipsec_accel_m->if_sa_deinstall(ifp, i->drv_spi, i->ifdata); @@ -597,18 +621,18 @@ ipsec_accel_spdadd_cb(if_t ifp, void *arg) sp = arg; inp = sp->ipsec_accel_add_sp_inp; - printf("ipsec_accel_spdadd_cb: ifp %s m %p sp %p inp %p\n", + dprintf("ipsec_accel_spdadd_cb: ifp %s m %p sp %p inp %p\n", if_name(ifp), ifp->if_ipsec_accel_m->if_spdadd, sp, inp); error = ipsec_accel_remember_sp(sp, ifp, &i); if (error != 0) { - printf("ipsec_accel_spdadd: %s if_spdadd %p remember res %d\n", + dprintf("ipsec_accel_spdadd: %s if_spdadd %p remember res %d\n", if_name(ifp), sp, error); return (error); } error = ifp->if_ipsec_accel_m->if_spdadd(ifp, sp, inp, &i->ifdata); if (error != 0) { i->flags |= IFP_HP_REJECTED; - printf("ipsec_accel_spdadd: %s if_spdadd %p res %d\n", + dprintf("ipsec_accel_spdadd: %s if_spdadd %p res %d\n", if_name(ifp), sp, error); } return (error); @@ -676,11 +700,11 @@ ipsec_accel_spddel_act(void *arg, int pending) NET_EPOCH_WAIT(); if ((i->flags & (IFP_HP_HANDLED | IFP_HP_REJECTED)) == IFP_HP_HANDLED) { - printf("spd deinstall %s %p\n", if_name(i->ifp), sp); + dprintf("spd deinstall %s %p\n", if_name(i->ifp), sp); error = i->ifp->if_ipsec_accel_m->if_spddel(i->ifp, sp, i->ifdata); if (error != 0) { - printf( + dprintf( "ipsec_accel_spddel: %s if_spddel %p res %d\n", if_name(i->ifp), sp, error); } @@ -741,12 +765,12 @@ ipsec_accel_on_ifdown_sp(struct ifnet *ifp) NET_EPOCH_WAIT(); if ((i->flags & (IFP_HP_HANDLED | IFP_HP_REJECTED)) == IFP_HP_HANDLED) { - printf("spd deinstall %s %p\n", if_name(ifp), sp); + dprintf("spd deinstall %s %p\n", if_name(ifp), sp); error = ifp->if_ipsec_accel_m->if_spddel(ifp, sp, i->ifdata); } if (error != 0) { - printf( + dprintf( "ipsec_accel_on_ifdown_sp: %s if_spddel %p res %d\n", if_name(ifp), sp, error); } @@ -894,7 +918,7 @@ ipsec_accel_input(struct mbuf *m, int offset, int proto) if (tag->drv_spi < IPSEC_ACCEL_DRV_SPI_MIN || tag->drv_spi > IPSEC_ACCEL_DRV_SPI_MAX) { - printf("if %s mbuf %p drv_spi %d invalid, packet dropped\n", + dprintf("if %s mbuf %p drv_spi %d invalid, packet dropped\n", (m->m_flags & M_PKTHDR) != 0 ? if_name(m->m_pkthdr.rcvif) : "", m, tag->drv_spi); m_freem(m); From nobody Sun Jul 21 08:58:05 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRckj3QZWz5R5Cy; Sun, 21 Jul 2024 08:58: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRckj2fvbz4pnH; Sun, 21 Jul 2024 08:58:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721552285; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ty9VDF6jO4m27rcGwVYkXJjd4tjFRiGGpah9AN4k+2k=; b=UxsTn0CNTn0qUPz6XOd34rRdsLi0kD63uSciWT4Y8FgnuyjAQZji3B8x8Wt3YLMqQ7rtOJ 5s7uguGxgBOIXI9zLqbb8JbpDj5NHVaBiVIkLPQce2ihtX3sOL5fFXo3vJvafZEjJswgPL 8Q+e+aHUSuLJVU50HPd8UqgTeI6nl5rgmTDX8ZDVg77DtrSY4ihLNqxLJva8l3Qw714hIn yQD8f6cD1H7OribtB7QmTgR0EPrfKdaL2rH1udd9eaiiJvQ6xNU7NQkpwD033vKfeJCbF5 XIbC9My+9Tsx8DQ/DmK9jWzuxz7WiJcqlB2gys8mG4/YopFgXdZB1CQ7JbSogw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721552285; a=rsa-sha256; cv=none; b=bocDM3bbwwtrBIjcSGzApdITN3++zJPwFE8KUA5ZFtK3scnLtut5ygZ1caXBAQlwvpVy9q jaIOLrbBKunInDrTJXT4cAhGwHjN6TdqTVRXw7naoNIR1vJBCE6VzcMuh/R6hQbiSToF3I TonbOlIIITTIdzzQUH+xa3+fauvxtwkG2SxCWxl3SA3vrw8uH7mbC7mpVjoPfJ+OVgzDqy RZqruMETgo8G25e1mvdnwaI7IixM3O2GCLmkZYtRqYcP8jXYWt2n3ji/TOVu1aJ39BuiqO xRGESZMFzNnZMEVualrtDqD/hpbFNrkl69RtgbkyIz9L2O6u2Z2ieraV1rKwOg== 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=1721552285; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ty9VDF6jO4m27rcGwVYkXJjd4tjFRiGGpah9AN4k+2k=; b=ZZFlXKUA0KZ24mgPNzTUNAObY/z+z7QcZYY00FBT/B16z/vS3861E0k2e5+R+xWHnE6O0j j8gSmUS6AVzy/WouAfx1p09sxgRKjXWUKXk5MMIWn2FpZQ9CxZtwi7r0+5kp2geeaLqnzY iEXvSeDHoogvLKdO8esi1bkc6dxyXCoDoWLXzkHAnrechcb6vz4jM/id5ttTel5VEGbsZB +4kla9id6LH+PdonKjVhiHd8/V19GKpqxiL2mAYNzq/hFN2wj01ZYTMvd2PSNtAUhMhSpE hvVyG7xVUtBPhOhx7Feppaju22PMgxMbUMVRGL68xLuq/WgVqQEGoAuuSYEZCg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRckj1w0Xzt5W; Sun, 21 Jul 2024 08:58:05 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46L8w5QN075855; Sun, 21 Jul 2024 08:58:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46L8w59I075852; Sun, 21 Jul 2024 08:58:05 GMT (envelope-from git) Date: Sun, 21 Jul 2024 08:58:05 GMT Message-Id: <202407210858.46L8w59I075852@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Gordon Bergling Subject: git: 58c99e07506e - main - sctp(4): Fix typos in source code comments List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gbe X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 58c99e07506e67c06d703b080c2fc22cc39237f2 Auto-Submitted: auto-generated The branch main has been updated by gbe: URL: https://cgit.FreeBSD.org/src/commit/?id=58c99e07506e67c06d703b080c2fc22cc39237f2 commit 58c99e07506e67c06d703b080c2fc22cc39237f2 Author: Gordon Bergling AuthorDate: 2024-07-21 08:57:22 +0000 Commit: Gordon Bergling CommitDate: 2024-07-21 08:57:22 +0000 sctp(4): Fix typos in source code comments - s/collasped/collapsed/ - s/defininitions/definitions/ - s/optionaly/optionally/ Obtained from: NetBSD MFC after: 3 days --- sys/netinet6/sctp6_usrreq.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/netinet6/sctp6_usrreq.c b/sys/netinet6/sctp6_usrreq.c index e3ed37b53425..0f194821ea94 100644 --- a/sys/netinet6/sctp6_usrreq.c +++ b/sys/netinet6/sctp6_usrreq.c @@ -359,7 +359,7 @@ sctp6_ctlinput(struct ip6ctlparam *ip6cp) } /* - * this routine can probably be collasped into the one in sctp_userreq.c + * this routine can probably be collapsed into the one in sctp_userreq.c * since they do the same thing and now we lookup with a sockaddr */ static int @@ -721,8 +721,8 @@ connected_type: * note with the current version this code will only be used * by OpenBSD, NetBSD and FreeBSD have methods for * re-defining sosend() to use sctp_sosend(). One can - * optionaly switch back to this code (by changing back the - * defininitions but this is not advisable. + * optionally switch back to this code (by changing back the + * definitions but this is not advisable. */ struct epoch_tracker et; int ret; From nobody Sun Jul 21 09:01:36 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRcpn0bYxz5R5Vs; Sun, 21 Jul 2024 09:01: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRcpm6Ndmz4q1w; Sun, 21 Jul 2024 09:01:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721552496; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Ut+eQSiiIrr9D4nj7Cixc2iF14KiFHKvRwspvkQnRK4=; b=cvgytKTnlczh9tGJ2AGykLfNY0sy+aEXoWtnoj3zyjXloRH4I7shATcwIkh4nY/1c+Wfnw tNW1tByBlMNe0nQv2BhyoppO+IF5bwZ6HoDALWMT/7/6O5tAszJDq8MmvZd4KS+I2s/PKx QbQMYiSOinCPusI1SL7fzom+/RI3D3d+2GMKc08l9t1I/i6IRmioWxVcOWNfzFrQeuku/x 1GIiA56m9pZ6yTrj0H82bJisPAlk5VYjm7Gm70Qz9QD5jmxzSkHDUwpUz+Da6Yq71KpmGK MBa98RYzdq4cQ8BbR4C8pRpEc4405qJT2gLBFcXZbrpO4HSNrxp9UF08coBTuA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721552496; a=rsa-sha256; cv=none; b=ECu6TDU7fq1HfWQXJPnjRSKzOO2G7KSHBk/natqf1s1sKQHSABdNlUf2z79wyg7greXYXp /woiraoxlpQaqx0WQqiRwO6AZJR6L9O4vrUJTOZFzqL1O/amPtr5sz40BGpfpdAi3A0dbK 6TcIe/pqoH5DmWNnCFYJ3M3TN42gI0H6yzjGGfW6x83+YSNmGiDLp8AuB0U5m5iIJbN+6z +KewX7WPZgr5KzrBqsmoFejIBH/5qvVGUwU48LgCqsC4Fz34ICBicYctmlrmOlpa7ZPamv X4AOTZ++sj1G/r+gwP65nL5wEJCr7kwvPY8axcuynnjbqtwP+CGdin5Tpkew6Q== 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=1721552496; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Ut+eQSiiIrr9D4nj7Cixc2iF14KiFHKvRwspvkQnRK4=; b=opn8YEUnji55BZDxnLirD8lTrYV5wJ+A0oW5oDpvOcSllSSY90PNP/2wAxBesVaOpZvPee DBy+JwoN/G9YS9/4lY3vjkz+dPcJFIDb8NlnkvD12ekWGvPloEFUT+E9AewFeSiQOx3P4D ZFbkN76avYUtdLxYOLfkEg3UusQd5HAC4RuOxiQsG777DC43x5wZq7UTEEm/6ORuodRd0V DND8iAsoBXEyq+w9Kr1m+EvcgcUoo5GR+Dw6NTiGZFiaQPtVMM6UpRHJupMQhBN9FqBsBz DZdfMvkHVwJuIaZqtDgIxO6AiLnQH8pDhjjSrmMr97VO1Cr8xTo7TK8UkeX5cw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRcpm5GY5ztbG; Sun, 21 Jul 2024 09:01:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46L91aYF088958; Sun, 21 Jul 2024 09:01:36 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46L91a8Y088955; Sun, 21 Jul 2024 09:01:36 GMT (envelope-from git) Date: Sun, 21 Jul 2024 09:01:36 GMT Message-Id: <202407210901.46L91a8Y088955@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Gordon Bergling Subject: git: 32a9b95a8751 - main - stress2: Fix a typo in namecache2.sh List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gbe X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 32a9b95a8751f916deef5970476f010995244bfe Auto-Submitted: auto-generated The branch main has been updated by gbe: URL: https://cgit.FreeBSD.org/src/commit/?id=32a9b95a8751f916deef5970476f010995244bfe commit 32a9b95a8751f916deef5970476f010995244bfe Author: Gordon Bergling AuthorDate: 2024-07-21 09:00:58 +0000 Commit: Gordon Bergling CommitDate: 2024-07-21 09:00:58 +0000 stress2: Fix a typo in namecache2.sh - s/inconsistancy/inconsistency/ MFC after: 3 days --- tools/test/stress2/misc/namecache2.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/test/stress2/misc/namecache2.sh b/tools/test/stress2/misc/namecache2.sh index 9fcfe5e0226c..b32d41974468 100755 --- a/tools/test/stress2/misc/namecache2.sh +++ b/tools/test/stress2/misc/namecache2.sh @@ -26,7 +26,7 @@ # SUCH DAMAGE. # -# UFS cache inconsistancy for rename(2) demonstrated +# UFS cache inconsistency for rename(2) demonstrated # Fails with: # ls -ali /mnt # ls: tfa1022: No such file or directory From nobody Sun Jul 21 09:02:49 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRcr939ftz5R69K; Sun, 21 Jul 2024 09:02: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRcr92ckVz4qfC; Sun, 21 Jul 2024 09:02:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721552569; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=fEJVnjm25i86Ud2sJvTckTL3cQekNAv9oYeN9jGXCqw=; b=n/jnM45/JhJ7KTpjb2y7YFNNjGWSwWfbfB0w1TbXT3nX5uhrSzdQ6/3h0IxxL2qS80Smd4 o4jo9E0QaarnAIp7KmkCOXbviXRYP1d+tXA2LlzhHoptWP89KJejlHjUVEAL4df6LeXi3A yceJAEzM+qKRl1xneWMx+DFzKw20HiPl7L0qMyF4mN4viQX7zsZumJHNXzR6FqGjQRSqhf m6bNjOKgKGa4QExSDPKzZ2SOqNxueka62JkYs+BIqq4Z6LDdXlh1cGCoHLLJ+qtrmbB+HG 3Qb1azeqTbaiPsptwZfv+oknFnDxxatCeciaiF+OBUAvLkzLhWtmvhVEKmAUnQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721552569; a=rsa-sha256; cv=none; b=EiknmY9iiMjeLuTAHY2WTi+i0rB2g7RKRlDDpR3WMSHgYNpw1XWhQS/BP5F3tVOdmZ7AIb xchZy/e55ypEdF64gZAxrhR1l1n0WE024r+Y0Sj74jl7HyggBcVoFSXRfdEk4PpSWDxHXE H4t82FBT57Idu6LkTLzLWT1cZ5r/6LzpU+Dv+yH9YJ6bAUOizE+7kVI7+zCxUsr+iIr/cK za6azRoGfniEVH5ZKfUJuPph686rup6cnqKyOEOhjhQJFByF6CbD/hIlVkZTiTqb3ybI5T INAfT5b9BibdhWb+CYfEJy9Qxyew9dY87f5y5j+OmAMUtOls5lPdNm4cPfYx+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=1721552569; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=fEJVnjm25i86Ud2sJvTckTL3cQekNAv9oYeN9jGXCqw=; b=uvpzpD3lfqS2U3YM1VCuSs7Fc4VQz2SuIGfoM/VzT3LqJAlxAs0OpLxQujWuIzL6+m8uMZ L8j2p5A3mfyHHVN/u+dBwOBffFCsiqCTzG1F18Bn7FmuMe/a1z3sz5iHqOcjF9LbCNhROq 4RhgTRBSwnsRm1XJSfYNvIYMPJk9+sw4NHw0CD12LB/Zg6fgmHirgm/G+Pk7StHtKh3B8/ JDWyr8x2v+jJtTV9UAZ3oArnvNNVlE78tA3pM8dwoIGhRv9er7+HSjdnIjdf4Lfdl09Gm4 n525TpH9B2I8Ial++ucr2W0dvnw6qmLzlyIZEy9AZRGrerqzYtNH8sW4Zc37hA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRcr927b2ztqq; Sun, 21 Jul 2024 09:02:49 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46L92n2W092664; Sun, 21 Jul 2024 09:02:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46L92nJ5092661; Sun, 21 Jul 2024 09:02:49 GMT (envelope-from git) Date: Sun, 21 Jul 2024 09:02:49 GMT Message-Id: <202407210902.46L92nJ5092661@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Gordon Bergling Subject: git: c90a206496fc - main - ipfilter(4): Fix typos in source code comments List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gbe X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: c90a206496fc431854e0c2989c2214b048e960d5 Auto-Submitted: auto-generated The branch main has been updated by gbe: URL: https://cgit.FreeBSD.org/src/commit/?id=c90a206496fc431854e0c2989c2214b048e960d5 commit c90a206496fc431854e0c2989c2214b048e960d5 Author: Gordon Bergling AuthorDate: 2024-07-21 09:02:31 +0000 Commit: Gordon Bergling CommitDate: 2024-07-21 09:02:31 +0000 ipfilter(4): Fix typos in source code comments - s/inconsistancy/inconsistency/ MFC after: 3 days --- sys/netpfil/ipfilter/netinet/mlfk_ipl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/netpfil/ipfilter/netinet/mlfk_ipl.c b/sys/netpfil/ipfilter/netinet/mlfk_ipl.c index 69be4abb2485..1c3051fb6615 100644 --- a/sys/netpfil/ipfilter/netinet/mlfk_ipl.c +++ b/sys/netpfil/ipfilter/netinet/mlfk_ipl.c @@ -536,7 +536,7 @@ ipfclose(dev_t dev, int flags) /* * ipfread/ipflog * both of these must operate with at least splnet() lest they be - * called during packet processing and cause an inconsistancy to appear in + * called during packet processing and cause an inconsistency to appear in * the filter lists. */ #ifdef __FreeBSD__ @@ -579,7 +579,7 @@ static int ipfread(dev, uio, ioflag) /* * ipfwrite * both of these must operate with at least splnet() lest they be - * called during packet processing and cause an inconsistancy to appear in + * called during packet processing and cause an inconsistency to appear in * the filter lists. */ #ifdef __FreeBSD__ From nobody Sun Jul 21 09:06:29 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRcwP2rpVz5R6Pv; Sun, 21 Jul 2024 09:06: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRcwP2MzVz4r5Y; Sun, 21 Jul 2024 09:06:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721552789; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=PKyoPQy4YUcYETNMx6qbpur+avt5GgAXKCZAqV3IjeY=; b=Tempj1P7NS2b2t3VCcqOr7dHb/PRu5voMgIoROqzsOKTJqYp+qYhmy0r/QhVPPT+CHm1sc aCPZkyc6v1kvzbRctVfH89dpTwOx+IQ+4q9WNznyYF4nSL5TRYDq+pXjYgw6H/IjOhgSfs ejT1vuWkPqlQ0QTt671Z7lMDAAfxEkC3xod1po6iiUHvzOJ7NIPuEDQRKKr5bNVE4GR54+ dw+o7Fgo/DdmV0OT/y3lQ1btSddfmgu1sTIBNxtNTOARoNrqk4GHxUhZ/l4/6d1WXbZtLa M4e1ugs/vpLjIZUh/T23IXfidFKM9al88ElJS+LRjcFOl6mx5WVftOsYr1TXdA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721552789; a=rsa-sha256; cv=none; b=YMsgIP/Qp7tLEHcpQ8sTDCvGJSGLQPM6m71xCIAoBt4+1hmjrGKpPEn2nYN5Jw4YK0JQcw JStp6tBzuen3Tbe2cPgSx5jtIl9GU+JdSqhYCPFu4WIjrmEC1fOhPrdlLrCQT+ayAepltM OK+HuYXqBAUdNS4KEoP/0nz+kWF96Z7PBezdS5RX4XbOtBzDtU0c0m5gbHYIuK6lz78ykf kr8N8AXoSni6mjpgWEFhwKoyroCU3hU8D1AgJUCnEtFhcef9gocUfdEv44tEJrdkukgeh0 a60y9mwAO3ibGYni/LxpttV1A9DdVjJugi1QpQTCtZfxZfdCrKCN1Qv0Fh3yIA== 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=1721552789; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=PKyoPQy4YUcYETNMx6qbpur+avt5GgAXKCZAqV3IjeY=; b=eGTeemN1ghLIBXJ8pfjCoIwd1qAWsP9lixMRUMKYEigxtkWwo4w51DIXJYSliVygPXghAz GiK3j+7R3SltlpA0PIHs2LBmFEBOz1amEOElVt6qGgk8klT7zLui7VYmgEFqNeufpn9CAC tXS9T82e7BQ3rcbQtZ+TNfPq8XT3Fv7N84ZghNLleJojHbWTRW62bzoAZbAT6B0fKeszVw 3676kDaHkU2P5VGi2+gwv2tz0tDAOlAG+hlTBk1BKl8HA75WrDQz5HhpTTSqjrqxX0/HUe CfOEoXcZAj/k+5qmYZrpUcbh0Jo0LNGQdbPO85oZihRZtabKyBz7AQi3S8njyg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRcwP1sDvzv0k; Sun, 21 Jul 2024 09:06:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46L96Toq093299; Sun, 21 Jul 2024 09:06:29 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46L96Tbv093296; Sun, 21 Jul 2024 09:06:29 GMT (envelope-from git) Date: Sun, 21 Jul 2024 09:06:29 GMT Message-Id: <202407210906.46L96Tbv093296@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Gordon Bergling Subject: git: 619c9488a31c - main - axgbe: Fix two typos in source code comments List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gbe X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 619c9488a31ce14c6570d2e31f70d416382ed7a6 Auto-Submitted: auto-generated The branch main has been updated by gbe: URL: https://cgit.FreeBSD.org/src/commit/?id=619c9488a31ce14c6570d2e31f70d416382ed7a6 commit 619c9488a31ce14c6570d2e31f70d416382ed7a6 Author: Gordon Bergling AuthorDate: 2024-07-21 09:06:07 +0000 Commit: Gordon Bergling CommitDate: 2024-07-21 09:06:07 +0000 axgbe: Fix two typos in source code comments - s/specfied/specified/ MFC after: 3 days --- sys/dev/axgbe/xgbe-phy-v2.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/dev/axgbe/xgbe-phy-v2.c b/sys/dev/axgbe/xgbe-phy-v2.c index d08ed118a8a8..5b39d61694e6 100644 --- a/sys/dev/axgbe/xgbe-phy-v2.c +++ b/sys/dev/axgbe/xgbe-phy-v2.c @@ -500,7 +500,7 @@ xgbe_phy_i2c_write(struct xgbe_prv_data *pdata, unsigned int target, void *val, retry = 1; again: - /* Write the specfied register */ + /* Write the specified register */ i2c_op.cmd = XGBE_I2C_CMD_WRITE; i2c_op.target = target; i2c_op.len = val_len; @@ -539,7 +539,7 @@ again1: retry = 1; again2: - /* Read the specfied register */ + /* Read the specified register */ i2c_op.cmd = XGBE_I2C_CMD_READ; i2c_op.target = target; i2c_op.len = val_len; From nobody Sun Jul 21 09:46:24 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRdpj6DThz5R9j8; Sun, 21 Jul 2024 09:46:37 +0000 (UTC) (envelope-from kp@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRdpj5KHrz4tyG; Sun, 21 Jul 2024 09:46:37 +0000 (UTC) (envelope-from kp@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721555197; 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=4lCbD59s7sGlwRUQjAmaWwjdD6T85E0gyWGYRewuRxM=; b=MlF65gS6tYD/mRw6Uwu07I/ubH8nFrZFVnM0JG7AFJ6XbSQs4xplS15AEWLDjXM8VhUrNk DKhForp1dL9DtLNKqyqaj2G3G9sfzopURE7ymqF6IUrN0bSjEa8Ki7dWcrakTPX6yjC5sq vtUVs0E2EiUfRvxtnfc52H/yfSqX++6VwdBlEjOnvvaaof7+a1JwdxZ3KQ5VNh4EZshdws /VsSr+xrAaY+CiRk6xuDfOF/S4mFvD+NXdwwmsu/W9U96qp2WsxYc3mMOOyuzWUWdvZ5lv Xqa5S2O21jm4J3e5I12rXhLvt05DO0RFDRdToQ+vTozXi8FKHb5bjM0de0o6TQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721555197; a=rsa-sha256; cv=none; b=GW718S0/iFlG2VDrIOCYOTLwSIYw8O7mvHUGuJ8ERLZaa4ZMHlQeYoHWXA7OnQpMxRjxGq pqSEkTd0t6wWDtrVHMS2SZYWkboHc4RoWWYS4LEaBApYF7jxltAlzRajs6JLZShUZOms3T AKsypMRWUUR/YpVNNpBPnWfhbh0W8hkNbHSlRWs8GH9gKnnnYCV5deKSZpyHo0T9VZ2prH XcDSqZh7AaXSGFWYkV+LMt8I8ju5upZdS81pvOF1fY2K8orNRGYhYFuBzzONlb8fEgjEP/ ZEJyViNUbsUne6YWnRpnXWlZdgFTO1djJhz6hoFWbvMZEpRX1vT8MxVOi7GeDw== 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=1721555197; 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=4lCbD59s7sGlwRUQjAmaWwjdD6T85E0gyWGYRewuRxM=; b=XKOXxUdV8zbCK2fTMU6jqNi1iez2suxZBLNS3yTwlESK0D6xcRPQxqOjsXw9YYlhIrXBs9 m1lwG4ddZnfGz01Rfh/MLJ1dUHyZU1w3iijXwV+RLlOyph5Tz3Tp4WnAdZTOutvz4BkZxG lqN1+wsvVw3H4vdNTyMAHo7EvwZ4/nulw+/pvKLkI5aPZ4WILRN2cg7bCPBArYIU/YLefJ PekN0sV0YBdPPuKW20MKKE8uacDUCYupovcPzwukmaNnzC1T/lhA1a6oogjUQgDAulJHbm Oesx3Xr1R6wS/VT+MyrZxZfHApNks8J6tWtmjsEq5iuzZW7p+RV+PljmnX3OQw== Received: from venus.codepro.be (venus.codepro.be [5.9.86.228]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "mx1.codepro.be", Issuer "R3" (verified OK)) (Authenticated sender: kp) by smtp.freebsd.org (Postfix) with ESMTPSA id 4WRdpj3bC0z1Gnw; Sun, 21 Jul 2024 09:46:37 +0000 (UTC) (envelope-from kp@freebsd.org) Received: by venus.codepro.be (Postfix, authenticated sender kp) id 0CF098FCB; Sun, 21 Jul 2024 11:46:35 +0200 (CEST) Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable From: Kristof Provost List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org Mime-Version: 1.0 (1.0) Subject: Re: git: 9a7096ff547d - main - ipsec_offload: hide SA/SP offload lifecycle prints under verbose sysctl Date: Sun, 21 Jul 2024 11:46:24 +0200 Message-Id: <99B7FE52-7920-4806-95AD-36F8C85DA9EF@freebsd.org> References: <202407210853.46L8rkoh075102@gitrepo.freebsd.org> Cc: src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org In-Reply-To: <202407210853.46L8rkoh075102@gitrepo.freebsd.org> To: Konstantin Belousov X-Mailer: iPhone Mail (21F90) Thanks! > On 21 Jul 2024, at 10:53, Konstantin Belousov wrote: >=20 > =EF=BB=BFThe branch main has been updated by kib: >=20 > URL: https://cgit.FreeBSD.org/src/commit/?id=3D9a7096ff547de2b5a09c5a46838= 53568e08c2f8a >=20 > commit 9a7096ff547de2b5a09c5a4683853568e08c2f8a > Author: Konstantin Belousov > AuthorDate: 2024-07-19 19:15:35 +0000 > Commit: Konstantin Belousov > CommitDate: 2024-07-21 08:53:19 +0000 >=20 > ipsec_offload: hide SA/SP offload lifecycle prints under verbose sysctl= >=20 > Reported and reviewed by: kp > Discussed with: np > Sponsored by: NVIDIA networking > Differential revision: https://reviews.freebsd.org/D46045 > --- > sys/netipsec/ipsec_offload.c | 58 +++++++++++++++++++++++++++++++---------= ---- > 1 file changed, 41 insertions(+), 17 deletions(-) >=20 > diff --git a/sys/netipsec/ipsec_offload.c b/sys/netipsec/ipsec_offload.c > index 48082830b88b..8ccae7a94f2a 100644 > --- a/sys/netipsec/ipsec_offload.c > +++ b/sys/netipsec/ipsec_offload.c > @@ -35,9 +35,12 @@ > #include > #include > #include > +#include > #include > #include >=20 > +#include > + > #include > #include > #include > @@ -190,6 +193,27 @@ ipsec_accel_fini(void *arg) > SYSUNINIT(ipsec_accel_fini, SI_SUB_VNET_DONE, SI_ORDER_ANY, > ipsec_accel_fini, NULL); >=20 > +SYSCTL_NODE(_net_inet_ipsec, OID_AUTO, offload, CTLFLAG_RW | CTLFLAG_MPSA= FE, 0, > + ""); > + > +static bool ipsec_offload_verbose =3D false; > +SYSCTL_BOOL(_net_inet_ipsec_offload, OID_AUTO, verbose, CTLFLAG_RW, > + &ipsec_offload_verbose, 0, > + "Verbose SA/SP offload install and deinstall"); > + > +static void > +dprintf(const char *fmt, ...) > +{ > + va_list ap; > + > + if (!ipsec_offload_verbose) > + return; > + > + va_start(ap, fmt); > + vprintf(fmt, ap); > + va_end(ap); > +} > + > static void > ipsec_accel_alloc_forget_tq(struct secasvar *sav) > { > @@ -209,7 +233,7 @@ ipsec_accel_sa_install_match(if_t ifp, void *arg) > if ((ifp->if_capenable2 & IFCAP2_BIT(IFCAP2_IPSEC_OFFLOAD)) =3D=3D 0) > return (false); > if (ifp->if_ipsec_accel_m->if_sa_newkey =3D=3D NULL) { > - printf("driver bug ifp %s if_sa_newkey NULL\n", > + dprintf("driver bug ifp %s if_sa_newkey NULL\n", > if_name(ifp)); > return (false); > } > @@ -226,7 +250,7 @@ ipsec_accel_sa_newkey_cb(if_t ifp, void *arg) >=20 > tq =3D arg; >=20 > - printf("ipsec_accel_sa_newkey_act: ifp %s h %p spi %#x " > + dprintf("ipsec_accel_sa_newkey_act: ifp %s h %p spi %#x " > "flags %#x seq %d\n", > if_name(ifp), ifp->if_ipsec_accel_m->if_sa_newkey, > be32toh(tq->sav->spi), tq->sav->flags, tq->sav->seq); > @@ -240,7 +264,7 @@ ipsec_accel_sa_newkey_cb(if_t ifp, void *arg) > } > if (drv_spi =3D=3D -1) { > /* XXXKIB */ > - printf("ipsec_accel_sa_install_newkey: cannot alloc " > + dprintf("ipsec_accel_sa_install_newkey: cannot alloc " > "drv_spi if %s spi %#x\n", if_name(ifp), > be32toh(tq->sav->spi)); > return (ENOMEM); > @@ -249,14 +273,14 @@ ipsec_accel_sa_newkey_cb(if_t ifp, void *arg) > drv_spi, &priv); > if (error !=3D 0) { > if (error =3D=3D EOPNOTSUPP) { > - printf("ipsec_accel_sa_newkey: driver " > + dprintf("ipsec_accel_sa_newkey: driver " > "refused sa if %s spi %#x\n", > if_name(ifp), be32toh(tq->sav->spi)); > error =3D ipsec_accel_handle_sav(tq->sav, > ifp, drv_spi, priv, IFP_HS_REJECTED, NULL); > /* XXXKIB */ > } else { > - printf("ipsec_accel_sa_newkey: driver " > + dprintf("ipsec_accel_sa_newkey: driver " > "error %d if %s spi %#x\n", > error, if_name(ifp), be32toh(tq->sav->spi)); > /* XXXKIB */ > @@ -266,7 +290,7 @@ ipsec_accel_sa_newkey_cb(if_t ifp, void *arg) > drv_spi, priv, IFP_HS_HANDLED, NULL); > if (error !=3D 0) { > /* XXXKIB */ > - printf("ipsec_accel_sa_newkey: handle_sav " > + dprintf("ipsec_accel_sa_newkey: handle_sav " > "err %d if %s spi %#x\n", error, > if_name(ifp), be32toh(tq->sav->spi)); > } > @@ -324,13 +348,13 @@ ipsec_accel_sa_newkey_impl(struct secasvar *sav) > SADB_KEY_ACCEL_DEINST)) !=3D 0) > return; >=20 > - printf( > + dprintf( > "ipsec_accel_sa_install_newkey: spi %#x flags %#x seq %d\n", > be32toh(sav->spi), sav->flags, sav->seq); >=20 > tq =3D malloc(sizeof(*tq), M_TEMP, M_NOWAIT); > if (tq =3D=3D NULL) { > - printf("ipsec_accel_sa_install_newkey: no memory for tq, " > + dprintf("ipsec_accel_sa_install_newkey: no memory for tq, " > "spi %#x\n", be32toh(sav->spi)); > /* XXXKIB */ > return; > @@ -403,7 +427,7 @@ ipsec_accel_forget_handle_sav(struct ifp_handle_sav *i= , bool freesav) > sav =3D i->sav; > if ((i->flags & (IFP_HS_HANDLED | IFP_HS_REJECTED)) =3D=3D > IFP_HS_HANDLED) { > - printf("sa deinstall %s %p spi %#x ifl %#x\n", > + dprintf("sa deinstall %s %p spi %#x ifl %#x\n", > if_name(ifp), sav, be32toh(sav->spi), i->flags); > ifp->if_ipsec_accel_m->if_sa_deinstall(ifp, > i->drv_spi, i->ifdata); > @@ -597,18 +621,18 @@ ipsec_accel_spdadd_cb(if_t ifp, void *arg) >=20 > sp =3D arg; > inp =3D sp->ipsec_accel_add_sp_inp; > - printf("ipsec_accel_spdadd_cb: ifp %s m %p sp %p inp %p\n", > + dprintf("ipsec_accel_spdadd_cb: ifp %s m %p sp %p inp %p\n", > if_name(ifp), ifp->if_ipsec_accel_m->if_spdadd, sp, inp); > error =3D ipsec_accel_remember_sp(sp, ifp, &i); > if (error !=3D 0) { > - printf("ipsec_accel_spdadd: %s if_spdadd %p remember res %d\n", > + dprintf("ipsec_accel_spdadd: %s if_spdadd %p remember res %d\n", > if_name(ifp), sp, error); > return (error); > } > error =3D ifp->if_ipsec_accel_m->if_spdadd(ifp, sp, inp, &i->ifdata); > if (error !=3D 0) { > i->flags |=3D IFP_HP_REJECTED; > - printf("ipsec_accel_spdadd: %s if_spdadd %p res %d\n", > + dprintf("ipsec_accel_spdadd: %s if_spdadd %p res %d\n", > if_name(ifp), sp, error); > } > return (error); > @@ -676,11 +700,11 @@ ipsec_accel_spddel_act(void *arg, int pending) > NET_EPOCH_WAIT(); > if ((i->flags & (IFP_HP_HANDLED | IFP_HP_REJECTED)) =3D=3D > IFP_HP_HANDLED) { > - printf("spd deinstall %s %p\n", if_name(i->ifp), sp); > + dprintf("spd deinstall %s %p\n", if_name(i->ifp), sp); > error =3D i->ifp->if_ipsec_accel_m->if_spddel(i->ifp, > sp, i->ifdata); > if (error !=3D 0) { > - printf( > + dprintf( > "ipsec_accel_spddel: %s if_spddel %p res %d\n", > if_name(i->ifp), sp, error); > } > @@ -741,12 +765,12 @@ ipsec_accel_on_ifdown_sp(struct ifnet *ifp) > NET_EPOCH_WAIT(); > if ((i->flags & (IFP_HP_HANDLED | IFP_HP_REJECTED)) =3D=3D > IFP_HP_HANDLED) { > - printf("spd deinstall %s %p\n", if_name(ifp), sp); > + dprintf("spd deinstall %s %p\n", if_name(ifp), sp); > error =3D ifp->if_ipsec_accel_m->if_spddel(ifp, > sp, i->ifdata); > } > if (error !=3D 0) { > - printf( > + dprintf( > "ipsec_accel_on_ifdown_sp: %s if_spddel %p res %d\n", > if_name(ifp), sp, error); > } > @@ -894,7 +918,7 @@ ipsec_accel_input(struct mbuf *m, int offset, int prot= o) >=20 > if (tag->drv_spi < IPSEC_ACCEL_DRV_SPI_MIN || > tag->drv_spi > IPSEC_ACCEL_DRV_SPI_MAX) { > - printf("if %s mbuf %p drv_spi %d invalid, packet dropped\n", > + dprintf("if %s mbuf %p drv_spi %d invalid, packet dropped\n", > (m->m_flags & M_PKTHDR) !=3D 0 ? if_name(m->m_pkthdr.rcvif) : > "", m, tag->drv_spi); > m_freem(m); >=20 From nobody Sun Jul 21 13:14:44 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRkQs1Gxvz5RV5L; Sun, 21 Jul 2024 13:14: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRkQs0hcDz4RrX; Sun, 21 Jul 2024 13:14:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721567685; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=UINWRsbhsF3ZWYl6sWNgXHA2u/OEZIIOHp0h9EL1XfA=; b=fc0YTkJIvI0FRg9XtOYhC9UEaLOnarmnGBkwFR2WBEPb5yMdTbBRyzPbrhOBy3NbDo4IpF p7dm2aWdhVOHSrfifg/89pGNwlo5tH4KLWjErzJs4B5yDIv2d5PMmC6nVdZlmYeRhsy4FT TiK5JYo2m31zmNrKfQJ0gKBlUWTjsBH29Uy6+cNvcmJPQjcdS2ROObzQh0V1oXT7sX1QsD UZnfPaynyF8LkhfsDpFAh9+Fnl/RLZkuXjOZiBivZCx76x2JT9JLJNyFxkra8WvP4TQ7B6 bObvjqiUHLlSoehdHuwEvZF8pJekpdxiH59UcgRgQ1GIcLC6rrSGVGTqSpuIeg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721567685; a=rsa-sha256; cv=none; b=cDboZ2yvg/ZQnFFB09BsBu2liZN5N/lY5ZxnXaN5j7VnkpANJiBSvunSnS4UQtMoG778zZ cqpG+dkRhyzVF7rsXDBvX7Z+hijOH/S/Onj0dDcFv5qFrVj9w7Me9ORauWa5f8Za/ZzCyI qqQZRJMNx9jxTG8o5ubtWC8E63mWpsyZfSYLht+bGjh8zjCq+VPZTk/LXZSESgAq983bzU fXnk/EnmGAiGZMD9Ll+RQq6qTaov2LbmsLurq164WujfCkOabG8b4/SLuDIBqgl00zOnmt LkxJ1H4FrUbPMWugVhjPS43jfJ/SkNPaBU7STOwXZS3XvFFN3p640FFGadycmQ== 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=1721567685; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=UINWRsbhsF3ZWYl6sWNgXHA2u/OEZIIOHp0h9EL1XfA=; b=UBqRPbJcHirZsifSztgHcW/ozsEaqiW1cnaYloGVsWGc9kUnMFcRwLl6EQnndBadYj1JMA GVYYEjwAS/ivaKfhYsyHs67oZOxXWd3NN07kct5Sx7zpZ+L9nIbXQEX+R1kTuuGHSMXvMi GL3w0uN/31Zs/o18txKTo9HfLP/xRcaj4/L/hNaKh91NrDE72LPaB17Ygb+p2ZAe70YAer vF+7wpQT9QHM47nKrj/xmo7Z4I0KFHLnuHLBdjgbQp9E40s421U2k/wHqqlqBrMmkZZLxG dNb9KYhOwLyggzxKZKXUcn68MDJrMLAF1JTyVIojgtMCKFN5N4JZN5h+HSuUPA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRkQs0BC1z12Bf; Sun, 21 Jul 2024 13:14:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LDEihg022901; Sun, 21 Jul 2024 13:14:44 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LDEiqb022898; Sun, 21 Jul 2024 13:14:44 GMT (envelope-from git) Date: Sun, 21 Jul 2024 13:14:44 GMT Message-Id: <202407211314.46LDEiqb022898@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Vladimir Kondratyev Subject: git: 5d20075f8b9f - main - LinuxKPI: Automatically enable drm support for devices named "drmn" List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: wulf X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 5d20075f8b9f7107aa0a246e5165d9816e816a44 Auto-Submitted: auto-generated The branch main has been updated by wulf: URL: https://cgit.FreeBSD.org/src/commit/?id=5d20075f8b9f7107aa0a246e5165d9816e816a44 commit 5d20075f8b9f7107aa0a246e5165d9816e816a44 Author: Vladimir Kondratyev AuthorDate: 2024-07-21 13:02:08 +0000 Commit: Vladimir Kondratyev CommitDate: 2024-07-21 13:02:08 +0000 LinuxKPI: Automatically enable drm support for devices named "drmn" This allows replace linux_pci_(un)register_drm_driver calls with driver renaming to FreeBSD name. Sponsored by: Serenity CyberSecurity, LLC MFC after: 1 week Reviewed by: manu, bz Differential Revision: https://reviews.freebsd.org/D45906 --- sys/compat/linuxkpi/common/src/linux_pci.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/compat/linuxkpi/common/src/linux_pci.c b/sys/compat/linuxkpi/common/src/linux_pci.c index 825ebe319b1a..51a3b0b2ebe1 100644 --- a/sys/compat/linuxkpi/common/src/linux_pci.c +++ b/sys/compat/linuxkpi/common/src/linux_pci.c @@ -976,10 +976,10 @@ linux_pci_register_driver(struct pci_driver *pdrv) { devclass_t dc; - dc = devclass_find("pci"); + pdrv->isdrm = strcmp(pdrv->name, "drmn") == 0; + dc = pdrv->isdrm ? devclass_create("vgapci") : devclass_find("pci"); if (dc == NULL) return (-ENXIO); - pdrv->isdrm = false; return (_linux_pci_register_driver(pdrv, dc)); } @@ -1166,7 +1166,7 @@ linux_pci_unregister_driver(struct pci_driver *pdrv) { devclass_t bus; - bus = devclass_find("pci"); + bus = devclass_find(pdrv->isdrm ? "vgapci" : "pci"); spin_lock(&pci_lock); list_del(&pdrv->node); From nobody Sun Jul 21 13:14:46 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRkQt3R3Nz5RV2V; Sun, 21 Jul 2024 13:14: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRkQt1PhQz4Rp5; Sun, 21 Jul 2024 13:14:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721567686; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=NPid9u7HXeKI1tTP8D/wCqLoRwgSSvV4Q26f6jWpb4o=; b=jBdxBDsaaS7Jy+M0T4mz+ep7r3qJUOfWZVvCl/W60Inw0vxo+PCIVp5e+gV9YbFzFk4Tcx lWr8njU1Wl0wLuAyjG3bZwvdWK+A6bqeAxQVTYOti4p+N8RKD7Fd0q8bOZquERvFRSAsHw QkQovAAB2oryEgaHEmhzuyTo+RRfqGYH8nRwLNLTiSEpRDxmZu0umReTiC6u4lk63CHZDx lAbe7Z/Yuy5UkHsfX4FojfKVTiIX+Xa2TQzpnbO4NMXQW90U7T6TybSp4wuXSicuftY8JA GkC/35/IsL2uDgJ1Eln7zfsMljGjz4SEgXFnM/UEHZdFAj56/f3gANHpBs9rLA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721567686; a=rsa-sha256; cv=none; b=jYAzzFbTLngbEwbiHuwxD+vzOEXx08hmzN476ZXkMFYJ1Tu40XTnH9nc3eSHWPF1vzHvhN COjdq0GFCMgKV8mFt6h+rX/4tKkwvCtsrsZi+nDdtsFZD1gvuIOdZ/6A1oo7jYVGj+Sz8R 9AX4JTtlPk6/L6CW4CFLOoeG/4/PRwjFS5weMbDAZs2QdRrbakRnz/1NanX7TUNk4Y4G8H KptEsbuMpGNxhgAqJVbYsh6CEAl6ts6B+0dmFmnnGGvqRQY5gNoKqSoRVBLp2B4VfE/qBz NoOstyCqrgiqh2E1kTz6+nLTfQGLIFKFTxANicBa8pLn762f+ec4JqK7sZOxyA== 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=1721567686; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=NPid9u7HXeKI1tTP8D/wCqLoRwgSSvV4Q26f6jWpb4o=; b=KeoDRYkwbrtXlPJHBi+wcaSzPhMWPbZbgoUeVLlIu14yIVX3+0gfn/zSrtwSgyRhtZ9puc ROHbVgeDk9o+aH7XxP3hRBQ51SPn0SXfaCyIb/RcAjzBR0u9aI4Lt7Wsm0aWfJi9y5YLOe uVQCk6TByyDP1dapUu5ddpLjTP1qaxiXcqNTVELFFqLxnZ4IAWpSEzTOefYUK6xBNxU1wh oy/y+ydrFtFXOC+JlXk1kX3ZIp1CgIM5iNhmQCX7MxVEloazJDh/Hmpt0XqvB3U9LKowxk volU5RkdOe4bOb5pQiOF0z+4rZDxD6H8EsX+1vsfGaFBc5wg17eTccT/f4i2Kg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRkQt0wPJz12Bg; Sun, 21 Jul 2024 13:14:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LDEk0P022946; Sun, 21 Jul 2024 13:14:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LDEk5T022943; Sun, 21 Jul 2024 13:14:46 GMT (envelope-from git) Date: Sun, 21 Jul 2024 13:14:46 GMT Message-Id: <202407211314.46LDEk5T022943@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Vladimir Kondratyev Subject: git: ab6e1167909b - main - LinuxKPI: Add kvrealloc to linux/slab.h List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: wulf X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: ab6e1167909bf1e2792a2ba33000e13d33aaf551 Auto-Submitted: auto-generated The branch main has been updated by wulf: URL: https://cgit.FreeBSD.org/src/commit/?id=ab6e1167909bf1e2792a2ba33000e13d33aaf551 commit ab6e1167909bf1e2792a2ba33000e13d33aaf551 Author: Vladimir Kondratyev AuthorDate: 2024-07-21 13:08:28 +0000 Commit: Vladimir Kondratyev CommitDate: 2024-07-21 13:08:28 +0000 LinuxKPI: Add kvrealloc to linux/slab.h Sponsored by: Serenity Cyber Security, LLC MFC after: 1 week Reviewed by: manu Differential Revision: https://reviews.freebsd.org/D45616 --- sys/compat/linuxkpi/common/include/linux/slab.h | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/sys/compat/linuxkpi/common/include/linux/slab.h b/sys/compat/linuxkpi/common/include/linux/slab.h index 298306b6ea05..e2d17e0558c2 100644 --- a/sys/compat/linuxkpi/common/include/linux/slab.h +++ b/sys/compat/linuxkpi/common/include/linux/slab.h @@ -91,6 +91,8 @@ struct linux_kmem_cache; #define ZERO_SIZE_PTR ((void *)16) #define ZERO_OR_NULL_PTR(x) ((x) == NULL || (x) == ZERO_SIZE_PTR) +extern void *lkpi_kmalloc(size_t size, gfp_t flags); + static inline gfp_t linux_check_m_flags(gfp_t flags) { @@ -212,13 +214,29 @@ kfree_sensitive(const void *ptr) zfree(__DECONST(void *, ptr), M_KMALLOC); } +static inline void * +kvrealloc(const void *ptr, size_t oldsize, size_t newsize, gfp_t flags) +{ + void *newptr; + + if (newsize <= oldsize) + return (__DECONST(void *, ptr)); + + newptr = kvmalloc(newsize, flags); + if (newptr != NULL) { + memcpy(newptr, ptr, oldsize); + kvfree(ptr); + } + + return (newptr); +} + static inline size_t ksize(const void *ptr) { return (malloc_usable_size(ptr)); } -extern void *lkpi_kmalloc(size_t size, gfp_t flags); extern struct linux_kmem_cache *linux_kmem_cache_create(const char *name, size_t size, size_t align, unsigned flags, linux_kmem_ctor_t *ctor); extern void *lkpi_kmem_cache_alloc(struct linux_kmem_cache *, gfp_t); From nobody Sun Jul 21 13:14:47 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRkQw060jz5RVP0; Sun, 21 Jul 2024 13:14:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRkQv3Y5Jz4Rlw; Sun, 21 Jul 2024 13:14:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721567687; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=IW7VPWtTdGhfR/YoZsHqJkIDA2MVAaFK5ZtoYBm2k0E=; b=DhGx/yznFu+5dbpGaQ3lWkCksmOc20iVsUe8pSWBHH2xyqC4kGlgtZAHFuWlulW2KEErWc NcQ+G+II4kIz4hs6aod85He1DyCzeIb0i5EPzRRh5umn/wClIFOgmlSe/B43oDEIeCtoYh 9fWyyvXmsvX/B7hgQSi7MQxliUGjUR1FhmdNPkQsPatG9DaK5Eafj79jkjXp2UukGSS9LR 9P3MfeHOwP79QpsLp89wnJawj7AbNHK9gu4O1jKFOBcA5/hlYg9otc8QWhdDqvRBdeKzYU FEefeEvaMj50nFi25MRagy9l+6Vz14VX6BB+vmlUWqt+M0XC8hoNiMfnkjeepQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721567687; a=rsa-sha256; cv=none; b=U4dJ45itl43k3wIouF+yE3kzOmv0eGuLEhj7dpNL3LHodhh65iQfTom3H4U/2jTywbUxax Ma+0XBB9jcDiJ42/y88mUiJHsZiBs0Bq8ozElYUhqNe5bHLWQrzBooYEh44YxVb2R2mKBj FfJ4PpWA/sihu6B21nNWWaFjCaQdcodHApGFX/NmoIKW9PTxKP2H/nOPOp/kH4niTPhimJ PvjDOOGQf0qxUWB0osLNYInJHMjGtGlStf79HSDO1LMJZyRV2C8mB/Q5WJA3bt8LvJPdIz N9mNO4P7VqL3kjVWtD6GLtcImYpwKVzcla+ikNOMPEKNz65GAzSNXhtPFIXXTw== 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=1721567687; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=IW7VPWtTdGhfR/YoZsHqJkIDA2MVAaFK5ZtoYBm2k0E=; b=nn7Gf9soGBUDe6WeTNAT1mRecMZLvUs+U9gJJULyQdPI0wHTW5dvtzRSkIjVhmKfFWtYTQ IFoszfy2y3zJSGDvZcQlHOw04erSqj4l3it09g5gexVeYaltRRdUGdC36tnaRMdOnaIHcA rAVlILut6OSJBB/Za/mBqASt6sMJLp1H/tmofbGZdtJTQqHS+/XuE/lKbZIQFwiwIiuZVu ufgfbzVoBUg7vOnUaWMpxyfSSTAtIym+K1EFRKqISjKtmadRnyqiNB9kQB5cts6d1HQzko LehRSO9iWAGlcjXjy2EtQ7BP2dsnIrmqOie6nBksqpiauL+FUZ//uudNmV1Kcw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRkQv1vCBz11Zf; Sun, 21 Jul 2024 13:14:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LDElma022990; Sun, 21 Jul 2024 13:14:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LDElb2022987; Sun, 21 Jul 2024 13:14:47 GMT (envelope-from git) Date: Sun, 21 Jul 2024 13:14:47 GMT Message-Id: <202407211314.46LDElb2022987@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Vladimir Kondratyev Subject: git: ab1a5d8e2ade - main - LinuxKPI: Add kmalloc_size_roundup function List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: wulf X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: ab1a5d8e2ade8c706ff8cd7aa3d5c88a95633228 Auto-Submitted: auto-generated The branch main has been updated by wulf: URL: https://cgit.FreeBSD.org/src/commit/?id=ab1a5d8e2ade8c706ff8cd7aa3d5c88a95633228 commit ab1a5d8e2ade8c706ff8cd7aa3d5c88a95633228 Author: Vladimir Kondratyev AuthorDate: 2024-07-21 13:08:37 +0000 Commit: Vladimir Kondratyev CommitDate: 2024-07-21 13:08:37 +0000 LinuxKPI: Add kmalloc_size_roundup function kmalloc_size_roundup reports allocation bucket size for the given size. Sponsored by: Serenity CyberSecurity, LLC MFC after: 1 week Reviewed by: manu, emaste Differential Revision: https://reviews.freebsd.org/D45841 --- sys/compat/linuxkpi/common/include/linux/slab.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/sys/compat/linuxkpi/common/include/linux/slab.h b/sys/compat/linuxkpi/common/include/linux/slab.h index e2d17e0558c2..3f2d1621e148 100644 --- a/sys/compat/linuxkpi/common/include/linux/slab.h +++ b/sys/compat/linuxkpi/common/include/linux/slab.h @@ -237,6 +237,14 @@ ksize(const void *ptr) return (malloc_usable_size(ptr)); } +static inline size_t +kmalloc_size_roundup(size_t size) +{ + if (unlikely(size == 0 || size == SIZE_MAX)) + return (size); + return (malloc_size(size)); +} + extern struct linux_kmem_cache *linux_kmem_cache_create(const char *name, size_t size, size_t align, unsigned flags, linux_kmem_ctor_t *ctor); extern void *lkpi_kmem_cache_alloc(struct linux_kmem_cache *, gfp_t); From nobody Sun Jul 21 13:14:48 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRkQw73l0z5RV5Q; Sun, 21 Jul 2024 13:14:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRkQw4pdfz4S0B; Sun, 21 Jul 2024 13:14:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721567688; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=d36x+e9ORjUDuZ3v4VoYEh7FCqvaa09F5UvuGwsg+LU=; b=Q/2XXVSqxoV6KZ95cmvQb/L08wkt2wDlb/djn3lCjFW1+Om+RaMOFQDujlyT4DITmZ1yxm kb7eej8ThPtzeGUX3uO8iAhtQ0XQiA3lkmOJL4WckPVdBVubTw5fy3KV8FuPx7FvDHcSqz fGgAICDN0Et05C/IlSinlru9aJUCQhN7VTecO5TTMZfrU0S9UFx0LvHLpT6ItG6FZgagB0 E7HUCszp8MUKQl1uo4gFp8Q1vgw1OKT9a56fW69pXYpstlwgY0ZA4MG+Kt2daysbNU/R29 LBG/XbjUBXb35TZesXuAcxg2rc8IU4FSZvI7brMmB5KAbwaq1Sfm1l9tmFQuDg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721567688; a=rsa-sha256; cv=none; b=sL/xHfHm+FPo80YI011UQFoiss/UO37AKy352xUM9U4WQsK0cXn1RpAyCOi01MtkSNb2a9 gFWq7gzNoXJUOOgCQbvmiPk6qnHEfbgp0tn49gNPH+E7jZ2SzTbCVcait4B4LPyYAaXZjH Avr58LTDR1Tapz05UKK1f9PiJuT5uamV9TvvftPU68cNlhKyVkTFhIz+Ry42KFWOAcJQ4S rNVgmSaStrr9fq5LVvp6ZYsXgwXRJ+XuifVXqtz1KrzSLK8/V1PiGA1fTmHXKxwDgJqc9M 3QCWDRfb3gWEV5OKMhelWK/laMxFMY/yIOnyEVF6pDOLSLq6/tF+PPTfX9xRqQ== 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=1721567688; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=d36x+e9ORjUDuZ3v4VoYEh7FCqvaa09F5UvuGwsg+LU=; b=suvACY32oiILQcvRZbVP0wJkcKY8u8kLEP/vEK8KCu/+6+1IIORBVlv40bfyfPcCfjKJ52 oOgc6VSzMM4mThWLPDBJFj5tVN11h9sf2xrumF7oJmnddh9ESyriCEeAWZCdLwpu6G1IUs ZmdI3g8A7sl1z9TT6AHtZAqj679bRQ2zH5R2NtkGrpqxqm0dpZChobfnQjYue4J9mWYkYx 8zIgjM6wZ64SfQkR4fNMSaGRbnkoQE1fOJSzehH9fCesWjGccerbWXuDYCzuozcUCm0XPt QSemR313KNPr/Q4aA1XNnc6uTIcwbjXXtHCYaFwEzB/sIwg3m9sWSXpUF5KUiA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRkQw4FcBz11m9; Sun, 21 Jul 2024 13:14:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LDEmoO023029; Sun, 21 Jul 2024 13:14:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LDEmJ5023026; Sun, 21 Jul 2024 13:14:48 GMT (envelope-from git) Date: Sun, 21 Jul 2024 13:14:48 GMT Message-Id: <202407211314.46LDEmJ5023026@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Vladimir Kondratyev Subject: git: 742088d9fb54 - main - LinuxKPI: Add __diag macros List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: wulf X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 742088d9fb545296c8677119757a967141ba7d4a Auto-Submitted: auto-generated The branch main has been updated by wulf: URL: https://cgit.FreeBSD.org/src/commit/?id=742088d9fb545296c8677119757a967141ba7d4a commit 742088d9fb545296c8677119757a967141ba7d4a Author: Vladimir Kondratyev AuthorDate: 2024-07-21 13:08:48 +0000 Commit: Vladimir Kondratyev CommitDate: 2024-07-21 13:08:48 +0000 LinuxKPI: Add __diag macros __diag macros turn individual warnings and errors on and off locally, depending on version of compiler. Add dummy implementation as drm-kmod set warnings separately for each file. Sponsored by: Serenity Cyber Security, LLC MFC after: 1 week Reviewed by: manu, emaste Differential Revision: https://reviews.freebsd.org/D45842 --- sys/compat/linuxkpi/common/include/linux/compiler.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sys/compat/linuxkpi/common/include/linux/compiler.h b/sys/compat/linuxkpi/common/include/linux/compiler.h index d59e6faed12d..c82b9acd53fb 100644 --- a/sys/compat/linuxkpi/common/include/linux/compiler.h +++ b/sys/compat/linuxkpi/common/include/linux/compiler.h @@ -89,6 +89,10 @@ #define __printf(a,b) __printflike(a,b) +#define __diag_push() +#define __diag_pop() +#define __diag_ignore_all(...) + #define barrier() __asm__ __volatile__("": : :"memory") #define lower_32_bits(n) ((u32)(n)) From nobody Sun Jul 21 13:14:49 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRkQy2QZZz5RVHL; Sun, 21 Jul 2024 13:14:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRkQx5gPVz4S0Q; Sun, 21 Jul 2024 13:14:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721567689; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=X9ANBcYx3k+zWYbaRaUrQ/N72vBLMZf5++oeOuFOmlg=; b=bHOIktj9JuPKKiiZhn/RvHmfWj3dGhpy/iABNZmLhJ/BRIyiEmtFWOtgL+w0XMDx9mvpin HKRcRedZWHCzOWVQoey2ykCvjqFoNvuuAbxt9qRazLgfDRgDDJ2U5DP4xV10Xjy4h13YED 3VuwGFWAmTZot6DXCL7YBDjNA6K8etrCBZzf7BWl/nJZ18x0xfYzQ6FL2v9jdwJE51Ot76 v/D8uwEtoqZqhPL86lKSXjP/oM0tkpYugEy5OeN9Cw3VYrFwxqpUfHeHlA1qjT/S4IV2I1 3s290KvzvJaVzoX4KtF/CdGQscFOZv1sGFeFqDtHIHu3cSantuCdRhpNwrWQFw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721567689; a=rsa-sha256; cv=none; b=SNI1/+9+BD5sC1rIRERlXz95dJRnyL3Fv/6UYNWKUGzS21qFMCFWtIIcp8D70oNTogXiiV C45EkUPYPZFqPfawLoRa7s6/s9/fTKLiPT0/dT49gh1Tt0++tOmurS8sYiR5eFGf3+6pbY mHfKMU57EYAClTzABtwgG6lE/mIdWj6Ks4dpwB53SeljT65mrIoT5nbb5gj8KHFXpv65wx YCBjs5fxIW1NXTw1mwbibEpiSwCWarNAGwxDJJXqW9/r5Kap6XYPbB+4d7qERgil/YSsMv LUv7G2gadV75pF1xXhVWLyIR3L0AaoTdQHGQoEWjgHNd1o0+nNTt3fCkfR+5RQ== 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=1721567689; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=X9ANBcYx3k+zWYbaRaUrQ/N72vBLMZf5++oeOuFOmlg=; b=W2kcEUB5eTtZoKXhAMvL/fGO+8LLbX5BSiwDp1bslhEg8eSXZgZ1pxtifwWwO3r/Syatmi XuUTxj68WioIlfvwYhWZNsb+WgAG/s0PGq4Rqvo+iDTERQ2v4Dk8BPXx91vKoWS4AJ9Uih H9pdznLnpKiAUOJPdM2OHfnqIJK3uLRrldX4cL0Jpgk6jC70jjkGp81lGOTvHRkLNs1/1z CGDImwMvUofc/wMVIN+a+jyEGa/14+rDAhZ7viZ/kRiVmBQqD9Twibm6M0rl6rm1IePUY5 fzmeuGORKSvAkV5k6YMjDxxo7J1ooEYUsbKPTTAtsNhFpFMcQ4AEAR3a1qcatA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRkQx3wbMz12Bh; Sun, 21 Jul 2024 13:14:49 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LDEnDL023068; Sun, 21 Jul 2024 13:14:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LDEn51023065; Sun, 21 Jul 2024 13:14:49 GMT (envelope-from git) Date: Sun, 21 Jul 2024 13:14:49 GMT Message-Id: <202407211314.46LDEn51023065@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Vladimir Kondratyev Subject: git: 80aa295a5272 - main - LinuxKPI: Add page_to_virt function List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: wulf X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 80aa295a5272d01b7f21eff6719dcd45e14e8e09 Auto-Submitted: auto-generated The branch main has been updated by wulf: URL: https://cgit.FreeBSD.org/src/commit/?id=80aa295a5272d01b7f21eff6719dcd45e14e8e09 commit 80aa295a5272d01b7f21eff6719dcd45e14e8e09 Author: Vladimir Kondratyev AuthorDate: 2024-07-21 13:09:01 +0000 Commit: Vladimir Kondratyev CommitDate: 2024-07-21 13:09:01 +0000 LinuxKPI: Add page_to_virt function Sponsored by: Serenity Cyber Security, LLC MFC after: 1 week Reviewed by: manu Differential Revision: https://reviews.freebsd.org/D45843 --- sys/compat/linuxkpi/common/include/linux/page.h | 1 + 1 file changed, 1 insertion(+) diff --git a/sys/compat/linuxkpi/common/include/linux/page.h b/sys/compat/linuxkpi/common/include/linux/page.h index aa5acac4f5fe..37ab593a64e9 100644 --- a/sys/compat/linuxkpi/common/include/linux/page.h +++ b/sys/compat/linuxkpi/common/include/linux/page.h @@ -72,6 +72,7 @@ pgprot2cachemode(pgprot_t prot) return (VM_MEMATTR_DEFAULT); } +#define page_to_virt(page) linux_page_address(page) #define virt_to_page(x) PHYS_TO_VM_PAGE(vtophys(x)) #define page_to_pfn(pp) (VM_PAGE_TO_PHYS(pp) >> PAGE_SHIFT) #define pfn_to_page(pfn) (PHYS_TO_VM_PAGE((pfn) << PAGE_SHIFT)) From nobody Sun Jul 21 13:14:50 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRkQz2H6hz5RVP5; Sun, 21 Jul 2024 13:14:51 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRkQy6s1lz4Rs9; Sun, 21 Jul 2024 13:14:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721567691; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=yx468r2pKqsIZ9Q4FwNqV5n0xKbjsIGUczgFUbzZelA=; b=UY0QsUD257FEs8qyjpR5gMg+ptPm5KRibA9vHfXmfrW1T29MAuGlbx+nCZqdcHkMKvbgpv jQn8FKo5dY5MSpvbKJvscKwakuk+MbPiFGXWdhyQHboEtquJP7b+djCHsXM9xDEZMQrB4j qEsNFgVVV08dTkfKIYb3JMtyP9FuYvlPXQLUNkP5dh8C1OKsHRoWHeuCvmNWdy22Lc6w44 0jnGjvaFOiot4qgzaAo/ATo/rlOTsGzKTI8mQsNwe1uvEQToMtvsONmw+Y7UcQ0OKsuBRS 2UpKlk0/RNX9l0byt3Wj/ZUZdFbMBypgKyNbEutEGuq+tVthJdPFrbkvbjwH1Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721567691; a=rsa-sha256; cv=none; b=qlULSTs6OliQdOGY1CHIkKAKJ1wq9+UDJpyUI+KpbNvG/TylXcklXbaZYLorIEsmLA8tLg VVbzjU5BS/n7rvMtU7iVsjBem1POATjchpDM9jFgRIx0CXQ5AJy3WgEVYZEIrJ5FPfwkG8 v4KhCjJUnKW/a24AKDJu/t9H+p8JoMSdkOJqZkg3GSPjfa4FdldCa5hwJmZ1TejR2sp0+I T+auXvdt5+0eKWHD4gvVBU7l8+EP/VBe5T0dONXIBBE0VlUhetuJKhpurcyZEryoHBwbws xRiAFaqvdRq8hhPM254ke+lHgBsUln/B9ndKJkeubHMVnpum9RaPtXjINEb0Dw== 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=1721567691; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=yx468r2pKqsIZ9Q4FwNqV5n0xKbjsIGUczgFUbzZelA=; b=wHXrgCYivRfc4qulF86RZCBBfpm/blogRprQbZnws8YyVEuI5NrHn1ueCBhl5vwKTYuPOQ Jlu1+5vaBW8oAPRCbYaF8JGO30oLwrkv88gks1Z+ntfhGhKNKCnm2BH/aId3FSCBDjbIoA id4FU+kaH2gqvxl+8WVKClgAERnQRyqg2IBKbF4xaTKT47cz6TupUg1N9EUCVqMDkDilU/ UbcmZc8MLLG/sx+Uq3by8bfWHbrB5dzERzgGDA8D/yWr5AQLXaWRfeGkck6YZTiaF6IlGE rPw6l3tAz4rWJf8nhPAq6XoTq82kLrnFlSWRzz6dbx3VOYAj9mYeFu63D2154A== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRkQy4tvsz12Bj; Sun, 21 Jul 2024 13:14:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LDEoDo023110; Sun, 21 Jul 2024 13:14:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LDEoW4023107; Sun, 21 Jul 2024 13:14:50 GMT (envelope-from git) Date: Sun, 21 Jul 2024 13:14:50 GMT Message-Id: <202407211314.46LDEoW4023107@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Vladimir Kondratyev Subject: git: a1181662d370 - main - LinuxKPI: Add devm_device_add_group to linux/device.h List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: wulf X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: a1181662d3707d8165d7153a0aa5d76ea1ddc11a Auto-Submitted: auto-generated The branch main has been updated by wulf: URL: https://cgit.FreeBSD.org/src/commit/?id=a1181662d3707d8165d7153a0aa5d76ea1ddc11a commit a1181662d3707d8165d7153a0aa5d76ea1ddc11a Author: Vladimir Kondratyev AuthorDate: 2024-07-21 13:09:12 +0000 Commit: Vladimir Kondratyev CommitDate: 2024-07-21 13:09:12 +0000 LinuxKPI: Add devm_device_add_group to linux/device.h devm_device_add_group creates a managed attribute group for a device. Sponsored by: Serenity Cyber Security, LLC MFC after: 1 week Reviewed by: manu Differential Revision: https://reviews.freebsd.org/D45845 --- sys/compat/linuxkpi/common/include/linux/device.h | 4 +++ sys/compat/linuxkpi/common/src/linux_compat.c | 30 +++++++++++++++++++++++ 2 files changed, 34 insertions(+) diff --git a/sys/compat/linuxkpi/common/include/linux/device.h b/sys/compat/linuxkpi/common/include/linux/device.h index 00c55b31b248..912be8fbae8b 100644 --- a/sys/compat/linuxkpi/common/include/linux/device.h +++ b/sys/compat/linuxkpi/common/include/linux/device.h @@ -701,4 +701,8 @@ int lkpi_devm_add_action_or_reset(struct device *dev, void (*action)(void *), vo #define devm_add_action_or_reset(dev, action, data) \ lkpi_devm_add_action_or_reset(dev, action, data) +int lkpi_devm_device_add_group(struct device *dev, const struct attribute_group *group); +#define devm_device_add_group(dev, group) \ + lkpi_devm_device_add_group(dev, group) + #endif /* _LINUXKPI_LINUX_DEVICE_H_ */ diff --git a/sys/compat/linuxkpi/common/src/linux_compat.c b/sys/compat/linuxkpi/common/src/linux_compat.c index 90d03d480089..ec4e59f66e7f 100644 --- a/sys/compat/linuxkpi/common/src/linux_compat.c +++ b/sys/compat/linuxkpi/common/src/linux_compat.c @@ -2615,6 +2615,36 @@ device_can_wakeup(struct device *dev) return (false); } +static void +devm_device_group_remove(struct device *dev, void *p) +{ + const struct attribute_group **dr = p; + const struct attribute_group *group = *dr; + + sysfs_remove_group(&dev->kobj, group); +} + +int +lkpi_devm_device_add_group(struct device *dev, + const struct attribute_group *group) +{ + const struct attribute_group **dr; + int ret; + + dr = devres_alloc(devm_device_group_remove, sizeof(*dr), GFP_KERNEL); + if (dr == NULL) + return (-ENOMEM); + + ret = sysfs_create_group(&dev->kobj, group); + if (ret == 0) { + *dr = group; + devres_add(dev, dr); + } else + devres_free(dr); + + return (ret); +} + #if defined(__i386__) || defined(__amd64__) bool linux_cpu_has_clflush; struct cpuinfo_x86 boot_cpu_data; From nobody Sun Jul 21 13:14:51 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRkR00CSfz5RVJX; Sun, 21 Jul 2024 13:14:52 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRkQz6KBbz4S3f; Sun, 21 Jul 2024 13:14:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721567691; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=qBER54CX6z63kKat5UoLRX4PP42FbKvVMGB6vGUZSiM=; b=ok0/py24V4pQkJreW2CVGjYqihRcQqR8VvcOByUBFIBaovY9KtqM0QEDTRFN0xbj+FXQiw 3oFr+Tjfq9++zjgrdphL1PzML/ZmLDBhuCneAm3RHok1wmwU6jrjaved/0Z0b/XKzv3dk7 4/3NvRyNZVANca2Y4G2i/lcvn0jVxHs/s30/m3MhbLmjUZNrSfU0UDL4Z5H3vUIOZO9edU tOiNaBEioQ0S0gbGjN2JtngCCCn76cI5lz4uQq8V66ChgVY4Fr559eUv03EKVCF8bueZzF 9ylkwpyoL3scvkMx172bQaHEAbvDDiHVl5eNCkH+58aseTAndE1eRkNJ8en+GQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721567691; a=rsa-sha256; cv=none; b=I+1JSQuoMUcW5GKLLJ4iv/1aocuAvcA6gMlxrEb9oL0zK0uOrUdtST8OdSjUp0YgIRaIdI Nq0D3CuztUnj+d7TZfcBnErrPGNA/vpMpNCUXhQDzMd7rjbwM6as3mwabWUdfc8vS6Gl40 GKOTKvQKowj/149T2YTtq0d1zeFIiolxUd4fuCCOXe2CR4pvx8lkSVBpBs9O+5m5rUYmOG FtD1NRczm2k8xDSe0HAwUEGlzScRtjOGrSBD/EATUnxtpOKrDMebGtHP4Ut4QFXO6i+E/p HtzolhYy+AIS7DQHmDL7vbQBj0ltZHWoOZC9U2aw7vzdJDCBJoo3te6YY1A+/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=1721567691; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=qBER54CX6z63kKat5UoLRX4PP42FbKvVMGB6vGUZSiM=; b=j/KKfqu80HE50Dhs+F54L4QWfWhjdhDVNyQR2kV6wosWWT3AlFQNayTtvwoPDtts87OT1M YDu1NeFOrE4xXbeGgHluFv1UUblL9SU1tA78thniViL0zarzptKqdWLgb97an7edAQev/Q M+59qI9iHYFM1dFP9LS/rOTlbBSnQNKPqZFI8UMi3GVpKm7/uHeNWo3J4MZ7nGR0EsxUv5 jBZIDi6c7qgbyv/l7jMlOZ232XwaGfvPcKLKjkl1ya4rYnykfZYl8uIIUfcXrmxx08tyVv UzFsF119TIBKm8jNbx5RB7pL+p4R1Ubwjw3I0us6lzzwgXyL83ERUZHFVqT5vg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRkQz5sPmz11Zg; Sun, 21 Jul 2024 13:14:51 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LDEp23023156; Sun, 21 Jul 2024 13:14:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LDEpmo023153; Sun, 21 Jul 2024 13:14:51 GMT (envelope-from git) Date: Sun, 21 Jul 2024 13:14:51 GMT Message-Id: <202407211314.46LDEpmo023153@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Vladimir Kondratyev Subject: git: 5b1171a0b75f - main - LinuxKPI: Add pci_match_id to linux/pci.h List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: wulf X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 5b1171a0b75fc88bffb5a67b0b02d8d59eb8d5c4 Auto-Submitted: auto-generated The branch main has been updated by wulf: URL: https://cgit.FreeBSD.org/src/commit/?id=5b1171a0b75fc88bffb5a67b0b02d8d59eb8d5c4 commit 5b1171a0b75fc88bffb5a67b0b02d8d59eb8d5c4 Author: Vladimir Kondratyev AuthorDate: 2024-07-21 13:09:27 +0000 Commit: Vladimir Kondratyev CommitDate: 2024-07-21 13:09:27 +0000 LinuxKPI: Add pci_match_id to linux/pci.h It finds out if a given PCI device matches a given pci_id table. Sponsored by: Serenity Cyber Security, LLC MFC after: 1 week Reviewed by: manu Differential Revision: https://reviews.freebsd.org/D45846 --- sys/compat/linuxkpi/common/include/linux/pci.h | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/sys/compat/linuxkpi/common/include/linux/pci.h b/sys/compat/linuxkpi/common/include/linux/pci.h index be3b13f07e53..9c6a52aab83f 100644 --- a/sys/compat/linuxkpi/common/include/linux/pci.h +++ b/sys/compat/linuxkpi/common/include/linux/pci.h @@ -1268,6 +1268,29 @@ pci_dev_present(const struct pci_device_id *cur) return (0); } +static inline const struct pci_device_id * +pci_match_id(const struct pci_device_id *ids, struct pci_dev *pdev) +{ + if (ids == NULL) + return (NULL); + + for (; + ids->vendor != 0 || ids->subvendor != 0 || ids->class_mask != 0; + ids++) + if ((ids->vendor == PCI_ANY_ID || + ids->vendor == pdev->vendor) && + (ids->device == PCI_ANY_ID || + ids->device == pdev->device) && + (ids->subvendor == PCI_ANY_ID || + ids->subvendor == pdev->subsystem_vendor) && + (ids->subdevice == PCI_ANY_ID || + ids->subdevice == pdev->subsystem_device) && + ((ids->class ^ pdev->class) & ids->class_mask) == 0) + return (ids); + + return (NULL); +} + struct pci_dev *lkpi_pci_get_domain_bus_and_slot(int domain, unsigned int bus, unsigned int devfn); #define pci_get_domain_bus_and_slot(domain, bus, devfn) \ From nobody Sun Jul 21 13:14:52 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRkR11qclz5RVJd; Sun, 21 Jul 2024 13:14: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRkR10MKsz4S3w; Sun, 21 Jul 2024 13:14:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721567693; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=CrQ8u5CvrOVmQ05DrLyJLlp2QWSPnFvZTe4hPOj+KJ8=; b=paXEWMNwyYlqjDLVPVTzyrM54IzITXavo1NJmZLRTkaYlbq2SoZxiCJPGpipCyaUvasKHw 4Wr20I+f3rIMS3cx/AXVc3W2a2OnzMuUiksrGxjxKP5sI8wT0nL8pQNWwghknMZ6c2+ohN 2379ZYU5hvJTCsxISpu0KaZ3BPMQLsrpsxLmDDaK86x2LHL5dBJkOxBLlukJBzzIAVi7Cu jWo9IgV6pAO5rM3z9iK5MtbRXgKhw1rZ6DScXwVtlNFaXyLmLcSuGgJu7/xy0zKDf6+CK1 /nItZn3qGhHfLhdqadB/uPnAoe0xQ8fAzlcWO3ldtf0O9XF92+UQMgrjK4H2zw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721567693; a=rsa-sha256; cv=none; b=smAl4ssFMpXEnLvEHJTItcUVyJ1fmzmm7GGMLyMA3zX2fAT5njNfyBLFRQQ+6GaFWvDNJb xprM7+1dxR0BSLom1QVR3pWYslUUG9f9YQchvkG38RlQFbBIqlKSop3CTvww3vZJZxTkPB 7Jq4QM1KeCaSDCGDXvld/PerUQ9ij9q4TeE5FIkh9B6PfWjddhf8SSnYvDwii2HS8t9AIM iUNP21GDdXXFCFGHHORKE/SlH0F+d9re1BJS3so/pzjFHGaZx467xxPz5sphGIke9Puw4K /Y1ynYUDFcK6WvzgwLuHUKEm45OgOpQHsIDzbPkJMyGJw2JWKb+qr98zZi4ZQw== 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=1721567693; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=CrQ8u5CvrOVmQ05DrLyJLlp2QWSPnFvZTe4hPOj+KJ8=; b=dAlye5Ql+O4c8ClyoBJ7DJcbPayak0oGi/AcFQIN4Iz1RYSRMJVuNfNHGGY3VWswWUAm0F T9bY+6A2Mty6rMyykoKyJmiOucD23Km7To7UlZiZHFPPRnAXfwq/tEfkeMP3ObWuXpsiEa GVykoeeN8N3tkUO512qYq+oSKxs6ZCEmEoPnD04oDVv7poZ30Q3fMT7i+z609xvI3D+H0i gOX08zApAWAok1YbNJFVjZUU3LJ5xuDJiP50AdXP04Bzv3AY89oRVY3qZ2elUhWnUAQ6wi EEDfPG5yEUJbsOccrg0Ot/F/ZX63us2L2GIMYNC08v9NN0UlNrJ9ZCIr21HEYw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRkR06lpxz11Zh; Sun, 21 Jul 2024 13:14:52 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LDEqQe023204; Sun, 21 Jul 2024 13:14:52 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LDEqmx023201; Sun, 21 Jul 2024 13:14:52 GMT (envelope-from git) Date: Sun, 21 Jul 2024 13:14:52 GMT Message-Id: <202407211314.46LDEqmx023201@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Vladimir Kondratyev Subject: git: 3e90716331cd - main - LinuxKPI: Add acpi_dev_get_first_match_dev and acpi_device_handle List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: wulf X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 3e90716331cdbdee7465213d389a33f90dad11cf Auto-Submitted: auto-generated The branch main has been updated by wulf: URL: https://cgit.FreeBSD.org/src/commit/?id=3e90716331cdbdee7465213d389a33f90dad11cf commit 3e90716331cdbdee7465213d389a33f90dad11cf Author: Vladimir Kondratyev AuthorDate: 2024-07-21 13:09:37 +0000 Commit: Vladimir Kondratyev CommitDate: 2024-07-21 13:09:37 +0000 LinuxKPI: Add acpi_dev_get_first_match_dev and acpi_device_handle acpi_dev_get_first_match_dev returns the first match of ACPI device and acpi_device_handle returns its ACPI handle. Sponsored by: Serenity Cyber Security, LLC MFC after: 1 week Reviewed by: manu Differential Revision: https://reviews.freebsd.org/D45847 --- sys/compat/linuxkpi/common/include/acpi/acpi_bus.h | 7 +++++ sys/compat/linuxkpi/common/include/linux/acpi.h | 4 +++ sys/compat/linuxkpi/common/src/linux_acpi.c | 32 ++++++++++++++++++++++ 3 files changed, 43 insertions(+) diff --git a/sys/compat/linuxkpi/common/include/acpi/acpi_bus.h b/sys/compat/linuxkpi/common/include/acpi/acpi_bus.h index f107902a26ad..65bcbe7f1bdd 100644 --- a/sys/compat/linuxkpi/common/include/acpi/acpi_bus.h +++ b/sys/compat/linuxkpi/common/include/acpi/acpi_bus.h @@ -29,6 +29,9 @@ #ifndef _LINUXKPI_ACPI_ACPI_BUS_H_ #define _LINUXKPI_ACPI_ACPI_BUS_H_ +/* Aliase struct acpi_device to device_t */ +#define acpi_device _device + typedef char acpi_device_class[20]; struct acpi_bus_event { @@ -38,6 +41,8 @@ struct acpi_bus_event { }; #define acpi_dev_present(...) lkpi_acpi_dev_present(__VA_ARGS__) +#define acpi_dev_get_first_match_dev(...) \ + lkpi_acpi_dev_get_first_match_dev(__VA_ARGS__) ACPI_HANDLE bsd_acpi_get_handle(device_t bsddev); bool acpi_check_dsm(ACPI_HANDLE handle, const char *uuid, int rev, @@ -50,5 +55,7 @@ int unregister_acpi_notifier(struct notifier_block *nb); uint32_t acpi_target_system_state(void); bool lkpi_acpi_dev_present(const char *hid, const char *uid, int64_t hrv); +struct acpi_device *lkpi_acpi_dev_get_first_match_dev(const char *hid, + const char *uid, int64_t hrv); #endif /* _LINUXKPI_ACPI_ACPI_BUS_H_ */ diff --git a/sys/compat/linuxkpi/common/include/linux/acpi.h b/sys/compat/linuxkpi/common/include/linux/acpi.h index 610aa0784cb9..3e1ec1b20626 100644 --- a/sys/compat/linuxkpi/common/include/linux/acpi.h +++ b/sys/compat/linuxkpi/common/include/linux/acpi.h @@ -39,6 +39,10 @@ #define ACPI_HANDLE(dev) \ ((dev)->bsddev != NULL ? bsd_acpi_get_handle((dev)->bsddev) : NULL) +#define acpi_device_handle(dev) \ + ((dev) != NULL ? bsd_acpi_get_handle(dev) : NULL) +static inline void acpi_dev_put(struct acpi_device *adev) {} +#define acpi_handle_debug(handle, fmt, ...) #endif diff --git a/sys/compat/linuxkpi/common/src/linux_acpi.c b/sys/compat/linuxkpi/common/src/linux_acpi.c index 60ec838e9da7..6a9afb3ddff0 100644 --- a/sys/compat/linuxkpi/common/src/linux_acpi.c +++ b/sys/compat/linuxkpi/common/src/linux_acpi.c @@ -180,6 +180,7 @@ struct acpi_dev_present_ctx { const char *hid; const char *uid; int64_t hrv; + struct acpi_device *dev; }; static ACPI_STATUS @@ -187,6 +188,7 @@ acpi_dev_present_cb(ACPI_HANDLE handle, UINT32 level, void *context, void **result) { ACPI_DEVICE_INFO *devinfo; + struct acpi_device *dev; struct acpi_dev_present_ctx *match = context; bool present = false; UINT32 sta, hrv; @@ -230,6 +232,11 @@ acpi_dev_present_cb(ACPI_HANDLE handle, UINT32 level, void *context, return (AE_OK); } + dev = acpi_get_device(handle); + if (dev == NULL) + return (AE_OK); + match->dev = dev; + return (AE_ERROR); } @@ -249,6 +256,24 @@ lkpi_acpi_dev_present(const char *hid, const char *uid, int64_t hrv) return (rv == AE_ERROR); } +struct acpi_device * +lkpi_acpi_dev_get_first_match_dev(const char *hid, const char *uid, + int64_t hrv) +{ + struct acpi_dev_present_ctx match; + int rv; + + match.hid = hid; + match.uid = uid; + match.hrv = hrv; + match.dev = NULL; + + rv = AcpiWalkNamespace(ACPI_TYPE_DEVICE, ACPI_ROOT_OBJECT, + ACPI_UINT32_MAX, acpi_dev_present_cb, NULL, &match, NULL); + + return (rv == AE_ERROR ? match.dev : NULL); +} + static void linux_register_acpi_event_handlers(void *arg __unused) { @@ -322,4 +347,11 @@ lkpi_acpi_dev_present(const char *hid, const char *uid, int64_t hrv) return (false); } +struct acpi_device * +lkpi_acpi_dev_get_first_match_dev(const char *hid, const char *uid, + int64_t hrv) +{ + return (NULL); +} + #endif /* !DEV_ACPI */ From nobody Sun Jul 21 13:14:53 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRkR24ldsz5RVJm; Sun, 21 Jul 2024 13:14: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRkR21TF5z4S4D; Sun, 21 Jul 2024 13:14:54 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721567694; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=hCzORKFKq8/Ij3ROu57PSfsi9cNO3SSIbEPIjKZVP78=; b=GqQo16D0GjKP3j0rUZ9WrX4Q5JyysBMctgSvKLX3DlZ6MyVwbTIXvjcEWMtT1KflimeFU5 fbDTN/U3yL/ayg920qwTRLDKXAVE4IJIaA0hn+9MIDsfd/X6Js2OM2+f84JRhTlCzFa0Nb 0erZ8JdKfVZvXFkfQp0OOmqjb4jAXH0cpiq0Dzn6rG3dvFJDnIKjnyJiaeUfxMEvs7Svyd TcKmcoce6DHkfrCGYoIc1JB06q/nA0DK3MBvx+OMQZDwE1dpMJpUTVbkjNCv3hJqGp9Z9z Ycv4Ct9H1JbH2iope8D2cHfu3pz1/NjGMxtUMRpTLE0RufQEW3vjWHuRI43fFA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721567694; a=rsa-sha256; cv=none; b=GmVieaJxBR5Xo63sD/z7otqH2DFTlT1euHVm6sg7p32+N0Egkk/GTGpBz3wekeB65gPELi 8IDPkuvz3E9/coNThBljijXc5Fkc5MomP3qu9D3jkiQTD1/4+mNdZtXdPt9cSPYPfZbJEK Hs1Qyqvg2Lgn1wUZWV1FOOEWKnptrw64BlHhU6qTMZXHOzc5Qai1htuaVomYpSSUSqxAD8 JiEnpM5NjT5Z+e0ttRKZfX9OEjK/9T4NG0qi4wcYuGmtwiE85E3dYCDzDwvuhQ8AYHAiHl MHii1W+jnCf9x5vRWCxdQG9Pu7LQCR0J5dge319S3nGPOHba+1VFCz+Val+xtA== 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=1721567694; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=hCzORKFKq8/Ij3ROu57PSfsi9cNO3SSIbEPIjKZVP78=; b=LVxvj3bUuqZxhxdLpke3xnqXqr/6jrSkq4Ivw4tIU8M2nWvBcdiQbx0MnMofKg4HBGtwQp wVF/Z9vJuorzWqgbLrerQFDrR7UoSP1t8C9OJdvMTKu9GKMFaWCvqMddbRSDjEe1bCib+/ 0Czff8f5NeNaG8ELEJw6Ok2v1MqK0h+02cLxkiv7EFCuq+ldtIZn4CZALoSKGycjMmHT45 m2ipwu8+xBT8MaRJ0dZx8WDTZg80d8ve/CQmSfwUD8SY0yQ2JGbVquNbTIP0p6LqldecVM K0Zk6vlsm8vgAkIPY6L3+U0C5Xy+a3v+gLMeCdfJkT6aHC1Bz+9iGyoDwnMXpw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRkR20Q1hz11xQ; Sun, 21 Jul 2024 13:14:54 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LDEsts023252; Sun, 21 Jul 2024 13:14:54 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LDErRH023249; Sun, 21 Jul 2024 13:14:53 GMT (envelope-from git) Date: Sun, 21 Jul 2024 13:14:53 GMT Message-Id: <202407211314.46LDErRH023249@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Vladimir Kondratyev Subject: git: 7774e08adf6c - main - LinuxKPI: Add linux/eventfd.h and linux/memremap.h dummy headers List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: wulf X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 7774e08adf6c6364a0c7f07e8c40fb1ea7cc78e5 Auto-Submitted: auto-generated The branch main has been updated by wulf: URL: https://cgit.FreeBSD.org/src/commit/?id=7774e08adf6c6364a0c7f07e8c40fb1ea7cc78e5 commit 7774e08adf6c6364a0c7f07e8c40fb1ea7cc78e5 Author: Vladimir Kondratyev AuthorDate: 2024-07-21 13:09:48 +0000 Commit: Vladimir Kondratyev CommitDate: 2024-07-21 13:09:48 +0000 LinuxKPI: Add linux/eventfd.h and linux/memremap.h dummy headers Sponsored by: Serenity Cyber Security, LLC MFC after: 1 week Reviewed by: manu Differential Revision: https://reviews.freebsd.org/D45848 --- sys/compat/linuxkpi/dummy/include/linux/eventfd.h | 0 sys/compat/linuxkpi/dummy/include/linux/memremap.h | 0 2 files changed, 0 insertions(+), 0 deletions(-) diff --git a/sys/compat/linuxkpi/dummy/include/linux/eventfd.h b/sys/compat/linuxkpi/dummy/include/linux/eventfd.h new file mode 100644 index 000000000000..e69de29bb2d1 diff --git a/sys/compat/linuxkpi/dummy/include/linux/memremap.h b/sys/compat/linuxkpi/dummy/include/linux/memremap.h new file mode 100644 index 000000000000..e69de29bb2d1 From nobody Sun Jul 21 13:14:55 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRkR35MtPz5RV2f; Sun, 21 Jul 2024 13:14: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRkR32Xynz4S7v; Sun, 21 Jul 2024 13:14:55 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721567695; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=41ueWV+nd+58uDex5iY4JxpsqFjer/zkI492fQkxBZc=; b=Z/zxPPlF6E4xM60CzPWtS+7uMuJ2vGjDqy+Fw8ZM5NxWEUn11qzbkAA+DeM22SFIO9qJ01 aej4OusV7byx0a7pbeiFweLDeIajXXPp+4xDCSZuJAcac5gFMplgr2V3i7ZrYljk33/mTx 4IZymFyoetSKhjXQy0uEK2i41FUF2FSKV8D43N/8YuZ+7g8Q++lNGEZCLvh9gevUxX1c57 nwil31WsdQH/zFaBZlEXo8yqv+AaoYji/+mQUEcGsc1gR8lPgZAonVghjOQZAtbYM0QtN1 ptg665i53s6VgPsT4tF3xsLm8+VqOUWMHM7Pnkr7rMikwhq+FYpni9O8qBHNfw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721567695; a=rsa-sha256; cv=none; b=OjKbYq3p8xns7OomCXPJ8zuRgNTI7wbTtmSC2ZY2/gdnf6mpaSDZM3VZ+82giulv3ImLwk XSHslk38RYticUP+P18Wf48lfjUmUUX03QUWMs3dobuvJuSZkqj+WOinA5dq55r6k5ho7Z 4l9a6h6L6TGO7N3R5ebLT/1hUmFMndjslKsgG3K8zJ71ONaYt+GKdg0oJ/z90yPNuPVBhz nzD11tmzU47U7zZ2+zhFW+sQWhLr01Nnh5lwhaoEhrS4ibMJUU90S6g0A/BapdOMP+3aur fH3cKkP5yi1XmcyU2JC9RUFfuIVCQKtxohiSX5r6kdup7MucFagfHvTyKMZ/Nw== 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=1721567695; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=41ueWV+nd+58uDex5iY4JxpsqFjer/zkI492fQkxBZc=; b=BOCG+B0s8ODCgafGD07c7I/RPqFXMgGH35Z9Cv0risNzrKheykgesAJO1zd0ElrR93RbE8 0A8YHQQxKK3IsNj6dxjdp7kO+R8AcDq7+FW0qtCrdPk+33IckuT403kvecNOth9eYOq7ZS aPIJ8geGtvWDBHJoTfhrgv+HvSkCz+3ktuZKDcoUqI4BGsEXq4x9WNqFFHP/s/RWYhKRjM CUCa9wHYjQyDfk7eqH92Zwq/ZY1/npAKZIGy6XzjQVQgeuYlQCIe5uBuxVbbT9dL9NsXQB 3RacVfib1KrfImSQeKtJTm5ZBisiH7dPJAQwz4i8hxOMaOJ5rDSxl45X/7LGlw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRkR31tC2z12Bk; Sun, 21 Jul 2024 13:14:55 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LDEtN7023309; Sun, 21 Jul 2024 13:14:55 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LDEtsT023306; Sun, 21 Jul 2024 13:14:55 GMT (envelope-from git) Date: Sun, 21 Jul 2024 13:14:55 GMT Message-Id: <202407211314.46LDEtsT023306@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Vladimir Kondratyev Subject: git: 1fe7cd024342 - main - LinuxKPI: Remove owner argument from class_create function on KBI layer List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: wulf X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 1fe7cd02434257692100c484cd345566c9dba528 Auto-Submitted: auto-generated The branch main has been updated by wulf: URL: https://cgit.FreeBSD.org/src/commit/?id=1fe7cd02434257692100c484cd345566c9dba528 commit 1fe7cd02434257692100c484cd345566c9dba528 Author: Vladimir Kondratyev AuthorDate: 2024-07-21 13:09:58 +0000 Commit: Vladimir Kondratyev CommitDate: 2024-07-21 13:09:58 +0000 LinuxKPI: Remove owner argument from class_create function on KBI layer To chase Linux 6.4 Sponsored by: Serenity Cyber Security, LLC Differential Revision: https://reviews.freebsd.org/D45849 --- sys/compat/linuxkpi/common/include/linux/device.h | 7 ++++--- sys/compat/linuxkpi/common/src/linux_compat.c | 3 +-- sys/ofed/drivers/infiniband/core/ib_cm.c | 1 - 3 files changed, 5 insertions(+), 6 deletions(-) diff --git a/sys/compat/linuxkpi/common/include/linux/device.h b/sys/compat/linuxkpi/common/include/linux/device.h index 912be8fbae8b..f56a39e904c8 100644 --- a/sys/compat/linuxkpi/common/include/linux/device.h +++ b/sys/compat/linuxkpi/common/include/linux/device.h @@ -57,7 +57,6 @@ struct device; struct class { const char *name; - struct module *owner; struct kobject kobj; devclass_t bsdclass; const struct dev_pm_ops *pm; @@ -342,9 +341,11 @@ put_device(struct device *dev) kobject_put(&dev->kobj); } -struct class *class_create(struct module *owner, const char *name); +struct class *lkpi_class_create(const char *name); #if defined(LINUXKPI_VERSION) && LINUXKPI_VERSION >= 60400 -#define class_create(name) class_create(NULL, name) +#define class_create(name) lkpi_class_create(name) +#else +#define class_create(owner, name) lkpi_class_create(name) #endif static inline int diff --git a/sys/compat/linuxkpi/common/src/linux_compat.c b/sys/compat/linuxkpi/common/src/linux_compat.c index ec4e59f66e7f..9962154cffd9 100644 --- a/sys/compat/linuxkpi/common/src/linux_compat.c +++ b/sys/compat/linuxkpi/common/src/linux_compat.c @@ -342,13 +342,12 @@ error: } struct class * -class_create(struct module *owner, const char *name) +lkpi_class_create(const char *name) { struct class *class; int error; class = kzalloc(sizeof(*class), M_WAITOK); - class->owner = owner; class->name = name; class->class_release = linux_class_kfree; error = class_register(class); diff --git a/sys/ofed/drivers/infiniband/core/ib_cm.c b/sys/ofed/drivers/infiniband/core/ib_cm.c index 7ace287b1c88..046f10e085c7 100644 --- a/sys/ofed/drivers/infiniband/core/ib_cm.c +++ b/sys/ofed/drivers/infiniband/core/ib_cm.c @@ -4008,7 +4008,6 @@ static char *cm_devnode(struct device *dev, umode_t *mode) } struct class cm_class = { - .owner = THIS_MODULE, .name = "infiniband_cm", .devnode = cm_devnode, }; From nobody Sun Jul 21 13:14:56 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRkR50L8Lz5RV2j; Sun, 21 Jul 2024 13:14: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRkR44pttz4Rvl; Sun, 21 Jul 2024 13:14:56 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721567696; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Mr8v2GIQ4GMcxneFKXQCQLGG5p92Vtb3flo8z2b3x6M=; b=f19UemRLdJ1z+OxaAjmA1JmX4EW5dRuuuTbEzecnuJrf8jc4hu/C5d3w9qMGsXtG0XW28T rzT02tcmcXCVHRxEcRHIy1R1qc3/L8+p/U7MZkaq/4eph3XomzWMyNdixvkmQkAiJPdBrO kDwiCZvuypsRWr68MPTr+3/PCSUnkoJKbO6ppNbQWb9YoTt79iHVlm4y9I+zBl6TtrCqS4 H1ml0OUUslXArvVeO1jF8kCwHVlKWmIy+l7KFXYJ6fe6VciXDg5SXbVSdYDXSxR+kIrmvN piyqAQY4IVpwLkfhck6GkRcTgLCVsF1m39LYF/rbrPxOVob3nl0Cews6JTqIPQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721567696; a=rsa-sha256; cv=none; b=gZEAsf1NKVdfuO3RG1Jj9gaBz1XwJCcermwrZ1vdJCy+qRP328gjeaXBwR/ajrqVSpfybZ i5QYdeRZ2VQIiqayfb+ge4JWsNmiN1R0OtMlHYFykHOPmS99HznsfOBwuJOKv7CwQlExxJ k045IEco3stoI1q6V9YrwXGV87fbt9CtKqEYCCtvKboIwH/sR+E+SPA7YQW0V+9laJmLY8 Y1dBSTsZhxlvhVdZgOcqcZJQK1FWbfKI2gjMdzfnVdXuKw+pgXjTgSZ9GhGT0iY5GU6ADr 85LnlrB6HHce/hvpZ/CRxYfF0gXacGfSZP+53VWQO0k2pie0Gqo/nMl8Hk0Ocg== 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=1721567696; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Mr8v2GIQ4GMcxneFKXQCQLGG5p92Vtb3flo8z2b3x6M=; b=EnrP0gZO8M+Cx6N7JC3dNUPIqdX/FNsbch1KedDuBJI3nPk6d4Ve0VN7+I+Nybb0GFIo7Q YUfBB1uieZ+qHN4GICiH/n/fHxQx7R0datUydD2/mm27P/A1+UIy5Mo5jYGhjAohrE7Pcg 5dUq1Nf2+HkwNrL3Ryez1oe5uRnZx/karnWD383yevqhNq1KzES0hgdWMDvviIGA+lrNnP NpNl/HbPdW6avWmF7+dGunkhuyqxdcy7E5hVNb2cvo6z61kuJ5MLmdMP4JqgXdSGC42k+v Q+R/oHPc6f76oQNMS6MLpOgCadhJQNNtfBrEIsvKOun7pmzadtTL3Y9cjSyedg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRkR432gHz12Bl; Sun, 21 Jul 2024 13:14:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LDEuqB023363; Sun, 21 Jul 2024 13:14:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LDEuvo023360; Sun, 21 Jul 2024 13:14:56 GMT (envelope-from git) Date: Sun, 21 Jul 2024 13:14:56 GMT Message-Id: <202407211314.46LDEuvo023360@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Vladimir Kondratyev Subject: git: d42136e36162 - main - LinuxKPI: Remove vmas argument from get_user_pages on KBI layer List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: wulf X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: d42136e36162d60ea543ae346f32edd321de3f6e Auto-Submitted: auto-generated The branch main has been updated by wulf: URL: https://cgit.FreeBSD.org/src/commit/?id=d42136e36162d60ea543ae346f32edd321de3f6e commit d42136e36162d60ea543ae346f32edd321de3f6e Author: Vladimir Kondratyev AuthorDate: 2024-07-21 13:10:14 +0000 Commit: Vladimir Kondratyev CommitDate: 2024-07-21 13:10:14 +0000 LinuxKPI: Remove vmas argument from get_user_pages on KBI layer To chase Linux kernel 6.5 Sponsored by: Serenity Cyber Security, LLC Reviewed by: manu Differential Revision: https://reviews.freebsd.org/D45850 --- sys/compat/linuxkpi/common/include/linux/mm.h | 10 ++++++---- sys/compat/linuxkpi/common/src/linux_page.c | 4 ++-- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/sys/compat/linuxkpi/common/include/linux/mm.h b/sys/compat/linuxkpi/common/include/linux/mm.h index 56c849b02c32..b4c8bf3c1c30 100644 --- a/sys/compat/linuxkpi/common/include/linux/mm.h +++ b/sys/compat/linuxkpi/common/include/linux/mm.h @@ -276,12 +276,14 @@ get_page(struct page *page) } extern long -get_user_pages(unsigned long start, unsigned long nr_pages, - unsigned int gup_flags, struct page **, - struct vm_area_struct **); +lkpi_get_user_pages(unsigned long start, unsigned long nr_pages, + unsigned int gup_flags, struct page **); #if defined(LINUXKPI_VERSION) && LINUXKPI_VERSION >= 60500 #define get_user_pages(start, nr_pages, gup_flags, pages) \ - get_user_pages(start, nr_pages, gup_flags, pages, NULL) + lkpi_get_user_pages(start, nr_pages, gup_flags, pages) +#else +#define get_user_pages(start, nr_pages, gup_flags, pages, vmas) \ + lkpi_get_user_pages(start, nr_pages, gup_flags, pages) #endif #if defined(LINUXKPI_VERSION) && LINUXKPI_VERSION >= 60500 diff --git a/sys/compat/linuxkpi/common/src/linux_page.c b/sys/compat/linuxkpi/common/src/linux_page.c index 8b78a3739f25..d4f8e75a3251 100644 --- a/sys/compat/linuxkpi/common/src/linux_page.c +++ b/sys/compat/linuxkpi/common/src/linux_page.c @@ -277,8 +277,8 @@ get_user_pages_remote(struct task_struct *task, struct mm_struct *mm, } long -get_user_pages(unsigned long start, unsigned long nr_pages, - unsigned int gup_flags, struct page **pages, struct vm_area_struct **vmas) +lkpi_get_user_pages(unsigned long start, unsigned long nr_pages, + unsigned int gup_flags, struct page **pages) { vm_map_t map; From nobody Sun Jul 21 13:14:57 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRkR60qy3z5RVSP; Sun, 21 Jul 2024 13:14: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRkR5495Lz4S1x; Sun, 21 Jul 2024 13:14:57 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721567697; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=HwcVFe2j9os/JX6RlnSKEFxXk903YYF4VAlhyQTXAEc=; b=jBpHwCYbRY8QmImSM/3M/xE3GsEeQtQcXyYWH4ATwK+oE6vS/SAvXLaXwPYyG/vzLEonlL 5VSlR7j2rmDQ+Edza75bS8p7VbDqQd0cnZUXgkgpifeEH0iOBklyrDWqQBG+6VgpL3a7kV DyQHsFewn8PJ/Gc8Uc4U1K1aUy1DFUJap980A0q1Bn9ddru8F2nEkhta2A2Zq+UDa63hKM 7dKQFQGiit4WENHIoQbDZbTcu8OOp2dmYIaMIxIOdf21O3IPRAf+U37Z5i86T9wRnjBfxc ccsyd7lRj04CG1eDoHUJIlAGrqVAUhMJXof+Gw+H0KQ26T0V0MmTarHdyrpDFw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721567697; a=rsa-sha256; cv=none; b=uOOGhGoR7yN4GOdRtquX1kOzgMWPuingptCD7GGAxjS7RXnmtzZJp8Ghavl++x9FJ/9pB6 Z4mpXI02IP5z6i+AIimX8dzf23oYqEYmaOD92m/WiWC99kR4mHIIRMY52AD2YUMS5qnetv lPQrdhNyFCUm9TSsrSK1YsdhoVhT1wY0/vz8C3LoRbRBgtdHQotS/LRnb88pbm2B6LHppj Q5gejMojU83NqB6StU6QtydjcsDQzzTG89J0GP1LsNIHKYc55qdgdY/9KY/UUBK4QE0uZK FgXhqjm1D6zZDLVrRbjN4fVS+JlgF2j9a9+Ok6oyFGi/9tWaGnoxBGQRD15f7Q== 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=1721567697; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=HwcVFe2j9os/JX6RlnSKEFxXk903YYF4VAlhyQTXAEc=; b=MCcsaDcBrL0uOKXun6p+tmyu7WGDNyAEWx5kNq4oxJIVzpvyb9i23vRxh9Pqh0rZsA5eJt fxlrIkeeaurDw5pShjjSfCfiRGQc4y78nQ0WRF9HyaldQ8DFfKHOOfZXqvsFqMFoHkxoGG 3t3p5Ouih8c4beZZLuaPzrWVQRuP6UWYDopzkL9xFN16STCB4bwa5g+vRlQcfHMi4MkG9b qQvCmeuXXIU43emA3hDL1199OL574wKNSucDsTfof0taYdpgbxPv3SDIaz9kZ6ZCSr6EcU l/Fidj3+m2fzRbqT2WVaPwRc7TvVyrTj4Zm5oIhlxvhNRZaGELOn0pX25Yo16g== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRkR53Qmnz12Bm; Sun, 21 Jul 2024 13:14:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LDEvNf023402; Sun, 21 Jul 2024 13:14:57 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LDEv9l023399; Sun, 21 Jul 2024 13:14:57 GMT (envelope-from git) Date: Sun, 21 Jul 2024 13:14:57 GMT Message-Id: <202407211314.46LDEv9l023399@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Vladimir Kondratyev Subject: git: fcc350c375f7 - main - LinuxKPI: Add pci_iomap_range function List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: wulf X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: fcc350c375f776318d0da8021109631492ab9261 Auto-Submitted: auto-generated The branch main has been updated by wulf: URL: https://cgit.FreeBSD.org/src/commit/?id=fcc350c375f776318d0da8021109631492ab9261 commit fcc350c375f776318d0da8021109631492ab9261 Author: Vladimir Kondratyev AuthorDate: 2024-07-21 13:10:25 +0000 Commit: Vladimir Kondratyev CommitDate: 2024-07-21 13:10:25 +0000 LinuxKPI: Add pci_iomap_range function pci_iomap_range creates a virtual mapping cookie for a PCI BAR. As compared with pci_iomap it got extra offset parameter. Sponsored by: Serenity CyberSecurity, LLC MFC after: 1 week Reviewed by: manu, bz Differential Revision: https://reviews.freebsd.org/D45904 --- sys/compat/linuxkpi/common/include/linux/pci.h | 4 ++++ sys/compat/linuxkpi/common/src/linux_pci.c | 16 +++++++++++++--- 2 files changed, 17 insertions(+), 3 deletions(-) diff --git a/sys/compat/linuxkpi/common/include/linux/pci.h b/sys/compat/linuxkpi/common/include/linux/pci.h index 9c6a52aab83f..9457599d31d3 100644 --- a/sys/compat/linuxkpi/common/include/linux/pci.h +++ b/sys/compat/linuxkpi/common/include/linux/pci.h @@ -362,6 +362,8 @@ bool pci_device_is_present(struct pci_dev *pdev); int linuxkpi_pcim_enable_device(struct pci_dev *pdev); void __iomem **linuxkpi_pcim_iomap_table(struct pci_dev *pdev); +void *linuxkpi_pci_iomap_range(struct pci_dev *pdev, int mmio_bar, + unsigned long mmio_off, unsigned long mmio_size); void *linuxkpi_pci_iomap(struct pci_dev *pdev, int mmio_bar, int mmio_size); void linuxkpi_pci_iounmap(struct pci_dev *pdev, void *res); int linuxkpi_pcim_iomap_regions(struct pci_dev *pdev, uint32_t mask, @@ -774,6 +776,8 @@ static inline void pci_disable_sriov(struct pci_dev *dev) { } +#define pci_iomap_range(pdev, mmio_bar, mmio_off, mmio_size) \ + linuxkpi_pci_iomap_range(pdev, mmio_bar, mmio_off, mmio_size) #define pci_iomap(pdev, mmio_bar, mmio_size) \ linuxkpi_pci_iomap(pdev, mmio_bar, mmio_size) #define pci_iounmap(pdev, res) linuxkpi_pci_iounmap(pdev, res) diff --git a/sys/compat/linuxkpi/common/src/linux_pci.c b/sys/compat/linuxkpi/common/src/linux_pci.c index 51a3b0b2ebe1..3287a8a15ff5 100644 --- a/sys/compat/linuxkpi/common/src/linux_pci.c +++ b/sys/compat/linuxkpi/common/src/linux_pci.c @@ -755,7 +755,8 @@ _lkpi_pci_iomap(struct pci_dev *pdev, int bar, int mmio_size __unused) } void * -linuxkpi_pci_iomap(struct pci_dev *pdev, int mmio_bar, int mmio_size) +linuxkpi_pci_iomap_range(struct pci_dev *pdev, int mmio_bar, + unsigned long mmio_off, unsigned long mmio_size) { struct resource *res; @@ -765,7 +766,14 @@ linuxkpi_pci_iomap(struct pci_dev *pdev, int mmio_bar, int mmio_size) /* This is a FreeBSD extension so we can use bus_*(). */ if (pdev->want_iomap_res) return (res); - return ((void *)rman_get_bushandle(res)); + MPASS(mmio_off < rman_get_size(res)); + return ((void *)(rman_get_bushandle(res) + mmio_off)); +} + +void * +linuxkpi_pci_iomap(struct pci_dev *pdev, int mmio_bar, int mmio_size) +{ + return (linuxkpi_pci_iomap_range(pdev, mmio_bar, 0, mmio_size)); } void @@ -774,7 +782,9 @@ linuxkpi_pci_iounmap(struct pci_dev *pdev, void *res) struct pci_mmio_region *mmio, *p; TAILQ_FOREACH_SAFE(mmio, &pdev->mmio, next, p) { - if (res != (void *)rman_get_bushandle(mmio->res)) + if ((bus_space_handle_t)res < rman_get_bushandle(mmio->res) || + (bus_space_handle_t)res >= rman_get_bushandle(mmio->res) + + rman_get_size(mmio->res)) continue; bus_release_resource(pdev->dev.bsddev, mmio->type, mmio->rid, mmio->res); From nobody Sun Jul 21 13:14:58 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRkR70QNNz5RVVX; Sun, 21 Jul 2024 13:14: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRkR65QmYz4S8f; Sun, 21 Jul 2024 13:14:58 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721567698; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=4B45ruZkTaJ2wsc0x/dflLGkpqXFElg5y9ZlbTE7IGE=; b=Ay2L40nFOA0MBeR2Dd+YGt8mM3vs5zu6LkEYOhVJgCdBDSep6awlTKRN58/m6R7mSp3iai 3gzAxmWBFd1G9CQxRVtp5KcnfSqetbsDv0Nqz9fnvqRYjbfv+iXnjQNiJGzdEEZq53D3ul vObk6uuE8fc64QSEvWztUJMfrpqYzlNotaQc8mUuUaosUEm1LJ5adMmnRXowVeJnUE3yAv UQ75r9LdZQ4roworV72Z3bKJ9gVNK/CCPkeH+3HNHVvFKWTsvrfgIIrNqFNVcs5064P0LR 10xrDIDOeJVvdve6ak/HBhMOuT5qc9lYdpl9JG/Y9X1cO6SaqkgI5FYViOlEkA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721567698; a=rsa-sha256; cv=none; b=xaNRBNImZgKcalsBO4xcl8ptyx1zAqNXycMzHAA73tUQzmNIeGbPznJyssRqN9855sFyrB E+4puo+jz3yOdLFEPF75iiG6c4CPMWF123obrFWa0eWRDd9DgEoVDlfmGNtYZLEJaISpxB Rg+VA/wIpdgfpNJ8T2qVeV4rwO34lfVzfxjT/fKWEf89CWxW5Sb52OFYpNsQrMB4FzQiiC An32C7NMb8DABR9gK6ke++ZJ79RLjlfUC3PCDttk1hwOScX1NnjXCx/+bLrEB8cWSVGhZD ChtsfheBdfY6sAtZBeyQqiNqo9SOuCqA3ZpnSoWZclvN7fW5wy+04gO+xuFSwg== 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=1721567698; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=4B45ruZkTaJ2wsc0x/dflLGkpqXFElg5y9ZlbTE7IGE=; b=tZs/aXVHCIPMF6+cFyOVLrTUV6Yd+YXGGk2KprjICTs656vckO8mO/Em8Lau1ognXKEPzt qZBRx5D9DCU7p5L/xt51hsdVYZWnTEX9jm+O898M3iBOgCi/KKk5iTaeTL2JiOzKea4FpD REuwoxTw4q0cSLLM6vBKps+0HyhBeInckuDZBpZQ9KIT9ESnnFMPiZgFUZyPrNvAk5FNoc tXMmWahGpIwzH5Tw+6x9qt5Bp6zbnlwEwzcFBDboJ9JlFoCgjnx7RjsppAIvEluxuE4KkF sPQ7kWHWLxNQzNdQWSI7uNN/3PgMidMgbvUZiFynMQN7yW+6b+5Mbf0o05isIg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRkR64fx4z11mB; Sun, 21 Jul 2024 13:14:58 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LDEwKA023462; Sun, 21 Jul 2024 13:14:58 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LDEwoM023459; Sun, 21 Jul 2024 13:14:58 GMT (envelope-from git) Date: Sun, 21 Jul 2024 13:14:58 GMT Message-Id: <202407211314.46LDEwoM023459@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Vladimir Kondratyev Subject: git: 14fc33ea3a05 - main - LinuxKPI: Fix resource leak on pci_iounmap-ing of PCI BAR List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: wulf X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 14fc33ea3a0571ca70e609b6f9e67db39f7c6140 Auto-Submitted: auto-generated The branch main has been updated by wulf: URL: https://cgit.FreeBSD.org/src/commit/?id=14fc33ea3a0571ca70e609b6f9e67db39f7c6140 commit 14fc33ea3a0571ca70e609b6f9e67db39f7c6140 Author: Vladimir Kondratyev AuthorDate: 2024-07-21 13:10:44 +0000 Commit: Vladimir Kondratyev CommitDate: 2024-07-21 13:10:44 +0000 LinuxKPI: Fix resource leak on pci_iounmap-ing of PCI BAR If the resource was allocated with want_iomap_res flag set. Sponsored by: Serenity CyberSecurity, LLC MFC after: 1 week Reviewed by: manu, bz Differential Revision: https://reviews.freebsd.org/D45905 --- sys/compat/linuxkpi/common/src/linux_pci.c | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/sys/compat/linuxkpi/common/src/linux_pci.c b/sys/compat/linuxkpi/common/src/linux_pci.c index 3287a8a15ff5..3376d93053dc 100644 --- a/sys/compat/linuxkpi/common/src/linux_pci.c +++ b/sys/compat/linuxkpi/common/src/linux_pci.c @@ -780,12 +780,18 @@ void linuxkpi_pci_iounmap(struct pci_dev *pdev, void *res) { struct pci_mmio_region *mmio, *p; + bus_space_handle_t bh = (bus_space_handle_t)res; TAILQ_FOREACH_SAFE(mmio, &pdev->mmio, next, p) { - if ((bus_space_handle_t)res < rman_get_bushandle(mmio->res) || - (bus_space_handle_t)res >= rman_get_bushandle(mmio->res) + - rman_get_size(mmio->res)) - continue; + if (pdev->want_iomap_res) { + if (res != mmio->res) + continue; + } else { + if (bh < rman_get_bushandle(mmio->res) || + bh >= rman_get_bushandle(mmio->res) + + rman_get_size(mmio->res)) + continue; + } bus_release_resource(pdev->dev.bsddev, mmio->type, mmio->rid, mmio->res); TAILQ_REMOVE(&pdev->mmio, mmio, next); From nobody Sun Jul 21 13:15:48 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRkS4589dz5RVb6 for ; Sun, 21 Jul 2024 13:15: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRkS42m63z4TtV; Sun, 21 Jul 2024 13:15:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721567748; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=2PTP4qXEjv4CkkbP4MDZLpNiHcijh4kL0JAJBzSEPHA=; b=RBngsiOdbSzgkM1OE7A8Cb9cQbhKC57Ufc93PTPS/1E1JdskqWd5Qy17NRCiBSyQXR4Thk ikwwnAzlyWcvkF5T3kTIz0VUqWuCwMYnYsSBZHWkEuUhD45amejQH7V6d1Ysu1CN9XdTBF D72x+9Pr6gRWWOwVM/2wJX55/QU+l/60LIy992Ggmz4Wjkgc1QqQTtADMWkPuq06DuB0ec 50vPg/BJk+zcB9I2yaZeaIZdEHIk9AfQyqa6N3woI4ea5EHdHdoDMkhedpJkxKnVVW2gPa EVedTwK3jo6Mb950s7RkRFEa4SOA5cK9CUrDpL8X6P5wA+RN2t3Ua1MYjpWnng== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721567748; a=rsa-sha256; cv=none; b=usssND7HAhlXqrM2TNhHIlgYL08m0H7U/rPj8R5JWYYu+mIfxqJJxvNIn+IUFYsRXn9uD5 CpNOVnoOw3QlHdIUN1au/ndKp9gIHcLZUNDxYTb2Ogxcm3PYohGKj3tseWRLOwVXWmHzqq aLOl/Ma1eMcQMLLHoi43beDUSbUeLpdZTOTice2vBC6Wtnjo2OVPqY8K93HVn3xIgMxWFt l3KJwX9E4UXqPJYYdVuaf92dCV+iib3mzj3ND0cjChPWkNl2T8DPZUUm0Ls88QNG9PQLK5 KX0R3BTmp3PEEKjgFTE5akg7MZdlhG3DqbXsxsBKRsu6AB57G2L4ydBip3rZVQ== 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=1721567748; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=2PTP4qXEjv4CkkbP4MDZLpNiHcijh4kL0JAJBzSEPHA=; b=Kv2rWDnZLMqZquh8/vIJsCXvBBaNes4FcV4h1JO2cWjGdi24w29nSaRxo4TxQcBXzMbUY5 PmVWvKH37PQQqITSQ2ntrOu9GrA6674EMmz8kihCErAZnAPR5ZU/rUdb1hAWDHUOdZcH59 jkdmHbwQaEcS3ipn+I/TCC58W7YVPp97tN9gISZsaPFYjpWAKhdR94jAdowCPxOa+5M7Dd jcRAp5mbwwnQyg0B/hnY7MkgHt71h7siPExsPFdnB9W1HJT/cVx4Xuug4z3qJEkMcEtZgJ VO6dgbSX2LAfrzlOnjbj1JSf7BKiolJ2bR5FUk0bDGTu3RUseQy5abKy4kvwIA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRkS41c3Sz11xR; Sun, 21 Jul 2024 13:15:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LDFmwq023759; Sun, 21 Jul 2024 13:15:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LDFmtO023758; Sun, 21 Jul 2024 13:15:48 GMT (envelope-from git) Date: Sun, 21 Jul 2024 13:15:48 GMT Message-Id: <202407211315.46LDFmtO023758@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org From: Cy Schubert Subject: git: df0c787c3ece..950d2f43375b - vendor/wpa - vendor branch updated List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cy X-Git-Repository: src X-Git-Refname: refs/heads/vendor/wpa X-Git-Reftype: branch X-Git-Commit: 950d2f43375b87e95ebc0ecda9b281b84b2213d7 X-Git-Oldrev: df0c787c3ece1d65fd6fef34aa8f56da557b5ac0 X-Git-Newrev: 950d2f43375b87e95ebc0ecda9b281b84b2213d7 Auto-Submitted: auto-generated The branch vendor/wpa has been updated by cy: URL: https://cgit.FreeBSD.org/src/log/?id=df0c787c3ece..950d2f43375b 950d2f43375b wpa: Import wpa 2.11 From nobody Sun Jul 21 13:15:48 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRkS458vJz5RVKD for ; Sun, 21 Jul 2024 13:15: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRkS431Xqz4TtW; Sun, 21 Jul 2024 13:15:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721567748; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=s69nWdGDYKc3qKUrDT7QvvkdemHCrcVEdy7F4ZKwH7I=; b=okcq1tSqJqjXwM7EpPWEVpwikIJImP9b7L+s1yhZ+KbeD0PdEpYqIuGQgwqlf71IV7iP33 WCr9jbQPCLUofuH/SzS1qG7crLbD2eCeH5kwEU4tlO50ztT2nGZgnmPEMwRQ1bytlAB1jx sYmpxtNg2B+56yFEBvuVJNK7o3R/HoDLL0wMaRyX6mEYZfkE5FPZrFi5Bl5kddsegOru6i RBSywzmTa/O2ytqDw0ULm+pMpAP4wN3EfmBB55hpQnHzWgLJmAWN/HHXR26tnl7cgEr4u1 6BK9hxmKyLIR7BxUY30YX4jKt4IdUvN5xlY+EmuAG+zQznGlmVPhHSYX3iHXzw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721567748; a=rsa-sha256; cv=none; b=brHLK/99i74kVqI9hybej+zozTYUgiNRBF1SGIERPtdjbDALMETdQbp04A5124F9kd3t8G ocMG8du+oIHQHahRDM/QHHgaUPPhJrmLpxa8FIeW0IZguABlMtyylco3Q9j48uvz/KkTvr OxK2OqRAiLL+Ci0tG7rktpMDWdAPQvSncNx+J/ezLyZceNhiuxXw9Ur0yr3l7g3LDyJ597 cEakgBLzC6zN0DoFBecatYrFMLE81CPmAklD2oyTXUldmdCoED6F5/0zE2xF+hRFKHPVXL SJeDTvVeJbqzmSkbyErEGkdGsDE47RdPAU3lbvo0i2kGYCJRVHlYsaqr64rFcw== 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=1721567748; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=s69nWdGDYKc3qKUrDT7QvvkdemHCrcVEdy7F4ZKwH7I=; b=b7aQJspw7kyiDVE/2Cuup/0CQPVC113LF7KAH/2AY68Fu3adIrwNrO7ESvBrfvBeFf5iRc 1ygLw3/te3az13yEkYE5qkDnb2wmgWTXWPsMvBr34aPA7GXDXuwFEj2PXWKaPtAkS/YI7M kcMRfxgRCjqNrpmRbe4YVTJ6rdHXkxKW+1OBq947ixPzGLxr5QJ6TAfNfDclFpmCJeUO/r IudGAaVN3pI+nmkuHEV20PxnpELaj44oOvnWRLSiptjO4DQo+RFH7zg8nlhmAj/P40783J UaEm60RJz+AQUZn9VN0LJSh/tlaGttN9B8Wh+B+G4iHSzdFayyV8R9B/azTDUg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRkS42JXzz11Zj; Sun, 21 Jul 2024 13:15:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LDFmaO023778; Sun, 21 Jul 2024 13:15:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LDFmNF023777; Sun, 21 Jul 2024 13:15:48 GMT (envelope-from git) Date: Sun, 21 Jul 2024 13:15:48 GMT Message-Id: <202407211315.46LDFmNF023777@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org From: Cy Schubert Subject: git: 6a356ac6cff1 - Create tag vendor/wpa/2.11 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cy X-Git-Repository: src X-Git-Refname: refs/tags/vendor/wpa/2.11 X-Git-Reftype: annotated tag X-Git-Commit: 6a356ac6cff18c61e9e4352d6781482d9601d7b6 Auto-Submitted: auto-generated The annotated tag vendor/wpa/2.11 has been created by cy: URL: https://cgit.FreeBSD.org/src/tag/?h=vendor/wpa/2.11 tag vendor/wpa/2.11 Tagger: Cy Schubert TaggerDate: 2024-07-21 13:14:57 +0000 wpa: Tag 2.11 commit 950d2f43375b87e95ebc0ecda9b281b84b2213d7 Author: Cy Schubert AuthorDate: 2024-07-21 13:14:24 +0000 Commit: Cy Schubert CommitDate: 2024-07-21 13:14:24 +0000 wpa: Import wpa 2.11 From nobody Sun Jul 21 13:19:04 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRkWs1b8Jz5RVwV; Sun, 21 Jul 2024 13:19: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRkWs14Hzz4XYq; Sun, 21 Jul 2024 13:19:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721567945; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=QtfvL5EHVJpND4alMEeV51VijuTm4gL4xriUnFN9U7U=; b=VoK7xslmuBCT9DdZF2KhXeqnarpUYPFM7Ym8C6G/ImwTGEH0rKJVfPYolkVqaILozKz4It ACKI3b1UYk9beQOJxArm8S2PIqEPfmlIy4EaxJuF0XiHVFn5kDSUmcCF0eO1CjeF0Gcubo PrnlMUbmfrjFSIZNDpkoz+x44RfSBRB3jP1uL+356ocGREYihad1SGZnbwGT5hoHkqVSwN XZ1pZ+3irrkTs5vNrp5Nutn92PyfXgPokHcyz3MpyBhCNnxplwVqN6Ok0ziXvLw2NOOGGi 3Yjd676sA5VDyR1JZizzKS3J64GdghumvDuz93APH0xpJZgTtXc9G3AvoI2VKg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721567945; a=rsa-sha256; cv=none; b=Ank5m7l+/FIL8wg7wfShY/1T4iSxJ4irUYpyn6Rn+avvAzvjIUItFUfQS3m8cdDt/dv70c qjB22bVW+fO1tg66Huie7NSeFIYlUOiDcravqS/r5qlHcVoNknpyAByOIvrG6Lj9X3XQUU q3R47eQCBJLVdEy24wDrH6NTMpkDZ5BLyIrAVHaKInXEakdbwbqRH7z5TvehT6/hxjdX7F +eUz0ED5tV2m+z+7WjsJ7b+W1dXTFuLJQ7BLS2bGNSeUvlcRURW0D+G7GlI6Kjx41SR+Aj slrba9d2UHTAllbNhWCto1ZHBMB+8DbocevF7Z2EImreuLyvvYVRMl45o672tg== 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=1721567945; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=QtfvL5EHVJpND4alMEeV51VijuTm4gL4xriUnFN9U7U=; b=jflJ0JoTj4ITARgHQXT4/T4HJYyIZo8Zxw9peaY/M/H2MCVy9djIPUf8vLjjx5/3ezGueD noHK+KNG+0ShcQdnVsa48iL9VixlmY+o3Ic/RyaapyUYcQRI+Xo3nPxFKnh9yeXVo04GQH 1QJGmmk5V/LAH4H2jze7QSEHhtSJzvTuqsy7xwHIJbO8eSYP5KLs2R/hkQMy5K4z41LjEm wsxwa3kqWdAFVfNWWnTcZqytxYJm5MBbDmxoI86uTWegdt8w4DuyegwzAhm3SUPq8r4orW PYVisKXTwjvMGCFeEwfN3wb5coWeJSHijTVq2mnNTbGe5BSN/bPXBaEzda3QAw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRkWs0PVBz11mC; Sun, 21 Jul 2024 13:19:05 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LDJ47h024377; Sun, 21 Jul 2024 13:19:04 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LDJ4TO024374; Sun, 21 Jul 2024 13:19:04 GMT (envelope-from git) Date: Sun, 21 Jul 2024 13:19:04 GMT Message-Id: <202407211319.46LDJ4TO024374@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Vladimir Kondratyev Subject: git: 24388fccd551 - main - Bump __FreeBSD_version after LinuxKPI changes. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: wulf X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 24388fccd551f79f64e54099a7d78196535c0a29 Auto-Submitted: auto-generated The branch main has been updated by wulf: URL: https://cgit.FreeBSD.org/src/commit/?id=24388fccd551f79f64e54099a7d78196535c0a29 commit 24388fccd551f79f64e54099a7d78196535c0a29 Author: Vladimir Kondratyev AuthorDate: 2024-07-21 13:17:37 +0000 Commit: Vladimir Kondratyev CommitDate: 2024-07-21 13:17:37 +0000 Bump __FreeBSD_version after LinuxKPI changes. Sponsored by: Serenity Cyber Security, LLC --- sys/sys/param.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/sys/param.h b/sys/sys/param.h index 887c595a1de5..1ec875a0046e 100644 --- a/sys/sys/param.h +++ b/sys/sys/param.h @@ -73,7 +73,7 @@ * cannot include sys/param.h and should only be updated here. */ #undef __FreeBSD_version -#define __FreeBSD_version 1500020 +#define __FreeBSD_version 1500021 /* * __FreeBSD_kernel__ indicates that this system uses the kernel of FreeBSD, From nobody Sun Jul 21 17:32:27 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRr8D1MHJz5Rs5F; Sun, 21 Jul 2024 17:32: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRr8D0dZWz4v7B; Sun, 21 Jul 2024 17:32:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721583148; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=0fgGLVAlDXxTQZ2sj7Nz4C4gtn8VQ5i0zz8QWuMPWxc=; b=YeeItrUIqflYEy6ZcxDxx5tPmasLu0SG+FzALvz/py/xBY5e+140mUk5tmPxFXOL6gN2pD dadHH/F2CovvAN3ZyZIklD+WzemdoskBSxD3vtp1CDx9F9DCHgOnuXz6iEfxlyURnxYgAx VnNCLsPfsnbAyhvvRAcDD5/TbG8nTAmX9/grev8KRCuUcBTqeV0EBBsfizTT6JxwHg1KGq G7iT4NDZ0GxvYK7DBJncFbpQWlAm6WQAEAjQ5QXZ3XLQub2HXOirNhEEaDJ0SY+RJhnzOZ /YduXdg23resg9OCqzQSD1uhPu5WIsTEk9meNpBOQrF0rdEOGTFt1YVfFrdx6w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721583148; a=rsa-sha256; cv=none; b=Gt7hTTSPTDTSwT88JmVr2r4C0a2DPSX26JIgsDpHJEIA3CVHagz00E4ksm73DpjU0KzGVh 88Y3gQB4KoKfzVW4V5wWzelmFDsF6EYqi7FmAtcILgPfPNiT89QXzJ3dcPAc5cxtOKIb0W P9sPDiDwFksHHkUAaQWmYaTZa3ied/mRt/rX0c/kqXq4hgh+TDf9jgwMnp/PRCzGtR/ucn YL6HuvM0GHd5RoVtgyZGZ7uUoBO/WmoI4VjqAa/zDPzfzPq6YMI9W0de/VAm1CnH4fMmBt j/A9uWEQ0rkiMPWrF1zvDySiKRQ4fasE1AgHkPhlGIqERqHe//O4qpr7Nw3GXQ== 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=1721583148; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=0fgGLVAlDXxTQZ2sj7Nz4C4gtn8VQ5i0zz8QWuMPWxc=; b=sUl6Hu84xyaG7hRGEyBRWnbKqajo5B5WxK+Ts0vAkDZD+S5l+Lp5BkOgWPhMR1j9bfylhV qQhArZDqlK3KZXxSkiaN4Eo6jjkpEscLfepRWLMnnkX0fE9I2WQ8/Ecm87btBVNgBhEBXp vwKlRjWgZt0Jj3jcq7exfctaD1tc+QKIvit+OYosedZtUrHsRkXtWbUyLcctzslUJX0/po AzeQg9aFClsU4N5fpqXf9yo2nPkwVO8r5DyGciHeIOxMDaIY+BHdJUGQO3PINYnq1IB9c3 VRw52xz3G/jh2T/14435ah72BEAXZ/TPdVAgOIdAjebi5Bt1oEaMKYH1EWf49w== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRr8D0FWSz194V; Sun, 21 Jul 2024 17:32:28 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LHWROT062764; Sun, 21 Jul 2024 17:32:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LHWRo0062761; Sun, 21 Jul 2024 17:32:27 GMT (envelope-from git) Date: Sun, 21 Jul 2024 17:32:27 GMT Message-Id: <202407211732.46LHWRo0062761@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Bojan =?utf-8?Q?Novkovi=C4=87?= Subject: git: 82f5dfc12139 - main - db_pprint: Fix offset calculation for struct members List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: bnovkov X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 82f5dfc121391604b079ea96aa14ea71e6b618c9 Auto-Submitted: auto-generated The branch main has been updated by bnovkov: URL: https://cgit.FreeBSD.org/src/commit/?id=82f5dfc121391604b079ea96aa14ea71e6b618c9 commit 82f5dfc121391604b079ea96aa14ea71e6b618c9 Author: Bojan Novković AuthorDate: 2024-07-21 16:45:33 +0000 Commit: Bojan Novković CommitDate: 2024-07-21 17:31:48 +0000 db_pprint: Fix offset calculation for struct members The struct pretty-printing code uses the ctm_offset field in struct ctf_member_v3 to calculate the address of a struct member. However, the code treats this as a byte offset rather than the offset in bits, leading to wrong values being printed. Fix this by diving with ctm_offset by NBBY. Approved by: markj (mentor) Fixes: c21bc6f3c242 --- sys/ddb/db_pprint.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/ddb/db_pprint.c b/sys/ddb/db_pprint.c index 10334ce650c8..2925caedd49d 100644 --- a/sys/ddb/db_pprint.c +++ b/sys/ddb/db_pprint.c @@ -117,7 +117,7 @@ db_pprint_struct(db_addr_t addr, struct ctf_type_v3 *type, u_int depth) return; } mtype = db_ctf_typeid_to_type(&sym_data, mp->ctm_type); - maddr = addr + mp->ctm_offset; + maddr = addr + (mp->ctm_offset / NBBY); mname = db_ctf_stroff_to_str(&sym_data, mp->ctm_name); db_indent = depth; if (mname != NULL) { @@ -140,7 +140,7 @@ db_pprint_struct(db_addr_t addr, struct ctf_type_v3 *type, u_int depth) return; } mtype = db_ctf_typeid_to_type(&sym_data, mp->ctlm_type); - maddr = addr + CTF_LMEM_OFFSET(mp); + maddr = addr + (CTF_LMEM_OFFSET(mp) / NBBY); mname = db_ctf_stroff_to_str(&sym_data, mp->ctlm_name); db_indent = depth; if (mname != NULL) { From nobody Sun Jul 21 17:32:29 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRr8F2YBzz5Rs5G; Sun, 21 Jul 2024 17:32: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRr8F1wJbz4tkt; Sun, 21 Jul 2024 17:32:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721583149; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=AESWM4xSG3NcxHtikS9ua/bI/RXffsN+Zj6pvHLTibM=; b=SKxGU4DsdHONL9FS0UsIUDiNWvqp8MdzSTRmq0zTrsDcGL6mJCJUkQ9aUEgMjDIbk5WVjc TZrNd64Fq5M8xq9fGNtE8HyjbyoGJERUol8KAxA4XTiJLlLfq0Bs39ONcPVkrP+7vQZAXo dJ90tKKrmgTue2VIYVPmj8nSFdN1zuUCPw3lPh5w/dIh5eN/Nkd8gsRx08kOaiIT4KXA/r sl3qWU6PKXCuPZQIJYaQke055wTcivL5/fWvRKxDLO7vr9CO/YzXj0bYHIIVpftCBQJ1rl A95O8NV2Nl1C9107nQdWlQbeT5XdYiROeSAqxWoXkO8FZ8M58zQegYbZvD9CDw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721583149; a=rsa-sha256; cv=none; b=qd/cdxL5z+lsTJdRw+Hba0RuAwITCeIjPXSv60a70AygcWUaF7wparDTahPx5Bfiy5Oo2M xGJxGMJLFynDfv+y5xScBoVG7dgR5VnMc2lnKldQlwmx6AaQDy+3vofO6OVpEYiH7vo5nR dlHGI4rf7LVsqBvO7+7V0cKO9ldLLuER899XSZVYhagiBoT45qGyGObm/52vmfA6EVu+Sk IkyJzGoYaC5wa69zMDOLwVQ0X9130oYhmhBc93kf+GlGZJlNynua5c0BvNSAg6X1hYcydd vzPtXxJNxCO+eblxE09dU3lolirOsbes4MboEjk5csBljsdx1faGBBNhyB8eMg== 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=1721583149; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=AESWM4xSG3NcxHtikS9ua/bI/RXffsN+Zj6pvHLTibM=; b=nnC3cq5dW5Hesjawbhk/qGLhk+XigEd26QVde1s64Da9nqacCbBZSnm69aLejNppw9Mt9o ouFcEDaSSvHJuB7NyqcZ3mC5unyZYYIZcdQ+DpdrTagNERldGMllStxo7XwbUyFTtuLAPs 4ecgQvkxCX0AZ8uTTK4TxKcA3UCU9RMQ6rteU7Ho7k3tD5J5gjB2LEtVRpAZMFNVaeWxx7 v4swTd5Y2OpLojEWZ872jMne/HCq4NyogHM5sUT7OZpNNfIBOmLwLivkurO7qpbuRgsTwa ZqjuWFZXXui0F3cIywhQUT2pP2R9SV9UzeHkWkSn2hS7Z9Q6QCT8L0q9I/NI+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 4WRr8F1Fvrz184Z; Sun, 21 Jul 2024 17:32:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LHWTI8062813; Sun, 21 Jul 2024 17:32:29 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LHWTZ0062810; Sun, 21 Jul 2024 17:32:29 GMT (envelope-from git) Date: Sun, 21 Jul 2024 17:32:29 GMT Message-Id: <202407211732.46LHWTZ0062810@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Bojan =?utf-8?Q?Novkovi=C4=87?= Subject: git: 1cbd613f3343 - main - db_pprint: Properly handle complex pointer types List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: bnovkov X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 1cbd613f3343c873ace8a56df2e515626a18ef22 Auto-Submitted: auto-generated The branch main has been updated by bnovkov: URL: https://cgit.FreeBSD.org/src/commit/?id=1cbd613f3343c873ace8a56df2e515626a18ef22 commit 1cbd613f3343c873ace8a56df2e515626a18ef22 Author: Bojan Novković AuthorDate: 2024-07-21 16:51:22 +0000 Commit: Bojan Novković CommitDate: 2024-07-21 17:31:59 +0000 db_pprint: Properly handle complex pointer types The existing pretty-printing code fails to properly print complex pointer types. This commit fixes this behaviour by traversing the chain of CTF types until a base type is encountered. Approved by: markj (mentor) Fixes: c21bc6f3c242 --- sys/ddb/db_pprint.c | 38 ++++++++++++++++++++++++++++++-------- 1 file changed, 30 insertions(+), 8 deletions(-) diff --git a/sys/ddb/db_pprint.c b/sys/ddb/db_pprint.c index 2925caedd49d..0ca2b0bb952c 100644 --- a/sys/ddb/db_pprint.c +++ b/sys/ddb/db_pprint.c @@ -45,6 +45,7 @@ static void db_pprint_type(db_addr_t addr, struct ctf_type_v3 *type, static u_int max_depth = DB_PPRINT_DEFAULT_DEPTH; static struct db_ctf_sym_data sym_data; +static const char *asteriskstr = "*****"; /* * Pretty-prints a CTF_INT type. @@ -248,9 +249,14 @@ db_pprint_ptr(db_addr_t addr, struct ctf_type_v3 *type, u_int depth) const char *qual = ""; const char *name; db_addr_t val; + uint32_t tid; u_int kind; + int ptrcnt; - ref_type = db_ctf_typeid_to_type(&sym_data, type->ctt_type); + ptrcnt = 1; + tid = type->ctt_type; +again: + ref_type = db_ctf_typeid_to_type(&sym_data, tid); kind = CTF_V3_INFO_KIND(ref_type->ctt_info); switch (kind) { case CTF_K_STRUCT: @@ -258,25 +264,41 @@ db_pprint_ptr(db_addr_t addr, struct ctf_type_v3 *type, u_int depth) break; case CTF_K_VOLATILE: qual = "volatile "; - break; + tid = ref_type->ctt_type; + goto again; case CTF_K_CONST: qual = "const "; - break; + tid = ref_type->ctt_type; + goto again; + case CTF_K_RESTRICT: + qual = "restrict "; + tid = ref_type->ctt_type; + goto again; + case CTF_K_POINTER: + ptrcnt++; + tid = ref_type->ctt_type; + goto again; + case CTF_K_TYPEDEF: + tid = ref_type->ctt_type; + goto again; default: break; } - val = db_get_value(addr, sizeof(db_addr_t), false); - if (depth < max_depth) { + ptrcnt = min(ptrcnt, strlen(asteriskstr)); + val = (addr != 0) ? db_get_value(addr, sizeof(db_addr_t), false) : 0; + if (depth < max_depth && (val != 0)) { /* Print contents of memory pointed to by this pointer. */ - db_pprint_type(addr, ref_type, depth + 1); + db_pprint_type(val, ref_type, depth + 1); } else { name = db_ctf_stroff_to_str(&sym_data, ref_type->ctt_name); db_indent = depth; if (name != NULL) - db_printf("(%s%s *) 0x%lx", qual, name, (long)val); + db_printf("(%s%s %.*s) 0x%lx", qual, name, ptrcnt, + asteriskstr, (long)val); else - db_printf("(%s *) 0x%lx", qual, (long)val); + db_printf("(%s %.*s) 0x%lx", qual, ptrcnt, asteriskstr, + (long)val); } } From nobody Sun Jul 21 17:34:33 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRrBf0wVMz5Q8VH for ; Sun, 21 Jul 2024 17:34: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRrBf0Jk1z4vd2; Sun, 21 Jul 2024 17:34:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721583274; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=5oOJ9FQu3rTQ1mm2eE1K6U98KhqoVTBwZFsH6DWLNpE=; b=kM337dQ8HEyzG7/197y4nux23q9fqLRIz4lubUXcjmOMPjymRCnvlNE4guS6H13GPJmUvs f4BnMiUGUpyBSMpAgyJZRyA60arYcfzQim8goMiqNwL6KNWmIx7X9/+hYcuGLU7boB9Pvb 1zM9a9Oh+3EuBXHpkjOn9lR4EHF0MJfsuzh45Od75rv+2NE6F+ffZrMre36NsQTEa6YI2F crRZslCly0h73osm6jscxnE22zeP1e1yJinPL7MOguSGN+bbUSfg9wCBggYz5oeVL9jD7H ocy8l2Nhrk62h6n1fs7Au00r5teNHMw/NU2RklPlm3t56tszQYaHLVCzhILKpQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721583274; a=rsa-sha256; cv=none; b=Sm8/H7/voipuRFsQk/5wOdoRHiL9PTO6hN+pcp8u4tJdNfSnJGazueMyx/uYMvA2wy6YLf FDVkgiycAI3j/mbQyj5YpWzU6ZRA1AssPt6146RCoWngB890Q2Zo/Tm05hdZWHIkZr0h3I SAmL+OLZjp5WasKAk3XEqFHyFwu5/r1JXA8o5GDX0bRQ0kwIZrvgqjpd76LFucQRR2/PdD mXCZeOX4HblBfKgQzkTiCeWk/r4gG0FsZXcSDCdJXlGeoY35XyEec71mHA70RpiV4mRvtk 6Jq2guNpEWbM8VJxkBewY7SKal9EiuJIQdi+mchUHF732cuj+E+OHuYZS9JUww== 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=1721583274; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=5oOJ9FQu3rTQ1mm2eE1K6U98KhqoVTBwZFsH6DWLNpE=; b=nw0R9AENxmFpZeqN2VP3WQMSr/8nm6IobaHP97ha0r8EVuI4IQiWnce+/qdqZTBHAqhXFZ 5/g/mo4cAGFZ4AUzti4jmiL84JIaqd+u5wT6Bc8Hc87PbREdTgL6mTN+mu+I7tQs/sTdkr iVYXb8KVEUkPJGudK/U4lVMXcuiXP6Vfvcpgp2X3jf3DGGV6cuGpoZtJHEukULQWrwH8AN NnahiAUJNZdUSzd5xNOti7k5MXpTKXnzgh4OdyjkyLzvRlpI2VDu3nyr4DpycTPB6eTGnd 1H1NpQz/GlTSDN0JXBvtUOKhatLD6ZTour0+mSk5EsM0CTR+0kGhFj2ht/ybWA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRrBd6p2hz184d; Sun, 21 Jul 2024 17:34:33 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LHYXt9064511; Sun, 21 Jul 2024 17:34:33 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LHYXmV064508; Sun, 21 Jul 2024 17:34:33 GMT (envelope-from git) Date: Sun, 21 Jul 2024 17:34:33 GMT Message-Id: <202407211734.46LHYXmV064508@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org From: Mark Johnston Subject: git: 77dc2f52094a - internal/admin - Release bnovkov from mentorship List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/internal/admin X-Git-Reftype: branch X-Git-Commit: 77dc2f52094a106f8619d29b125b0b0ca5509e30 Auto-Submitted: auto-generated The branch internal/admin has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=77dc2f52094a106f8619d29b125b0b0ca5509e30 commit 77dc2f52094a106f8619d29b125b0b0ca5509e30 Author: Mark Johnston AuthorDate: 2024-07-21 17:30:30 +0000 Commit: Mark Johnston CommitDate: 2024-07-21 17:30:30 +0000 Release bnovkov from mentorship Approved by: core (implicit) --- mentors | 1 - 1 file changed, 1 deletion(-) diff --git a/mentors b/mentors index bab3f6241e4e..ce2c00a7dcbd 100644 --- a/mentors +++ b/mentors @@ -10,7 +10,6 @@ # Mentee Mentor Optional comment afedorov vmaffione Co-mentor: jhb akiyano cperciva -bnovkov markj Co-mentor: jhb brd allanjude Co-mentor: bapt bryanv grehan def oshogbo From nobody Sun Jul 21 17:46:20 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRrSF0s1lz5Q9q8; Sun, 21 Jul 2024 17:46: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRrSF0N6Wz3xLM; Sun, 21 Jul 2024 17:46:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721583981; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=RewJkfyOQAGti+nNCIotraQjKi0vwtP+H3sgc+MVeto=; b=xUKG7hC1ebcS7zLIwprHM9nqwApP7wWWHEAXlfnMeeJZfZRMCTR8iDXTqkH1kjV1Pmjj63 3CGU7I4jtJGLtOe/7QDlkq68IUTt8uIYuPiql4ObHKVyV13nJGy/js7LMQb6hWVzWbF8Em tnbOPypD4LXgaMRKB7iAYtPqWa03hznl/+UrKt92qsvTAXsN8EabJEdjVRdCsP46EAIL4P SRSne/RqhEfiTS1tExXd5QyTRPlq8nZ8pz9UrENcatqYkZIWDhff/xh1FzjsDsEjX8aDXk xdJySt5DUaqlGmvnSpGYKEb0itZAUVW21KeViEsk4dpo7MjuplJRFkrgqsC3jA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721583981; a=rsa-sha256; cv=none; b=ZqH3mtdeRKm1S29W90cVjTjru/oECvVJBKM6UMMEdNEcHtR8+Q6uAmgbu1WRKgRHfngIdy pHllrHVs9YuaSvnKFa0B1uRroRtyi8X5C2M7Ib97VUwsaBF6ld02QDDd6gDEeS6GgNTQtA 5vyRfYQvy2kUio2RevwDEu6vKmooE6BaE0qmKUtjehiZ0+xz0y2NrVh/LLgtQkwRU4cDvb kDSAfdxadslNIwYfw9FJwfyINyLRz33KFJi+b8GuaLvZNDX5izxyx5QXLzeLpQ2igB64Wi c/zOXm80yVr62QQ3zXKbIyDYySTNSG3SAq4yCuSsTCmwm+cKd95DLqmg744VYA== 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=1721583981; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=RewJkfyOQAGti+nNCIotraQjKi0vwtP+H3sgc+MVeto=; b=S+jyP80oANfNTAQXGTZyaGd4X6k8vTAqgHSJCFOiGbSjQnFiLiGNW3xxdvEoObWuPA2VwU 2Gy2R8Mzq0hSVTdnWw2vr0rk81Qef0KGYkQNLWW4Upg22K0UZPDiU/CDKKdx3Z3o1NA5ky JPG2+zeP3FEHpabr7jFbMYugS9/3mW04pK8e6thtny7a6hYANH624+TGbbmpJvvwQ+0Hz6 uKLUtllKxVfYRa1P9V24FNdXPl3hIQ6C4u8fkx+yruB7+R7Brff3RhiIt7D4/D2Vh/Auh/ nTBVdKKwQ4rLGDp7q6l0BQwP1k34Zu7G9+so8gEjRXk5AQb2Ix38dBkXAl6w6Q== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRrSD75jyz195W; Sun, 21 Jul 2024 17:46:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LHkK9Q081207; Sun, 21 Jul 2024 17:46:20 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LHkKGN081204; Sun, 21 Jul 2024 17:46:20 GMT (envelope-from git) Date: Sun, 21 Jul 2024 17:46:20 GMT Message-Id: <202407211746.46LHkKGN081204@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: 908777f1c258 - stable/14 - nvmecontrol: Fix "Workloadd" typo List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mav X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 908777f1c258760c50511d1de4eec4f43f4e71a1 Auto-Submitted: auto-generated The branch stable/14 has been updated by mav: URL: https://cgit.FreeBSD.org/src/commit/?id=908777f1c258760c50511d1de4eec4f43f4e71a1 commit 908777f1c258760c50511d1de4eec4f43f4e71a1 Author: Alexander Motin AuthorDate: 2024-07-12 15:36:40 +0000 Commit: Alexander Motin CommitDate: 2024-07-21 17:46:02 +0000 nvmecontrol: Fix "Workloadd" typo MFC after: 1 week (cherry picked from commit 6ac0f711ad9ecd9ac1525787bb08002c85c03cde) --- sbin/nvmecontrol/power.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sbin/nvmecontrol/power.c b/sbin/nvmecontrol/power.c index 95ee1763a28c..78de46dbc277 100644 --- a/sbin/nvmecontrol/power.c +++ b/sbin/nvmecontrol/power.c @@ -95,7 +95,7 @@ power_list(struct nvme_controller_data *cdata) int i; printf("\nPower States Supported: %d\n\n", cdata->npss + 1); - printf(" # Max pwr Enter Lat Exit Lat RT RL WT WL Idle Pwr Act Pwr Workloadd\n"); + printf(" # Max pwr Enter Lat Exit Lat RT RL WT WL Idle Pwr Act Pwr Workload\n"); printf("-- -------- --------- --------- -- -- -- -- -------- -------- --\n"); for (i = 0; i <= cdata->npss; i++) power_list_one(i, &cdata->power_state[i]); From nobody Sun Jul 21 17:46:54 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRrSt5RT5z5Q9nN; Sun, 21 Jul 2024 17:46: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRrSt4wHdz3xSm; Sun, 21 Jul 2024 17:46:54 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721584014; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=2qzeo4WiYBNBEwbMthMQoaXiOgFImtHCszQKuqiTC44=; b=bDNPiGt7XG12SzxIiLY6WnyXjFtIHDwKVhFVhgBNaZfmRlYi/fmzvTQ4k5nN6iO6wTxbxX Vy/K8OWg6ejMy7EpIMVIgcVTQRFY0oWGKtUwUzi9IJ3mgTM0PxFOVNtsqNqw0fCucm60zf bRkeHUNZuE0k5jJDLfvZoFa+IVFKPunO6uKEzMrP/vrMVlPD95N16og0FeB/rrrg04I+A6 nfxOartsxk8AMX4930jJagY+O6coBjHiznaU6Cr6oK9+1GY2uU7fvF78G8vDVjOEwUll0T JWDvmC0so2KD436Z0n0JaFoBWDX8wzGNveSayfC985kpLKPGEd2N/xzFKJelTA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721584014; a=rsa-sha256; cv=none; b=bL/QctJv7Sjqcu8DLyUrGn4s0ZpNXRACyLTHAakfpdzdBQ6Lgbv8WI8gkOd8GLqVa8u/8S YMDxWFJhzUYPTF30pSXu9EmLyp8BFC9jIUr/kRbp93uxaAcarVfSCb2pdc8taIrHtQSRoG 8f25Kbcse1kyzCdfYc6cgF3npom1O3W66l+RjuJQh5UIPX+pw/Ju1nrLcseVvpnA3mgpbJ TyQ+fgkgoDt9hMoh1hT+UM8iVY3vWNzsXodTbtn84Da2xtXYEYSMal2bEqTTmDmi7ZbMD9 8AIcw/ASTMEfSKL5bM64Dsg0iRQcJ4f34aE1eaLLDUYGtp6UdpEQ84mPpYtrgg== 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=1721584014; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=2qzeo4WiYBNBEwbMthMQoaXiOgFImtHCszQKuqiTC44=; b=rdl84ImONHLLbNIHXaHSbbjiiL23XmXXHdwowgQLTNsDyUuLFlmDNqNh4aNzPS2tYYEyZu mF1YYA9AGsBP/JzcLZQosjgrDpj2ntYV2PL6tK7lx9OeiilC1EzJhrS57AVXiQWUPAyUCU J2jFuq2ecVsh0nDUgz3HdOIYwd+gJr8qvTQXNT3Bfnj9ahaLacizzmMq9xjSh8v32ggMkm blPiJXSRGdNx5VbuoGDQeMaFQg9l2ixqT02pS0jJ2rCSLgJrWEFDLZFJ7JtROlpAHmN24Q ED3W5+FdKLcOZo/JYYCbxmUpWWwCTgrPrAHuel2Vh6BIbqf19mc57+2klcHRrQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRrSt4X0gz1850; Sun, 21 Jul 2024 17:46:54 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LHksxN081411; Sun, 21 Jul 2024 17:46:54 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LHks5G081408; Sun, 21 Jul 2024 17:46:54 GMT (envelope-from git) Date: Sun, 21 Jul 2024 17:46:54 GMT Message-Id: <202407211746.46LHks5G081408@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: 9746cb2197a1 - stable/13 - nvmecontrol: Fix "Workloadd" typo List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mav X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 9746cb2197a1576666c701d275c5a670381e8881 Auto-Submitted: auto-generated The branch stable/13 has been updated by mav: URL: https://cgit.FreeBSD.org/src/commit/?id=9746cb2197a1576666c701d275c5a670381e8881 commit 9746cb2197a1576666c701d275c5a670381e8881 Author: Alexander Motin AuthorDate: 2024-07-12 15:36:40 +0000 Commit: Alexander Motin CommitDate: 2024-07-21 17:46:50 +0000 nvmecontrol: Fix "Workloadd" typo MFC after: 1 week (cherry picked from commit 6ac0f711ad9ecd9ac1525787bb08002c85c03cde) --- sbin/nvmecontrol/power.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sbin/nvmecontrol/power.c b/sbin/nvmecontrol/power.c index 95ee1763a28c..78de46dbc277 100644 --- a/sbin/nvmecontrol/power.c +++ b/sbin/nvmecontrol/power.c @@ -95,7 +95,7 @@ power_list(struct nvme_controller_data *cdata) int i; printf("\nPower States Supported: %d\n\n", cdata->npss + 1); - printf(" # Max pwr Enter Lat Exit Lat RT RL WT WL Idle Pwr Act Pwr Workloadd\n"); + printf(" # Max pwr Enter Lat Exit Lat RT RL WT WL Idle Pwr Act Pwr Workload\n"); printf("-- -------- --------- --------- -- -- -- -- -------- -------- --\n"); for (i = 0; i <= cdata->npss; i++) power_list_one(i, &cdata->power_state[i]); From nobody Sun Jul 21 18:43:52 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRskc28QPz5QGGW; Sun, 21 Jul 2024 18:43: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRskc1b5Rz42qb; Sun, 21 Jul 2024 18: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=1721587432; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=cdsJ0HLJWdjWrqxJAzxqBnVBRKXxihQGjoiu6mnPdSM=; b=RoLMq7wcl75n5ZnYnC4gLMIJfs9EePLrtp52YjLDK75m1Ze7k3UTl8tO513IgEIjkZFfn9 hIcoTBmuRsttdgWcOzy4g7O1mClbrDoWEriyJfULcCtFRIId42xwfy7+x2yawKOUsfPwCw UKnLony8WBBpPXRhvWcrlqxqw4+N3xVlMMbkgaBKdS382QIecnUIwmrfPOxWchuJYyaoK/ SlAoKDRZ3SVZZmsvlczz1/01iZW8Y0dCRGwspK40emGThlePsicQlSwka1BP37fRDzVtsK N8f9P+g91xvU1J6h8IdQhTGSW1BwjYQKkFKcNOgw0tqnDQ86AnuoNfJsYaspSA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721587432; a=rsa-sha256; cv=none; b=QJhPBFGeHYucr6sbYi1ANaSwnX+nf+AjIYp9lZrl6Smco5PA43HcqdMjpWliWIeley1YU3 oD7UsW/4Rl2MTOfX5ytGh+Z3k2GastKXpFjBxsHPYbNygHbFo6qJEC0jB3Ux8dEQh2G1tw Ovm4UPyzejJSY/BlvJKKpcPtL3Gqf6D4ryZ+rVwquOavyje6aRn7yagiWLVUzWoKLRpujF LvjHzmaxwRoei08VWiSmRHLEtOe81hotVgXmuLExsIBr1XcayurvBCY3Y68Ufw6nQYbWii SwNaukKka4Gi2+9UG15byh8tEwf8vhv4nDpKpB0ldcYwAccDin0jbeZAvI90ew== 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=1721587432; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=cdsJ0HLJWdjWrqxJAzxqBnVBRKXxihQGjoiu6mnPdSM=; b=PCIc1IqdANUjQXyralrK/KvVFT31M6Se5JYKqzwQpX4Vohg4CVwSFMuKKQY17zK9zCxljY 4MW/m9fkNlunr8u/SXXaPoTl83CBf4LSmMyTamxM0w7mQziNJNzOlE/3zm7g9pjgJgjGup WgVefiFgRnXiDjpJ9RI8cm+8dSqkBBhZuzEzr39NXmnSvG30Vthhw8CqXORf+FzBL/pqzn USbGV2h8tZc5VSWRucAvq8SyE9hoLce0wkLEnT/3MA68gLJNmKUEa5RG+8rgizqwkry82u Ej6Qn0OM5SA4qStCjdBonmLhUqJEJMZnwtNwtkXC8yHlMy1VkEv5cQaHvL4f6w== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRskc19gqz1BST; Sun, 21 Jul 2024 18:43:52 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LIhqxp082742; Sun, 21 Jul 2024 18:43:52 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LIhqVN082739; Sun, 21 Jul 2024 18:43:52 GMT (envelope-from git) Date: Sun, 21 Jul 2024 18:43:52 GMT Message-Id: <202407211843.46LIhqVN082739@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Michael Tuexen Subject: git: 646c28ea80cb - main - tcp: improve SEG.ACK validation List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 646c28ea80cb0f9258386626297495b5a0e56db5 Auto-Submitted: auto-generated The branch main has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=646c28ea80cb0f9258386626297495b5a0e56db5 commit 646c28ea80cb0f9258386626297495b5a0e56db5 Author: Michael Tuexen AuthorDate: 2024-07-21 09:37:35 +0000 Commit: Michael Tuexen CommitDate: 2024-07-21 09:37:35 +0000 tcp: improve SEG.ACK validation Implement the improved SEG.ACK validation described in RFC 5961. In addition to that, also detect ghost ACKs, which are ACKs for data that has never been sent. The additional checks are enabled by default, but can be disabled by setting the sysctl-variable net.inet.tcp.insecure_ack to a non-zero value. PR: 250357 Reviewed by: Peter Lei, rscheff (older version) MFC after: 1 week Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D45894 --- share/man/man4/tcp.4 | 5 ++++- sys/netinet/in_kdtrace.c | 2 ++ sys/netinet/in_kdtrace.h | 3 +++ sys/netinet/tcp_input.c | 44 +++++++++++++++++++++++++++++++++++++++++++ sys/netinet/tcp_stacks/bbr.c | 37 ++++++++++++++++++++++++++++++++++++ sys/netinet/tcp_stacks/rack.c | 39 ++++++++++++++++++++++++++++++++++++++ sys/netinet/tcp_var.h | 9 ++++++++- usr.bin/netstat/inet.c | 8 ++++++-- 8 files changed, 143 insertions(+), 4 deletions(-) diff --git a/share/man/man4/tcp.4 b/share/man/man4/tcp.4 index 39db12752937..3f5d87da0ffb 100644 --- a/share/man/man4/tcp.4 +++ b/share/man/man4/tcp.4 @@ -31,7 +31,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd November 30, 2023 +.Dd July 21, 2024 .Dt TCP 4 .Os .Sh NAME @@ -699,6 +699,9 @@ Default is false. .It Va insecure_syn Use criteria defined in RFC793 instead of RFC5961 for accepting SYN segments. Default is false. +.It Va insecure_ack +Use criteria defined in RFC793 for validating SEG.ACK. +Default is false. .It Va isn_reseed_interval The interval (in seconds) specifying how often the secret data used in RFC 1948 initial sequence number calculations should be reseeded. diff --git a/sys/netinet/in_kdtrace.c b/sys/netinet/in_kdtrace.c index 8491a4d49d91..219bc6482910 100644 --- a/sys/netinet/in_kdtrace.c +++ b/sys/netinet/in_kdtrace.c @@ -339,6 +339,8 @@ MIB_PROBE_TCP(tcps_ecn_sndect1); MIB_PROBE_TCP(tcps_tlpresends); MIB_PROBE_TCP(tcps_tlpresend_bytes); +MIB_PROBE_TCP(tcps_rcvghostack); +MIB_PROBE_TCP(tcps_rcvacktooold); #endif SDT_PROBE_DEFINE6_XLATE(ip, , , receive, diff --git a/sys/netinet/in_kdtrace.h b/sys/netinet/in_kdtrace.h index 9896af96eb84..22f181974f93 100644 --- a/sys/netinet/in_kdtrace.h +++ b/sys/netinet/in_kdtrace.h @@ -330,6 +330,9 @@ SDT_PROBE_DECLARE(mib, tcp, count, tcps_ecn_sndect1); SDT_PROBE_DECLARE(mib, tcp, count, tcps_tlpresends); SDT_PROBE_DECLARE(mib, tcp, count, tcps_tlpresend_bytes); + +SDT_PROBE_DECLARE(mib, tcp, count, tcps_rcvghostack); +SDT_PROBE_DECLARE(mib, tcp, count, tcps_rcvacktooold); #endif SDT_PROBE_DECLARE(ip, , , receive); diff --git a/sys/netinet/tcp_input.c b/sys/netinet/tcp_input.c index 833a1e501780..ef24f20f784a 100644 --- a/sys/netinet/tcp_input.c +++ b/sys/netinet/tcp_input.c @@ -202,6 +202,11 @@ SYSCTL_INT(_net_inet_tcp, OID_AUTO, insecure_rst, CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(tcp_insecure_rst), 0, "Follow RFC793 instead of RFC5961 criteria for accepting RST packets"); +VNET_DEFINE(int, tcp_insecure_ack) = 0; +SYSCTL_INT(_net_inet_tcp, OID_AUTO, insecure_ack, CTLFLAG_VNET | CTLFLAG_RW, + &VNET_NAME(tcp_insecure_ack), 0, + "Follow RFC793 criteria for validating SEG.ACK"); + VNET_DEFINE(int, tcp_recvspace) = 1024*64; #define V_tcp_recvspace VNET(tcp_recvspace) SYSCTL_INT(_net_inet_tcp, TCPCTL_RECVSPACE, recvspace, CTLFLAG_VNET | CTLFLAG_RW, @@ -2438,6 +2443,45 @@ tcp_do_segment(struct tcpcb *tp, struct mbuf *m, struct tcphdr *th, /* * Ack processing. */ + if (SEQ_GEQ(tp->snd_una, tp->iss + (65535 << tp->snd_scale))) { + /* Checking SEG.ACK against ISS is definitely redundant. */ + tp->t_flags2 |= TF2_NO_ISS_CHECK; + } + if (!V_tcp_insecure_ack) { + tcp_seq seq_min; + bool ghost_ack_check; + + if (tp->t_flags2 & TF2_NO_ISS_CHECK) { + /* Check for too old ACKs (RFC 5961, Section 5.2). */ + seq_min = tp->snd_una - tp->max_sndwnd; + ghost_ack_check = false; + } else { + if (SEQ_GT(tp->iss + 1, tp->snd_una - tp->max_sndwnd)) { + /* Checking for ghost ACKs is stricter. */ + seq_min = tp->iss + 1; + ghost_ack_check = true; + } else { + /* + * Checking for too old ACKs (RFC 5961, + * Section 5.2) is stricter. + */ + seq_min = tp->snd_una - tp->max_sndwnd; + ghost_ack_check = false; + } + } + if (SEQ_LT(th->th_ack, seq_min)) { + if (ghost_ack_check) + TCPSTAT_INC(tcps_rcvghostack); + else + TCPSTAT_INC(tcps_rcvacktooold); + /* Send a challenge ACK. */ + tcp_respond(tp, mtod(m, void *), th, m, + tp->rcv_nxt, tp->snd_nxt, TH_ACK); + tp->last_ack_sent = tp->rcv_nxt; + m = NULL; + goto drop; + } + } switch (tp->t_state) { /* * In SYN_RECEIVED state, the ack ACKs our SYN, so enter diff --git a/sys/netinet/tcp_stacks/bbr.c b/sys/netinet/tcp_stacks/bbr.c index cb87932fa8db..445ba064b316 100644 --- a/sys/netinet/tcp_stacks/bbr.c +++ b/sys/netinet/tcp_stacks/bbr.c @@ -7711,6 +7711,43 @@ bbr_process_ack(struct mbuf *m, struct tcphdr *th, struct socket *so, bbr = (struct tcp_bbr *)tp->t_fb_ptr; lost = bbr->r_ctl.rc_lost; nsegs = max(1, m->m_pkthdr.lro_nsegs); + if (SEQ_GEQ(tp->snd_una, tp->iss + (65535 << tp->snd_scale))) { + /* Checking SEG.ACK against ISS is definitely redundant. */ + tp->t_flags2 |= TF2_NO_ISS_CHECK; + } + if (!V_tcp_insecure_ack) { + tcp_seq seq_min; + bool ghost_ack_check; + + if (tp->t_flags2 & TF2_NO_ISS_CHECK) { + /* Check for too old ACKs (RFC 5961, Section 5.2). */ + seq_min = tp->snd_una - tp->max_sndwnd; + ghost_ack_check = false; + } else { + if (SEQ_GT(tp->iss + 1, tp->snd_una - tp->max_sndwnd)) { + /* Checking for ghost ACKs is stricter. */ + seq_min = tp->iss + 1; + ghost_ack_check = true; + } else { + /* + * Checking for too old ACKs (RFC 5961, + * Section 5.2) is stricter. + */ + seq_min = tp->snd_una - tp->max_sndwnd; + ghost_ack_check = false; + } + } + if (SEQ_LT(th->th_ack, seq_min)) { + if (ghost_ack_check) + TCPSTAT_INC(tcps_rcvghostack); + else + TCPSTAT_INC(tcps_rcvacktooold); + /* Send challenge ACK. */ + ctf_do_dropafterack(m, tp, th, thflags, tlen, ret_val); + bbr->r_wanted_output = 1; + return (1); + } + } if (SEQ_GT(th->th_ack, tp->snd_max)) { ctf_do_dropafterack(m, tp, th, thflags, tlen, ret_val); bbr->r_wanted_output = 1; diff --git a/sys/netinet/tcp_stacks/rack.c b/sys/netinet/tcp_stacks/rack.c index b7d9d383fc61..bd7583d3843a 100644 --- a/sys/netinet/tcp_stacks/rack.c +++ b/sys/netinet/tcp_stacks/rack.c @@ -12472,6 +12472,45 @@ rack_process_ack(struct mbuf *m, struct tcphdr *th, struct socket *so, INP_WLOCK_ASSERT(tptoinpcb(tp)); rack = (struct tcp_rack *)tp->t_fb_ptr; + if (SEQ_GEQ(tp->snd_una, tp->iss + (65535 << tp->snd_scale))) { + /* Checking SEG.ACK against ISS is definitely redundant. */ + tp->t_flags2 |= TF2_NO_ISS_CHECK; + } + if (!V_tcp_insecure_ack) { + tcp_seq seq_min; + bool ghost_ack_check; + + if (tp->t_flags2 & TF2_NO_ISS_CHECK) { + /* Check for too old ACKs (RFC 5961, Section 5.2). */ + seq_min = tp->snd_una - tp->max_sndwnd; + ghost_ack_check = false; + } else { + if (SEQ_GT(tp->iss + 1, tp->snd_una - tp->max_sndwnd)) { + /* Checking for ghost ACKs is stricter. */ + seq_min = tp->iss + 1; + ghost_ack_check = true; + } else { + /* + * Checking for too old ACKs (RFC 5961, + * Section 5.2) is stricter. + */ + seq_min = tp->snd_una - tp->max_sndwnd; + ghost_ack_check = false; + } + } + if (SEQ_LT(th->th_ack, seq_min)) { + if (ghost_ack_check) + TCPSTAT_INC(tcps_rcvghostack); + else + TCPSTAT_INC(tcps_rcvacktooold); + /* Send challenge ACK. */ + __ctf_do_dropafterack(m, tp, th, thflags, tlen, ret_val, + &rack->r_ctl.challenge_ack_ts, + &rack->r_ctl.challenge_ack_cnt); + rack->r_wanted_output = 1; + return (1); + } + } if (SEQ_GT(th->th_ack, tp->snd_max)) { __ctf_do_dropafterack(m, tp, th, thflags, tlen, ret_val, &rack->r_ctl.challenge_ack_ts, diff --git a/sys/netinet/tcp_var.h b/sys/netinet/tcp_var.h index 1f48297c2b0a..f691579acf09 100644 --- a/sys/netinet/tcp_var.h +++ b/sys/netinet/tcp_var.h @@ -848,6 +848,7 @@ tcp_packets_this_ack(struct tcpcb *tp, tcp_seq ack) #define TF2_CANNOT_DO_ECN 0x00080000 /* The stack does not do ECN */ #define TF2_PROC_SACK_PROHIBIT 0x00100000 /* Due to small MSS size do not process sack's */ #define TF2_IPSEC_TSO 0x00200000 /* IPSEC + TSO supported */ +#define TF2_NO_ISS_CHECK 0x00200000 /* Don't check SEG.ACK against ISS */ /* * Structure to hold TCP options that are only used during segment @@ -1089,8 +1090,12 @@ struct tcpstat { uint64_t tcps_tlpresends; /* number of tlp resends */ uint64_t tcps_tlpresend_bytes; /* number of bytes resent by tlp */ + /* SEG.ACK validation failures */ + uint64_t tcps_rcvghostack; /* received ACK for data never sent */ + uint64_t tcps_rcvacktooold; /* received ACK for data too long ago */ - uint64_t _pad[3]; /* 3 TBD placeholder for STABLE */ + + uint64_t _pad[1]; /* 1 TBD placeholder for STABLE */ }; #define tcps_rcvmemdrop tcps_rcvreassfull /* compat */ @@ -1280,6 +1285,7 @@ VNET_DECLARE(int, tcp_ecn_maxretries); VNET_DECLARE(int, tcp_initcwnd_segments); VNET_DECLARE(int, tcp_insecure_rst); VNET_DECLARE(int, tcp_insecure_syn); +VNET_DECLARE(int, tcp_insecure_ack); VNET_DECLARE(uint32_t, tcp_map_entries_limit); VNET_DECLARE(uint32_t, tcp_map_split_limit); VNET_DECLARE(int, tcp_minmss); @@ -1327,6 +1333,7 @@ VNET_DECLARE(struct inpcbinfo, tcbinfo); #define V_tcp_initcwnd_segments VNET(tcp_initcwnd_segments) #define V_tcp_insecure_rst VNET(tcp_insecure_rst) #define V_tcp_insecure_syn VNET(tcp_insecure_syn) +#define V_tcp_insecure_ack VNET(tcp_insecure_ack) #define V_tcp_map_entries_limit VNET(tcp_map_entries_limit) #define V_tcp_map_split_limit VNET(tcp_map_split_limit) #define V_tcp_minmss VNET(tcp_minmss) diff --git a/usr.bin/netstat/inet.c b/usr.bin/netstat/inet.c index 5d7fd0e46cf1..9ff7c687353f 100644 --- a/usr.bin/netstat/inet.c +++ b/usr.bin/netstat/inet.c @@ -642,8 +642,12 @@ tcp_stats(u_long off, const char *name, int af1 __unused, int proto __unused) "{N:/UDP tunneled pkt%s}\n"); p(tcps_tunneled_errs, "\t\t{:received-bad-udp-tunneled-pkts/%ju} " "{N:/UDP tunneled pkt cnt with error%s}\n"); - p(tcps_rcvacktoomuch, "\t\t{:received-acks-for-unsent-data/%ju} " - "{N:/ack%s for unsent data}\n"); + p(tcps_rcvacktoomuch, "\t\t{:received-acks-for-data-not-yet-sent/%ju} " + "{N:/ack%s for data not yet sent}\n"); + p(tcps_rcvghostack, "\t\t{:received-acks-for-data-never-been-sent/%ju} " + "{N:/ack%s for data never been sent (ghost acks)}\n"); + p(tcps_rcvacktooold, "\t\t{:received-acks-for-data-being-too-old/%ju} " + "{N:/ack%s for data being too old}\n"); p2(tcps_rcvpack, tcps_rcvbyte, "\t\t" "{:received-in-sequence-packets/%ju} {N:/packet%s} " "({:received-in-sequence-bytes/%ju} {N:/byte%s}) " From nobody Sun Jul 21 18:52:56 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRsx50tj8z5QGwn; Sun, 21 Jul 2024 18:52: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRsx50Qgkz444j; Sun, 21 Jul 2024 18:52:57 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721587977; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=QHStPBn/VjKzAp6bYKDrfeDX1P44/Ks+Kq5qqbHBFCg=; b=g9vvUGJQIY1u0XK06qGiP0gTCZcBBqjGcyFD5u4YZ0/TNx5lJUxNkJxHAt9WxSNsPs6/0a 5W+qwJ6UD26VfwqMsVOyTu3VgOOtk9og0D0rMZfeb5OvbjKllHXQqPn0DXZfhsNeX5NJRk XRi0WFRjm9nVHe8wHsw2UaZ2VRxpMqFgvaVAMskrcs5fNBfe3vQwliX3aUsA7y3RC+lYiH eHKzx7QlqdbQhin00Zt3eVhyhRhWN+4APyEMc1L1dVPi6Y09QMJ8VHO+B3UjkvjFrMpBjN sHDkBE7A77N7fJY0KU5ps8J462SWYoQBhJihSB5O33znK8KDAk1mlgmrPgTNlA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721587977; a=rsa-sha256; cv=none; b=fl+slnWRNzyKNIA4SssqPxfgb+gpMR/vAkjPvvhfKHbfJQZtCc3mDHBRDt1SlPctZvaTLh 6vyXa7IfNvwOy4BQs+S0bpqemyH66u2R7MfTyFeZn2UBya6H6h3Pvgzw1pne4Bc23qPnwa 8JGDqjbjD7HT+n5OL9sx18nxJlW00nGoOunw+2qpbqz+f66/gdYq8S8px7uy3AqpGTUaui aTuVNm2MBbiGD8JiLWKCrE7NJMIX3c84P5yaJUI1J8WKz5mvINomxF2yqfmTDenEBNcaS+ 6sMiaG3abGs0KaQgtLvh/4Tq0z8vLMwuHj05QMr6E7k6UXeZnsotsOSrdydTNw== 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=1721587977; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=QHStPBn/VjKzAp6bYKDrfeDX1P44/Ks+Kq5qqbHBFCg=; b=rRyA01D/2avz0Al/XFPhQRHtvGx7iJfUitdYrbV0W6dZu1c8mBDaGEpCgHlfV4aBfMDt07 NOZ3B+V7D+4CWhHLqkfYP8MoDne0Cpmkeagip3HX34/2+VALlOzvZElcWHBhZMFYSHUh4F JXCvsXaMjB2t23wUSenyqdUMXx3/B7/Fin1ceDfkmyJym3nct8kGsvIhUqyOB+27VMnDXa g86JukuBW73D0s6eP+EnLvU39/IAxSUIo3y8h/djxWdBaQWSanKJqjmZcG2JS+zD6bLBJg wtV9J4kaRWkzHrBSZG+QwWBpHdrTZXCwJKrvyVRjrJ6ddAR8oN2lXpIdCSS0Sw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRsx46jrpz1BvM; Sun, 21 Jul 2024 18:52:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LIquf6099382; Sun, 21 Jul 2024 18:52:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LIqu5V099379; Sun, 21 Jul 2024 18:52:56 GMT (envelope-from git) Date: Sun, 21 Jul 2024 18:52:56 GMT Message-Id: <202407211852.46LIqu5V099379@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Michael Tuexen Subject: git: baee801c92d2 - main - tcp: simplify endpoint creation at the passive side List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: baee801c92d26f4b7d1b2a9edd755c1b07b84167 Auto-Submitted: auto-generated The branch main has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=baee801c92d26f4b7d1b2a9edd755c1b07b84167 commit baee801c92d26f4b7d1b2a9edd755c1b07b84167 Author: Michael Tuexen AuthorDate: 2024-07-21 09:49:37 +0000 Commit: Michael Tuexen CommitDate: 2024-07-21 09:49:37 +0000 tcp: simplify endpoint creation at the passive side Use the intended TCP stack when creating a TCP endpoint instead of creating it the endpoint the default stack first and after that switching it to use the intended TCP stack. Reviewed by: Peter Lei, rrs and jtl (older version) Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D45411 --- sys/netinet/tcp_subr.c | 19 +++++++++++++++++-- sys/netinet/tcp_syncache.c | 39 ++++++--------------------------------- sys/netinet/tcp_usrreq.c | 2 +- sys/netinet/tcp_var.h | 2 +- 4 files changed, 25 insertions(+), 37 deletions(-) diff --git a/sys/netinet/tcp_subr.c b/sys/netinet/tcp_subr.c index 5743d1bbd100..6dc8e0c1c46e 100644 --- a/sys/netinet/tcp_subr.c +++ b/sys/netinet/tcp_subr.c @@ -2180,9 +2180,11 @@ tcp_respond(struct tcpcb *tp, void *ipgen, struct tcphdr *th, struct mbuf *m, * Create a new TCP control block, making an empty reassembly queue and hooking * it to the argument protocol control block. The `inp' parameter must have * come from the zone allocator set up by tcpcbstor declaration. + * The caller can provide a pointer to a tcpcb of the listener to inherit the + * TCP function block from the listener. */ struct tcpcb * -tcp_newtcpcb(struct inpcb *inp) +tcp_newtcpcb(struct inpcb *inp, struct tcpcb *listening_tcb) { struct tcpcb *tp = intotcpcb(inp); #ifdef INET6 @@ -2200,8 +2202,21 @@ tcp_newtcpcb(struct inpcb *inp) tp->t_ccv.type = IPPROTO_TCP; tp->t_ccv.ccvc.tcp = tp; rw_rlock(&tcp_function_lock); - tp->t_fb = V_tcp_func_set_ptr; + if (listening_tcb != NULL) { + INP_LOCK_ASSERT(tptoinpcb(listening_tcb)); + KASSERT(listening_tcb->t_fb != NULL, + ("tcp_newtcpcb: listening_tcb->t_fb is NULL")); + if (listening_tcb->t_fb->tfb_flags & TCP_FUNC_BEING_REMOVED) { + rw_runlock(&tcp_function_lock); + return (NULL); + } + tp->t_fb = listening_tcb->t_fb; + } else { + tp->t_fb = V_tcp_func_set_ptr; + } refcount_acquire(&tp->t_fb->tfb_refcnt); + KASSERT((tp->t_fb->tfb_flags & TCP_FUNC_BEING_REMOVED) == 0, + ("tcp_newtcpcb: using TFB being removed")); rw_runlock(&tcp_function_lock); /* * Use the current system default CC algorithm. diff --git a/sys/netinet/tcp_syncache.c b/sys/netinet/tcp_syncache.c index 1a3b6ebf6788..c797c6a99f4f 100644 --- a/sys/netinet/tcp_syncache.c +++ b/sys/netinet/tcp_syncache.c @@ -777,7 +777,7 @@ done: static struct socket * syncache_socket(struct syncache *sc, struct socket *lso, struct mbuf *m) { - struct tcp_function_block *blk; + struct tcpcb *listening_tcb; struct inpcb *inp = NULL; struct socket *so; struct tcpcb *tp; @@ -802,7 +802,11 @@ syncache_socket(struct syncache *sc, struct socket *lso, struct mbuf *m) goto allocfail; } inp = sotoinpcb(so); - if ((tp = tcp_newtcpcb(inp)) == NULL) { + if (V_functions_inherit_listen_socket_stack) + listening_tcb = sototcpcb(lso); + else + listening_tcb = NULL; + if ((tp = tcp_newtcpcb(inp, listening_tcb)) == NULL) { in_pcbfree(inp); sodealloc(so); goto allocfail; @@ -912,37 +916,6 @@ syncache_socket(struct syncache *sc, struct socket *lso, struct mbuf *m) tp->t_port = sc->sc_port; tcp_rcvseqinit(tp); tcp_sendseqinit(tp); - blk = sototcpcb(lso)->t_fb; - if (V_functions_inherit_listen_socket_stack && blk != tp->t_fb) { - /* - * Our parents t_fb was not the default, - * we need to release our ref on tp->t_fb and - * pickup one on the new entry. - */ - struct tcp_function_block *rblk; - void *ptr = NULL; - - rblk = find_and_ref_tcp_fb(blk); - KASSERT(rblk != NULL, - ("cannot find blk %p out of syncache?", blk)); - - if (rblk->tfb_tcp_fb_init == NULL || - (*rblk->tfb_tcp_fb_init)(tp, &ptr) == 0) { - /* Release the old stack */ - if (tp->t_fb->tfb_tcp_fb_fini != NULL) - (*tp->t_fb->tfb_tcp_fb_fini)(tp, 0); - refcount_release(&tp->t_fb->tfb_refcnt); - /* Now set in all the pointers */ - tp->t_fb = rblk; - tp->t_fb_ptr = ptr; - } else { - /* - * Initialization failed. Release the reference count on - * the looked up default stack. - */ - refcount_release(&rblk->tfb_refcnt); - } - } tp->snd_wl1 = sc->sc_irs; tp->snd_max = tp->iss + 1; tp->snd_nxt = tp->iss + 1; diff --git a/sys/netinet/tcp_usrreq.c b/sys/netinet/tcp_usrreq.c index 3bc283c5a9db..c43e4523f358 100644 --- a/sys/netinet/tcp_usrreq.c +++ b/sys/netinet/tcp_usrreq.c @@ -172,7 +172,7 @@ tcp_usr_attach(struct socket *so, int proto, struct thread *td) if (error) goto out; inp = sotoinpcb(so); - tp = tcp_newtcpcb(inp); + tp = tcp_newtcpcb(inp, NULL); if (tp == NULL) { error = ENOBUFS; in_pcbfree(inp); diff --git a/sys/netinet/tcp_var.h b/sys/netinet/tcp_var.h index f691579acf09..099fb32ee613 100644 --- a/sys/netinet/tcp_var.h +++ b/sys/netinet/tcp_var.h @@ -1454,7 +1454,7 @@ void tcp_mss_update(struct tcpcb *, int, int, struct hc_metrics_lite *, void tcp_mss(struct tcpcb *, int); int tcp_mssopt(struct in_conninfo *); struct tcpcb * - tcp_newtcpcb(struct inpcb *); + tcp_newtcpcb(struct inpcb *, struct tcpcb *); int tcp_default_output(struct tcpcb *); void tcp_state_change(struct tcpcb *, int); void tcp_respond(struct tcpcb *, void *, From nobody Sun Jul 21 18:53:34 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRsxq1MZlz5QHNR for ; Sun, 21 Jul 2024 18:53: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRsxq0qH1z44WG; Sun, 21 Jul 2024 18:53:35 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721588015; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=+/vwxtnNRctssESKhGAhjHNur7soAuObpHOU61jAk8g=; b=Wt8p+qv4kcMhqer5G1mEkb3BFy/LeZ9G7n3/gQq8cSy625yHt+kfv1ofFpFrh/VodPZk51 zoWGv9+HZ+Qx6wmvKnKrnAiqALd3PhJletNtvmFYQZKanxZcO14Ikgdm1CzidLgvcu9AS4 ikZttvDmbUq9Ds1KeaIDUg2Nh9LnlR3APWYsKdLud1TYKNEbnhjGsUqTeolAfZS/C80XMh uGEYZupRucAXN15RUl7CI+yiPt9FhJrqDIuqq5B5VY6b4yMnSkQFVrzHaLFOcAjVWacv8n yWrxzWvi7equbvEI5G7nhM3mVsEakECJnBCQNNXHT1K9vwGqLtyvzVu5Od9mjQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721588015; a=rsa-sha256; cv=none; b=TzAU+SkllLbVJGnrcz00jsiZqRr3/IMKP3GKlBRcGIu3VTuURVeVLxXswbFHVcMZ7rDwmh Fub1Kr3k8hhgl6GBke3TTHmHoeZ02tTXwOmMO9OKbdwPgLjTepHfLViqcEzsM+SEOTYHEG gdxegd26yjVy9FHnAPuslE6jiySFdR3t7xTipN3k9ISoy+ObD/XB3cAIH92ZFqNr6KIIZh oijavl/KdrMhGqT3ias2VMbaSnmlQ4rGRf7B0jeHC4zx97RayDwsjm1pfFQawnOw6sDDOM i2V1XcFX5uZa1hxBavhPtQsf6tZ/cIwbXm0gyi6S/uStCfcUiGGjs02GOEWfRQ== 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=1721588015; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=+/vwxtnNRctssESKhGAhjHNur7soAuObpHOU61jAk8g=; b=TmBztF1YnhdKfQgc0szQ6J6O+60y7ZI2k9UZLBLRD2AIROFgTrk5rWlgXsmFt4hMGviWoP enOwmxO6Y1y04mmP1KaEm4uwcIVGPBkq5NL/F1lOo5XTu2h3P4KnBnXFiP+SLgbAraRUrn 4Vk/1pADM5wtj3sYLa+bD5AiAJSJHzhoT70VZpB2xdc2T9n9MrCDsRbbVrSqxDZYwHMHvG b0RLbGE3OZD4TZfPfJOL+UuRrMetE90IJI2/7ztOo/tK543/fUUIda/G7y193tAMlFmLWW 9bzMCTXKjUuAAKF05MJSSb7AEiR2V27H8TDeMltEHGCBwK1zAajyB6Ae0lYzOw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRsxq07TCz1BWw; Sun, 21 Jul 2024 18:53:35 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LIrYWu099582; Sun, 21 Jul 2024 18:53:34 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LIrYY5099581; Sun, 21 Jul 2024 18:53:34 GMT (envelope-from git) Date: Sun, 21 Jul 2024 18:53:34 GMT Message-Id: <202407211853.46LIrYY5099581@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org From: Cy Schubert Subject: git: 950d2f43375b..6377230b3cf4 - vendor/wpa - vendor branch updated List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cy X-Git-Repository: src X-Git-Refname: refs/heads/vendor/wpa X-Git-Reftype: branch X-Git-Commit: 6377230b3cf4f238dcd0dc2d76ff25943d3040e5 X-Git-Oldrev: 950d2f43375b87e95ebc0ecda9b281b84b2213d7 X-Git-Newrev: 6377230b3cf4f238dcd0dc2d76ff25943d3040e5 Auto-Submitted: auto-generated The branch vendor/wpa has been updated by cy: URL: https://cgit.FreeBSD.org/src/log/?id=950d2f43375b..6377230b3cf4 6377230b3cf4 wpa: Import hostapd 2.11 into wpa From nobody Sun Jul 21 20:41:28 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRwLJ6WSdz5QSBc; Sun, 21 Jul 2024 20:41: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRwLJ5qS2z4FnK; Sun, 21 Jul 2024 20:41:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721594488; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=LOShq+gt3M+3OeV+hpirKTQbIDymYv1uuozlQts6pjg=; b=geYqZcunMSeptlf81/98YzyoFTVPyvLmoFZbyY/F9k5k2fidlUMIizL9D+6bGvu07xJf/a coAVqG3zxEDlNJQAXukMe0XHSJprS83jqwrKn01oKz3a7sREnX5GfKjVDcG+03x8JlQ/be IBaXb6OuGJFR/6ib/hwvkKiJ9hleAMCMRQSB72zz7uLOpINBIogummI2zN8WiZnay0UDAR zoZ99zKHhXTcOPq0q7V152Oe4oKH1TIgh33GP316i6MClYOb9mJbHsh6d57rsfGXRFrS0P +Cs8301jX+hPtTFvcitKgPMeq7LJ4zCowncwhrh54KfIiTPceQvrgAqkJCXJ5g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721594488; a=rsa-sha256; cv=none; b=cjzG4DU9FXDNUJZhFC6hHiX/uhenGhuFW/aRJHuzWPRGa0ACPRhm8bvSRPEfvcQ1RwXVbS 32Ud5Nu1if8XESuIzO6fWDW6B8Vx+YEWAHSKLumCeWhg+s5g+RnpC8BMJoibW3y1Qx4gkF 9gyEhqHVBVvXGamx47FcGBd8wM3j8/ne69WeWV7AInM5xpUQbVs2QFb/CV2HdmMUeWN8Pl hCMQaI4C7Jei/6xIDeZRWqe5tnA9NQJBaN9BIqf6+9FrxfHX+fgXEuSwjU+9lthko2v+Il LzKV4BB+HduvEu9qvcvVlfS8rzFCy3b+fgKiG5jtVwxiQ6aNmsFeI75aLOyznQ== 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=1721594488; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=LOShq+gt3M+3OeV+hpirKTQbIDymYv1uuozlQts6pjg=; b=REPbh8R79u6HBSm9Q5tTFnbqihc6uRvjKQktocVYU3fJ/Ds5HFAu6G+grhACA5AhO3dAfJ OAMHMyL0iCEIB1Hnm4pDNzNy7dRQ1uMzKzJ2werYNL44NqoitbehcqCnr+zIM2iw8yNZBi nQIEaBAXKPghpetQKmFMIx1MNdolauXJeHPvNcVwDf/bRiHZfeShpZoi6QWhVmdNKzYdbl MjSBokmdByzZj3gYsu202g3cTdrinDnuuB1QaHDDr5Y06z2caJwvEO08CrwIJxfRf1mtmC pI5R0TdDKqpwRvtRZABHB/lnpF+JfxgIpP1KqCcMRD7Y7l0FBNE3Id1OAOeewg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRwLJ5QghzFqL; Sun, 21 Jul 2024 20:41:28 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LKfSMN082000; Sun, 21 Jul 2024 20:41:28 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LKfSfZ081997; Sun, 21 Jul 2024 20:41:28 GMT (envelope-from git) Date: Sun, 21 Jul 2024 20:41:28 GMT Message-Id: <202407212041.46LKfSfZ081997@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Dimitry Andric Subject: git: 397c2693fa66 - main - Fix llvm register allocator for native/cross build differences List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: dim X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 397c2693fa66508cb5e6b173650a1f3bc6c4dd4f Auto-Submitted: auto-generated The branch main has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=397c2693fa66508cb5e6b173650a1f3bc6c4dd4f commit 397c2693fa66508cb5e6b173650a1f3bc6c4dd4f Author: Dimitry Andric AuthorDate: 2024-07-21 20:37:27 +0000 Commit: Dimitry Andric CommitDate: 2024-07-21 20:37:27 +0000 Fix llvm register allocator for native/cross build differences Work around an issue in LLVM's register allocator, which can cause slightly different i386 object files, when produced by a native or cross build of clang. This adds another volatile qualifier to a float variable declaration in the weightCalcHelper() function, which otherwise produces slightly different float results on amd64 and i386 hosts. In turn, this can lead to different (but equivalent) register choices, and thus non-identical assembly code. See https://github.com/llvm/llvm-project/issues/99396 for more details. Note this is a temporary fix, meant to merge in time for 13.4. As soon as upstream has a permanent solution we will import that. PR: 276961 Reported by: cperciva MFC after: 3 days --- contrib/llvm-project/llvm/lib/CodeGen/CalcSpillWeights.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/contrib/llvm-project/llvm/lib/CodeGen/CalcSpillWeights.cpp b/contrib/llvm-project/llvm/lib/CodeGen/CalcSpillWeights.cpp index f3cb7fa5af61..afde8d001f88 100644 --- a/contrib/llvm-project/llvm/lib/CodeGen/CalcSpillWeights.cpp +++ b/contrib/llvm-project/llvm/lib/CodeGen/CalcSpillWeights.cpp @@ -256,7 +256,12 @@ float VirtRegAuxInfo::weightCalcHelper(LiveInterval &LI, SlotIndex *Start, return -1.0f; } - float Weight = 1.0f; + // FreeBSD customization: similar to the HWeight declaration below, add a + // volatile qualifier to avoid slightly different weight results on amd64 + // and i386 hosts, and possibly choosing different registers in the register + // allocator. See for + // more details. + volatile float Weight = 1.0f; if (IsSpillable) { // Get loop info for mi. if (MI->getParent() != MBB) { From nobody Sun Jul 21 22:57:55 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRzMl4W8Vz5Qjb4; Sun, 21 Jul 2024 22:57: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRzMl2mwBz4VpV; Sun, 21 Jul 2024 22:57:55 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721602675; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=xBRLuOve5wBgQ6nc8aUoxmrOKNb9YL2Dlg43BTFvPc4=; b=gQiZGEPutjQmMvbzQxmKqe+PUxUk+xRRC2Dxeg3l/8JbqXsqY6E1ScuiAMWYxRg1531pq2 8AoCU0mWg8BRkRwXbZAMHfOJfXVDg4nHN3kFRE821lUbQ+dxETKLV5WqAl099GzxJD6JUj AC4QUqyJO13MrkbulXi8MVS93biDeiUiC+DoIa2U/OUm0Bz3doaq68q4MhahaZqfNTtNeO lA2f4AMklIHd3YDco4VhbahnWPpNJr4bwDKU85cow3+gEY0SAkTvU2bNQJs0jaAxzFB0Rh RO2N23AMdUUbsr3UsqyaFaaRldMg61S0pJKouKXjZtop1Cv/CNHhziSxg9nVKw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721602675; a=rsa-sha256; cv=none; b=m5GlvYKcxGjlDdzVbDtX/vuiMhayjQKOMkZUeKG6vjt5MK3NZ2ANiVaEgIgP54BJIoHAd/ ftdG+p9HVsdBKfv/VNdL84sXws0sCIm5+WdDT2AFbbxjv1ud7qfxRpKlBIjTBPZU/q3ZbB eCoAxtiT4fIB+cjy8osNoDkfWivYr9CHPUES66o2TpEBLBmyuDtW0CJgZ+Gn2B5iovcG/8 zpdjnb42tUGdI7XXdd0G5dkEwVDcaNGirEkRWBZqJo/H4vaYSy3A7zoBL3AXqRtWZOQDlO tnavAm5k13k4E36iyA/maM8K+uxvP9X9yPoex4gdJsxi4dqkgBamLYifYVHP4w== 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=1721602675; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=xBRLuOve5wBgQ6nc8aUoxmrOKNb9YL2Dlg43BTFvPc4=; b=cdvVHQ+27YrNMEPF8Egrm4CDClUdqMBsZCENjJE6bnPjK9bm1Qrg2/GqCLxMqCO/voioZC TdNY0nggPKb1CZV75ma9FLgc1fazQoUIJDvRKuo+LwpzYM4xtKK3ooMx6HadIA3p8rFG9l V6kbRe6O4j/APjikxo/qxE+CnQAJmumN6EwhqTRK+6u7ZXk5cPaDekMfAA7yTwiYePFxfY lpi5gMnZjCFyPjRZGxc4u+xQb7c0Gn2fnHa6Yg/Orq/6qp3YseY6FF15L4qFNxVNhu65Uf BYy5weVQA/BFRVP1Wf1bnCc9WnIN2/6lzOZbOqJpqM8AAAlN7K9LfeLIiQ2sSg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRzMl2FnNzKfB; Sun, 21 Jul 2024 22:57:55 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LMvtLR004416; Sun, 21 Jul 2024 22:57:55 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LMvtLg004413; Sun, 21 Jul 2024 22:57:55 GMT (envelope-from git) Date: Sun, 21 Jul 2024 22:57:55 GMT Message-Id: <202407212257.46LMvtLg004413@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Rick Macklem Subject: git: 026cdaa3b3a9 - main - nfscl: Scan readdir reply filenames for invalid characters List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: rmacklem X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 026cdaa3b3a92574d9ac3155216e5cc0b0bd4c51 Auto-Submitted: auto-generated The branch main has been updated by rmacklem: URL: https://cgit.FreeBSD.org/src/commit/?id=026cdaa3b3a92574d9ac3155216e5cc0b0bd4c51 commit 026cdaa3b3a92574d9ac3155216e5cc0b0bd4c51 Author: Rick Macklem AuthorDate: 2024-07-21 22:56:16 +0000 Commit: Rick Macklem CommitDate: 2024-07-21 22:56:16 +0000 nfscl: Scan readdir reply filenames for invalid characters The NFS RFCs are pretty loose with respect to what characters can be in a filename returned by a Readdir. However, FreeBSD, as a POSIX system will not handle imbedded '/' or nul characters in file names. Also, for NFSv4, the file names "." and ".." are handcrafted on the client and should not be returned by a NFSv4 server. This patch scans for the above in filenames returned by Readdir and ignores any entry returned by Readdir which has them in it. Because an imbedded nul would be a string terminator, it was not possible to code this check efficiently using string(3) functions. Reported by: Apple Security Engineering and Architecture (SEAR) MFC after: 1 week --- sys/fs/nfsclient/nfs_clrpcops.c | 137 ++++++++++++++++++++++++++++++++-------- 1 file changed, 110 insertions(+), 27 deletions(-) diff --git a/sys/fs/nfsclient/nfs_clrpcops.c b/sys/fs/nfsclient/nfs_clrpcops.c index 13bdc74655dd..8947b608b743 100644 --- a/sys/fs/nfsclient/nfs_clrpcops.c +++ b/sys/fs/nfsclient/nfs_clrpcops.c @@ -142,6 +142,7 @@ static int nfsrpc_createv4(vnode_t , char *, int, struct vattr *, nfsquad_t, int, struct nfsclowner *, struct nfscldeleg **, struct ucred *, NFSPROC_T *, struct nfsvattr *, struct nfsvattr *, struct nfsfh **, int *, int *, int *); +static bool nfscl_invalidfname(bool, char *, int); static int nfsrpc_locku(struct nfsrv_descript *, struct nfsmount *, struct nfscllockowner *, u_int64_t, u_int64_t, u_int32_t, struct ucred *, NFSPROC_T *, int); @@ -3321,6 +3322,31 @@ nfsrpc_rmdir(vnode_t dvp, char *name, int namelen, struct ucred *cred, return (error); } +/* + * Check to make sure the file name in a Readdir reply is valid. + */ +static bool +nfscl_invalidfname(bool is_v4, char *name, int len) +{ + int i; + char *cp; + + if (is_v4 && ((len == 1 && name[0] == '.') || + (len == 2 && name[0] == '.' && name[1] == '.'))) { + printf("Readdir NFSv4 reply has dot or dotdot in it\n"); + return (true); + } + cp = name; + for (i = 0; i < len; i++, cp++) { + if (*cp == '/' || *cp == '\0') { + printf("Readdir reply file name had imbedded / or nul" + " byte\n"); + return (true); + } + } + return (false); +} + /* * Readdir rpc. * Always returns with either uio_resid unchanged, if you are at the @@ -3373,6 +3399,8 @@ nfsrpc_readdir(vnode_t vp, struct uio *uiop, nfsuint64 *cookiep, KASSERT(uiop->uio_iovcnt == 1 && (uiop->uio_resid & (DIRBLKSIZ - 1)) == 0, ("nfs readdirrpc bad uio")); + KASSERT(uiop->uio_segflg == UIO_SYSSPACE, + ("nfsrpc_readdir: uio userspace")); ncookie.lval[0] = ncookie.lval[1] = 0; /* * There is no point in reading a lot more than uio_resid, however @@ -3630,6 +3658,17 @@ nfsrpc_readdir(vnode_t vp, struct uio *uiop, nfsuint64 *cookiep, uiop->uio_resid) bigenough = 0; if (bigenough) { + struct iovec saviov; + off_t savoff; + ssize_t savresid; + int savblksiz; + + saviov.iov_base = uiop->uio_iov->iov_base; + saviov.iov_len = uiop->uio_iov->iov_len; + savoff = uiop->uio_offset; + savresid = uiop->uio_resid; + savblksiz = blksiz; + dp = (struct dirent *)uiop->uio_iov->iov_base; dp->d_pad0 = dp->d_pad1 = 0; dp->d_off = 0; @@ -3645,20 +3684,35 @@ nfsrpc_readdir(vnode_t vp, struct uio *uiop, nfsuint64 *cookiep, uiop->uio_iov->iov_base = (char *)uiop->uio_iov->iov_base + DIRHDSIZ; uiop->uio_iov->iov_len -= DIRHDSIZ; + cp = uiop->uio_iov->iov_base; error = nfsm_mbufuio(nd, uiop, len); if (error) goto nfsmout; - cp = uiop->uio_iov->iov_base; - tlen -= len; - NFSBZERO(cp, tlen); - cp += tlen; /* points to cookie storage */ - tl2 = (u_int32_t *)cp; - uiop->uio_iov->iov_base = - (char *)uiop->uio_iov->iov_base + tlen + - NFSX_HYPER; - uiop->uio_iov->iov_len -= tlen + NFSX_HYPER; - uiop->uio_resid -= tlen + NFSX_HYPER; - uiop->uio_offset += (tlen + NFSX_HYPER); + /* Check for an invalid file name. */ + if (nfscl_invalidfname( + (nd->nd_flag & ND_NFSV4) != 0, cp, len)) { + /* Skip over this entry. */ + uiop->uio_iov->iov_base = + saviov.iov_base; + uiop->uio_iov->iov_len = + saviov.iov_len; + uiop->uio_offset = savoff; + uiop->uio_resid = savresid; + blksiz = savblksiz; + } else { + cp = uiop->uio_iov->iov_base; + tlen -= len; + NFSBZERO(cp, tlen); + cp += tlen; /* points to cookie store */ + tl2 = (u_int32_t *)cp; + uiop->uio_iov->iov_base = + (char *)uiop->uio_iov->iov_base + + tlen + NFSX_HYPER; + uiop->uio_iov->iov_len -= tlen + + NFSX_HYPER; + uiop->uio_resid -= tlen + NFSX_HYPER; + uiop->uio_offset += (tlen + NFSX_HYPER); + } } else { error = nfsm_advance(nd, NFSM_RNDUP(len), -1); if (error) @@ -3824,6 +3878,8 @@ nfsrpc_readdirplus(vnode_t vp, struct uio *uiop, nfsuint64 *cookiep, KASSERT(uiop->uio_iovcnt == 1 && (uiop->uio_resid & (DIRBLKSIZ - 1)) == 0, ("nfs readdirplusrpc bad uio")); + KASSERT(uiop->uio_segflg == UIO_SYSSPACE, + ("nfsrpc_readdirplus: uio userspace")); ncookie.lval[0] = ncookie.lval[1] = 0; timespecclear(&dctime); *attrflagp = 0; @@ -4059,6 +4115,17 @@ nfsrpc_readdirplus(vnode_t vp, struct uio *uiop, nfsuint64 *cookiep, uiop->uio_resid) bigenough = 0; if (bigenough) { + struct iovec saviov; + off_t savoff; + ssize_t savresid; + int savblksiz; + + saviov.iov_base = uiop->uio_iov->iov_base; + saviov.iov_len = uiop->uio_iov->iov_len; + savoff = uiop->uio_offset; + savresid = uiop->uio_resid; + savblksiz = blksiz; + dp = (struct dirent *)uiop->uio_iov->iov_base; dp->d_pad0 = dp->d_pad1 = 0; dp->d_off = 0; @@ -4077,25 +4144,41 @@ nfsrpc_readdirplus(vnode_t vp, struct uio *uiop, nfsuint64 *cookiep, cnp->cn_nameptr = uiop->uio_iov->iov_base; cnp->cn_namelen = len; NFSCNHASHZERO(cnp); + cp = uiop->uio_iov->iov_base; error = nfsm_mbufuio(nd, uiop, len); if (error) goto nfsmout; - cp = uiop->uio_iov->iov_base; - tlen -= len; - NFSBZERO(cp, tlen); - cp += tlen; /* points to cookie storage */ - tl2 = (u_int32_t *)cp; - if (len == 2 && cnp->cn_nameptr[0] == '.' && - cnp->cn_nameptr[1] == '.') - isdotdot = 1; - else - isdotdot = 0; - uiop->uio_iov->iov_base = - (char *)uiop->uio_iov->iov_base + tlen + - NFSX_HYPER; - uiop->uio_iov->iov_len -= tlen + NFSX_HYPER; - uiop->uio_resid -= tlen + NFSX_HYPER; - uiop->uio_offset += (tlen + NFSX_HYPER); + /* Check for an invalid file name. */ + if (nfscl_invalidfname( + (nd->nd_flag & ND_NFSV4) != 0, cp, len)) { + /* Skip over this entry. */ + uiop->uio_iov->iov_base = + saviov.iov_base; + uiop->uio_iov->iov_len = + saviov.iov_len; + uiop->uio_offset = savoff; + uiop->uio_resid = savresid; + blksiz = savblksiz; + } else { + cp = uiop->uio_iov->iov_base; + tlen -= len; + NFSBZERO(cp, tlen); + cp += tlen; /* points to cookie store */ + tl2 = (u_int32_t *)cp; + if (len == 2 && + cnp->cn_nameptr[0] == '.' && + cnp->cn_nameptr[1] == '.') + isdotdot = 1; + else + isdotdot = 0; + uiop->uio_iov->iov_base = + (char *)uiop->uio_iov->iov_base + + tlen + NFSX_HYPER; + uiop->uio_iov->iov_len -= tlen + + NFSX_HYPER; + uiop->uio_resid -= tlen + NFSX_HYPER; + uiop->uio_offset += (tlen + NFSX_HYPER); + } } else { error = nfsm_advance(nd, NFSM_RNDUP(len), -1); if (error) From nobody Sun Jul 21 23:10:23 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WRzf76mDWz5Qkm9; Sun, 21 Jul 2024 23:10: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WRzf769pMz4X50; Sun, 21 Jul 2024 23:10:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721603423; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Wn3xzDG42vXRdG8QIcc5HJnVrsm0RU2pttwAmHXPY0o=; b=dFsqqcaxIhhseQlVzpGD4+jNqMih4hCAMiZacDd+pDVpXq0IMii3dfIBDm7qCJqyVfNRe1 xfcxch8hazv1lv2ZDuxsyafruzAg4EJQNPTuRkOC1g0Z4Z3eVwuXLW64UGnaTJxfYhVVs1 xv+LDpELwIHRjVDvvSrcyBcOZ/XttLPoQtf3iU4ghOmMpRLQeKTjQlGZBC23ryLNQ4Z1An mJB18X6thdsk+vjRgFcf48PYtG21m+5aj/yx8ldUZS82mMURXd+XyxY1ZD/Ky/ZSyC2eii UOMS8PmveNkKA1cNYQ3z2srDOwu0NxT0Ieudq8VkJnUZ4tQM6q5AMDtsep8lPA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721603423; a=rsa-sha256; cv=none; b=AuJhpgnq/th68i/bd9f/TNnkHkVw9F0TPkKqM4C7HkxqiChVZDT8uIK7DqhP9b97E1BUVx 3SViVb9rsEku7bD8hY2/8GPRiEsYG6aQZQGdjcmpsrTA+DNphCrmyO1EuFI1cVsc7YXxfX UURQwYb+gXZ2aJm/jALPtWF+QCXVwsyNPEfxmlSr2ALUhdHb9IA3s0gUmi3yxB4zfCwL9j 9kOlAyTVr3j0GBbtQcoehowuEskr2k4dfcl5/fOKoZrMyPYwjNHA8RP/0gYb7X+qLhMzJl 2XumSRqD+ktCNr8ENoGq1X2MBCtiUzeNpzmBIAr1ASeNRYadB4JjFNcj77J02w== 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=1721603423; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Wn3xzDG42vXRdG8QIcc5HJnVrsm0RU2pttwAmHXPY0o=; b=b13hi67/BLaEUc95BP3d5mvgqtHdBxU/nkE8wYRZyfd6Zoer9Fi2xKxAYYRbqLP6PU67jj FYfIbJBtbeGK0AzFAY3i5E0myCv3zCzNCtfVFli/7BPtux3meeDE353EIC5SOxnt8LSm2W 7h85QyO9ji9K4dNa5PtCqKFBrdLBXdbAbS9AiTSDwK+zhj39225LoArGXJeLSqIqD+tJm7 ROkWIRmWdrdosl2ywQOksYH7ZNqa2McBDFhXjET4QRIHfdrd+UcHg9xKNC2rlhhXn13j3E qyTbME2pP+tNalKteFBxWp1b6AEr+xc9iIlDuvAufhZjKtIbrOshlxhaHN58aw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WRzf75hsczKFR; Sun, 21 Jul 2024 23:10:23 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LNANCv031982; Sun, 21 Jul 2024 23:10:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LNANS2031979; Sun, 21 Jul 2024 23:10:23 GMT (envelope-from git) Date: Sun, 21 Jul 2024 23:10:23 GMT Message-Id: <202407212310.46LNANS2031979@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Rick Macklem Subject: git: 7ac2b39c59bd - stable/14 - nfsd: Fix nfsrv_cleanclient so that it can be called with a mutex List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: rmacklem X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 7ac2b39c59bda30d42478ed6ca09baf588bff773 Auto-Submitted: auto-generated The branch stable/14 has been updated by rmacklem: URL: https://cgit.FreeBSD.org/src/commit/?id=7ac2b39c59bda30d42478ed6ca09baf588bff773 commit 7ac2b39c59bda30d42478ed6ca09baf588bff773 Author: Rick Macklem AuthorDate: 2024-06-21 22:08:48 +0000 Commit: Rick Macklem CommitDate: 2024-07-21 23:06:02 +0000 nfsd: Fix nfsrv_cleanclient so that it can be called with a mutex On Feb. 28, a problem was reported on freebsd-stable@ where a nfsd thread processing an ExchangeID operation was blocked for a long time by another nfsd thread performing a copy_file_range. This occurred because the copy_file_range was taking a long time, but also because handling a clientID requires that all other nfsd threads be blocked via an exclusive lock, as required by ExchangeID. This patch adds two arguments to nfsv4_cleanclient() so that it can optionally be called with a mutex held. For this patch, the first of these arguments is "false" and, as such, there is no change in semantics. However, this change will allow a future commit to modify handling of the clientID so that it can be done with a mutex held while other nfsd threads continue to process NFS RPCs. (cherry picked from commit a7de51068502ad1e2851d4a855ed28b27573bb36) --- sys/fs/nfs/nfsrvstate.h | 2 +- sys/fs/nfsserver/nfs_nfsdsocket.c | 2 +- sys/fs/nfsserver/nfs_nfsdstate.c | 55 +++++++++++++++++++++++---------------- 3 files changed, 35 insertions(+), 24 deletions(-) diff --git a/sys/fs/nfs/nfsrvstate.h b/sys/fs/nfs/nfsrvstate.h index da214ae9d4e9..cc19ed6fa1d2 100644 --- a/sys/fs/nfs/nfsrvstate.h +++ b/sys/fs/nfs/nfsrvstate.h @@ -333,7 +333,7 @@ struct nfsf_rec { u_int32_t numboots; /* Number of boottimes */ }; -void nfsrv_cleanclient(struct nfsclient *, NFSPROC_T *); +void nfsrv_cleanclient(struct nfsclient *, NFSPROC_T *, bool, SVCXPRT **); void nfsrv_freedeleglist(struct nfsstatehead *); /* diff --git a/sys/fs/nfsserver/nfs_nfsdsocket.c b/sys/fs/nfsserver/nfs_nfsdsocket.c index 1f50634405d0..df0c0edd1b59 100644 --- a/sys/fs/nfsserver/nfs_nfsdsocket.c +++ b/sys/fs/nfsserver/nfs_nfsdsocket.c @@ -797,7 +797,7 @@ nfsrvd_compound(struct nfsrv_descript *nd, int isdgram, u_char *tag, !LIST_EMPTY(&clp->lc_deleg)) nfsrv_writestable(clp->lc_id, clp->lc_idlen, NFSNST_REVOKE, p); - nfsrv_cleanclient(clp, p); + nfsrv_cleanclient(clp, p, false, NULL); nfsrv_freedeleglist(&clp->lc_deleg); nfsrv_freedeleglist(&clp->lc_olddeleg); LIST_REMOVE(clp, lc_hash); diff --git a/sys/fs/nfsserver/nfs_nfsdstate.c b/sys/fs/nfsserver/nfs_nfsdstate.c index ce3f3481f04a..7a28e51e21fc 100644 --- a/sys/fs/nfsserver/nfs_nfsdstate.c +++ b/sys/fs/nfsserver/nfs_nfsdstate.c @@ -204,7 +204,7 @@ static void nfsrv_locklf(struct nfslockfile *lfp); static void nfsrv_unlocklf(struct nfslockfile *lfp); static struct nfsdsession *nfsrv_findsession(uint8_t *sessionid); static int nfsrv_freesession(struct nfsrv_descript *nd, struct nfsdsession *sep, - uint8_t *sessionid); + uint8_t *sessionid, bool locked, SVCXPRT **old_xprtp); static int nfsv4_setcbsequence(struct nfsrv_descript *nd, struct nfsclient *clp, int dont_replycache, struct nfsdsession **sepp, int *slotposp); static int nfsv4_getcbsession(struct nfsclient *clp, struct nfsdsession **sepp); @@ -337,7 +337,7 @@ nfsrv_setclient(struct nfsrv_descript *nd, struct nfsclient **new_clpp, */ if (i != nfsrv_clienthashsize) { LIST_REMOVE(clp, lc_hash); - nfsrv_cleanclient(clp, p); + nfsrv_cleanclient(clp, p, false, NULL); nfsrv_freedeleglist(&clp->lc_deleg); nfsrv_freedeleglist(&clp->lc_olddeleg); zapit = 1; @@ -390,7 +390,7 @@ nfsrv_setclient(struct nfsrv_descript *nd, struct nfsclient **new_clpp, */ if (clp->lc_expiry < NFSD_MONOSEC && (!LIST_EMPTY(&clp->lc_open) || !LIST_EMPTY(&clp->lc_deleg))) { - nfsrv_cleanclient(clp, p); + nfsrv_cleanclient(clp, p, false, NULL); nfsrv_freedeleglist(&clp->lc_deleg); } @@ -454,7 +454,7 @@ nfsrv_setclient(struct nfsrv_descript *nd, struct nfsclient **new_clpp, /* Get rid of all sessions on this clientid. */ LIST_FOREACH_SAFE(sep, &clp->lc_session, sess_list, nsep) { - ret = nfsrv_freesession(NULL, sep, NULL); + ret = nfsrv_freesession(NULL, sep, NULL, false, NULL); if (ret != 0) printf("nfsrv_setclient: verifier changed free" " session failed=%d\n", ret); @@ -725,7 +725,7 @@ nfsrv_getclient(nfsquad_t clientid, int opflags, struct nfsclient **clpp, * for an Open with CLAIM_DELEGATE_PREV unless in * grace, but get rid of the rest of the state. */ - nfsrv_cleanclient(clp, p); + nfsrv_cleanclient(clp, p, false, NULL); nfsrv_freedeleglist(&clp->lc_olddeleg); if (nfsrv_checkgrace(nd, clp, 0)) { /* In grace, so just delete delegations */ @@ -893,7 +893,7 @@ nfsrv_destroyclient(struct nfsrv_descript *nd, nfsquad_t clientid, NFSPROC_T *p) } /* Destroy the clientid and return ok. */ - nfsrv_cleanclient(clp, p); + nfsrv_cleanclient(clp, p, false, NULL); nfsrv_freedeleglist(&clp->lc_deleg); nfsrv_freedeleglist(&clp->lc_olddeleg); LIST_REMOVE(clp, lc_hash); @@ -962,7 +962,7 @@ nfsrv_adminrevoke(struct nfsd_clid *revokep, NFSPROC_T *p) */ clp->lc_flags &= ~LCL_CALLBACKSON; clp->lc_flags |= LCL_ADMINREVOKED; - nfsrv_cleanclient(clp, p); + nfsrv_cleanclient(clp, p, false, NULL); nfsrv_freedeleglist(&clp->lc_deleg); nfsrv_freedeleglist(&clp->lc_olddeleg); NFSLOCKV4ROOTMUTEX(); @@ -1382,7 +1382,8 @@ nfsrv_servertimer(void *arg __unused) * there are no other active nfsd threads. */ void -nfsrv_cleanclient(struct nfsclient *clp, NFSPROC_T *p) +nfsrv_cleanclient(struct nfsclient *clp, NFSPROC_T *p, bool locked, + SVCXPRT **old_xprtp) { struct nfsstate *stp, *nstp; struct nfsdsession *sep, *nsep; @@ -1391,7 +1392,8 @@ nfsrv_cleanclient(struct nfsclient *clp, NFSPROC_T *p) nfsrv_freeopenowner(stp, 1, p); if ((clp->lc_flags & LCL_ADMINREVOKED) == 0) LIST_FOREACH_SAFE(sep, &clp->lc_session, sess_list, nsep) - (void)nfsrv_freesession(NULL, sep, NULL); + (void)nfsrv_freesession(NULL, sep, NULL, locked, + old_xprtp); } /* @@ -4499,7 +4501,7 @@ nfsrv_docallback(struct nfsclient *clp, int procnum, nfsv4stateid_t *stateidp, if (procnum != NFSV4PROC_CBNULL) nfsv4_freeslot(&sep->sess_cbsess, slotpos, true); - nfsrv_freesession(NULL, sep, NULL); + nfsrv_freesession(NULL, sep, NULL, false, NULL); } else if (nd->nd_procnum == NFSV4PROC_CBNULL) error = newnfs_connect(NULL, &clp->lc_req, cred, NULL, 1, dotls, &clp->lc_req.nr_client); @@ -4548,7 +4550,7 @@ nfsrv_docallback(struct nfsclient *clp, int procnum, nfsv4stateid_t *stateidp, nfsv4_freeslot(&sep->sess_cbsess, slotpos, true); } - nfsrv_freesession(NULL, sep, NULL); + nfsrv_freesession(NULL, sep, NULL, false, NULL); } else error = newnfs_request(nd, NULL, clp, &clp->lc_req, NULL, NULL, cred, clp->lc_program, @@ -5151,7 +5153,7 @@ nfsrv_clientconflict(struct nfsclient *clp, int *haslockp, vnode_t vp, */ nfsrv_writestable(clp->lc_id, clp->lc_idlen, NFSNST_REVOKE, p); nfsrv_backupstable(); - nfsrv_cleanclient(clp, p); + nfsrv_cleanclient(clp, p, false, NULL); nfsrv_freedeleglist(&clp->lc_deleg); nfsrv_freedeleglist(&clp->lc_olddeleg); LIST_REMOVE(clp, lc_hash); @@ -5343,7 +5345,7 @@ nfsrv_delegconflict(struct nfsstate *stp, int *haslockp, NFSPROC_T *p, nfsrv_writestable(clp->lc_id, clp->lc_idlen, NFSNST_REVOKE, p); nfsrv_backupstable(); if (clp->lc_expiry < NFSD_MONOSEC) { - nfsrv_cleanclient(clp, p); + nfsrv_cleanclient(clp, p, false, NULL); nfsrv_freedeleglist(&clp->lc_deleg); nfsrv_freedeleglist(&clp->lc_olddeleg); LIST_REMOVE(clp, lc_hash); @@ -6150,7 +6152,7 @@ nfsrv_throwawayallstate(NFSPROC_T *p) for (i = 0; i < nfsrv_clienthashsize; i++) { LIST_FOREACH_SAFE(clp, &NFSD_VNET(nfsclienthash)[i], lc_hash, nclp) { - nfsrv_cleanclient(clp, p); + nfsrv_cleanclient(clp, p, false, NULL); nfsrv_freedeleglist(&clp->lc_deleg); nfsrv_freedeleglist(&clp->lc_olddeleg); free(clp->lc_stateid, M_NFSDCLIENT); @@ -6373,7 +6375,7 @@ nfsrv_destroysession(struct nfsrv_descript *nd, uint8_t *sessionid) } while (igotlock == 0); NFSUNLOCKV4ROOTMUTEX(); - error = nfsrv_freesession(nd, NULL, sessionid); + error = nfsrv_freesession(nd, NULL, sessionid, false, NULL); if (error == 0 && samesess != 0) nd->nd_flag &= ~ND_HASSEQUENCE; @@ -6469,12 +6471,13 @@ out: */ static int nfsrv_freesession(struct nfsrv_descript *nd, struct nfsdsession *sep, - uint8_t *sessionid) + uint8_t *sessionid, bool locked, SVCXPRT **old_xprtp) { struct nfssessionhash *shp; int i; - NFSLOCKSTATE(); + if (!locked) + NFSLOCKSTATE(); if (sep == NULL) { shp = NFSSESSIONHASH(sessionid); NFSLOCKSESSION(shp); @@ -6488,28 +6491,36 @@ nfsrv_freesession(struct nfsrv_descript *nd, struct nfsdsession *sep, if (nd != NULL && nfsrv_checkmachcred(NFSV4OP_DESTROYSESSION, nd, sep->sess_clp) != 0) { NFSUNLOCKSESSION(shp); - NFSUNLOCKSTATE(); + if (!locked) + NFSUNLOCKSTATE(); return (NFSERR_AUTHERR | AUTH_TOOWEAK); } sep->sess_refcnt--; if (sep->sess_refcnt > 0) { NFSUNLOCKSESSION(shp); - NFSUNLOCKSTATE(); + if (!locked) + NFSUNLOCKSTATE(); return (NFSERR_BACKCHANBUSY); } LIST_REMOVE(sep, sess_hash); LIST_REMOVE(sep, sess_list); } NFSUNLOCKSESSION(shp); - NFSUNLOCKSTATE(); + if (!locked) + NFSUNLOCKSTATE(); if (sep == NULL) return (NFSERR_BADSESSION); for (i = 0; i < NFSV4_SLOTS; i++) if (sep->sess_slots[i].nfssl_reply != NULL) m_freem(sep->sess_slots[i].nfssl_reply); - if (sep->sess_cbsess.nfsess_xprt != NULL) - SVC_RELEASE(sep->sess_cbsess.nfsess_xprt); + if (!locked) { + if (sep->sess_cbsess.nfsess_xprt != NULL) + SVC_RELEASE(sep->sess_cbsess.nfsess_xprt); + if (old_xprtp != NULL) + *old_xprtp = NULL; + } else if (old_xprtp != NULL) + *old_xprtp = sep->sess_cbsess.nfsess_xprt; free(sep, M_NFSDSESSION); return (0); } From nobody Sun Jul 21 23:57:32 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WS0hY1kB3z5QqF1; Sun, 21 Jul 2024 23:57: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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WS0hY173tz4bjT; Sun, 21 Jul 2024 23:57:33 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1721606253; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Nv0nqlTcdQSlQAhp/yrcpVZgK6DLawzGCx4wSciAI9U=; b=S5oC9n1Rr2NlFmhpnvPa2qPRGUsIUNP1yunWq+oJtpUNAhY8iiPdp/+2LQOHGoN6Rb0i0o x2zg3gaLQhkcBWNzx7cpek0leRC0/x3asKJxgV+UsRxztOYuvvUmPfGfDNsFuBlfV3KXMc X8FeDIhezkk7CkYu1esDAlS2kR+otspiP1hFdwRGyW1bl0jWv0Oq4e8iMkClhJzUnQkUu8 b/9AfFOpNHKssdi6b/S3P1R4nVfDJpDjQ6SqVaFf5yKE+v40J/J251P2/nO5eQdJf0beUd shXJXpDiJSyTVC6U3gKj2qNPLWVENf6gMZ0mDtl3+cYDQB5Ni7htDuAcxr24lg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1721606253; a=rsa-sha256; cv=none; b=YCSpQuCsVT+Na+jmV+C0Hhyi2RH3KyH+rJJ307fRJwI4yJF+ybPKSqPXB5sI9lT52dMeMD 7UR35PTl6CfDNoGrOdJjXtHSWBuJRehZrPl+ENg5NzI3wazXaMPogvQaMWy5HASaxAzKHV 4dRL4rg2cTi/QT/W6raig+5RM0UPQQx5IxfBTRdSWQR+q8NwwQyTyaGdRaQA4wxAqCqqKK eoQDNa6y2NlPXcg6VsOuKa62yYiC7/Usj3gj5G2UJde2lNfAN0pgtoSKfyQQFivjxCpbkg 4U9cKAZayKx8q5rQxU3kcC+ntkgwdu99aIOIl9hopzp/TswzsKhPr59M/hROow== 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=1721606253; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Nv0nqlTcdQSlQAhp/yrcpVZgK6DLawzGCx4wSciAI9U=; b=M72cwtHUIc1CVfOYrootKlgRDCHFMf855xUR+3vVdgMizj2A6CKgFX8KXqprXFFbuudh8e xaakXNcTi+NTjkUoyWFYPXzjujCbu5FVXYuoN909IBQ61Fkmv/YYk/8Jm64gD573Luwb+0 ciayCWsY4kySdIIHW7HazMaZTZjqrcQ7403GGu3/vTe3s/Iahna0ISqdOeizMBUmxxe1Cn brvaqbMxt7gIJ7ZuSYcv9Gz9wILrY/HbOsImliMWoBzqwl2xdWnbQMh6ROMjIYafi3ipzx GfkTIctdhqofr+HHAk/gFTIHv9gUB+aFV7zYq4UclY/CogLN73BZogVdRmVEcg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WS0hY0dNTzLvm; Sun, 21 Jul 2024 23:57:33 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46LNvWql006299; Sun, 21 Jul 2024 23:57:32 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46LNvWw4006296; Sun, 21 Jul 2024 23:57:32 GMT (envelope-from git) Date: Sun, 21 Jul 2024 23:57:32 GMT Message-Id: <202407212357.46LNvWw4006296@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Michael Tuexen Subject: git: e0b080f850cc - main - tcp: mark TCP stacks which can serve as a default stack List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e0b080f850cc0418353cc196cbfe81075cf76661 Auto-Submitted: auto-generated The branch main has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=e0b080f850cc0418353cc196cbfe81075cf76661 commit e0b080f850cc0418353cc196cbfe81075cf76661 Author: Michael Tuexen AuthorDate: 2024-07-21 13:06:10 +0000 Commit: Michael Tuexen CommitDate: 2024-07-21 13:06:10 +0000 tcp: mark TCP stacks which can serve as a default stack Allow a TCP function block (tfb) to become the default stack only if tfb->tfb_flags has the TCP_FUNC_DEFAULT_OK flags set. This allows a TCP function block, that is not suitable as a default function block to ensure that it is not set as the default via sysctl. In this case sysctl would return EINVAL. Reviewed by: gallatin, Peter Lei Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D45419 --- sys/netinet/tcp_stacks/bbr.c | 2 +- sys/netinet/tcp_stacks/rack.c | 2 +- sys/netinet/tcp_subr.c | 5 +++++ sys/netinet/tcp_var.h | 1 + 4 files changed, 8 insertions(+), 2 deletions(-) diff --git a/sys/netinet/tcp_stacks/bbr.c b/sys/netinet/tcp_stacks/bbr.c index 445ba064b316..cf64451f0c87 100644 --- a/sys/netinet/tcp_stacks/bbr.c +++ b/sys/netinet/tcp_stacks/bbr.c @@ -14181,7 +14181,7 @@ struct tcp_function_block __tcp_bbr = { .tfb_tcp_mtu_chg = bbr_mtu_chg, .tfb_pru_options = bbr_pru_options, .tfb_switch_failed = bbr_switch_failed, - .tfb_flags = TCP_FUNC_OUTPUT_CANDROP, + .tfb_flags = TCP_FUNC_OUTPUT_CANDROP | TCP_FUNC_DEFAULT_OK, }; /* diff --git a/sys/netinet/tcp_stacks/rack.c b/sys/netinet/tcp_stacks/rack.c index bd7583d3843a..44ddfac2a6ca 100644 --- a/sys/netinet/tcp_stacks/rack.c +++ b/sys/netinet/tcp_stacks/rack.c @@ -25289,7 +25289,7 @@ static struct tcp_function_block __tcp_rack = { .tfb_compute_pipe = rack_compute_pipe, .tfb_stack_info = rack_stack_information, .tfb_inherit = rack_inherit, - .tfb_flags = TCP_FUNC_OUTPUT_CANDROP, + .tfb_flags = TCP_FUNC_OUTPUT_CANDROP | TCP_FUNC_DEFAULT_OK, }; diff --git a/sys/netinet/tcp_subr.c b/sys/netinet/tcp_subr.c index 6dc8e0c1c46e..42d29d64e09f 100644 --- a/sys/netinet/tcp_subr.c +++ b/sys/netinet/tcp_subr.c @@ -359,6 +359,7 @@ static struct tcp_function_block tcp_def_funcblk = { .tfb_tcp_fb_init = tcp_default_fb_init, .tfb_tcp_fb_fini = tcp_default_fb_fini, .tfb_switch_failed = tcp_default_switch_failed, + .tfb_flags = TCP_FUNC_DEFAULT_OK, }; static int tcp_fb_cnt = 0; @@ -676,6 +677,10 @@ sysctl_net_inet_default_tcp_functions(SYSCTL_HANDLER_ARGS) error = ENOENT; goto done; } + if ((blk->tfb_flags & TCP_FUNC_DEFAULT_OK) == 0) { + error = EINVAL; + goto done; + } V_tcp_func_set_ptr = blk; done: rw_wunlock(&tcp_function_lock); diff --git a/sys/netinet/tcp_var.h b/sys/netinet/tcp_var.h index 099fb32ee613..52fd0f181e01 100644 --- a/sys/netinet/tcp_var.h +++ b/sys/netinet/tcp_var.h @@ -540,6 +540,7 @@ typedef enum { /* Flags for tcp functions */ #define TCP_FUNC_BEING_REMOVED 0x01 /* Can no longer be referenced */ #define TCP_FUNC_OUTPUT_CANDROP 0x02 /* tfb_tcp_output may ask tcp_drop */ +#define TCP_FUNC_DEFAULT_OK 0x04 /* Can be used as default */ /** * tfb_tcp_handoff_ok is a mandatory function allowing