Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp2170014pxa; Mon, 3 Aug 2020 09:09:12 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyg0dKhHwmT+Pv96aN4qYXKe0N02jf9SBiCILG9ZKy2RyzsA4SWr4g7jdh0Pk00P2z8QsSK X-Received: by 2002:a50:cbc3:: with SMTP id l3mr16449396edi.58.1596470952220; Mon, 03 Aug 2020 09:09:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1596470952; cv=none; d=google.com; s=arc-20160816; b=sSdMAXbUqgJuz4LjYjGBAjzMqTejd0xx5wb8XlVax7o/P1O+WTDpevdvCMS7IsdpUT +c30AZTJqIC4hF/fXiva2DUbCj/f07ibnPml+pakuzdrBSvHw6qwYxI6UccnJYlFEVzc Azc2OFIpd+jqRrbNM7gAasQpM7GlzeM3bqdCG9o9e8jndPTM4IaprNyLmTFrhAi1TA7x 6hsJD4Mra75YWfj46NprLJy7UJnqcgOz1tjl9bFuQZ6SGTMnE0o/gJyULQ6VdrJ1kANI ik7w6ZKS1si8tUCovsll2mkwcQ68Asie6IAW9uvVF6ur66xlwJdf+DJctNAgp5p3mJjp HVOw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=Ah4YH4xbs7o/4fq+m4lwGvpsZR2W5DSohgKfYKy8nDY=; b=pfmvpcZReF4zGEz/tt4kMnOQ1cHvku2UEaLFV1/dwSxjV6L4aHph2wMgsx0IsCCEQx 186paMfw1iQwSksF37qqQ+wx6G2V4Xeyu2hUkVQzeXiKld9f9V2aUzaOMBxBLTh1ElXj xWSFg0l3bPtfvs5HeWHiSrNT4OEVk0nvghCo3oy9xhgeXQTOPDaFKd/ZmokLLAbDCa2/ YrS14JL3ZG2hiLsRu5UjRVug7fh9pHz+ii0mv43MdF4m+J+wB1bQBXWei6aAUU1ojiT0 yxQNLXREKU6dd/DxHrjOD9njgtJFqqHKIeJ+rKhuMS7evJyt0KX+lreVw4Ka6JzXyrSC QBuw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=RRT3NoZz; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id n2si9962285edy.473.2020.08.03.09.08.48; Mon, 03 Aug 2020 09:09:12 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=RRT3NoZz; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728313AbgHCQFk (ORCPT + 99 others); Mon, 3 Aug 2020 12:05:40 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47970 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726489AbgHCQFk (ORCPT ); Mon, 3 Aug 2020 12:05:40 -0400 Received: from mail-ej1-x644.google.com (mail-ej1-x644.google.com [IPv6:2a00:1450:4864:20::644]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AF65FC06174A; Mon, 3 Aug 2020 09:05:39 -0700 (PDT) Received: by mail-ej1-x644.google.com with SMTP id jp10so12634287ejb.0; Mon, 03 Aug 2020 09:05:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=Ah4YH4xbs7o/4fq+m4lwGvpsZR2W5DSohgKfYKy8nDY=; b=RRT3NoZzMjb6Id7P0RK+UDCMsf5oZdEydsvBjoMiJcskzKRpOUEsQzx6qIvuoQlmDT u8vRodRqxLsPWN5Dbj2lA2PviILlK5OwWWUFTbYWQTvS9W6fhhBrOsCEbN5MkJ3IG9HW eIgu3QAEawQBR3Cv2vkjl2bXrYrf8zIgZ3UWAZ6DMQY0sW+2ac/IuRcOKVyhVykmSWRX Y74nTh4lPAbGDNg+C2zB/FD976THLzC5hXy9pS2ljImHkaOpf7cXMGodgJMan0Toee4N qte5ce3imkSfVSwKVxqNEM4LVNSKw9WHeyqYDiqh+Vos87hWhPJkMXhyevGdBlz6A9UA aKJA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=Ah4YH4xbs7o/4fq+m4lwGvpsZR2W5DSohgKfYKy8nDY=; b=mk3vXgVfkDFtTCRmBPDNVNiLZfEGaUGJuykFO0dDOtb/wQnhes7pXTy4yllx9rb3mY ppfLwH+7Syc0vtF9buGZ1hQymlpI43vy1LYdKj9CHWx7gvXFs5my+l6xR8JDiqQVnOWW q/SC/3lWFZN1bSTtKDUiIvVu3mTVqR1fTMUvbDCLTt1VnHJ/WwPqUGw3IWuG+sDRp/0l fARV2OA2NDzmV1vMkTm9l5QIMVHLTurqZmEkUksS3onOygTiCNvPCEsnA8zhM1oZEi5T WeSwQAI35gAWIlI/IilSwY5uW3AEcagfIA4QNKoMHWqbRqySyGpUO9cKzHCMYvjLSb2q dS2Q== X-Gm-Message-State: AOAM531Nr9VV/kBwvHcrO8A8cj428Z/NVqWPMaBLwTLs4saXg5GLUC9T OQpigdy3JAwB3xxD1Ox44U45rgrnr23CevrkygY= X-Received: by 2002:a17:906:3449:: with SMTP id d9mr17737671ejb.460.1596470738295; Mon, 03 Aug 2020 09:05:38 -0700 (PDT) MIME-Version: 1.0 References: <20200726111215.22361-1-konradybcio@gmail.com> <20200726111215.22361-5-konradybcio@gmail.com> <20200803110016.GL12965@vkoul-mobl> In-Reply-To: <20200803110016.GL12965@vkoul-mobl> From: Rob Clark Date: Mon, 3 Aug 2020 09:06:22 -0700 Message-ID: Subject: Re: [PATCH 4/9] drm/msm/dsi: Add phy configuration for SDM630/636/660 To: Vinod Koul Cc: Konrad Dybcio , Bjorn Andersson , martin.botka1@gmail.com, Sean Paul , David Airlie , Daniel Vetter , Rob Herring , Andy Gross , Kishon Vijay Abraham I , Greg Kroah-Hartman , Michael Turquette , Stephen Boyd , Felipe Balbi , Jordan Crouse , zhengbin , Jeffrey Hugo , AngeloGioacchino Del Regno , Ben Dooks , Krzysztof Wilczynski , Harigovindan P , Brian Masney , Sam Ravnborg , Xiaozhe Shi , Manu Gautam , linux-arm-msm , dri-devel , freedreno , "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" , Linux Kernel Mailing List , Linux USB List , linux-clk Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Aug 3, 2020 at 4:00 AM Vinod Koul wrote: > > On 26-07-20, 13:12, Konrad Dybcio wrote: > > These SoCs make use of the 14nm phy, but at different > > addresses than other 14nm units. > > > > Signed-off-by: Konrad Dybcio > > --- > > .../devicetree/bindings/display/msm/dsi.txt | 1 + > > drivers/gpu/drm/msm/dsi/phy/dsi_phy.c | 2 ++ > > drivers/gpu/drm/msm/dsi/phy/dsi_phy.h | 1 + > > drivers/gpu/drm/msm/dsi/phy/dsi_phy_14nm.c | 18 ++++++++++++++++++ > > Is there a reason why dsi phy needs to be here and not in phy subsystem > drivers/phy/ ? *maybe* it would be possible to split out all of the dsi (and hdmi) phy to drivers/phy. But splitting out just the new ones wouldn't be practical (it would duplicate a lot of code, and make the rest of the dsi code have to deal with both cases). And unlike dp/usb-c I'm not really sure I see an advantage to justify the churn. BR, -R > > > 4 files changed, 22 insertions(+) > > > > diff --git a/Documentation/devicetree/bindings/display/msm/dsi.txt b/Documentation/devicetree/bindings/display/msm/dsi.txt > > index af95586c898f..7884fd7a85c1 100644 > > --- a/Documentation/devicetree/bindings/display/msm/dsi.txt > > +++ b/Documentation/devicetree/bindings/display/msm/dsi.txt > > @@ -87,6 +87,7 @@ Required properties: > > * "qcom,dsi-phy-20nm" > > * "qcom,dsi-phy-28nm-8960" > > * "qcom,dsi-phy-14nm" > > + * "qcom,dsi-phy-14nm-660" > > * "qcom,dsi-phy-10nm" > > * "qcom,dsi-phy-10nm-8998" > > - reg: Physical base address and length of the registers of PLL, PHY. Some > > diff --git a/drivers/gpu/drm/msm/dsi/phy/dsi_phy.c b/drivers/gpu/drm/msm/dsi/phy/dsi_phy.c > > index f509ebd77500..009f5b843dd1 100644 > > --- a/drivers/gpu/drm/msm/dsi/phy/dsi_phy.c > > +++ b/drivers/gpu/drm/msm/dsi/phy/dsi_phy.c > > @@ -499,6 +499,8 @@ static const struct of_device_id dsi_phy_dt_match[] = { > > #ifdef CONFIG_DRM_MSM_DSI_14NM_PHY > > { .compatible = "qcom,dsi-phy-14nm", > > .data = &dsi_phy_14nm_cfgs }, > > + { .compatible = "qcom,dsi-phy-14nm-660", > > + .data = &dsi_phy_14nm_660_cfgs }, > > #endif > > #ifdef CONFIG_DRM_MSM_DSI_10NM_PHY > > { .compatible = "qcom,dsi-phy-10nm", > > diff --git a/drivers/gpu/drm/msm/dsi/phy/dsi_phy.h b/drivers/gpu/drm/msm/dsi/phy/dsi_phy.h > > index 24b294ed3059..ef8672d7b123 100644 > > --- a/drivers/gpu/drm/msm/dsi/phy/dsi_phy.h > > +++ b/drivers/gpu/drm/msm/dsi/phy/dsi_phy.h > > @@ -45,6 +45,7 @@ extern const struct msm_dsi_phy_cfg dsi_phy_28nm_lp_cfgs; > > extern const struct msm_dsi_phy_cfg dsi_phy_20nm_cfgs; > > extern const struct msm_dsi_phy_cfg dsi_phy_28nm_8960_cfgs; > > extern const struct msm_dsi_phy_cfg dsi_phy_14nm_cfgs; > > +extern const struct msm_dsi_phy_cfg dsi_phy_14nm_660_cfgs; > > extern const struct msm_dsi_phy_cfg dsi_phy_10nm_cfgs; > > extern const struct msm_dsi_phy_cfg dsi_phy_10nm_8998_cfgs; > > > > diff --git a/drivers/gpu/drm/msm/dsi/phy/dsi_phy_14nm.c b/drivers/gpu/drm/msm/dsi/phy/dsi_phy_14nm.c > > index 1594f1422372..519400501bcd 100644 > > --- a/drivers/gpu/drm/msm/dsi/phy/dsi_phy_14nm.c > > +++ b/drivers/gpu/drm/msm/dsi/phy/dsi_phy_14nm.c > > @@ -161,3 +161,21 @@ const struct msm_dsi_phy_cfg dsi_phy_14nm_cfgs = { > > .io_start = { 0x994400, 0x996400 }, > > .num_dsi_phy = 2, > > }; > > + > > +const struct msm_dsi_phy_cfg dsi_phy_14nm_660_cfgs = { > > + .type = MSM_DSI_PHY_14NM, > > + .src_pll_truthtable = { {false, false}, {true, false} }, > > + .reg_cfg = { > > + .num = 1, > > + .regs = { > > + {"vcca", 17000, 32}, > > + }, > > + }, > > + .ops = { > > + .enable = dsi_14nm_phy_enable, > > + .disable = dsi_14nm_phy_disable, > > + .init = dsi_14nm_phy_init, > > + }, > > + .io_start = { 0xc994400, 0xc996000 }, > > + .num_dsi_phy = 2, > > +}; > > -- > > 2.27.0 > > -- > ~Vinod