Received: by 2002:a05:6a10:16a7:0:0:0:0 with SMTP id gp39csp1935454pxb; Sat, 14 Nov 2020 07:16:05 -0800 (PST) X-Google-Smtp-Source: ABdhPJy/fIKHzsrjhGDk08wN6EOmdP230K9QQahrJ5qB6YLDWUUxtmf+PqoivXK2yLotCwmFhs6i X-Received: by 2002:a17:906:280a:: with SMTP id r10mr6944230ejc.58.1605366965052; Sat, 14 Nov 2020 07:16:05 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1605366965; cv=none; d=google.com; s=arc-20160816; b=xUjEaRXeH5Z16xtVqCtqjErdC+gP0sMje0p6pp/opif3Q+8FDXRnwRaYWWi39LWnQJ g3B5Grf9djU29FpxEuqIgGFed2mXdkiq01bysIKpe25vY5Jz5czvwuLjVNQab3Dkkb1P OH1zm/UwgURHgnYLw8kexStqOcjYbzVWdLENi4RKHY628oiwV6AZRMTyu+McdX8Tozh5 qux7/lI1tB0LePEJE0hi1xaGrSyt/f3N/ucpXnRiYaHnaL+1oDYJnzImbvaRmlHwHasr 5m+7VKbUK34p/G1V8WScVq9pa8M2CuTiL2rsE77HLCWixgrj9D+gv9gugm7moimD0Chx y6gw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=qmAMP16i07tpeovQ+3O4vWE0SUyj6XLgAHu8H2A/50k=; b=nMibml4bgAPxbd40yGZxYWXZ5gDz7o31ocYoSuiG+A1P6zGuhI1MkzpYNLNK1fF8Y8 5c99NRFYGKorTPMUtJY8tl8SlAp3y3QZczO2JHzwKavDoZClbP3P9MbuiaiYYRgOf46s Y9neao8bg369SYxZXU5Skizp/EVHUFS3yBl90T50gopvUEtfEUo9shrwlv0XQIeaAv3p BgIRUcAbOhRtWVj5JEeyLrqlnuq8tub4hKG4neo+jf0bOvVPI9MHgznar8xhe/sGdiuY 1xgpuApgaRoPhkrBsGfowmLMGG9kMOkS2T62TCWa9mXTx3c0CM3q+ZqNPAkR97TzcjLJ CrUw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=WCGQ00On; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id v7si8493536edq.305.2020.11.14.07.15.41; Sat, 14 Nov 2020 07:16:05 -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=@gmail.com header.s=20161025 header.b=WCGQ00On; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726917AbgKNPOR (ORCPT + 99 others); Sat, 14 Nov 2020 10:14:17 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34622 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726495AbgKNPOP (ORCPT ); Sat, 14 Nov 2020 10:14:15 -0500 Received: from mail-pl1-x644.google.com (mail-pl1-x644.google.com [IPv6:2607:f8b0:4864:20::644]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 123BAC0613D1; Sat, 14 Nov 2020 07:14:15 -0800 (PST) Received: by mail-pl1-x644.google.com with SMTP id d17so4402527plr.5; Sat, 14 Nov 2020 07:14:14 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=qmAMP16i07tpeovQ+3O4vWE0SUyj6XLgAHu8H2A/50k=; b=WCGQ00OnR7FbKKyFM2kuqPgRD0BxvtC5FoFZLujcvlcMVtVUqkhC6KPH1FcK7RyVkw funKZTRHwDqWmmxkpDPGl3fXzO12FeMbEqq/7k8s3DqReZQpUnhxCV40McJZuVaq30Xu FjX5ywCwOsTR4XcklZ0Zvd6N4mAo9SnNaaF7+D0NrhrWVxQDZyBsTbd/NVeHQ6ayocg4 NqonoQQuQ2Nf7DyHEr+aD9+2RNfLBkz2LLf4ACXTqObiYakbn3Cu7m1Ir9AG1HhlFiYp EFdgvdXyL9J3oTj+kOisAZok3iZNmbjbBej5TeVEwZ2saGsTHUEOfnveucYApjX6vMwD dFlA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=qmAMP16i07tpeovQ+3O4vWE0SUyj6XLgAHu8H2A/50k=; b=YU76zl9hWUkXV1jxTuzF8r3Lx1fq6uOi88HaVZ/yi2/1IZ25+EGiwe7Z+24HKy3GqL USESbJRr0QBOaPk8BYC3M+KREvM+/j76gr3fLGGkku/AxOxhU5jh5HTwKuie8mF4xkKp d0YA56CLY1D+nuWw7c6uJPzDg9nXZiMrEnX2UQGz6vavy5OHJkQ8G+Xhw7bpgFTdrI9u Uycz3KNo6niSqnOAXHXMPSQA0Nzj4E0kw9c5yRK0UOjonpq/lpGzwKVXxdmJUfARmGa0 GFRVtWZzuemK5Zfuz9i+5XY6m4MayM1XYVzPkhKu7dIpL1VKd4QAoP1zbWYHgquZJiB+ J/Bw== X-Gm-Message-State: AOAM532pcqLj2K9cRfTXR0RvqQ0QQlOru9nJMNkWIumd/KfMKsMWIXHO yO1GN6s+G9VrWQFp3yHgiSk= X-Received: by 2002:a17:90b:2343:: with SMTP id ms3mr8061968pjb.130.1605366854549; Sat, 14 Nov 2020 07:14:14 -0800 (PST) Received: from hoboy.vegasvil.org (c-73-241-114-122.hsd1.ca.comcast.net. [73.241.114.122]) by smtp.gmail.com with ESMTPSA id y124sm12796375pfy.28.2020.11.14.07.14.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 14 Nov 2020 07:14:13 -0800 (PST) Date: Sat, 14 Nov 2020 07:14:10 -0800 From: Richard Cochran To: Arnd Bergmann Cc: =?utf-8?B?546L5pOO?= , Jakub Kicinski , Grygorii Strashko , "David S. Miller" , Samuel Zou , Kurt Kanzenbach , Ivan Khoronzhuk , Networking , "linux-kernel@vger.kernel.org" Subject: Re: Re: [PATCH V4 net-bugfixs] net/ethernet: Update ret when ptp_clock is ERROR Message-ID: <20201114151410.GA24250@hoboy.vegasvil.org> References: <20201111080027.7830f756@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com> <20201112181954.GD21010@hoboy.vegasvil.org> <20201112232735.GA26605@hoboy.vegasvil.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Nov 13, 2020 at 05:21:43PM +0100, Arnd Bergmann wrote: > I've prototyped a patch that I think makes this more sensible > again: https://pastebin.com/AQ5nWS9e I like the behavior described in the text. Instead of this ... - if a built-in driver calls PTP interface functions but fails to select HAVE_PTP_1588_CLOCK or depend on PTP_1588_CLOCK, and PTP support is a loadable module, we get a link error instead of having an unusable clock. how about simply deleting the #else clause of --- a/include/linux/ptp_clock_kernel.h +++ b/include/linux/ptp_clock_kernel.h @@ -173,7 +173,7 @@ struct ptp_clock_event { }; }; -#if IS_REACHABLE(CONFIG_PTP_1588_CLOCK) +#if IS_ENABLED(CONFIG_PTP_1588_CLOCK) so that invalid configurations throw a compile time error instead? Thanks, Richard