From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-15.5 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS,UNPARSEABLE_RELAY, URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2C548C433E0 for ; Thu, 7 Jan 2021 08:52:40 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id D8E942313B for ; Thu, 7 Jan 2021 08:52:39 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726884AbhAGIwX (ORCPT ); Thu, 7 Jan 2021 03:52:23 -0500 Received: from bhuna.collabora.co.uk ([46.235.227.227]:37486 "EHLO bhuna.collabora.co.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725959AbhAGIwX (ORCPT ); Thu, 7 Jan 2021 03:52:23 -0500 Received: from [127.0.0.1] (localhost [127.0.0.1]) (Authenticated sender: tomeu) with ESMTPSA id E026A1F462C2 Subject: Re: [PATCH v7 3/4] drm/panfrost: devfreq: Disable devfreq when num_supplies > 1 To: Nicolas Boichat Cc: Rob Herring , Steven Price , Alyssa Rosenzweig , Kristian Kristensen , Fei Shao , Hsin-Yi Wang , Boris Brezillon , Daniel Vetter , David Airlie , dri-devel , lkml References: <20210107082653.3519337-1-drinkcat@chromium.org> <20210107162632.v7.3.I3af068abe30c9c85cabc4486385c52e56527a509@changeid> From: Tomeu Vizoso Message-ID: Date: Thu, 7 Jan 2021 09:51:38 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.3.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 1/7/21 9:49 AM, Nicolas Boichat wrote: > On Thu, Jan 7, 2021 at 4:31 PM Tomeu Vizoso wrote: >> >> On 1/7/21 9:26 AM, Nicolas Boichat wrote: >>> GPUs with more than a single regulator (e.g. G72 on MT8183) will >>> require platform-specific handling, disable devfreq for now. >>> >>> Signed-off-by: Nicolas Boichat >>> --- >>> >>> Changes in v7: >>> - Fix GPU ID in commit message >>> >>> Changes in v6: >>> - New change >>> >>> drivers/gpu/drm/panfrost/panfrost_devfreq.c | 9 +++++++++ >>> 1 file changed, 9 insertions(+) >>> >>> diff --git a/drivers/gpu/drm/panfrost/panfrost_devfreq.c b/drivers/gpu/drm/panfrost/panfrost_devfreq.c >>> index f44d28fad085..1f49043aae73 100644 >>> --- a/drivers/gpu/drm/panfrost/panfrost_devfreq.c >>> +++ b/drivers/gpu/drm/panfrost/panfrost_devfreq.c >>> @@ -92,6 +92,15 @@ int panfrost_devfreq_init(struct panfrost_device *pfdev) >>> struct thermal_cooling_device *cooling; >>> struct panfrost_devfreq *pfdevfreq = &pfdev->pfdevfreq; >>> >>> + if (pfdev->comp->num_supplies > 1) { >>> + /* >>> + * GPUs with more than 1 supply require platform-specific handling: >>> + * continue without devfreq >>> + */ >>> + DRM_DEV_ERROR(dev, "More than 1 supply is not supported yet\n"); >> >> Should this be info instead? > > Sure, will fix in v8. Thanks. With that change, patches 3 and 4 are R-b. Thanks again! Tomeu >> >> Regards, >> >> Tomeu >> >>> + return 0; >>> + } >>> + >>> opp_table = dev_pm_opp_set_regulators(dev, pfdev->comp->supply_names, >>> pfdev->comp->num_supplies); >>> if (IS_ERR(opp_table)) { >>>