Skip to content

Commit

Permalink
clk: imx8qxp: Support building i.MX8QXP clock driver as module
Browse files Browse the repository at this point in the history
Change configuration to "tristate", add module author, description and
license to support building i.MX8QXP clock drivers as module.

Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
Reviewed-by: Stephen Boyd <sboyd@kernel.org>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
  • Loading branch information
Anson Huang authored and Shawn Guo committed Aug 22, 2020
1 parent 9a976cd commit e0d0d4d
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 9 deletions.
10 changes: 6 additions & 4 deletions drivers/clk/imx/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,9 @@ config MXC_CLK
depends on ARCH_MXC || COMPILE_TEST

config MXC_CLK_SCU
bool
depends on IMX_SCU
tristate "IMX SCU clock"
depends on ARCH_MXC || COMPILE_TEST
depends on IMX_SCU && HAVE_ARM_SMCCC

config CLK_IMX1
def_bool SOC_IMX1
Expand Down Expand Up @@ -97,8 +98,9 @@ config CLK_IMX8MQ
Build the driver for i.MX8MQ CCM Clock Driver

config CLK_IMX8QXP
bool "IMX8QXP SCU Clock"
depends on ARCH_MXC && IMX_SCU && ARM64
tristate "IMX8QXP SCU Clock"
depends on (ARCH_MXC && ARM64) || COMPILE_TEST
depends on IMX_SCU && HAVE_ARM_SMCCC
select MXC_CLK_SCU
help
Build the driver for IMX8QXP SCU based clocks.
9 changes: 4 additions & 5 deletions drivers/clk/imx/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,14 @@ mxc-clk-objs += clk-pll14xx.o
mxc-clk-objs += clk-sscg-pll.o
obj-$(CONFIG_MXC_CLK) += mxc-clk.o

obj-$(CONFIG_MXC_CLK_SCU) += \
clk-scu.o \
clk-lpcg-scu.o

obj-$(CONFIG_CLK_IMX8MM) += clk-imx8mm.o
obj-$(CONFIG_CLK_IMX8MN) += clk-imx8mn.o
obj-$(CONFIG_CLK_IMX8MP) += clk-imx8mp.o
obj-$(CONFIG_CLK_IMX8MQ) += clk-imx8mq.o
obj-$(CONFIG_CLK_IMX8QXP) += clk-imx8qxp.o clk-imx8qxp-lpcg.o

obj-$(CONFIG_MXC_CLK_SCU) += clk-imx-scu.o clk-imx-lpcg-scu.o
clk-imx-scu-$(CONFIG_CLK_IMX8QXP) += clk-scu.o clk-imx8qxp.o
clk-imx-lpcg-scu-$(CONFIG_CLK_IMX8QXP) += clk-lpcg-scu.o clk-imx8qxp-lpcg.o

obj-$(CONFIG_CLK_IMX1) += clk-imx1.o
obj-$(CONFIG_CLK_IMX21) += clk-imx21.o
Expand Down
4 changes: 4 additions & 0 deletions drivers/clk/imx/clk-imx8qxp-lpcg.c
Original file line number Diff line number Diff line change
Expand Up @@ -232,3 +232,7 @@ static struct platform_driver imx8qxp_lpcg_clk_driver = {
};

builtin_platform_driver(imx8qxp_lpcg_clk_driver);

MODULE_AUTHOR("Aisheng Dong <aisheng.dong@nxp.com>");
MODULE_DESCRIPTION("NXP i.MX8QXP LPCG clock driver");
MODULE_LICENSE("GPL v2");
4 changes: 4 additions & 0 deletions drivers/clk/imx/clk-imx8qxp.c
Original file line number Diff line number Diff line change
Expand Up @@ -152,3 +152,7 @@ static struct platform_driver imx8qxp_clk_driver = {
.probe = imx8qxp_clk_probe,
};
builtin_platform_driver(imx8qxp_clk_driver);

MODULE_AUTHOR("Aisheng Dong <aisheng.dong@nxp.com>");
MODULE_DESCRIPTION("NXP i.MX8QXP clock driver");
MODULE_LICENSE("GPL v2");

0 comments on commit e0d0d4d

Please sign in to comment.