Received: by 2002:ad5:4acb:0:0:0:0:0 with SMTP id n11csp3850946imw; Thu, 7 Jul 2022 08:31:51 -0700 (PDT) X-Google-Smtp-Source: AGRyM1uRUT7bPrUYHVDR29lwCch7aK9gtRVkwHmCA8A4TuHFIyajlqnyXb1Aeyp41o0Iu72Us1mw X-Received: by 2002:a05:6402:34c8:b0:437:74d5:f8df with SMTP id w8-20020a05640234c800b0043774d5f8dfmr61980723edc.274.1657207911665; Thu, 07 Jul 2022 08:31:51 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1657207911; cv=pass; d=google.com; s=arc-20160816; b=DUSpzFshr4JDmLunQv4P3Pf83Y3MnKdvhriP9aEAOiWeaacwVqth3UghwJj2coIfGz zNNKx9sSEnNm0nYaFjVEsQcLZIM30Lyn3viemxi42lu42XFCMh/kATTFYHebr/O+TMO8 iJSbg9HO6YWazniySx7kNF5KBuE6tQ170VP5g//T6tnmd3QVqPPWvUdcYRBnl4pGmr5k t6EFaMt6xoGCf3a/7s+/R3g+FiJSamy9/sgTJn0Mw8J4p7xiX2lKtHQAi7D9gAsRKXb1 Q2GfaH7TWekH5048MBkFgBeBabZKFnmDE+dNx0y9H0KuCamkyLoWTFUhrcpF8N/Q6RNP v41A== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :content-language:in-reply-to:user-agent:date:message-id:from :references:cc:to:subject:dkim-signature; bh=ecedMdUa9UhAfpsTIqAEINcbcP/2xpTrW3vWneaE0L8=; b=XdZBr+6pVcKGwx83jBOhWh2rPhfggwdp/e/He8p+ra/OV0xdr9wWvxLgYIoeVVEdUB 0QEWlNSnWdFph4CEkby0bPfyzNF4fUQ73j7QjDi+BrD+07W6HrZUst3WT2Qfvz9hf51l u1vrfZwW4QZuJ1eRxjwAG1v82QlYcss0peBL1K4r4BHJUPatp4GW2FKEcqc+AqPmpfk9 d7WZUoXlNqVv7yhvmpFSqQyep1+QhJPbdPq052JVCawZBGmMZ1G+HgYE2FXSLPGXYJOQ 3CBM1O8ntQyfbW59DEv+ATedIBI5QCBCjzS+/QxvSP+29s6h0rKIZeui83elIKJ4DNpE uz1w== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@seco.com header.s=selector1 header.b=qt4OcKo2; arc=pass (i=1 spf=pass spfdomain=seco.com dkim=pass dkdomain=seco.com dmarc=pass fromdomain=seco.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; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=seco.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id r13-20020a170906364d00b00726b8363630si15928845ejb.923.2022.07.07.08.31.23; Thu, 07 Jul 2022 08:31:51 -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; dkim=pass header.i=@seco.com header.s=selector1 header.b=qt4OcKo2; arc=pass (i=1 spf=pass spfdomain=seco.com dkim=pass dkdomain=seco.com dmarc=pass fromdomain=seco.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; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=seco.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236278AbiGGPBS (ORCPT + 99 others); Thu, 7 Jul 2022 11:01:18 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56802 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236301AbiGGPBB (ORCPT ); Thu, 7 Jul 2022 11:01:01 -0400 Received: from EUR03-DBA-obe.outbound.protection.outlook.com (mail-dbaeur03on2062.outbound.protection.outlook.com [40.107.104.62]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7882C5C959; Thu, 7 Jul 2022 08:00:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=H0nd8juVVxdlIYphYSYKTb4p6hFAJMCJ4ISDk/oEUFvr04hexuWws5pqH2fHQJHxLEdNN+AWfS7wsmwA2meNg+FCyjDdKWZqqsU7o7sXiu6XoAv1uf7P2XD0LX8hc1+Pwl8bFbUbXy289WQehpievQjWQaX8eNC7nEM88uIYDB0gCTjQgCzNA4rUyfCWFrPkgdQnnmxTFwFYuWyduk/dzXWXQgQvbwBRzOTptM9HcSyZJ8HcfEdtGKbUe7pb44RitPUs5+xOL5EJoRXJB+NhiPxBEQLz20DmKC57BPPMZsNgJrKlaIRNlCZ4JTsTzXgG2lWTr3ZwUjClFszJLpvCyg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=ecedMdUa9UhAfpsTIqAEINcbcP/2xpTrW3vWneaE0L8=; b=me0tur5dCQUxaTzXUgFjOEbIdAwYN2cCi4zpEak2xBOj0fa4XKjucM/EZodKsmn7plxGyrm5iKuhIyYx4MIZ5tJLKnEn9d/sUQASkt6XlM66YpEq87w4GjiI9xnxIi+Jl+jB7nJIrjsu8IyTRRxWtsxzjX51ruj7xRIgd9oj0cmYN+nHBMS1q+PSY1NJt9KpfCOOqU7ArZmTBdYuKivQg8/1sLqfGsMUUQSvJZ6CvNlrnaHCkKXXIsxRyU74ktJ78Liyxsgo/cc9s5NhxgX0GRLbIEAiT6HaeHNLMr+1y/UPTn9S6uGE8kOCftIAIdKFNKXt5wIn/SnCzo5Juw48gA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=seco.com; dmarc=pass action=none header.from=seco.com; dkim=pass header.d=seco.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=seco.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=ecedMdUa9UhAfpsTIqAEINcbcP/2xpTrW3vWneaE0L8=; b=qt4OcKo2aokeAzEjsoGJ2eqCu2yMAZzAWQpZWjuhhF2mX/Op/PyJKGujXmc1RNtcFuIRFhnXkxkpCkbmBlOZifUaiJVwX/VVjJnKmGORHKWMldHnN3eFPE/X8Eq76k+WHuernCgRs8am3IT2FL9w454cL2aMhPKWhx5dSGCgxho50SmQd0ci6QODH423l1s6jCYVutKFMQGaS4yx9t8siq5p9sPmujXDMOmOXTg6tGSd/s5ktDlFqQQouixsGPxCYwudmxEVInd/0NrZk2NuJovreUpjM4LF9lCmtRbv6bAdVmb0H8TwdfgL91ijRyZZFNRLXjPUOb63eJmn+dZ56g== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=seco.com; Received: from DB7PR03MB4972.eurprd03.prod.outlook.com (2603:10a6:10:7d::22) by PAXPR03MB8114.eurprd03.prod.outlook.com (2603:10a6:102:227::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5395.21; Thu, 7 Jul 2022 15:00:27 +0000 Received: from DB7PR03MB4972.eurprd03.prod.outlook.com ([fe80::757e:b75f:3449:45b1]) by DB7PR03MB4972.eurprd03.prod.outlook.com ([fe80::757e:b75f:3449:45b1%6]) with mapi id 15.20.5417.016; Thu, 7 Jul 2022 15:00:27 +0000 Subject: Re: [PATCH net-next v2 04/35] [RFC] phy: fsl: Add Lynx 10G SerDes driver To: Vinod Koul Cc: "David S . Miller" , Jakub Kicinski , Madalin Bucur , netdev@vger.kernel.org, Russell King , Paolo Abeni , linux-arm-kernel@lists.infradead.org, Eric Dumazet , linux-kernel@vger.kernel.org, Ioana Ciornei , Jonathan Corbet , Kishon Vijay Abraham I , Krzysztof Kozlowski , Rob Herring , devicetree@vger.kernel.org, linux-doc@vger.kernel.org, linux-phy@lists.infradead.org References: <20220628221404.1444200-1-sean.anderson@seco.com> <20220628221404.1444200-5-sean.anderson@seco.com> <431a014a-3a8f-fdc7-319e-29df52832128@seco.com> From: Sean Anderson Message-ID: Date: Thu, 7 Jul 2022 11:00:20 -0400 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-ClientProxiedBy: BL0PR02CA0044.namprd02.prod.outlook.com (2603:10b6:207:3d::21) To DB7PR03MB4972.eurprd03.prod.outlook.com (2603:10a6:10:7d::22) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: f5a07ca6-7ef0-419e-5cd5-08da60296d02 X-MS-TrafficTypeDiagnostic: PAXPR03MB8114:EE_ X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: Z/5/6arsFB73NafNvLeQO0ufNAX3X5WS6CSW71rH6X8+e0RI9QUuUT1fX0HMIm73wwKChr3haIR6yi3KdJVZTpBFj99MR8LYz3275CnIWBho9fNbWlFNXM2dnAtrlvLwdJ4LSZbL5wSZTO1lrUUaeCn25SF6dR/AaYIb3AOD3aXaa7Il4OrEtMEAoPQybnMsEwpqvFgdchqTwgREMJfXpp1sKDUmCz93QhungFVm+fLf8omXhcjGSKvmBozXv7xsByiruvVMbFHAMj/9ZtiN6G3j/v8w+k2chUv4TWb34/98GGXmNBoExm3XwD2UuTCmzSVPRYfjrrxsAZ1hAooPV4X2EoUEbd3Fljjpl1006uRWhIZPQ1gLlPSJn5hDuhZnqwssrKarOWqDq4Y0vu7dcQUE6OUs3GNQDpscEFpKO1W8Uaf5m3Di0B6wQU4cIH+RV9y8yT7MgmS0OYa/HhvOVgqGbqBp9T+qGFeQJqkcxyElnKPEAmN3GJeDDxOTm/z7Z2ISTI22MkItRcnRKAahJ6DYfApVC5LN8oHp9Dpoqz8kde5K3jveRJt6WVLYbGOJhzbT4CEO9eEZ+q0Ihri3iDrgjwnwCTbs4VsU3ysOKv+HW+f3mtNmNf14qe3cFrFUuveX9nOHLcDaXOw26k+qaZ/NhH6h3I0cxG6CL2syXooZjZ7k1B1lPckGrof1QLnp03MYGxc+AmKYbR3sgxV9mIFBC59aCh+4TMu/PQoPdsUdndiY66muWzaMKnRPunP+rzrrA92u216e8CNaS6C0+OuzHZ/uwJClzw4T//TxKRSN6PRlT8mxZTSCQOTyIToGzrQZoRlq5DMZ393ZL4qkG9hjdBlCAX3I+xCpXmH94+Qls3Wnln21LwYOQMRWOzq0 X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DB7PR03MB4972.eurprd03.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230016)(346002)(39850400004)(396003)(376002)(136003)(366004)(2616005)(186003)(26005)(38350700002)(4326008)(36756003)(54906003)(31686004)(8676002)(6916009)(38100700002)(66556008)(83380400001)(66476007)(66946007)(86362001)(6486002)(478600001)(5660300002)(53546011)(6506007)(6666004)(31696002)(316002)(7416002)(44832011)(6512007)(8936002)(2906002)(41300700001)(52116002)(45980500001)(43740500002);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?QmVqNWFmT0JOaTV6c000SzhHRDN4Y2djWnBMOUVZL2JzbmR6c0dJM0s0emRr?= =?utf-8?B?dVJabXR4UEs0VFY3aDJpdGhBaDhCSkNvSEtxVVUvMzR4NU9icEV5UnZBVGVD?= =?utf-8?B?SUZzM3pBMzN3d0FUMjFpUXBoaW43TDdM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xZWtw?= =?utf-8?B?TTN6QU5iY0dBL05UT3N0OVU4eld4SWpVRjN6ZTIzMjJjN2k4NlRnUFdWZDhn?= =?utf-8?B?cFJQRDdQbzBPRURWQVhtL2RYMjNtMlBWbjZvWmJJR2ZlaG9HVC90VEdBSWF5?= =?utf-8?B?R0xvNk1kcWd6N211YXNOZnVnNjdqT1hFV2FhYVJybnBndXM2UVd6bk12VDJX?= =?utf-8?B?RC9OOEdkM1NLVXN1cFY2bE5DZDl6QzB3WTY1YUlLNk1RVTQ3WFVmVElNTy9l?= =?utf-8?B?UkE9PQ==?= X-OriginatorOrg: seco.com X-MS-Exchange-CrossTenant-Network-Message-Id: f5a07ca6-7ef0-419e-5cd5-08da60296d02 X-MS-Exchange-CrossTenant-AuthSource: DB7PR03MB4972.eurprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 Jul 2022 15:00:26.8424 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: bebe97c3-6438-442e-ade3-ff17aa50e733 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: /r6MRSZA4GDwcXoooFqBO4bzNSVX1olrpWprsDsE7tbNFuq93n3or5MMWTzN0S+UgX1KNIFu9syjE27VU2+Vzw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: PAXPR03MB8114 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,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 Hi Vinod, On 7/6/22 12:57 PM, Vinod Koul wrote: > On 05-07-22, 11:29, Sean Anderson wrote: > >> >> + /* TODO: wait for the PLL to lock */ >> > >> > when will this be added? >> >> I'm not sure. I haven't had any issues with this, and waiting on the lock bit is >> only mentioned in some datasheets for this SerDes. On the LS1046A for example, >> there is no mention of waiting for lock. > > okay maybe remove the comment then? Well, as it happens, on the write before this (where we request the reset), we must wait for the request to clear before making this write. Since that needed a read_poll_timeout anyway, I added one for this line as well. >> >> +static const struct clk_ops lynx_pll_clk_ops = { >> >> + .enable = lynx_pll_enable, >> >> + .disable = lynx_pll_disable, >> >> + .is_enabled = lynx_pll_is_enabled, >> >> + .recalc_rate = lynx_pll_recalc_rate, >> >> + .round_rate = lynx_pll_round_rate, >> >> + .set_rate = lynx_pll_set_rate, >> >> +}; >> > >> > right, this should be a clk driver >> >> Well, it is a clock driver, effectively internal to the SerDes. There are a few >> examples of this already (e.g. the qualcomm and cadence phys). It could of course >> be split off, but I would prefer that they remained together. > > I would prefer clk driver is split and we maintain clean split b/w phy > and clk > OK. I will split this into drivers/phy/freescale/phy-fsl-lynx-10g-clk.c --Sean