Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp35049191rwd; Mon, 10 Jul 2023 01:37:54 -0700 (PDT) X-Google-Smtp-Source: APBJJlFaMRY7UZRJBntpRa+4JB4b7Xyu3i1kzZutW+/tjepG9pQLNYpy8r/03ifpTQPyWxb3O8GM X-Received: by 2002:a05:6402:74e:b0:51e:27e9:ad45 with SMTP id p14-20020a056402074e00b0051e27e9ad45mr11276249edy.33.1688978274498; Mon, 10 Jul 2023 01:37:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1688978274; cv=none; d=google.com; s=arc-20160816; b=siAnAK4ePdU9S8Th0a0fGtfJgIPTqIVmaMLiFA0BAHp8NBGMjB/cjN9S2s+MH41pRQ 4oHCYcoaHhKKlCCw1eFUWITR2/xnDf9jgaH6PT5ubJRk3hK1zxpBdfXtczZAU/c0QzU+ yl5ER7ChCzqFGEqvnhcqZvQYmlnQAS3bS82a+Iqr5XPbIpqaHwpA2bzQmq74U/k2mG+h kiA6kA2HDKVEpwvSbA9wShEKjuD9+74/M9LhErUyFx8Vgiw6tkYPUzIAPKgdhKrSEPWV vPTYw8n0uIvFN+/T5gNGFRQpHpiNt8WGQjsHO9Hsc9vd/Hq5krQmSqLiu3qqEDtPdjYq 35WA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=lVVTTcakGIJzotpbfodORieW7nDILC8yQwEKuMOUYLA=; fh=lr7jvbpzhOxWUzQyb46beSQk7gNZvB5yDKIePrjxFKE=; b=HDxTCt4C1ajlhY3JjxVPxtNZ3AID42uV+zsxfCRXS/ghG/gdqpTOrEefyAIR1jPe3L aFtrR9ab7gOpxV8ca91KvyN9UxK9fAXddrmNC9xmLBkRlIqYaAAPvD5AfGAeHDjUsKQa faUyXCY2dxR77ghHpDV6Q4B+bC8R4ygCwe6pmj6mTiDX7b/YEAeNhHrjDXDimT3/ut++ GqwNVsJjw4Ywn0nzxaB0SE5wpO48BL1mef0Hilop8PIOYx98xSQVZCCu1ovWBn2UTJju aMIS9Ymocnn5iIqdYrI6DPpd8PLzGMp5EAVqU2GQ+lNvvPQ3xU7cYMyaqIGea/fezSq+ gusw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@resnulli-us.20221208.gappssmtp.com header.s=20221208 header.b=v8PbxExQ; 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 z15-20020aa7c64f000000b0051de3433c89si7920368edr.427.2023.07.10.01.37.30; Mon, 10 Jul 2023 01:37:54 -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=@resnulli-us.20221208.gappssmtp.com header.s=20221208 header.b=v8PbxExQ; 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 S232678AbjGJIYZ (ORCPT + 99 others); Mon, 10 Jul 2023 04:24:25 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43672 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232995AbjGJIYI (ORCPT ); Mon, 10 Jul 2023 04:24:08 -0400 Received: from mail-ej1-x62e.google.com (mail-ej1-x62e.google.com [IPv6:2a00:1450:4864:20::62e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B2EA0E74 for ; Mon, 10 Jul 2023 01:23:57 -0700 (PDT) Received: by mail-ej1-x62e.google.com with SMTP id a640c23a62f3a-992ace062f3so548624066b.2 for ; Mon, 10 Jul 2023 01:23:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=resnulli-us.20221208.gappssmtp.com; s=20221208; t=1688977436; x=1691569436; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=lVVTTcakGIJzotpbfodORieW7nDILC8yQwEKuMOUYLA=; b=v8PbxExQdeZ1rHkHw7LZ/7j9U0WaA1dkJRr1esV51tDnEYnz1yXdBnwheipucQw7iU Dwny0J0H5BLnpfGCG5wzHd2FnzlN2eKCW8gMzeSEoxaUGxTKsnw6EvOsEUU4TK67JfFM Fphyzekktczmyd9ASIWTNFAeo2y/sK6qzV5gvKJEWK5UQrHLGo1bEQy410Gg0pjYZAno l+f8A80ndIBgzckm1LdIX5bAeQYPaJaXuB13ipB3GplwZOJY/GVnmBg1MPjebry6Ueg9 L5E9ztuma8giElufrDqCE9zHYDHjDcl1vKgQ9QXsO3zircBl8jFsHwzGNf5dL/40PtRb 4zSQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1688977436; x=1691569436; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=lVVTTcakGIJzotpbfodORieW7nDILC8yQwEKuMOUYLA=; b=RxH2gvJPorBVpvcTZRn7d3hNxEXie2mJs1e07GHlK79eVGSQNKqtkszWYBschqrpo8 d/PHrKSd6SG/yq5GV4K8fy/8K3yrYGc4l9yVSWoeLGKFOM+STsi1tYr3sz7dI0zZVKr9 Lw7+dLuD/nbJkhn59iDAKJOt/hJLur94e/FV9pDYhTsMTcAQK6+2UNz3YIIIKR7poghI GpxlF5oX1Zn2mix5/GG8Kd2k+s+Lzz28ER0NEmnA4bphA6xV68Ep5/ydhRLbp2/N9Rh+ 88zBHbaSOKMIDXVfrp8OPL68A9fNn87lSc7zQf7nxhtoLrTIqulT/1gIPmqTMWZrzm7w it8Q== X-Gm-Message-State: ABy/qLYwvoN2JzL1Ji7DoJHRE8VWNBkltZPNFk9UTxKFcEmpxlfoPXPE eodH+ZAphJgbqs2mjeJCHbXWCg== X-Received: by 2002:a17:906:101e:b0:993:fba5:cdf3 with SMTP id 30-20020a170906101e00b00993fba5cdf3mr5110018ejm.6.1688977436009; Mon, 10 Jul 2023 01:23:56 -0700 (PDT) Received: from localhost (host-213-179-129-39.customer.m-online.net. [213.179.129.39]) by smtp.gmail.com with ESMTPSA id u2-20020a1709063b8200b0098e42bef732sm5733689ejf.183.2023.07.10.01.23.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 Jul 2023 01:23:55 -0700 (PDT) Date: Mon, 10 Jul 2023 10:23:53 +0200 From: Jiri Pirko To: "Kubalewski, Arkadiusz" Cc: "kuba@kernel.org" , "vadfed@meta.com" , "jonathan.lemon@gmail.com" , "pabeni@redhat.com" , "corbet@lwn.net" , "davem@davemloft.net" , "edumazet@google.com" , "vadfed@fb.com" , "Brandeburg, Jesse" , "Nguyen, Anthony L" , "M, Saeed" , "leon@kernel.org" , "richardcochran@gmail.com" , "sj@kernel.org" , "javierm@redhat.com" , "ricardo.canuelo@collabora.com" , "mst@redhat.com" , "tzimmermann@suse.de" , "Michalik, Michal" , "gregkh@linuxfoundation.org" , "jacek.lawrynowicz@linux.intel.com" , "airlied@redhat.com" , "ogabbay@kernel.org" , "arnd@arndb.de" , "nipun.gupta@amd.com" , "axboe@kernel.dk" , "linux@zary.sk" , "masahiroy@kernel.org" , "benjamin.tissoires@redhat.com" , "geert+renesas@glider.be" , "Olech, Milena" , "kuniyu@amazon.com" , "liuhangbin@gmail.com" , "hkallweit1@gmail.com" , "andy.ren@getcruise.com" , "razor@blackwall.org" , "idosch@nvidia.com" , "lucien.xin@gmail.com" , "nicolas.dichtel@6wind.com" , "phil@nwl.cc" , "claudiajkang@gmail.com" , "linux-doc@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "netdev@vger.kernel.org" , "intel-wired-lan@lists.osuosl.org" , "linux-rdma@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" , poros , mschmidt , "linux-clk@vger.kernel.org" , "vadim.fedorenko@linux.dev" Subject: Re: [RFC PATCH v8 08/10] ice: implement dpll interface to control cgu Message-ID: References: <20230609121853.3607724-1-arkadiusz.kubalewski@intel.com> <20230609121853.3607724-9-arkadiusz.kubalewski@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_BLOCKED,SPF_HELO_NONE,SPF_NONE, T_SCC_BODY_TEXT_LINE autolearn=unavailable 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 Mon, Jul 03, 2023 at 02:37:18PM CEST, arkadiusz.kubalewski@intel.com wrote: >>From: Jiri Pirko >>Sent: Thursday, June 29, 2023 8:14 AM >> >>Wed, Jun 21, 2023 at 02:29:59PM CEST, jiri@resnulli.us wrote: >>>Mon, Jun 19, 2023 at 10:34:12PM CEST, arkadiusz.kubalewski@intel.com >>wrote: >>>>>From: Jiri Pirko >>>>>Sent: Saturday, June 10, 2023 6:37 PM >>>>> >>>>>Fri, Jun 09, 2023 at 02:18:51PM CEST, arkadiusz.kubalewski@intel.com >>>>>wrote: >>>>> >>>>>[...] >>>>> >>>>> >>>>>>+static int ice_dpll_mode_get(const struct dpll_device *dpll, void *priv, >>>>>>+ enum dpll_mode *mode, >>>>>>+ struct netlink_ext_ack *extack) >>>>>>+{ >>>>>>+ *mode = DPLL_MODE_AUTOMATIC; >>>>> >>>>>I don't understand how the automatic mode could work with SyncE. The >>>>>There is one pin exposed for one netdev. The SyncE daemon should select >>>>>exacly one pin. How do you achieve that? >>>>>Is is by setting DPLL_PIN_STATE_SELECTABLE on the pin-netdev you want to >>>>>select and DPLL_PIN_STATE_DISCONNECTED on the rest? >>>>> >>>>> >>>>>[...] >>>> >>>>AUTOMATIC mode autoselects highest priority valid signal. >>>>As you have pointed out, for SyncE selection, the user must be able to >>>>manually >>>>select a pin state to enable recovery of signal from particular port. >>>> >>>>In "ice" case there are 2 pins for network PHY clock signal recovery, and >>>>both >>>>are parent pins (MUX-type). There are also 4 pins assigned to netdevs >>>>(one per >>>>port). Thus passing a signal from PHY to the pin is done through the MUX- >>>>pin, >>>>by selecting proper state on pin-parent pair (where parent pins is highest >>>>prio >>>>pin on dpll). >>> >>>Could you show me some examples please? >> >>Arkadiusz, could you please reply to this? >>Thanks! >> > >Sure, sorry for the delays, let's try that. > >'ice' use case: >Enabling a PHY clock recovery for DPLL_MODE_AUTOMATIC dpll (ID#0) with PHY >recovered clock signals (PIN_ID#13) being muxed using MUX-type pin (PIN_ID#2) > >1. Set MUX-type pin to state selectable and highest priority on a dpll device >(or make sure it is already configured): >CMD_PIN_SET: > PIN_ID 2 > PIN_PARENT_DEVICE (nest) > ID 0 > PIN_STATE SELECTABLE > PIN_PRIO 0 >(assume all the other pins have prio >=1) > >2. Set connected state on a pin-parent_pin tuple where parent is a pin from #1 >CMD_PIN_SET: > PIN_ID 13 > PIN_PARENT_PIN (nest) > PIN_ID 2 > PIN_STATE CONNECTED How does this look from the perspective of a SyncE flow. Let's say you have eth0 and eth1, both is connected with a DPLL pin. Could you show how you select eth0 and then eth1? > >Thank you! >Arkadiusz > >>> >>> >>>> >>>>Thank you! >>>>Arkadiusz