Skip to contentSkip to conversation

Add Global clock controller support for IPQ6018

PATCH Superseded Sricharan R 3 participants 7 messages Jan 3, 2020 – Jan 6, 2020

Subsystems (6)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

cover Add Global clock controller support for IPQ6018

The IPQ6018 is Qualcomm’s 802.11ax SoC for Routers, Gateways and Access Points.

This series adds Global clock controller support for ipq6018.

The patches were a part of https://patchwork.kernel.org/cover/11303075/,
now moved it outside based on Stephen's suggestion.

Sricharan R (2):
clk: qcom: Add DT bindings for ipq6018 gcc clock controller
clk: qcom: Add ipq6018 Global Clock Controller support

 .../devicetree/bindings/clock/qcom,gcc.yaml        |    3 +-
 drivers/clk/qcom/Kconfig                           |    8 +
 drivers/clk/qcom/Makefile                          |    1 +
 drivers/clk/qcom/gcc-ipq6018.c                     | 4643 ++++++++++++++++++++
 include/dt-bindings/clock/qcom,gcc-ipq6018.h       |  262 ++
 include/dt-bindings/reset/qcom,gcc-ipq6018.h       |  157 +
 6 files changed, 5073 insertions(+), 1 deletion(-)
 create mode 100644 drivers/clk/qcom/gcc-ipq6018.c
 create mode 100644 include/dt-bindings/clock/qcom,gcc-ipq6018.h
 create mode 100644 include/dt-bindings/reset/qcom,gcc-ipq6018.h
Signature · 1 line
1.9.1
#1 lore raw

PATCH 1/2 clk: qcom: Add DT bindings for ipq6018 gcc clock controller

Add the compatible strings and the include file for ipq6018 gcc clock controller.

---
 .../devicetree/bindings/clock/qcom,gcc.yaml        |   3 +-
 include/dt-bindings/clock/qcom,gcc-ipq6018.h       | 262 +++++++++++++++++++++
 include/dt-bindings/reset/qcom,gcc-ipq6018.h       | 157 ++++++++++++
 3 files changed, 421 insertions(+), 1 deletion(-)
 create mode 100644 include/dt-bindings/clock/qcom,gcc-ipq6018.h
 create mode 100644 include/dt-bindings/reset/qcom,gcc-ipq6018.h
Documentation/devicetree/bindings/clock/qcom,gcc.yaml +2 -1
index e73a56f..e67341a 100644
@@ -19,8 +19,9 @@ properties:
     enum:
        - qcom,gcc-apq8064
        - qcom,gcc-apq8084
-       - qcom,gcc-ipq8064
        - qcom,gcc-ipq4019
+       - qcom,gcc-ipq6018
+       - qcom,gcc-ipq8064
        - qcom,gcc-ipq8074
        - qcom,gcc-msm8660
        - qcom,gcc-msm8916
include/dt-bindings/clock/qcom,gcc-ipq6018.h new file +262 -0

262 lines not on this page · raw message

include/dt-bindings/reset/qcom,gcc-ipq6018.h new file +157 -0

157 lines not on this page · raw message

Signature · 1 line
QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, hosted by The Linux Foundation
#2 lore raw

PATCH 2/2 clk: qcom: Add ipq6018 Global Clock Controller support

In reply to Sricharan R

This patch adds support for the global clock controller found on the ipq6018 based devices.

---
 drivers/clk/qcom/Kconfig       |    7 +
 drivers/clk/qcom/Makefile      |    1 +
 drivers/clk/qcom/gcc-ipq6018.c | 4635 ++++++++++++++++++++++++++++++++++++++++
 3 files changed, 4643 insertions(+)
 create mode 100644 drivers/clk/qcom/gcc-ipq6018.c
drivers/clk/qcom/Kconfig +7 -0
index 3b33ef1..bc9972b 100644
@@ -95,6 +95,13 @@ config IPQ_GCC_4019
 	  Say Y if you want to use peripheral devices such as UART, SPI,
 	  i2c, USB, SD/eMMC, etc.
 
+config IPQ_GCC_6018
+	tristate "IPQ6018 Global Clock Controller"
+	help
+	  Support for global clock controller on ipq6018 devices.
+	  Say Y if you want to use peripheral devices such as UART, SPI,
+	  i2c, USB, SD/eMMC, etc.
+
 config IPQ_GCC_806X
 	tristate "IPQ806x Global Clock Controller"
 	help
drivers/clk/qcom/Makefile +1 -0
index d899661..546275b 100644
@@ -20,6 +20,7 @@ clk-qcom-$(CONFIG_QCOM_GDSC) += gdsc.o
 obj-$(CONFIG_APQ_GCC_8084) += gcc-apq8084.o
 obj-$(CONFIG_APQ_MMCC_8084) += mmcc-apq8084.o
 obj-$(CONFIG_IPQ_GCC_4019) += gcc-ipq4019.o
+obj-$(CONFIG_IPQ_GCC_6018) += gcc-ipq6018.o
 obj-$(CONFIG_IPQ_GCC_806X) += gcc-ipq806x.o
 obj-$(CONFIG_IPQ_GCC_8074) += gcc-ipq8074.o
 obj-$(CONFIG_IPQ_LCC_806X) += lcc-ipq806x.o
drivers/clk/qcom/gcc-ipq6018.c new file +4635 -0

2,980 lines not on this page · raw message

The rest of this diff is not shown. View the raw message.

Signature · 1 line
QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, hosted by The Linux Foundation

Part of the diff is not shown here. View the raw message.

#3 lore raw

Re: [PATCH 2/2] clk: qcom: Add ipq6018 Global Clock Controller support

