From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Miller Subject: Re: [PATCH net-next] net: core: Assert the size of netdev_featres_t Date: Sun, 29 Apr 2018 22:52:03 -0400 (EDT) Message-ID: <20180429.225203.723683450119100255.davem@davemloft.net> References: <20180427201114.28830-1-f.fainelli@gmail.com> Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: netdev@vger.kernel.org, edumazet@google.com To: f.fainelli@gmail.com Return-path: Received: from shards.monkeyblade.net ([184.105.139.130]:54680 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751343AbeD3CwF (ORCPT ); Sun, 29 Apr 2018 22:52:05 -0400 In-Reply-To: <20180427201114.28830-1-f.fainelli@gmail.com> Sender: netdev-owner@vger.kernel.org List-ID: From: Florian Fainelli Date: Fri, 27 Apr 2018 13:11:14 -0700 > We have about 53 netdev_features_t bits defined and counting, add a > build time check to catch when an u64 type will not be enough and we > will have to convert that to a bitmap. This is done in > register_netdevice() for convenience. > > Signed-off-by: Florian Fainelli Applied, but I don't know about putting that check as an inline function in a header file included by every networking foo.c file. It means that the inline function has to be parsed and (potentially) optimized by the compiler for every foo.c file that either directly or indirectly includes that header.