Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp3089577rwd; Mon, 22 May 2023 08:30:22 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4+q+0zQSKJKWh5/r1O0+C1l3ZUw9ZufdA0IvOcfh9rzN3XTOssti+IaxYKvgYwPlo2J4B0 X-Received: by 2002:a05:6a00:98c:b0:646:59e4:94eb with SMTP id u12-20020a056a00098c00b0064659e494ebmr15357428pfg.15.1684769421866; Mon, 22 May 2023 08:30:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684769421; cv=none; d=google.com; s=arc-20160816; b=xna2HDb9KxRwGPlky71v0BvShJhEs07WMb76qEEvJeZRitzcBcTGjilNDMWPwa4z8z rNfPlvCAM8gwf12bsq+fhfkg/+3a70xRguFOmSBLWHqvN580W/HqWeZy2jv7PF6GuLeT Ybi8+PPZjPyDIWGPGcHL7z7DsT0zfAOGndAK+ZK5FOhJlsDDkXJQrfvxW8rJPwt1xZyj 8l/gsEbG1EOSCUWOtGZgJNkADY/5KS3YHqwCabuUUDBwEqcM3jvqJxwDZN7D8Nij2e5S wQSsPCyylklsUT3ZxkpEcojIe2Ur39jo4yiejhhQV1OllMWCHFnnolT9HoGIhHJt+YTo tApw== 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; bh=HBk03lmBCIdlxcADrwvs2+NsFidnjlUvO0YEfHTYJmo=; b=mDt8aEO8I7BRtbt0FImfCLbaHLcv4tYy3oMP9GUgMb04tUgs9T0Z7AbOrXK9i+q51x c6MGzznN4LiEPA9nDLhhVUL8Jel9m6Kk21jDigHdaxYMRwCyEw4ZrgsHZh+c02JHVZp4 WiSTLHANsaCH2sTS6WL+oA00tOBZIimUcpQfjkbovQTlVUt6JguW6XSjxZXO+tfVZaaY 6L0e5bgIPwnma/G4tOVc8bOSBQi0MXGEAQV5wHLOQcH1sauZkBCzjCZJIdoGY/o/fQB1 ZE0ryHUUD5CTjlr5/cCuBWJe/BHC4VovTWZpmALfYVB+twL+Lchfxx0B79BO12dz04/O kG9Q== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id i9-20020aa796e9000000b0063b1739532esi4964166pfq.139.2023.05.22.08.30.08; Mon, 22 May 2023 08:30:21 -0700 (PDT) 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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234184AbjEVPWi (ORCPT + 99 others); Mon, 22 May 2023 11:22:38 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57302 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234114AbjEVPWh (ORCPT ); Mon, 22 May 2023 11:22:37 -0400 Received: from smtp.missinglinkelectronics.com (smtp.missinglinkelectronics.com [162.55.135.183]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0B85E139; Mon, 22 May 2023 08:22:28 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by smtp.missinglinkelectronics.com (Postfix) with ESMTP id 778D920619; Mon, 22 May 2023 17:22:27 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at missinglinkelectronics.com Received: from smtp.missinglinkelectronics.com ([127.0.0.1]) by localhost (mail.missinglinkelectronics.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 8pDyng2re-HT; Mon, 22 May 2023 17:22:27 +0200 (CEST) Received: from nucnuc.mle (p578c5bfe.dip0.t-ipconnect.de [87.140.91.254]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: david) by smtp.missinglinkelectronics.com (Postfix) with ESMTPSA id EBF67202D0; Mon, 22 May 2023 17:22:26 +0200 (CEST) Date: Mon, 22 May 2023 17:22:21 +0200 From: David Epping To: Vladimir Oltean Cc: Andrew Lunn , Heiner Kallweit , Russell King , "David S . Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, UNGLinuxDriver@microchip.com Subject: Re: [PATCH net 3/3] net: phy: mscc: enable VSC8501/2 RGMII RX clock Message-ID: <20230522152221.GA21090@nucnuc.mle> References: <20230520160603.32458-1-david.epping@missinglinkelectronics.com> <20230520160603.32458-4-david.epping@missinglinkelectronics.com> <20230521134356.ar3itavhdypnvasc@skbuf> <20230521161650.GC2208@nucnuc.mle> <20230522095833.otk2nv24plmvarpt@skbuf> <20230522140057.GB18381@nucnuc.mle> <20230522151104.clf3lmsqdndihsvo@skbuf> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230522151104.clf3lmsqdndihsvo@skbuf> User-Agent: Mutt/1.9.4 (2018-02-28) X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_PASS, SPF_PASS,T_SCC_BODY_TEXT_LINE 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 Mon, May 22, 2023 at 06:11:04PM +0300, Vladimir Oltean wrote: > On Mon, May 22, 2023 at 04:00:57PM +0200, David Epping wrote: > > Since the clock enablement now happens in all modes the existing rgmii > > function name seems misleading to me. > > To be fair, it's only as misleading as the datasheet name for the register > that holds this field, "RGMII CONTROL". Anyway, the function could be > renamed as necessary to be less confusing: vsc85xx_update_rgmii_ctrl() > or something along those lines. > > MDIO reads and writes are not exactly the quickest I/O in the world, and > having 2 read-modify-write consecutive accesses to the same paged > register (which in turn implies indirect access) just because readability > seems like the type of thing that can play its part in deteriorating > boot time latency. Maybe we can deal with the readability some other way. You are right. It's an easy job for the CPU and saves time for hardware access. I'll prepare and send a new patch set. > > Also we don't want to enable for > > all PHY types, and the differentiation is already available at the > > caller. I would thus opt for a separate function and fewer conditional > > statements. > > I don't understand this. We don't? For what PHY types don't we want to > enable the RX_CLK? I meant all PHYs using vsc85xx_rgmii_set_skews() via vsc8584_config_init(). As you pointed out they don't have a clear definition of what bit 11 means for them. But we can easily differentiate using the condition you suggested. I'll do that for the new patch version.