Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp1790085imu; Wed, 21 Nov 2018 01:54:16 -0800 (PST) X-Google-Smtp-Source: AFSGD/UNef+HJbQ6Xg31PUrpEMX9nCxzFrceZyuFCjRggQDa6icvA7uoKh97K5hT85vp1ZIZoY0/ X-Received: by 2002:a63:24c2:: with SMTP id k185mr5171433pgk.406.1542794056770; Wed, 21 Nov 2018 01:54:16 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1542794056; cv=none; d=google.com; s=arc-20160816; b=zhW8TJrNrYrmrAiA6lKJ2pUVCSdKXYpHzeMm5VSi7Wus4R7Xr6Ql96/tCodYvAd/pS 2/40/2pgzzmWCY23kzf9QpxVKtTkCogPR9gVviMWYGyFeOnqOiK2yVQFOUvsnAEikuWs Co52mpDeAXbyelKD9d6FQEYnvKLtrOi2CXugHdRP9spkLJOr+UtHrriAhGjr2SXdN0zs UuZB/HgnuNaH7w1OxwepGIaMGFpjAw6gd1OwfNoxCMPf5pM7hNUOgtpNu324ddlaT9U3 81Hrz4Q/nt/TyYllNMZbZlKrC/gd5YiLZ2WVQnqeZPWAqNLo9+0VWD2RiTt8kgQve1r9 bObQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=RaYLBY3C9MifiQMpPdFmMCEqSCg9MCBNo4xS+LD2sRw=; b=Gz9EJnoznunyFbOx0pFSDk9+xIaqgDLdQYW9toKH1ZzO1CCcC+Okze3ozND3phWPZb tGGnS/4ySgjaNboxA3S+pesqk9rsiQC3ff8+4IhMva030KUVK/rY35paJ9GgOk6b+BM/ uI8qmetTaQMLRLwa189x6kDcYp+RjDHNVszShdnB9YYoBpTpFNaP4sDjuP4LB172oQQl RRpf9IeHJUgkYqPaQ9UBYxgyA9+AXg1YlYGC2gn4IH9IIcW4B1mgNPVbBD9pwRki/hzy DMO1XfDGYtFsCWcwJqaISIurSlvrh8SbM9Gegi7R1ZlUrC0jD2TfFNXB1/QqtbsWb05z n5TA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b="c8Q7fCU/"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id p2si45297927pgr.133.2018.11.21.01.54.02; Wed, 21 Nov 2018 01:54:16 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b="c8Q7fCU/"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729126AbeKUT3q (ORCPT + 99 others); Wed, 21 Nov 2018 14:29:46 -0500 Received: from fllv0016.ext.ti.com ([198.47.19.142]:58752 "EHLO fllv0016.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726665AbeKUT3q (ORCPT ); Wed, 21 Nov 2018 14:29:46 -0500 Received: from fllv0034.itg.ti.com ([10.64.40.246]) by fllv0016.ext.ti.com (8.15.2/8.15.2) with ESMTP id wAL8tEq0076197; Wed, 21 Nov 2018 02:55:14 -0600 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1542790514; bh=RaYLBY3C9MifiQMpPdFmMCEqSCg9MCBNo4xS+LD2sRw=; h=Subject:To:CC:References:From:Date:In-Reply-To; b=c8Q7fCU/lQagzbQQo2+ffO2GwBd+o2nPHcMNx6+qDdvaxykMVmOKk0Pl3aH5Q30Hl gRWHR2LQz4GBD0DNI0AUhE4+yUNFaYjob+V6Isl+M0YCAT3yX+0kEoevFvQYlPboX/ TPYHc8ypFcKHnv1NIoCFsZp00F+2lSstpi3rKU2A= Received: from DFLE112.ent.ti.com (dfle112.ent.ti.com [10.64.6.33]) by fllv0034.itg.ti.com (8.15.2/8.15.2) with ESMTPS id wAL8tEMX050548 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Wed, 21 Nov 2018 02:55:14 -0600 Received: from DFLE105.ent.ti.com (10.64.6.26) by DFLE112.ent.ti.com (10.64.6.33) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1591.10; Wed, 21 Nov 2018 02:55:14 -0600 Received: from dflp33.itg.ti.com (10.64.6.16) by DFLE105.ent.ti.com (10.64.6.26) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.1.1591.10 via Frontend Transport; Wed, 21 Nov 2018 02:55:14 -0600 Received: from [172.24.190.233] (ileax41-snat.itg.ti.com [10.172.224.153]) by dflp33.itg.ti.com (8.14.3/8.13.8) with ESMTP id wAL8t863019198; Wed, 21 Nov 2018 02:55:08 -0600 Subject: Re: [PATCH v3 0/5] phy: core: rework phy_set_mode to accept phy mode and submode To: Grygorii Strashko , "David S. Miller" , Antoine Tenart , Quentin Schulz , Russell King - ARM Linux , Maxime Chevallier CC: , Sekhar Nori , , , Tony Lindgren , , , Alexandre Belloni , Vivek Gautam , Maxime Ripard , Chen-Yu Tsai , Carlo Caione , Chunfeng Yun , Matthias Brugger , Manu Gautam References: <20181120012424.11802-1-grygorii.strashko@ti.com> From: Kishon Vijay Abraham I Message-ID: <6418b7c3-7345-76e8-90c0-9a77769f6f87@ti.com> Date: Wed, 21 Nov 2018 14:25:04 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.2.1 MIME-Version: 1.0 In-Reply-To: <20181120012424.11802-1-grygorii.strashko@ti.com> Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: 7bit X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 20/11/18 6:54 AM, Grygorii Strashko wrote: > Hi Kishon, All, > > Thank you for your review. > I've not added "Tested-by"/"Acked-by" tags due to code changes in v3. merged after adding the required ACKs. Thanks Kishon > > As was discussed in [1] I'm posting series which introduces rework of > phy_set_mode to accept phy mode and submode. I've dropped TI specific patches as > this change is pretty big by itself. > > Patch 1 is cumulative change which refactors PHY framework code to > support dual level PHYs mode configuration - PHY mode and PHY submode. It > extends .set_mode() callback to support additional parameter "int submode" > and converts all corresponding PHY drivers to support new .set_mode() > callback declaration. > The new extended PHY API > int phy_set_mode_ext(struct phy *phy, enum phy_mode mode, int submode) > is introduced to support dual level PHYs mode configuration and existing > phy_set_mode() API is converted to macros, so PHY framework consumers do > not need to be changed (~21 matches). > > Patches 2-4: Add new PHY's mode to be used by Ethernet PHY interface drivers or > multipurpose PHYs like serdes and convert ocelot-serdes and mvebu-cp110-comphy > PHY drivers to use recently introduced PHY_MODE_ETHERNET and phy_set_mode_ext(). > > Patch 5 - removes unused, ethernet specific phy modes from enum phy_mode. > > Testing: > - series tested on TI am335x/am437x/am5(dra7) paltforms. > - other driver build tested. > > changes in v3: > - mux tables for PHY ocelot-serdes driver updated to store PHY mode and submode > - mux tables for PHY mvebu-cp110-comphy driver updated to store PHY mode > and submode > changes in v2: > - marvell PHY and net drivers updated as recommended by Russell King > > v2: https://lkml.org/lkml/2018/11/10/220 > v1: https://lkml.org/lkml/2018/11/8/260 > > [1] https://lkml.org/lkml/2018/10/25/366 > > Grygorii Strashko (5): > phy: core: rework phy_set_mode to accept phy mode and submode > phy: core: add PHY_MODE_ETHERNET > phy: ocelot-serdes: convert to use eth phy mode and submode > phy: mvebu-cp110-comphy: convert to use eth phy mode and submode > phy: core: clean up unused ethernet specific phy modes > > drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c | 19 +---- > drivers/net/ethernet/mscc/ocelot.c | 9 +-- > drivers/phy/allwinner/phy-sun4i-usb.c | 3 +- > drivers/phy/amlogic/phy-meson-gxl-usb2.c | 5 +- > drivers/phy/amlogic/phy-meson-gxl-usb3.c | 5 +- > drivers/phy/marvell/phy-mvebu-cp110-comphy.c | 93 ++++++++++++++----------- > drivers/phy/mediatek/phy-mtk-tphy.c | 2 +- > drivers/phy/mediatek/phy-mtk-xsphy.c | 2 +- > drivers/phy/mscc/phy-ocelot-serdes.c | 24 +++++-- > drivers/phy/phy-core.c | 6 +- > drivers/phy/qualcomm/phy-qcom-qmp.c | 3 +- > drivers/phy/qualcomm/phy-qcom-qusb2.c | 3 +- > drivers/phy/qualcomm/phy-qcom-ufs-qmp-14nm.c | 3 +- > drivers/phy/qualcomm/phy-qcom-ufs-qmp-20nm.c | 3 +- > drivers/phy/qualcomm/phy-qcom-usb-hs.c | 3 +- > drivers/phy/ti/phy-da8xx-usb.c | 3 +- > drivers/phy/ti/phy-tusb1210.c | 2 +- > include/linux/phy/phy.h | 18 +++-- > 18 files changed, 111 insertions(+), 95 deletions(-) >