Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp709049pxb; Fri, 15 Oct 2021 14:32:16 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzUGbr13maEHa+4bKtmaCt0zqShPECqkJGUCpbyq5StKaFfRY2lzMHPwMi5PaVsfYO5qWcZ X-Received: by 2002:a17:903:1103:b0:13e:ec6d:524a with SMTP id n3-20020a170903110300b0013eec6d524amr12890457plh.85.1634333536415; Fri, 15 Oct 2021 14:32:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1634333536; cv=none; d=google.com; s=arc-20160816; b=t1VlXLcc5ifen8OVlGyWTWhWO73Y8W6DIeMb5K0ZjtnnQ4u4mwmqZfTYBbJZNjm1FL WJql+ubqxz30QU6rpesJ0w78IyVR4xE7NfFrAUgzbcTkCTNGwBN+mQHPnsPE8LvBUsAg e6fYc/DrBSZ8ALi9iZ82YKmJPz7H8liiz9DPJyFMw0KQI4AEVbkP1xmwGwZ9j0Vnjnue tFbWo/hTc/q+J5/EURaObdogQurQ9Pfw0jbkP0NE+llVxXgjZMiHu7LTK9CBVqc+hv4g L9ghuFa6SvFjsly+KCk/VrJZnPKtbUafHWZSngTLX5KQ5cJx3P2dHl0f7VyAP/jY551f QNyw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature; bh=kb1x9tsGXaYeNovFWGdEXry3yHSkE+lL9wmnxYr/M0g=; b=mGjPvZpyAojNmt1iBDjeBZUFd0I3nqg6yDi/e2Jk5gsgqsk0ZhvD62mxcxg7cBDyqv iaVKFYJARW7KCXbvKOrAmd+kSKQ5VKeMA83v7UHLmd4jbB7tgcneFrVhSBvJKM+Sm/xx caE63L2OfYJ+JGdnXwhDHc5iWRMLcluD/6R9CA64tsG5sxZX1+GyR8I2GpLLYEjEr6Nf YgbfysAFYxTKffB/Q3NVxHDUj+MpgrAXwk0/oNW/RBCohZ4unit+ROkG6XXYzTYzr/X3 hxjbihwQcZ8q950cmILYURwyTguYSLVPNwAbVneiUG5Xb9O+PHhxZz4fNdDh8nYF8C+k DTOA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@rasmusvillemoes.dk header.s=google header.b=Bq4tlA+u; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id m125si1943555pfb.54.2021.10.15.14.32.00; Fri, 15 Oct 2021 14:32:16 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@rasmusvillemoes.dk header.s=google header.b=Bq4tlA+u; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238530AbhJOLsT (ORCPT + 99 others); Fri, 15 Oct 2021 07:48:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45672 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235360AbhJOLsM (ORCPT ); Fri, 15 Oct 2021 07:48:12 -0400 Received: from mail-lf1-x12a.google.com (mail-lf1-x12a.google.com [IPv6:2a00:1450:4864:20::12a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9A967C061570 for ; Fri, 15 Oct 2021 04:46:05 -0700 (PDT) Received: by mail-lf1-x12a.google.com with SMTP id y15so40560350lfk.7 for ; Fri, 15 Oct 2021 04:46:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rasmusvillemoes.dk; s=google; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=kb1x9tsGXaYeNovFWGdEXry3yHSkE+lL9wmnxYr/M0g=; b=Bq4tlA+uaiVDOAMaQlhWb6N1uJGXs0377YAXJi+mSLJBdZP7u2gejSataJoCZ8f4pc MnZSVOVGrtxx0rudmcxPom5LsH6e49Ev6XAs2VB50w1QVnr9gmraFdv3o5d7k39Qw08K 6htYVsZR65vgZJtlMn2TwQ9VpI2v2zKOxmL8I= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=kb1x9tsGXaYeNovFWGdEXry3yHSkE+lL9wmnxYr/M0g=; b=Vk7G3p8pee3o6QEx0PgaPImgT+X4wXtzSbwvdpgarOsbBuoQks+0kUlb0ZG5IfwWIm maPeVVq8parf1Pw8nr6p6KbN+iG5iLn0hm7lGS8FDBkdZXyxuJOLO4vNP8WQVwL/4QMN URuPY1qbeREC+25vaQbAXyl4nEKlxH5YMh/nwtRr7CB0DPsaYJ93nSIXzEDPsW1+g/87 epLzQfyDIakIuqHengNkyayvfZoxW9TdHN2qAzaCpX/kmTydL9Ize4qa4mIvowQPjhKK HrQfLQG50jbJdaJEQvhTAUaKnIniA5F82MWrhbFDf9GdVENSFuOyzveJfwQU4TEcaJMP Nz+w== X-Gm-Message-State: AOAM532S0jsxAPklktGPZk9ksp3kxeTmEQDijP4s75moGrqHCrUyZjAZ nagkblqq0n8xXVhtEbn3p4NHR8mUmbhJ88+F X-Received: by 2002:a05:6512:118a:: with SMTP id g10mr11924978lfr.662.1634298363790; Fri, 15 Oct 2021 04:46:03 -0700 (PDT) Received: from [172.16.11.1] ([81.216.59.226]) by smtp.gmail.com with ESMTPSA id s17sm526594lfe.10.2021.10.15.04.46.02 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 15 Oct 2021 04:46:03 -0700 (PDT) Subject: Re: [PATCH] linux/container_of.h: switch to static_assert To: Andy Shevchenko Cc: akpm@linux-foundation.org, Miguel Ojeda , Nick Desaulniers , linux-kernel@vger.kernel.org References: <20211015090530.2774079-1-linux@rasmusvillemoes.dk> From: Rasmus Villemoes Message-ID: <63cb6259-ea8e-46a8-63fc-d942c2225fcc@rasmusvillemoes.dk> Date: Fri, 15 Oct 2021 13:46:01 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.13.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 15/10/2021 15.13, Andy Shevchenko wrote: > Btw, shouldn't we also remove build_bug.h in the container_of.h with this? > (Or if this goes first, do we still need bug.h?) > We absolutely need build_bug.h, as that is where static_assert is defined. container_of.h doesn't include bug.h AFAICT, nor should it need to. (We should still find a quiet place for __same_type and have container_of include that header, but that's unrelated to this patch.) Rasmus