Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp1335014imm; Tue, 22 May 2018 02:20:19 -0700 (PDT) X-Google-Smtp-Source: AB8JxZqKVe9GaLEcHqdeKZ6J50LA2JMmixSqMN9UjdwiqD9prcGjHJ5WbnX67tU1t64AuycGiEFw X-Received: by 2002:a17:902:6041:: with SMTP id a1-v6mr23807058plt.59.1526980819302; Tue, 22 May 2018 02:20:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1526980819; cv=none; d=google.com; s=arc-20160816; b=SwlWf7vECKR6EOX0029x0evQpJrDLDNJW9CBb7XFr4CefR51V8tMT0YW00c6I2u5PN TIF1ktLu+QJilgSeI3q5Lsl1gyrEaDRQbZ24NK2WDCd3l71WsJ1+nhzd2GSSotXTOfuz 5nRZTU75d5l/oCg0yGi4OqwjFBq1vMH4A0n9FKRPfiUj9HNZn/yGPpnqNJ1SiJ1lfQh6 nYkgjbvekKXkE2DSlRGpoTab8/DjNs/8CsOi6f9rdUQktBfel7rAMGqHQTCf5cz6XafF AQ8SC+D3ihlOfNz4h1PLAKAePkIfY8zAHL9hp8FyugxweOr+WvUTKG1iZ1fvgrvEBYEM evvA== 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:organization:from:references:to:subject:cc :arc-authentication-results; bh=sjITXt8/brZjpHOSvk2oQImldDHehtyxQbyFDNIt4zM=; b=dXjEti4usPltc7/e/rvSQ0v5JzHdE6m5Je4D8kOD1VfEDrC4h4LcTvfUdShC8F3DDC KY1CxXA4/qtukCKsjMFlv78P0DPOCULiDFSfB4jI4SAnpqbCP4QGMTxv+QQ5PJtaUAL3 aBdJ1YTomdd5fgdxlP/5qFm98mlewnZmfEYmY+vQzlNE8tqqTISqSHPugauxMaG0R2b+ 2j7YephIM7lXtQZAEez8QbfLtKrwhuUGWwQZLKTKMC/gjhoNs8Qml1wbN5TIEbD2Z6vY 9q1L+ITDtVRhADEIc5bXEw+oI9uwp6JMtYogr4b7enEjdKGDuQ9WFJVbVhxLx7TG3CjZ /8uQ== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g6-v6si16906045pll.69.2018.05.22.02.20.04; Tue, 22 May 2018 02:20:19 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751453AbeEVJSZ (ORCPT + 99 others); Tue, 22 May 2018 05:18:25 -0400 Received: from usa-sjc-mx-foss1.foss.arm.com ([217.140.101.70]:33394 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750733AbeEVJSW (ORCPT ); Tue, 22 May 2018 05:18:22 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id E38601435; Tue, 22 May 2018 02:18:21 -0700 (PDT) Received: from [10.1.210.28] (unknown [10.1.210.28]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id AB2AC3F577; Tue, 22 May 2018 02:18:16 -0700 (PDT) Cc: Sudeep Holla , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, rnayak@codeaurora.org, amit.kucheria@linaro.org, nicolas.dechesne@linaro.org, celster@codeaurora.org, tfinkel@codeaurora.org Subject: Re: [PATCH] cpufreq: Add Kryo CPU scaling driver To: ilialin@codeaurora.org, mturquette@baylibre.com, sboyd@kernel.org, robh@kernel.org, mark.rutland@arm.com, viresh.kumar@linaro.org, nm@ti.com, lgirdwood@gmail.com, broonie@kernel.org, andy.gross@linaro.org, david.brown@linaro.org, catalin.marinas@arm.com, will.deacon@arm.com, rjw@rjwysocki.net, linux-clk@vger.kernel.org References: <1526555955-29960-11-git-send-email-ilialin@codeaurora.org> <1526729701-8589-1-git-send-email-ilialin@codeaurora.org> <153cc316-dcb5-972f-5a2f-c91fe0f6348b@arm.com> <000f01d3f103$3ff78ba0$bfe6a2e0$@codeaurora.org> <2ace10bc-e1c4-2060-94d3-eb71e966ffbe@arm.com> <001401d3f1a2$c7328850$559798f0$@codeaurora.org> From: Sudeep Holla Organization: ARM Message-ID: <7690ea9d-0155-ecd1-8fb2-08d0bd61e081@arm.com> Date: Tue, 22 May 2018 10:18:15 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.7.0 MIME-Version: 1.0 In-Reply-To: <001401d3f1a2$c7328850$559798f0$@codeaurora.org> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 22/05/18 08:59, ilialin@codeaurora.org wrote: > OK, I think I found out the way. Would this be correct? No. > ----------------------------------------------------------------------------------------------- > extern struct cpu_topology cpu_topology[NR_CPUS]; > > static struct device *qcom_cpufreq_kryo_get_cluster_lead(int cluster) > { > unsigned cpu; > > for_each_possible_cpu(cpu) { > if ((cluster == cpu_topology[cpu].cluster_id) && cluster_id is going away soon, so avoid relying on that. IIUC there's a way already something like opp_of_get_shared_cpus. -- Regards, Sudeep