Received: by 2002:a05:6a10:16a7:0:0:0:0 with SMTP id gp39csp2003776pxb; Sat, 14 Nov 2020 09:31:40 -0800 (PST) X-Google-Smtp-Source: ABdhPJwXgFYRPHViTfGo0BDZAelldP96Noc1Yo81//R9shIlWWMaAoqQEc9nwG+axP3jXojViTP9 X-Received: by 2002:a17:906:57cc:: with SMTP id u12mr7608993ejr.163.1605375100799; Sat, 14 Nov 2020 09:31:40 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1605375100; cv=none; d=google.com; s=arc-20160816; b=MNBY7kpfqga//jatzOiBsdHvmI06fk1NFi1QCZYEIyK66MN+S7Y2XHsBJ1+LLD0JRq IdhGePJBT4AfjUXu/KxiBZDL+NKB6CNsHpDzng9t7Qu6S5MLGcMV6rA3f4LFMrZqIn2c vt8r6c9QwhVm5kzeI/OwV8h9acbxEEjArXdtrYWK7i9yXJ7nhDN3ywzzTswCPyUgq0Hy r9mkFRd2bdBGr79esXrX0K+P5ELjS4hzCIjoyRvOii3jKYTOb3ZL1HzxA2hh2i3X86IC AsIFUMdKiTW89TuJIHoRWhMzSmSwmQDBEPXtytDiwxw3co2sjwqsa7g0JhC1MqtL2s86 WCaw== 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=nFIjmU3PyYTtN+/KPAaiBpQ9mhotPT9InWONOcxLEKw=; b=VcVQHHVFxeJz9VHgjdJDe1MowetrTkIRjp+yxyG7Zh4F+i988aTiHsxFgwta/XhXSI J7p/pSmDTXGyy5VkH2yfGj0cE35koD46lmj8I6XxWZLBU7HcVOM8/Bl7KqGPk1RFBXWw hwLrMphZC5uRBQgzEkp9sXCqOBsH9GJvAxkC52oXadO+rza3ffgEOceCxBLmMlGl1BIl n+t4GzlDnHTLWr34Bb2sNP581/6caQ2DNcUAenWHsq6OhxFzpIvCyO4NxtWZbsKwa/2l gTqJj0GLAX+YSaJpUmqRWkigsCJUaxKxBlJlfaqo3+NtCKTgoYJEN3iNV9MAoxgD4gkV 3IhQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=merlin.20170209 header.b=VP6O6FTL; 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 gb9si7909353ejc.725.2020.11.14.09.31.17; Sat, 14 Nov 2020 09:31:40 -0800 (PST) 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=@infradead.org header.s=merlin.20170209 header.b=VP6O6FTL; 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 S1726251AbgKNR11 (ORCPT + 99 others); Sat, 14 Nov 2020 12:27:27 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54874 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726070AbgKNR10 (ORCPT ); Sat, 14 Nov 2020 12:27:26 -0500 Received: from merlin.infradead.org (merlin.infradead.org [IPv6:2001:8b0:10b:1231::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 739A4C0613D1; Sat, 14 Nov 2020 09:27:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=merlin.20170209; h=Content-Transfer-Encoding:Content-Type: In-Reply-To:MIME-Version:Date:Message-ID:From:References:Cc:To:Subject:Sender :Reply-To:Content-ID:Content-Description; bh=nFIjmU3PyYTtN+/KPAaiBpQ9mhotPT9InWONOcxLEKw=; b=VP6O6FTLaPgIzlW2qwuSOXOyzW Kolh+nSrb8DTpSIiSxLmzjsPU3KGkOCYELDJBlIBZHa7zSwz3Oyu5Ku2oDCjNOucmmYnEjMoN6fe/ aPDqJyQs+QbhNchsftgaET7gT43vvPiV7iv/+CE4bWdndy5XCMhLtTe6SYUO8tOEbgeN0h6YMlgvT 4faDo3sLezINoU/WmkX5iX2VcmP/mHpyZpgYzv8yEjVBemVItqcMnQIDrU0q/jFk3MhJ6dbWBslV7 3LRH/AV/7IJM27h7IqM5UwczPd1T4+DTgLUxTlJ2hR2fS6QFXJ67ONDYAWqAqCJwBJLlPUgwM5s1a wcvG93Iw==; Received: from [2601:1c0:6280:3f0::f32] by merlin.infradead.org with esmtpsa (Exim 4.92.3 #3 (Red Hat Linux)) id 1kdzKb-0006hj-7C; Sat, 14 Nov 2020 17:27:21 +0000 Subject: Re: [PATCH net-next] net: linux/skbuff.h: combine NET + KCOV handling To: Matthieu Baerts , linux-kernel@vger.kernel.org Cc: kernel test robot , Aleksandr Nogikh , Willem de Bruijn , Jakub Kicinski , linux-next@vger.kernel.org, netdev@vger.kernel.org References: <20201114011110.21906-1-rdunlap@infradead.org> <52502fe4-8f41-0630-5b9c-be2e07b6932c@tessares.net> From: Randy Dunlap Message-ID: <8198558c-55f0-0ea3-3a23-e3dafb2cb09d@infradead.org> Date: Sat, 14 Nov 2020 09:27:16 -0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.12.0 MIME-Version: 1.0 In-Reply-To: <52502fe4-8f41-0630-5b9c-be2e07b6932c@tessares.net> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 11/14/20 12:01 AM, Matthieu Baerts wrote: > Hi Randy, > > On 14/11/2020 02:11, Randy Dunlap wrote: >> The previous Kconfig patch led to some other build errors as >> reported by the 0day bot and my own overnight build testing. > > Thank you for looking at that! > > I had the same issue and I was going to propose a similar fix with one small difference, please see below. > >> --- linux-next-20201113.orig/include/linux/skbuff.h >> +++ linux-next-20201113/include/linux/skbuff.h >> @@ -4608,7 +4608,7 @@ static inline void skb_reset_redirect(st >>   #endif >>   } >>   -#ifdef CONFIG_KCOV >> +#if IS_ENABLED(CONFIG_KCOV) && IS_ENABLED(CONFIG_NET) >>   static inline void skb_set_kcov_handle(struct sk_buff *skb, > Should we have here CONFIG_SKB_EXTENSIONS instead of CONFIG_NET? > > It is valid to use NET thanks to your commit 85ce50d337d1 ("net: kcov: don't select SKB_EXTENSIONS when there is no NET") that links SKB_EXTENSIONS with NET for KCOV but it looks strange to me to use a "non direct" dependence :) > I mean: here below, skb_ext_add() and skb_ext_find() are called but they are defined only if SKB_EXTENSIONS is enabled, not only NET. > > But as I said, this patch fixes the issue. It's fine for me if we prefer to use CONFIG_NET. I think it would be safer to use CONFIG_SKB_EXTENSIONS. >> @@ -4636,7 +4636,7 @@ static inline u64 skb_get_kcov_handle(st >>   static inline void skb_set_kcov_handle(struct sk_buff *skb, >>                          const u64 kcov_handle) { } >>   static inline u64 skb_get_kcov_handle(struct sk_buff *skb) { return 0; } >> -#endif /* CONFIG_KCOV */ >> +#endif /* CONFIG_KCOV &&  CONFIG_NET */ > > (Small detail if you post a v2: there is an extra space between "&&" and "CONFIG_NET") Oops. Fixed in v2. Thanks for looking. v2 on the way. -- ~Randy