Thank you for the patch! Perhaps something to improve:

Hi Sricharan,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on clk/clk-next]
[also build test WARNING on v5.5-rc4 next-20191220]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982]

url:    https://github.com/0day-ci/linux/commits/Sricharan-R/Add-Global-clock-controller-support-for-IPQ6018/20200104-133041
base:   https://git.kernel.org/pub/scm/linux/kernel/git/clk/linux.git clk-next
reproduce:
        # apt-get install sparse
        # sparse version: v0.6.1-129-g341daf20-dirty
        make ARCH=x86_64 allmodconfig
        make C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__'

If you fix the issue, kindly add following tag

sparse warnings: (new ones prefixed by >>)

>> drivers/clk/qcom/gcc-ipq6018.c:2623:17: sparse: sparse: symbol 'lpass_core_axim_clk_src' was not declared. Should it be static?
>> drivers/clk/qcom/gcc-ipq6018.c:2642:17: sparse: sparse: symbol 'lpass_snoc_cfg_clk_src' was not declared. Should it be static?
>> drivers/clk/qcom/gcc-ipq6018.c:2661:17: sparse: sparse: symbol 'lpass_q6_axim_clk_src' was not declared. Should it be static?
>> drivers/clk/qcom/gcc-ipq6018.c:2674:17: sparse: sparse: symbol 'ftbl_rbcpr_wcss_clk_src' was not declared. Should it be static?
>> drivers/clk/qcom/gcc-ipq6018.c:2680:17: sparse: sparse: symbol 'rbcpr_wcss_clk_src' was not declared. Should it be static?

Please review and possibly fold the followup patch.

---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org Intel Corporation

#4 lore raw

[RFC PATCH] clk: qcom: lpass_core_axim_clk_src can be static

In reply to Sricharan R
Fixes: ac86608aeb82 ("clk: qcom: Add ipq6018 Global Clock Controller support")
Fixes ac86608aeb82 ("clk: qcom: Add ipq6018 Global Clock Controller support")
---
 gcc-ipq6018.c |   10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
drivers/clk/qcom/gcc-ipq6018.c +5 -5
index a3597f46ad017..3f9c2f61a5d93 100644
@@ -2620,7 +2620,7 @@ static const struct freq_tbl ftbl_lpass_core_axim_clk_src[] = {
 	{ }
 };
 
-struct clk_rcg2 lpass_core_axim_clk_src = {
+static struct clk_rcg2 lpass_core_axim_clk_src = {
 	.cmd_rcgr = 0x1F020,
 	.freq_tbl = ftbl_lpass_core_axim_clk_src,
 	.hid_width = 5,
@@ -2639,7 +2639,7 @@ static const struct freq_tbl ftbl_lpass_snoc_cfg_clk_src[] = {
 	{ }
 };
 
-struct clk_rcg2 lpass_snoc_cfg_clk_src = {
+static struct clk_rcg2 lpass_snoc_cfg_clk_src = {
 	.cmd_rcgr = 0x1F040,
 	.freq_tbl = ftbl_lpass_snoc_cfg_clk_src,
 	.hid_width = 5,
@@ -2658,7 +2658,7 @@ static const struct freq_tbl ftbl_lpass_q6_axim_clk_src[] = {
 	{ }
 };
 
-struct clk_rcg2 lpass_q6_axim_clk_src = {
+static struct clk_rcg2 lpass_q6_axim_clk_src = {
 	.cmd_rcgr = 0x1F008,
 	.freq_tbl = ftbl_lpass_q6_axim_clk_src,
 	.hid_width = 5,
@@ -2671,13 +2671,13 @@ struct clk_rcg2 lpass_q6_axim_clk_src = {
 	},
 };
 
-struct freq_tbl ftbl_rbcpr_wcss_clk_src[] = {
+static struct freq_tbl ftbl_rbcpr_wcss_clk_src[] = {
 	F(24000000, P_XO, 1, 0, 0),
 	F(50000000, P_GPLL0, 16, 0, 0),
 	{ }
 };
 
-struct clk_rcg2 rbcpr_wcss_clk_src = {
+static struct clk_rcg2 rbcpr_wcss_clk_src = {
 	.cmd_rcgr = 0x3a00c,
 	.freq_tbl = ftbl_rbcpr_wcss_clk_src,
 	.hid_width = 5,
maintainer
#5 lore raw
In reply to Sricharan R

Quoting Sricharan R (2020-01-03 03:25:42)

Quoted 4 lines

The IPQ6018 is Qualcomm\u2019s 802.11ax SoC for Routers, Gateways and Access Points.

This series adds Global clock controller support for ipq6018.

Can you fold the fixes in?

Quoted 3 lines

The patches were a part of https://patchwork.kernel.org/cover/11303075/,
now moved it outside based on Stephen's suggestion.

Thanks, but I still got the other pinctrl patches :(

#6 lore raw

Hi Stephen,

Quoted 8 lines · Stephen Boyd

Quoting Sricharan R (2020-01-03 03:25:42)

Quoted 4 lines

The IPQ6018 is Qualcomm\u2019s 802.11ax SoC for Routers, Gateways and Access Points.

This series adds Global clock controller support for ipq6018.

Can you fold the fixes in?

Sure, will do and resend.

Quoted 6 lines
Quoted 3 lines

The patches were a part of https://patchwork.kernel.org/cover/11303075/,
now moved it outside based on Stephen's suggestion.

Thanks, but I still got the other pinctrl patches :(

ho, will remove you from CC on those.

Regards,
Sricharan

Signature · 1 line
"QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, hosted by The Linux Foundation