Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp1460807rdb; Wed, 6 Dec 2023 22:26:01 -0800 (PST) X-Google-Smtp-Source: AGHT+IEGsNTambqE9uaqkBsvigt37p8oSJJx1O0BVRINg+/beFgF22OYP+JZNrYQQ39d/XDfDru2 X-Received: by 2002:a17:90b:4b4d:b0:286:6a6c:25e6 with SMTP id mi13-20020a17090b4b4d00b002866a6c25e6mr1554879pjb.39.1701930361029; Wed, 06 Dec 2023 22:26:01 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701930361; cv=none; d=google.com; s=arc-20160816; b=Ra+fa9iUCgyLG10yd8IVhxMjH1WR8kWNvORMsJfi0pcoc+5p8GU0gr1dzx8vT26+i7 Je4zpDzKGN4LAdbXwMFJ8xafMK9AnTU4yw5typTEICLGSTUE2o//utNvFZ4ExZsP9BWC SF/7mjPX0iBZak+ktgpKLrtKjvNIKYdqn85spoDatHqFGJws5J0CbpPqo6+i/kdqRx/N +/Y4lcWa9PzgYY6YACgKkCsUa2zqugCfK1G8PI6es/SE0HASO1eTIRWfE1fG7zKnRTE+ iEgT6mW13wASdK5oa9qe10x+ojec2Sf6fo0T8DxDR2yPVxy5K3Wp9sYXDofhfbniHsuN 3KLg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=oErw/cP3v6K5Ya8MvRoT24q1uLCEk2UvmxpABeanB3I=; fh=2wNBg9HW42gPL8RmU74Zrr0644/xhzuMmt0my449IPI=; b=tJOj0GG0C8y15CtEFxGUr9/5qq8Dstmc3g0uERsglc1i5MCSt/YZuPgZfxAUPyRWb7 zlmo+Ku2KkwkqISGU84P1kS1YOOaU4ApgL4+0LCh8sUGWKJ2Z9gG7VlGEzuI0Z+JXSC7 GqF9Sy6GXLpB3+CpEzQ2JDYwvOVGzg6t9qKeMzi+LAePy5M2zupVsXaDPfkw6P1RlI7+ oqpWB0/Oh0xjHcPwjBNLZD3/h7IZA9OOj96+BqN1PxTHUSaAIJUv7eegkMyk5LINIvjt JdYpHhbz/BHtIzscKyyFTT0NPrQgzBrtAmsBnxU5X9Gv+yj/u0+fo83QSSSJzASnDujy oHYg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20210309 header.b=b7qtNXQA; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from snail.vger.email (snail.vger.email. [23.128.96.37]) by mx.google.com with ESMTPS id k92-20020a17090a3ee500b0028874227b74si537092pjc.100.2023.12.06.22.26.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 06 Dec 2023 22:26:01 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) client-ip=23.128.96.37; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20210309 header.b=b7qtNXQA; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id 2131A80DF26F; Wed, 6 Dec 2023 22:26:00 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231130AbjLGGZu (ORCPT + 99 others); Thu, 7 Dec 2023 01:25:50 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47422 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229454AbjLGGZs (ORCPT ); Thu, 7 Dec 2023 01:25:48 -0500 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 99545D4B; Wed, 6 Dec 2023 22:25:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=oErw/cP3v6K5Ya8MvRoT24q1uLCEk2UvmxpABeanB3I=; b=b7qtNXQAzmhYhQLy1jF6GCwRCH QjW3MqinvyJQYA6bgI1bw6zpavs66kYaLy1RrSXUUGZWbRZFOWm57k0vGU1uMa8W1V5TwQHsvoLlz 8V2tlia9l/FQn58wQKDf6RmDPdmv6Aod5UAAnluBwN50VmzWBeZlqcvt8JW5dn7T4Ir4N4ZT+eAjC YqwIg3arRxfy+SN26sSTMoKO0XvyvfUdnmTNUOT9/VPuUvMl2558RWSer1HMtNSnONbwZuoVR6Rfv EVBM5vCbrAZojOfmzLZKUYL4y729A4j1WAFr03gocNmYnmeYz15rkDam7nFKFNLefbjO0lWMgrhIF zsmoRM9w==; Received: from hch by bombadil.infradead.org with local (Exim 4.96 #2 (Red Hat Linux)) id 1rB7pW-00Byao-2U; Thu, 07 Dec 2023 06:25:50 +0000 Date: Wed, 6 Dec 2023 22:25:50 -0800 From: Christoph Hellwig To: Nick Desaulniers Cc: Andrew Morton , tanzirh@google.com, Kees Cook , Andy Shevchenko , linux-hardening@vger.kernel.org, linux-kernel@vger.kernel.org, Nick DeSaulniers , llvm@lists.linux.dev Subject: Re: [PATCH] lib/string: shrink lib/string.i via IWYU Message-ID: References: <20231205-libstringheader-v1-1-7f9c573053a7@gmail.com> <20231205130449.8e330a26ecbed1f7b5ad5d7a@linux-foundation.org> <20231205132452.418722bea8f6878dca88142a@linux-foundation.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Wed, 06 Dec 2023 22:26:00 -0800 (PST) On Tue, Dec 05, 2023 at 01:39:47PM -0800, Nick Desaulniers wrote: > Hmm...how does one know that linux/bits.h is the higher-level include > of asm/bitsperlong.h? I think this the wrong way of thinking. In general we should always avoid including asm/ headers unless there is no other way. No other way is not formalized right now, but I think the answer is roughly if no linux/ headers includes that asm header. This will probably give a few wrong results at the moment, but it's probably worth fixing them up.