From nobody Tue Nov 28 08:44:32 2023 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4SfbcG4yB0z52R02; Tue, 28 Nov 2023 08:44:46 +0000 (UTC) (envelope-from manu@bidouilliste.com) Received: from mx.blih.net (mx.blih.net [212.83.155.74]) (using TLSv1.3 with cipher TLS_AES_256_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 4SfbcF5htSz3LgD; Tue, 28 Nov 2023 08:44:45 +0000 (UTC) (envelope-from manu@bidouilliste.com) Authentication-Results: mx1.freebsd.org; none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bidouilliste.com; s=mx; t=1701161077; 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=vlBLd3giNfGVRzZEiGXZ3iw/XsHK/+hbYIgoTIT6OKU=; b=pqbouY1a5zyyCQ8pFyVs3NPSGNF8jkzIEpbT+jnIRuwyr6Szt9JwuZ2OrMceeDSMn6KS4j tKzMgEPKJqK/5H9ZPGUg+FO8JwUwGe9VjwbgtWZRBQ/+ICZ7SWb/kHTQjyU0ucz6zdR92u BKcn4QP/JUOKYQtfCCjlR8ZqolER1E8= Received: from skull.home.blih.net (lfbn-lyo-1-2174-135.w90-66.abo.wanadoo.fr [90.66.97.135]) by mx.blih.net (OpenSMTPD) with ESMTPSA id d6353377 (TLSv1.3:TLS_AES_256_GCM_SHA384:256:NO); Tue, 28 Nov 2023 08:44:37 +0000 (UTC) Date: Tue, 28 Nov 2023 09:44:32 +0100 From: Emmanuel Vadot To: Gleb Smirnoff Cc: John Baldwin , Emmanuel Vadot , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Subject: Re: git: 2a35f3cdf63d - main - sys/mutex.h: Include sys/lock.h instead of sys/_lock.h Message-Id: <20231128094432.decd3248611d3f1bf231dd23@bidouilliste.com> In-Reply-To: References: <202311240950.3AO9oSeH089169@gitrepo.freebsd.org> <79e6e3a1-96a5-4d3e-9c48-a89bcbd6303d@FreeBSD.org> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.33; amd64-portbld-freebsd15.0) List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit 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:12876, ipnet:212.83.128.0/19, country:FR] X-Rspamd-Queue-Id: 4SfbcF5htSz3LgD On Mon, 27 Nov 2023 11:51:03 -0800 Gleb Smirnoff wrote: > On Fri, Nov 24, 2023 at 09:27:39AM -0800, John Baldwin wrote: > J> > commit 2a35f3cdf63d1f9b1ea5ab0174adabb631757210 > J> > Author: Emmanuel Vadot > J> > AuthorDate: 2022-10-27 09:43:19 +0000 > J> > Commit: Emmanuel Vadot > J> > CommitDate: 2023-11-24 09:49:58 +0000 > J> > > J> > sys/mutex.h: Include sys/lock.h instead of sys/_lock.h > J> > It uses the LA_ defines when INVARIANTS is set. > J> > This unbreak dpaa2 with FDT only kernel (like ALLWINNER or ROCKCHIP) as > J> > the driver only include sys/lock.h via header polution for ACPI kernels. > J> > Sponsored by: Beckhoff Automation GmbH & Co. KG > J> > Differential Revision: https://reviews.freebsd.org/D37145 > J> > Reviewed by: kib, mjg > J> > J> Avoiding the nested include here was originally an intentional design decision. > J> It was supposed to be a compile error if you didn't include lock.h first, and > J> callers are always supposed to include both (up until now). However, I'm fine > J> with changing this, but we should be consistent and change all the other lock > J> headers at once including sys/rwlock.h, sys/sx.h, and sys/lockmgr.h. > J> > J> You will also need to patch all of these headers to remove the #error if > J> LOCK_DEBUG or LOCK_FILE isn't defined (including sys/mutex.h which you missed > J> in this commit). > J> > J> You will also need to update all the relevant manpages (mutex.9, sx.9, rwlock.9, > J> and lockmgr.9) to remove the #include . > J> > J> For MFC purposes I would suggest to also fix dpaa2 to #include > J> explicitly as it was supposed to do previously. > > I'd rather recommend to revert this commit and fix dpaa2 properly. This module has > a long history of incorrect include usage, which we were able to handle properly: > > d6eabdac2ef444b62aba186c793fbd5d4226b157 > 7fb975c8fb970b35fc34561ed30a0fe220346cb6 > b0484678d405722f40278e93cdebe95829c71f3b > > We should not modify system headers to satisfy dpaa2 or any other driver. > > -- > Gleb Smirnoff Yes I've just reverted those commits. This was an old review that I cleaned up and it's not even needed anymore (also as you said the fix wasn't correct). Cheers, -- Emmanuel Vadot