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=-6.0 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=no 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 D3D98C4338F for ; Tue, 10 Aug 2021 10:14:22 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 6FA34600CD for ; Tue, 10 Aug 2021 10:14:22 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 6FA34600CD Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=arm.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:Content-Type: Content-Transfer-Encoding:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:Date:Message-ID:From: References:Cc:To:Subject:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=MXWWmY1ewyRWEyuK1m73fJCdszJlF37/qHlg5Xze4cs=; b=q9eq7ua18vK3bOpmE6QQWTapMT kEb7l2KEJ3MNxEDOHx4J52CWUxuPWQ8wzsigJXjWoc+orUZc237EnbNT6Ds5LTLPYVK4Cu8IxD1Lc IRmKj3T5aJgAksTbxAr72wAidHsQsZGa19Y2ja7gyAQYwRJUWXA1natd2iOTOG28+35vW4tYLH0Dt kwJyETYpCGh8x5r/VxdpKibkB0i5oh9dNMs+DGgEzUrcqRaUJRBbC9yGd4Rp1+V10OEYZB9MgpHFR pjAW6euQYX1egjWLzAEk3v8v/Glhhfi8WKxLdW6nsDS7TRR8LyvoyR0TxFTR9IQitGr4rOOvBO0Op C4LJ63zw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mDOjT-003TEO-Ei; Tue, 10 Aug 2021 10:11:39 +0000 Received: from foss.arm.com ([217.140.110.172]) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mDOjQ-003TDF-6i for linux-arm-kernel@lists.infradead.org; Tue, 10 Aug 2021 10:11:37 +0000 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 608E46D; Tue, 10 Aug 2021 03:11:34 -0700 (PDT) Received: from [10.57.9.181] (unknown [10.57.9.181]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 8384F3F70D; Tue, 10 Aug 2021 03:11:32 -0700 (PDT) Subject: Re: [PATCH 8/8] cpufreq: vexpress: Use auto-registration for energy model To: Viresh Kumar Cc: Rafael Wysocki , Vincent Donnefort , Sudeep Holla , linux-pm@vger.kernel.org, Vincent Guittot , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org References: <87fecd84e3f6ff6f153be14b0d53de93c0b04ae6.1628579170.git.viresh.kumar@linaro.org> <20210810100652.h473q6hgtc5czfyk@vireshk-i7> From: Lukasz Luba Message-ID: <2210acb9-2666-7aa9-d36c-346480541f3c@arm.com> Date: Tue, 10 Aug 2021 11:11:31 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.9.0 MIME-Version: 1.0 In-Reply-To: <20210810100652.h473q6hgtc5czfyk@vireshk-i7> Content-Language: en-US X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210810_031136_344494_E42ABECB X-CRM114-Status: GOOD ( 17.95 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 8/10/21 11:06 AM, Viresh Kumar wrote: > On 10-08-21, 11:05, Lukasz Luba wrote: >> I can see that this driver calls explicitly the >> of_cpufreq_cooling_register() >> It does this in the cpufreq_driver->ready() callback >> implementation: ve_spc_cpufreq_ready() >> >> With that in mind, the new code in the patch 1/8, which >> registers the EM, should be called even earlier, above: >> ---------------------8<--------------------------------- >> /* Callback for handling stuff after policy is ready */ >> if (cpufreq_driver->ready) >> cpufreq_driver->ready(policy); >> ------------------->8---------------------------------- > > Thanks. I will look at this sequencing issue again. > >> This also triggered a question: >> If this new flag can be set in the cpufreq driver which hasn't set >> CPUFREQ_IS_COOLING_DEV >> ? > > Why not ? I thought someone could try to call cpufreq_cooling_register() from the cpufreq driver init function, but it's not possible. I have just checked that, so should be good with these two flags being independent and working fine. > >> I can only see one driver (this one in the patch) which has such >> configuration. > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel