Received: by 10.192.165.148 with SMTP id m20csp417943imm; Fri, 4 May 2018 12:21:24 -0700 (PDT) X-Google-Smtp-Source: AB8JxZqeTTC4hRG6AJMkWMQ3I7sEhRRNoByLmCLe+kRZfGKEJSQ9ldFie5fgBtrCWPLxB7kOu2ao X-Received: by 10.98.137.16 with SMTP id v16mr27602767pfd.13.1525461684220; Fri, 04 May 2018 12:21:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1525461684; cv=none; d=google.com; s=arc-20160816; b=Hbp3x7KU7OQ+kcHtF+Ym/RmXQa4zu7vLL1XPHFKKzXoBs2FTvHL+M/qsjgo7lPSRmX SDeKU6MxUsDTJ35iABpgzwkzXjaguq5gKT7ROgJ0e9L1ofl2IbuQumaAERxj9UbEI2Mq JfXqnmX798FQee452PRzDJKe3t/nNIObauTvnNOHhUPJdPVtlMPkpMiV2IEDocjSr42O W8YmxsQ932faK3NfSmcXinaz8mYo1ae3tWPYy2DDMaCyYbL76PC9ewGbY8l8ACXItEqj a6oExB28X9hhvykCq4Y9CaWJPSXLSj78gK5+J2tgfMi06ng/nK/jIF9AFhurhdZApvgh JUOg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-language:thread-index :content-transfer-encoding:mime-version:message-id:date:subject :in-reply-to:references:cc:to:from:dmarc-filter:dkim-signature :dkim-signature:arc-authentication-results; bh=s9DglliSGbMcA3313/Bm70KpZAGS4M04a1oTgzqwC78=; b=fV4Mq/nhiL6fzUrovpAu6QEiaebys3H7sQ6FaTMzQT3q14kU3A1OPgRgiZVBA+IMWb 4IL3iWpH1pMgX5R3LIp10Ov38NftCEWIWTcks87Jiow9X9YchILhmOq47qZ1pGFI13FD 3rMh0kKNp/xLQ3An16kcmau7sSQygWZoxIg0O3qxgBCJL6kPZPIHKnNYW5Utsqt2D4xA +6UN8VsuajbYlExsDyXxg5Y2v960BqAkLxSsqV6jUsppBfMaYrwgHpQ0NG1ktwheWf+/ G6P2oypHXOLnAEy5pHvOrYyC3ygbmZeM33G0y4q3sn6V4ZmKkwr6obB3tEm0A5Dd6m4F i1OQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@codeaurora.org header.s=default header.b=Ct/gtLb3; dkim=pass header.i=@codeaurora.org header.s=default header.b=RNqhsCQX; 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 f18si14222958pff.208.2018.05.04.12.21.09; Fri, 04 May 2018 12:21:24 -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=@codeaurora.org header.s=default header.b=Ct/gtLb3; dkim=pass header.i=@codeaurora.org header.s=default header.b=RNqhsCQX; 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 S1751820AbeEDTUt (ORCPT + 99 others); Fri, 4 May 2018 15:20:49 -0400 Received: from smtp.codeaurora.org ([198.145.29.96]:46904 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751628AbeEDTUq (ORCPT ); Fri, 4 May 2018 15:20:46 -0400 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id B31186085F; Fri, 4 May 2018 19:20:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1525461645; bh=p6CQxhfuFZ1cVgG08Kl2/WDJESMinE9U06h/APUdcAY=; h=From:To:Cc:References:In-Reply-To:Subject:Date:From; b=Ct/gtLb3rGMyGZxao/isqVcfIHjePjyZyHTQe5ph57moK1TMg1/EadBpJbThuDLFw +JmjysyuZfgNXNhxe8ZmT9aGKyv05cHxd9V9/Q+joe5tXpE/ILKx8ntxl2MNX6LI93 SwmlwaK/d/MsLyi6yxZkHQjQP94yE1dOuGm6GY04= X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on pdx-caf-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.8 required=2.0 tests=ALL_TRUSTED,BAYES_00, DKIM_SIGNED,T_DKIM_INVALID autolearn=no autolearn_force=no version=3.4.0 Received: from ilial (unknown [37.19.120.234]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: ilialin@codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id 95A4B6055D; Fri, 4 May 2018 19:20:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1525461629; bh=p6CQxhfuFZ1cVgG08Kl2/WDJESMinE9U06h/APUdcAY=; h=From:To:Cc:References:In-Reply-To:Subject:Date:From; b=RNqhsCQXv+J9wYZs+rbov4umBgVQL+Jp9Zm+kM/a3R72RMid4I9YI96WMc/TvrzrN VzQNO7fc+F95vSFiRZXt2gZzEECC3SAjoy1gKfRkyAmswWNim7OdCelM7+/o0B3Iyz jbz7OIGemch3jChnjP21fZ7B0k2jD/Bz0WKo3kio= DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 95A4B6055D Authentication-Results: pdx-caf-mail.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: pdx-caf-mail.web.codeaurora.org; spf=none smtp.mailfrom=ilialin@codeaurora.org From: To: "'Viresh Kumar'" Cc: , , , , , , , , , , , , , , , , , , , , , , References: <1525348355-25471-1-git-send-email-ilialin@codeaurora.org> <1525348355-25471-13-git-send-email-ilialin@codeaurora.org> <20180504060827.7bddb53ln2ogwcvv@vireshk-i7> <002a01d3e373$6b6ee410$424cac30$@codeaurora.org> <20180504065709.62kacfext6bbprlo@vireshk-i7> In-Reply-To: <20180504065709.62kacfext6bbprlo@vireshk-i7> Subject: RE: [PATCH v5 12/14] cpufreq: Add Kryo CPU scaling driver Date: Fri, 4 May 2018 22:20:17 +0300 Message-ID: <007601d3e3dc$f7454a60$e5cfdf20$@codeaurora.org> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Outlook 16.0 Thread-Index: AQIw4YufeDUO1xSdYb5xrMmiursktAKqm3zYAYB5uIMCqLXAuQHA6QnsoyFQp7A= Content-Language: en-us Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > -----Original Message----- > From: Viresh Kumar > Sent: Friday, May 4, 2018 09:57 > To: ilialin@codeaurora.org > Cc: mturquette@baylibre.com; sboyd@kernel.org; robh@kernel.org; > mark.rutland@arm.com; rjw@rjwysocki.net; lgirdwood@gmail.com; > broonie@kernel.org; andy.gross@linaro.org; david.brown@linaro.org; > catalin.marinas@arm.com; will.deacon@arm.com; linux-clk@vger.kernel.org; > 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 v5 12/14] cpufreq: Add Kryo CPU scaling driver > > On 04-05-18, 09:44, ilialin@codeaurora.org wrote: > > > > > > > -----Original Message----- > > > From: Viresh Kumar > > > Sent: Friday, May 4, 2018 09:08 > > > To: Ilia Lin > > > Cc: mturquette@baylibre.com; sboyd@kernel.org; robh@kernel.org; > > > mark.rutland@arm.com; rjw@rjwysocki.net; lgirdwood@gmail.com; > > > broonie@kernel.org; andy.gross@linaro.org; david.brown@linaro.org; > > > catalin.marinas@arm.com; will.deacon@arm.com; > > > linux-clk@vger.kernel.org; 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 v5 12/14] cpufreq: Add Kryo CPU scaling driver > > > > > > On 03-05-18, 14:52, Ilia Lin wrote: > > > > In Certain QCOM SoCs like apq8096 and msm8996 that have KRYO > > > > processors, the CPU ferequencies subset and voltage value of each > > > > OPP varies based on the silicon variant in use. Qualcomm Process > > > > Voltage Scaling Tables defines the voltage and frequency value > > > > based on the msm-id in SMEM and speedbin blown in the efuse > combination. > > > > The qcom-cpufreq-kryo driver reads the msm-id and efuse value from > > > > the SoC to provide the OPP framework with required information. > > > > This is used to determine the voltage and frequency value for each > > > > OPP of > > > > operating-points-v2 table when it is parsed by the OPP framework. > > > > > > > > Signed-off-by: Ilia Lin > > > > --- > > > > drivers/cpufreq/Kconfig.arm | 11 +++ > > > > drivers/cpufreq/Makefile | 1 + > > > > drivers/cpufreq/cpufreq-dt-platdev.c | 3 + > > > > drivers/cpufreq/qcom-cpufreq-kryo.c | 153 > > > > +++++++++++++++++++++++++++++++++++ > > > > 4 files changed, 168 insertions(+) create mode 100644 > > > > drivers/cpufreq/qcom-cpufreq-kryo.c > > > > > > > > diff --git a/drivers/cpufreq/Kconfig.arm > > > > b/drivers/cpufreq/Kconfig.arm index de55c7d..f9da18c 100644 > > > > --- a/drivers/cpufreq/Kconfig.arm > > > > +++ b/drivers/cpufreq/Kconfig.arm > > > > @@ -124,6 +124,17 @@ config ARM_OMAP2PLUS_CPUFREQ > > > > depends on ARCH_OMAP2PLUS > > > > default ARCH_OMAP2PLUS > > > > > > > > +config ARM_QCOM_CPUFREQ_KRYO > > > > + tristate "Qualcomm Technologies, Inc. Kryo based CPUFreq" > > > > > > I don't see any reply to Sricharan's query on this being tristate. > > > > Why shouldn't we leave possibility to compile the cpufreq-dt built-in, > > and the qcom-cpufreq-kryo module? > > I was not saying this is incorrect, all I am saying is that you never replied to a > comment from one of the reviewers. > > And I don't see a reason why this should be a tristate really. > cpufreq-dt is already capable of being a module, all your driver does is that it > creates the cpufreq-dt platform device after setting the OPP hw properties.. > > Over that, have you ever tried inserting, then removing and inserting the > driver module again? I feel it will fail. > > The reason is that you never provided an exit routine which can get rid of the > platform device created in the first place. Convinced. I'll change it to bool. > > > > > + depends on QCOM_QFPROM > > > > + depends on QCOM_SMEM > > > > + select PM_OPP > > > > + help > > > > + This adds the CPUFreq driver for > > > > + Qualcomm Technologies, Inc. Kryo SoC based boards. > > > > + > > > > + If in doubt, say N. > > > > + > > > > config ARM_S3C_CPUFREQ > > > > bool > > > > help > > > > diff --git a/drivers/cpufreq/Makefile b/drivers/cpufreq/Makefile > > > > index 8d24ade..fb4a2ec 100644 > > > > --- a/drivers/cpufreq/Makefile > > > > +++ b/drivers/cpufreq/Makefile > > > > @@ -65,6 +65,7 @@ obj-$(CONFIG_MACH_MVEBU_V7) += > > > mvebu-cpufreq.o > > > > obj-$(CONFIG_ARM_OMAP2PLUS_CPUFREQ) += omap-cpufreq.o > > > > obj-$(CONFIG_ARM_PXA2xx_CPUFREQ) += pxa2xx-cpufreq.o > > > > obj-$(CONFIG_PXA3xx) += pxa3xx-cpufreq.o > > > > +obj-$(CONFIG_ARM_QCOM_CPUFREQ_KRYO) += qcom-cpufreq- > > > kryo.o > > > > obj-$(CONFIG_ARM_S3C2410_CPUFREQ) += s3c2410-cpufreq.o > > > > obj-$(CONFIG_ARM_S3C2412_CPUFREQ) += s3c2412-cpufreq.o > > > > obj-$(CONFIG_ARM_S3C2416_CPUFREQ) += s3c2416-cpufreq.o > > > > diff --git a/drivers/cpufreq/cpufreq-dt-platdev.c > > > > b/drivers/cpufreq/cpufreq-dt-platdev.c > > > > index 3b585e4..77d6ab8 100644 > > > > --- a/drivers/cpufreq/cpufreq-dt-platdev.c > > > > +++ b/drivers/cpufreq/cpufreq-dt-platdev.c > > > > @@ -118,6 +118,9 @@ > > > > > > > > { .compatible = "nvidia,tegra124", }, > > > > > > > > + { .compatible = "qcom,apq8096", }, > > > > + { .compatible = "qcom,msm8996", }, > > > > + > > > > { .compatible = "st,stih407", }, > > > > { .compatible = "st,stih410", }, > > > > > > > > diff --git a/drivers/cpufreq/qcom-cpufreq-kryo.c > > > > b/drivers/cpufreq/qcom-cpufreq-kryo.c > > > > new file mode 100644 > > > > index 0000000..32371cc > > > > --- /dev/null > > > > +++ b/drivers/cpufreq/qcom-cpufreq-kryo.c > > > > @@ -0,0 +1,153 @@ > > > > +// SPDX-License-Identifier: GPL-2.0 > > > > +/* Copyright (c) 2018, The Linux Foundation. All rights reserved. > > > > > > Incorrect multi line comment. > > > > This was done as per Bjorn's instruction. > > You haven't followed him correctly. > > What he asked for is: > > // SPDX... > /* > * XXXX > */ > > What you have done is: > > // SPDX... > /* XXXX > */ OK. Got you. Will fix. > > -- > viresh