Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp29155rwb; Wed, 30 Nov 2022 21:26:12 -0800 (PST) X-Google-Smtp-Source: AA0mqf6Ke2MiXm00XFG3NgegY5ueGc70n28j7428QDfdlLCn6CSbcsB49RT8/nciJioxLrr9RU/g X-Received: by 2002:a17:906:164d:b0:7c0:b602:f9a1 with SMTP id n13-20020a170906164d00b007c0b602f9a1mr9961ejd.88.1669872372275; Wed, 30 Nov 2022 21:26:12 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669872372; cv=none; d=google.com; s=arc-20160816; b=LLzhAPDWVk9zxP+WTW7dl7JGd8hcq0vtQJtdD5bcz9BPGk/rvcwosQHCSH85mqXbvK uJkDmL4zbNxUXEO8RVf7yu1i91E3ASrxl8CtR+nfNCgtvcYS+mNU6VDuvgGW3qm2Fddq +sv/3pse40Rjg66Apc+J0Ap1bXwbiKOfz6EWBXaccEOUcV9X+miLENyN//SxiVwi6rqD G2Wc2xWFZVHEIH63jjTw6u9teFfX+4kNYYyMou56fcnJgn2/52izzcyLyCci4qeHQApU ktO0TotPqXUrpY+vYxjUi1rUn+9g+aN8j2a6N2r81PnvPWNri34E8p9Uz6GvYUoyAmz/ Nk1Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=t7XW16wx22FGkUBPDGEhVLyaMN5yPLVfYjJBfREPfiI=; b=ntkJ/8O2NYwVJAOpjv+WlgHq/fK+WsNwjNHQiXxESiYzHQLSoV7lU+JU4suL5/gFLx 4D1if6BlFr2NJrB+Yxz8j8AH5nVMqvspxWr3tPIvASo13cn7XCQYM5rNcS63TujLVL9Z YcVhC/lPW3raTburmLF6L4BZPOpaL2zr9xfoKvZCxhuvZ8d4oXxCn6mHYPUp9uxNt6Kf rvJMBCr0UFWby1aqGWyl9xc1jlx36/kxpgzzRcXCDwCA4bdA4MfKHjjwDSO+R4PQI5iu dQ0CUgeP8cIATGAl8/BqZqogO0prEiAmeU/04mScuQ9r8/h0+7i81aFtnMsfAw7w73jd kdEg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=gEI9ozPM; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id y22-20020aa7d516000000b00461237816efsi2684419edq.120.2022.11.30.21.25.52; Wed, 30 Nov 2022 21:26:12 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=gEI9ozPM; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229668AbiLAElQ (ORCPT + 83 others); Wed, 30 Nov 2022 23:41:16 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41874 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229513AbiLAElO (ORCPT ); Wed, 30 Nov 2022 23:41:14 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5FD96528A0; Wed, 30 Nov 2022 20:41:14 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id C6D6660F97; Thu, 1 Dec 2022 04:41:13 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id B1CF8C433D6; Thu, 1 Dec 2022 04:41:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1669869673; bh=e9HBJM9S7MI0S93i5urpVzAQ17BPPVCn42w9xMKJHbg=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=gEI9ozPM4ONciFPi4+0sPhRKjsaHBbqZJNW+g42j34oVV3r9LSu5CSOi2Hv0Gn11P 9HzN3A+3aF1ofTvrmmnAvwVQ8ZK4JLJ4HxHC2oHm3yooWWQOaBfTQtBSv1udDZT5hH 6uerdF4xkHJ01HJkoeyJz04Q3NakSNgb94wytxt9GCcRjIvPDWhfcpmTVrJsu3ALcM fU1Vt4nYmXfajfpGPV1zyNPN1vovU9pigeEpAfx2utHusFjMUBwJXsxAZx/AT//9w1 dwZw7QrOzpyxpJVru+J0Nfl9/ixZwU/MUJwsmlx0BWXJIqFrZc0iPNF9JM9bjvMiKi Gap238ofnvqwQ== Date: Wed, 30 Nov 2022 20:41:11 -0800 From: Jakub Kicinski To: "Arnd Bergmann" Cc: "Richard Cochran" , YueHaibing , "David S . Miller" , "Eric Dumazet" , "Paolo Abeni" , "Naresh Kamboju" , Netdev , linux-kernel@vger.kernel.org, "Greg Kroah-Hartman" , "Florian Fainelli" Subject: Re: [PATCH] net: broadcom: Add PTP_1588_CLOCK_OPTIONAL dependency for BCMGENET under ARCH_BCM2835 Message-ID: <20221130204111.2287b2c9@kernel.org> In-Reply-To: <10c264a3-019e-4473-9c20-9bb0c9af97c3@app.fastmail.com> References: <20221125115003.30308-1-yuehaibing@huawei.com> <20221128191828.169197be@kernel.org> <92671929-46fb-4ea8-9e98-1a01f8d6375e@app.fastmail.com> <10c264a3-019e-4473-9c20-9bb0c9af97c3@app.fastmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS 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 On Tue, 29 Nov 2022 12:58:23 +0100 Arnd Bergmann wrote: > > The original report was for a different bug that resulted in the > > BROADCOM_PHY driver not being selectable at all. > > > > The remaining problem here is this configuration: > > > > CONFIG_ARM=y > > CONFIG_BCM2835=y > > CONFIG_BCMGENET=y > > CONFIG_PTP_1588_CLOCK=m > > CONFIG_PTP_1588_CLOCK_OPTIONAL=m > > CONFIG_BROADCOM_PHY=m > > > > In this case, BCMGENET should 'select BROADCOM_PHY' to make the > > driver work correctly, but fails to do this because of the > > dependency. During early boot, this means it cannot access the > > PHY because that is in a loadable module, despite commit > > 99addbe31f55 ("net: broadcom: Select BROADCOM_PHY for BCMGENET") > > trying to ensure that it could. > > > > Note that many other ethernet drivers don't have this > > particular 'select' statement and just rely on the .config > > to contain a sensible set of drivers. In particular that > > is true when running 64-bit kernels on the same chip, > > which is now the normal configuration. > > > > The alternative to YueHaibing's fix would be to just revert > > 99addbe31f55 ("net: broadcom: Select BROADCOM_PHY for BCMGENET") > > and instead change the defconfig file to include the phy driver, > > as we do elsewhere. Ah, got it now, I think. Alternatively we could flip the 'select' to 'depends on' and make the user do the legwork? Enough brain cycles spend on this simple fix tho, so applying, thanks! :)