Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp4230585ybi; Tue, 18 Jun 2019 14:18:49 -0700 (PDT) X-Google-Smtp-Source: APXvYqzS52geMDRiaaC9sA0YiSb6JzNiaLXiqeQpSxStsbqQr/WItnVZ5nFoegjG+16er59cj8dz X-Received: by 2002:a17:90a:20a2:: with SMTP id f31mr7282641pjg.90.1560892729461; Tue, 18 Jun 2019 14:18:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1560892729; cv=none; d=google.com; s=arc-20160816; b=kzYhfoYNPL+48zQBJs6MbHxEDBNIuG5NtmcWDwVhAHa+MBJwWvZx8Im17rm8w1S3YP TGGiufrAb6hP30mmiHBCpngRTklxZ7cbB9e6sQf9FBr1vNSQqe1RIeVrgWij1+qxzY5X xo13sSwUIAriybf6iKIdlqjReaJvEsRdBd1VM6PbYUw7DehE8eGvOEATpbQuVnbWkXPj Yn7csC8+osNZ9IyT1bdupPyc7KaypEgDFjsg6Ax1GTEZahw78xjUrBonfZ909qphtBFe LiBMQ9cYGRCUd8AuSeHqI893OuvBwG98fGgDKqy09aDZPqxyp+awitBiX0X49ao9ff5T p2Sw== 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=OVaisiOXoE8CbQX92HOyrJL+g6lUDABMWhLy1INrNs8=; b=RYxECcBP5KdJ+gkp8ihDCa5rz5xNTKsHeCVCxrwqaEJLhBAEVTw5wCRv6pVy6m2b0w r0ezXr3AAfMtIip82mWPFAXqJBcqvBTUXm4ZVgp4ebMRikc0uQHFJGxPB/2rXzSK75kg N7Wyb5MD0q8zHQcEdyMKxYgGbhitiGTN2WiB+vMLCYsXons3AaxY4CkDluSlHwng3qcc nOV779KTN/BrNok98GOREh/mVtkOqgMm8+HT0Qh8j4fjXMbtOntSVNHsoYOQcFjpe/OQ cavk8RqrR6RvtzPq5O4BUkVFUDweB4fs9tB40ICwvvKjfASBnBVM8NgEL3JodedcsJM/ 6fnA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=Oz5HV1mo; 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=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b188si14216600pfa.8.2019.06.18.14.18.33; Tue, 18 Jun 2019 14:18:49 -0700 (PDT) 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=@chromium.org header.s=google header.b=Oz5HV1mo; 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=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730301AbfFRVRb (ORCPT + 99 others); Tue, 18 Jun 2019 17:17:31 -0400 Received: from mail-oi1-f195.google.com ([209.85.167.195]:39752 "EHLO mail-oi1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729982AbfFRVRa (ORCPT ); Tue, 18 Jun 2019 17:17:30 -0400 Received: by mail-oi1-f195.google.com with SMTP id m202so8862395oig.6 for ; Tue, 18 Jun 2019 14:17:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=OVaisiOXoE8CbQX92HOyrJL+g6lUDABMWhLy1INrNs8=; b=Oz5HV1moPPoMk0SLnChqqtEqzhvfYwLU7u/hCFBWGfivTj/kHAznEvBv4R467lgKUO L2o4N+QjgGqsEEMT4nhuu34XkAv6TAvuLPG4rGiFrzyjtN+WuhwAOlydPGmDrk1cHusX sQaGvh6JEmDt3/1c+1QEanNN00IfKCa9rHtZo= 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=OVaisiOXoE8CbQX92HOyrJL+g6lUDABMWhLy1INrNs8=; b=JdQTeD47mjVvcJAbvPH5Vi4hUtzuKUm1v8RRNSSgomFCEAsE1W/fh+xuErRHLgfy3h YFlsOqd0geQv96ow6JA2RICpTrJcL9g/XY3xBgEAf9o17S0hf4q61hxoPJfuKhfJeOCv DeI7ng1zNw/bTVr3WMi35SH6k4CZFOvxKfn4GzVlqqN3kSGba3GX8qy1L3If6UcXMNy/ YBW2ZQkIUmMR5pB3lV9VzRqJbECyiyNC25ReyI7xUriQb5U0oCaNQNkdmNkPtOErHWgJ 86MTtoOl8Gj2IssHo9xSAEyHPg6aXk3ZeQZxRbhdol+LV1GdQx8C4Hg0/9ANmNTg+lmc F4HQ== X-Gm-Message-State: APjAAAX8Sop/MCBvLiVuNKTl/gU1auMBzEMJwdFCpsM5HeHfKYLR7t07 KENDjsMb8S04VvH2+GaqoOPHmOhJ4QVhpZpwsTPXiQ== X-Received: by 2002:aca:ab13:: with SMTP id u19mr396863oie.127.1560892650121; Tue, 18 Jun 2019 14:17:30 -0700 (PDT) MIME-Version: 1.0 References: <20190618202425.15259-1-robdclark@gmail.com> <20190618202425.15259-6-robdclark@gmail.com> In-Reply-To: From: Rob Clark Date: Tue, 18 Jun 2019 14:17:16 -0700 Message-ID: Subject: Re: [Freedreno] [PATCH 5/5] drm/msm/mdp5: Use the interconnect API To: Jeffrey Hugo Cc: Rob Clark , "open list:DRM PANEL DRIVERS" , freedreno , Rajesh Yadav , Boris Brezillon , David Airlie , MSM , lkml , Mamta Shukla , Sean Paul , Daniel Vetter , Sean Paul , Georgi Djakov 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 Tue, Jun 18, 2019 at 1:44 PM Jeffrey Hugo wrote: > > On Tue, Jun 18, 2019 at 2:25 PM Rob Clark wrote: > > > > From: Georgi Djakov > > > > The interconnect API provides an interface for consumer drivers to > > express their bandwidth needs in the SoC. This data is aggregated > > and the on-chip interconnect hardware is configured to the most > > appropriate power/performance profile. > > > > Use the API to configure the interconnects and request bandwidth > > between DDR and the display hardware (MDP port(s) and rotator > > downscaler). > > > > v2: update the path names to be consistent with dpu, handle the NULL > > path case, updated commit msg from Georgi. > > > > Signed-off-by: Georgi Djakov > > Signed-off-by: Rob Clark > > --- > > drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.c | 14 ++++++++++++++ > > 1 file changed, 14 insertions(+) > > > > diff --git a/drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.c b/drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.c > > index 97179bec8902..eeac429acf40 100644 > > --- a/drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.c > > +++ b/drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.c > > @@ -16,6 +16,7 @@ > > * this program. If not, see . > > */ > > > > +#include > > #include > > > > #include "msm_drv.h" > > @@ -1050,6 +1051,19 @@ static const struct component_ops mdp5_ops = { > > > > static int mdp5_dev_probe(struct platform_device *pdev) > > { > > + struct icc_path *path0 = of_icc_get(&pdev->dev, "mdp0-mem"); > > + struct icc_path *path1 = of_icc_get(&pdev->dev, "mdp1-mem"); > > + struct icc_path *path_rot = of_icc_get(&pdev->dev, "rotator-mem"); > > + > > + if (IS_ERR_OR_NULL(path0)) > > + return PTR_ERR_OR_ZERO(path0); > > Umm, am I misunderstanding something? It seems like of_icc_get() > returns NULL if the property doesn't exist. Won't this be backwards > incompatible? Existing DTs won't specify the property, and I don't > believe the property is supported on all targets. Seems like we'll > break things by not calling the below component_add() if the > interconnect is not supported, specified, or the interconnect driver > is not compiled. hmm, right, I guess I should test this w/out the dts patch.. probably should just revert back to the previous logic.. BR, -R > > + icc_set_bw(path0, 0, MBps_to_icc(6400)); > > + > > + if (!IS_ERR_OR_NULL(path1)) > > + icc_set_bw(path1, 0, MBps_to_icc(6400)); > > + if (!IS_ERR_OR_NULL(path_rot)) > > + icc_set_bw(path_rot, 0, MBps_to_icc(6400)); > > + > > DBG(""); > > return component_add(&pdev->dev, &mdp5_ops); > > } > > -- > > 2.20.1 > > > > _______________________________________________ > > Freedreno mailing list > > Freedreno@lists.freedesktop.org > > https://lists.freedesktop.org/mailman/listinfo/freedreno