From nobody Fri Nov 24 17:27:39 2023 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4ScMPV2g3Qz51Lnh; Fri, 24 Nov 2023 17:27:42 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4ScMPV2C5lz4HSD; Fri, 24 Nov 2023 17:27:42 +0000 (UTC) (envelope-from jhb@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1700846862; h=from:from:reply-to:subject: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=LhkH4PTSu595nBFXLYXN3K35Btg3cLswbFkc5Jl1g4I=; b=dfYFkJbCmFipB75nR9pcG1KlO+Nvw5vvzA4G4QlwZCJ/laUk4+7i9NLX+l/9i8IO22kPoi Fk5L60TL7no0hdu21q8S5LERx+Px0ac+LPuBWUmLBg5yecyIeUoQt2ji3Tqtg3JIZcJL4F gbrdWh+gL+bU6UNnl0c9Pa2OOqBiLb/IelBOIBXuMva7DQLAnFHTR0PrwpxmFVk54WoePt wgY1GUSznCx+fXFXEbL5xlxE4vqi8B2WnlrF/WpCR9V4/Z7B7oiTV+WdeCBL26HYG2lnB9 h+KvFLicQKTBt4JxhVOgsO0bKIehCYjOOQwUuqxwVwd6Q4QbxfKneC3Esrmphg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1700846862; h=from:from:reply-to:subject: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=LhkH4PTSu595nBFXLYXN3K35Btg3cLswbFkc5Jl1g4I=; b=PymXkhDpzpnsAUrpwaTY0m1WgYSkZXUwEVQ4YvulTZR6G8OOa2a8XqB3R2DwKwiKTlVJAc 9IFz2AxEOp+3I+82VEVCksjN8kkqad5+smNY4GsD7mJq6uG4QUHOyosxD7Ss87wxzJPb8P NhGdHY4tj8vGlxY0tlVK6MgPyt8YRWPIs+hlhVZTE2Z5aLszZD7u/2opLUIsL14jVKM7tC d9NBKQZfY/C/CuWYPY4H+Uw0BKCgmb38+g9g97+Fm08xWOW144bpe8+waAog53Pffw3jG/ vmC/dQIO/PtswSNjmXHJgV3O1BEF1kpkTYvivr3hhyFcETzD7VNxhEM+7Zr9Fw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1700846862; a=rsa-sha256; cv=none; b=HYQRtxXzDtkosBmDLunnrjMIS1y9kr58kcht7DUmBimwk9BKIlxdrDez/KQJf/Qf77lYNG ecV5m3TAVBIL42Cqb3haisUctk1WjrU+YqaWmkFl/szp8fMllkjOyOsHdyn80MF1JMdD1C 7FK/2QFF1yid4BfWkpia9D+kV89BbWmy/MwcAHqcMCvvNrKgTA30Q4FE/8W4FpeId2B3LU l1roIvpNEvjxLaqeOLT0plNdYhovmxYQA8GjiFds5lOLgjCPKPUBYqgBkZrE8dKEYzmbHp Nxb5SAPKvHdfj3FtcQQin1XbPJfnFGKCoDVM9fmNpE1C9hrYGbAjHB5/h+b2bg== Received: from [IPV6:2601:648:8384:fd00:cd8e:ae25:64ed:d338] (unknown [IPv6:2601:648:8384:fd00:cd8e:ae25:64ed:d338]) (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 4ScMPT5GMtz49q; Fri, 24 Nov 2023 17:27:41 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Message-ID: <79e6e3a1-96a5-4d3e-9c48-a89bcbd6303d@FreeBSD.org> Date: Fri, 24 Nov 2023 09:27:39 -0800 List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: dev-commits-src-main@freebsd.org MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: git: 2a35f3cdf63d - main - sys/mutex.h: Include sys/lock.h instead of sys/_lock.h Content-Language: en-US To: Emmanuel Vadot , src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org References: <202311240950.3AO9oSeH089169@gitrepo.freebsd.org> From: John Baldwin In-Reply-To: <202311240950.3AO9oSeH089169@gitrepo.freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 11/24/23 1:50 AM, Emmanuel Vadot wrote: > The branch main has been updated by manu: > > URL: https://cgit.FreeBSD.org/src/commit/?id=2a35f3cdf63d1f9b1ea5ab0174adabb631757210 > > commit 2a35f3cdf63d1f9b1ea5ab0174adabb631757210 > Author: Emmanuel Vadot > AuthorDate: 2022-10-27 09:43:19 +0000 > Commit: Emmanuel Vadot > CommitDate: 2023-11-24 09:49:58 +0000 > > sys/mutex.h: Include sys/lock.h instead of sys/_lock.h > > It uses the LA_ defines when INVARIANTS is set. > This unbreak dpaa2 with FDT only kernel (like ALLWINNER or ROCKCHIP) as > the driver only include sys/lock.h via header polution for ACPI kernels. > > Sponsored by: Beckhoff Automation GmbH & Co. KG > Differential Revision: https://reviews.freebsd.org/D37145 > Reviewed by: kib, mjg Avoiding the nested include here was originally an intentional design decision. It was supposed to be a compile error if you didn't include lock.h first, and callers are always supposed to include both (up until now). However, I'm fine with changing this, but we should be consistent and change all the other lock headers at once including sys/rwlock.h, sys/sx.h, and sys/lockmgr.h. You will also need to patch all of these headers to remove the #error if LOCK_DEBUG or LOCK_FILE isn't defined (including sys/mutex.h which you missed in this commit). You will also need to update all the relevant manpages (mutex.9, sx.9, rwlock.9, and lockmgr.9) to remove the #include . For MFC purposes I would suggest to also fix dpaa2 to #include explicitly as it was supposed to do previously. -- John Baldwin