18c2ecf20Sopenharmony_ci// SPDX-License-Identifier: GPL-2.0
28c2ecf20Sopenharmony_ci/*
38c2ecf20Sopenharmony_ci * Copyright (c) 2017-2020, The Linux Foundation. All rights reserved.
48c2ecf20Sopenharmony_ci */
58c2ecf20Sopenharmony_ci
68c2ecf20Sopenharmony_ci#include <linux/clk-provider.h>
78c2ecf20Sopenharmony_ci#include <linux/module.h>
88c2ecf20Sopenharmony_ci#include <linux/platform_device.h>
98c2ecf20Sopenharmony_ci#include <linux/regmap.h>
108c2ecf20Sopenharmony_ci
118c2ecf20Sopenharmony_ci#include <dt-bindings/clock/qcom,gpucc-sm8150.h>
128c2ecf20Sopenharmony_ci
138c2ecf20Sopenharmony_ci#include "common.h"
148c2ecf20Sopenharmony_ci#include "clk-alpha-pll.h"
158c2ecf20Sopenharmony_ci#include "clk-branch.h"
168c2ecf20Sopenharmony_ci#include "clk-pll.h"
178c2ecf20Sopenharmony_ci#include "clk-rcg.h"
188c2ecf20Sopenharmony_ci#include "clk-regmap.h"
198c2ecf20Sopenharmony_ci#include "reset.h"
208c2ecf20Sopenharmony_ci#include "gdsc.h"
218c2ecf20Sopenharmony_ci
228c2ecf20Sopenharmony_cienum {
238c2ecf20Sopenharmony_ci	P_BI_TCXO,
248c2ecf20Sopenharmony_ci	P_CORE_BI_PLL_TEST_SE,
258c2ecf20Sopenharmony_ci	P_GPLL0_OUT_MAIN,
268c2ecf20Sopenharmony_ci	P_GPLL0_OUT_MAIN_DIV,
278c2ecf20Sopenharmony_ci	P_GPU_CC_PLL1_OUT_MAIN,
288c2ecf20Sopenharmony_ci};
298c2ecf20Sopenharmony_ci
308c2ecf20Sopenharmony_cistatic const struct pll_vco trion_vco[] = {
318c2ecf20Sopenharmony_ci	{ 249600000, 2000000000, 0 },
328c2ecf20Sopenharmony_ci};
338c2ecf20Sopenharmony_ci
348c2ecf20Sopenharmony_cistatic struct alpha_pll_config gpu_cc_pll1_config = {
358c2ecf20Sopenharmony_ci	.l = 0x1a,
368c2ecf20Sopenharmony_ci	.alpha = 0xaaa,
378c2ecf20Sopenharmony_ci	.config_ctl_val = 0x20485699,
388c2ecf20Sopenharmony_ci	.config_ctl_hi_val = 0x00002267,
398c2ecf20Sopenharmony_ci	.config_ctl_hi1_val = 0x00000024,
408c2ecf20Sopenharmony_ci	.test_ctl_val = 0x00000000,
418c2ecf20Sopenharmony_ci	.test_ctl_hi_val = 0x00000000,
428c2ecf20Sopenharmony_ci	.test_ctl_hi1_val = 0x00000020,
438c2ecf20Sopenharmony_ci	.user_ctl_val = 0x00000000,
448c2ecf20Sopenharmony_ci	.user_ctl_hi_val = 0x00000805,
458c2ecf20Sopenharmony_ci	.user_ctl_hi1_val = 0x000000d0,
468c2ecf20Sopenharmony_ci};
478c2ecf20Sopenharmony_ci
488c2ecf20Sopenharmony_cistatic struct clk_alpha_pll gpu_cc_pll1 = {
498c2ecf20Sopenharmony_ci	.offset = 0x100,
508c2ecf20Sopenharmony_ci	.vco_table = trion_vco,
518c2ecf20Sopenharmony_ci	.num_vco = ARRAY_SIZE(trion_vco),
528c2ecf20Sopenharmony_ci	.regs = clk_alpha_pll_regs[CLK_ALPHA_PLL_TYPE_TRION],
538c2ecf20Sopenharmony_ci	.clkr = {
548c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
558c2ecf20Sopenharmony_ci			.name = "gpu_cc_pll1",
568c2ecf20Sopenharmony_ci			.parent_data =  &(const struct clk_parent_data){
578c2ecf20Sopenharmony_ci				.fw_name = "bi_tcxo",
588c2ecf20Sopenharmony_ci			},
598c2ecf20Sopenharmony_ci			.num_parents = 1,
608c2ecf20Sopenharmony_ci			.ops = &clk_alpha_pll_trion_ops,
618c2ecf20Sopenharmony_ci		},
628c2ecf20Sopenharmony_ci	},
638c2ecf20Sopenharmony_ci};
648c2ecf20Sopenharmony_ci
658c2ecf20Sopenharmony_cistatic const struct parent_map gpu_cc_parent_map_0[] = {
668c2ecf20Sopenharmony_ci	{ P_BI_TCXO, 0 },
678c2ecf20Sopenharmony_ci	{ P_GPU_CC_PLL1_OUT_MAIN, 3 },
688c2ecf20Sopenharmony_ci	{ P_GPLL0_OUT_MAIN, 5 },
698c2ecf20Sopenharmony_ci	{ P_GPLL0_OUT_MAIN_DIV, 6 },
708c2ecf20Sopenharmony_ci};
718c2ecf20Sopenharmony_ci
728c2ecf20Sopenharmony_cistatic const struct clk_parent_data gpu_cc_parent_data_0[] = {
738c2ecf20Sopenharmony_ci	{ .fw_name = "bi_tcxo" },
748c2ecf20Sopenharmony_ci	{ .hw = &gpu_cc_pll1.clkr.hw },
758c2ecf20Sopenharmony_ci	{ .fw_name = "gcc_gpu_gpll0_clk_src" },
768c2ecf20Sopenharmony_ci	{ .fw_name = "gcc_gpu_gpll0_div_clk_src" },
778c2ecf20Sopenharmony_ci};
788c2ecf20Sopenharmony_ci
798c2ecf20Sopenharmony_cistatic const struct freq_tbl ftbl_gpu_cc_gmu_clk_src[] = {
808c2ecf20Sopenharmony_ci	F(19200000, P_BI_TCXO, 1, 0, 0),
818c2ecf20Sopenharmony_ci	F(200000000, P_GPLL0_OUT_MAIN_DIV, 1.5, 0, 0),
828c2ecf20Sopenharmony_ci	F(500000000, P_GPU_CC_PLL1_OUT_MAIN, 1, 0, 0),
838c2ecf20Sopenharmony_ci	{ }
848c2ecf20Sopenharmony_ci};
858c2ecf20Sopenharmony_ci
868c2ecf20Sopenharmony_cistatic struct clk_rcg2 gpu_cc_gmu_clk_src = {
878c2ecf20Sopenharmony_ci	.cmd_rcgr = 0x1120,
888c2ecf20Sopenharmony_ci	.mnd_width = 0,
898c2ecf20Sopenharmony_ci	.hid_width = 5,
908c2ecf20Sopenharmony_ci	.parent_map = gpu_cc_parent_map_0,
918c2ecf20Sopenharmony_ci	.freq_tbl = ftbl_gpu_cc_gmu_clk_src,
928c2ecf20Sopenharmony_ci	.clkr.hw.init = &(struct clk_init_data){
938c2ecf20Sopenharmony_ci		.name = "gpu_cc_gmu_clk_src",
948c2ecf20Sopenharmony_ci		.parent_data = gpu_cc_parent_data_0,
958c2ecf20Sopenharmony_ci		.num_parents = ARRAY_SIZE(gpu_cc_parent_data_0),
968c2ecf20Sopenharmony_ci		.flags = CLK_SET_RATE_PARENT,
978c2ecf20Sopenharmony_ci		.ops = &clk_rcg2_ops,
988c2ecf20Sopenharmony_ci	},
998c2ecf20Sopenharmony_ci};
1008c2ecf20Sopenharmony_ci
1018c2ecf20Sopenharmony_cistatic struct clk_branch gpu_cc_ahb_clk = {
1028c2ecf20Sopenharmony_ci	.halt_reg = 0x1078,
1038c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT_DELAY,
1048c2ecf20Sopenharmony_ci	.clkr = {
1058c2ecf20Sopenharmony_ci		.enable_reg = 0x1078,
1068c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
1078c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
1088c2ecf20Sopenharmony_ci			.name = "gpu_cc_ahb_clk",
1098c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
1108c2ecf20Sopenharmony_ci		},
1118c2ecf20Sopenharmony_ci	},
1128c2ecf20Sopenharmony_ci};
1138c2ecf20Sopenharmony_ci
1148c2ecf20Sopenharmony_cistatic struct clk_branch gpu_cc_crc_ahb_clk = {
1158c2ecf20Sopenharmony_ci	.halt_reg = 0x107c,
1168c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
1178c2ecf20Sopenharmony_ci	.clkr = {
1188c2ecf20Sopenharmony_ci		.enable_reg = 0x107c,
1198c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
1208c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
1218c2ecf20Sopenharmony_ci			.name = "gpu_cc_crc_ahb_clk",
1228c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
1238c2ecf20Sopenharmony_ci		},
1248c2ecf20Sopenharmony_ci	},
1258c2ecf20Sopenharmony_ci};
1268c2ecf20Sopenharmony_ci
1278c2ecf20Sopenharmony_cistatic struct clk_branch gpu_cc_cx_apb_clk = {
1288c2ecf20Sopenharmony_ci	.halt_reg = 0x1088,
1298c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
1308c2ecf20Sopenharmony_ci	.clkr = {
1318c2ecf20Sopenharmony_ci		.enable_reg = 0x1088,
1328c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
1338c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
1348c2ecf20Sopenharmony_ci			.name = "gpu_cc_cx_apb_clk",
1358c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
1368c2ecf20Sopenharmony_ci		},
1378c2ecf20Sopenharmony_ci	},
1388c2ecf20Sopenharmony_ci};
1398c2ecf20Sopenharmony_ci
1408c2ecf20Sopenharmony_cistatic struct clk_branch gpu_cc_cx_gmu_clk = {
1418c2ecf20Sopenharmony_ci	.halt_reg = 0x1098,
1428c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
1438c2ecf20Sopenharmony_ci	.clkr = {
1448c2ecf20Sopenharmony_ci		.enable_reg = 0x1098,
1458c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
1468c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
1478c2ecf20Sopenharmony_ci			.name = "gpu_cc_cx_gmu_clk",
1488c2ecf20Sopenharmony_ci			.parent_data =  &(const struct clk_parent_data){
1498c2ecf20Sopenharmony_ci				.hw = &gpu_cc_gmu_clk_src.clkr.hw,
1508c2ecf20Sopenharmony_ci			},
1518c2ecf20Sopenharmony_ci			.num_parents = 1,
1528c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
1538c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
1548c2ecf20Sopenharmony_ci		},
1558c2ecf20Sopenharmony_ci	},
1568c2ecf20Sopenharmony_ci};
1578c2ecf20Sopenharmony_ci
1588c2ecf20Sopenharmony_cistatic struct clk_branch gpu_cc_cx_snoc_dvm_clk = {
1598c2ecf20Sopenharmony_ci	.halt_reg = 0x108c,
1608c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
1618c2ecf20Sopenharmony_ci	.clkr = {
1628c2ecf20Sopenharmony_ci		.enable_reg = 0x108c,
1638c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
1648c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
1658c2ecf20Sopenharmony_ci			.name = "gpu_cc_cx_snoc_dvm_clk",
1668c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
1678c2ecf20Sopenharmony_ci		},
1688c2ecf20Sopenharmony_ci	},
1698c2ecf20Sopenharmony_ci};
1708c2ecf20Sopenharmony_ci
1718c2ecf20Sopenharmony_cistatic struct clk_branch gpu_cc_cxo_aon_clk = {
1728c2ecf20Sopenharmony_ci	.halt_reg = 0x1004,
1738c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
1748c2ecf20Sopenharmony_ci	.clkr = {
1758c2ecf20Sopenharmony_ci		.enable_reg = 0x1004,
1768c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
1778c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
1788c2ecf20Sopenharmony_ci			.name = "gpu_cc_cxo_aon_clk",
1798c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
1808c2ecf20Sopenharmony_ci		},
1818c2ecf20Sopenharmony_ci	},
1828c2ecf20Sopenharmony_ci};
1838c2ecf20Sopenharmony_ci
1848c2ecf20Sopenharmony_cistatic struct clk_branch gpu_cc_cxo_clk = {
1858c2ecf20Sopenharmony_ci	.halt_reg = 0x109c,
1868c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
1878c2ecf20Sopenharmony_ci	.clkr = {
1888c2ecf20Sopenharmony_ci		.enable_reg = 0x109c,
1898c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
1908c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
1918c2ecf20Sopenharmony_ci			.name = "gpu_cc_cxo_clk",
1928c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
1938c2ecf20Sopenharmony_ci		},
1948c2ecf20Sopenharmony_ci	},
1958c2ecf20Sopenharmony_ci};
1968c2ecf20Sopenharmony_ci
1978c2ecf20Sopenharmony_cistatic struct clk_branch gpu_cc_gx_gmu_clk = {
1988c2ecf20Sopenharmony_ci	.halt_reg = 0x1064,
1998c2ecf20Sopenharmony_ci	.halt_check = BRANCH_HALT,
2008c2ecf20Sopenharmony_ci	.clkr = {
2018c2ecf20Sopenharmony_ci		.enable_reg = 0x1064,
2028c2ecf20Sopenharmony_ci		.enable_mask = BIT(0),
2038c2ecf20Sopenharmony_ci		.hw.init = &(struct clk_init_data){
2048c2ecf20Sopenharmony_ci			.name = "gpu_cc_gx_gmu_clk",
2058c2ecf20Sopenharmony_ci			.parent_data =  &(const struct clk_parent_data){
2068c2ecf20Sopenharmony_ci				.hw = &gpu_cc_gmu_clk_src.clkr.hw,
2078c2ecf20Sopenharmony_ci			},
2088c2ecf20Sopenharmony_ci			.num_parents = 1,
2098c2ecf20Sopenharmony_ci			.flags = CLK_SET_RATE_PARENT,
2108c2ecf20Sopenharmony_ci			.ops = &clk_branch2_ops,
2118c2ecf20Sopenharmony_ci		},
2128c2ecf20Sopenharmony_ci	},
2138c2ecf20Sopenharmony_ci};
2148c2ecf20Sopenharmony_ci
2158c2ecf20Sopenharmony_cistatic struct gdsc gpu_cx_gdsc = {
2168c2ecf20Sopenharmony_ci	.gdscr = 0x106c,
2178c2ecf20Sopenharmony_ci	.gds_hw_ctrl = 0x1540,
2188c2ecf20Sopenharmony_ci	.pd = {
2198c2ecf20Sopenharmony_ci		.name = "gpu_cx_gdsc",
2208c2ecf20Sopenharmony_ci	},
2218c2ecf20Sopenharmony_ci	.pwrsts = PWRSTS_OFF_ON,
2228c2ecf20Sopenharmony_ci	.flags = VOTABLE,
2238c2ecf20Sopenharmony_ci};
2248c2ecf20Sopenharmony_ci
2258c2ecf20Sopenharmony_cistatic struct gdsc gpu_gx_gdsc = {
2268c2ecf20Sopenharmony_ci	.gdscr = 0x100c,
2278c2ecf20Sopenharmony_ci	.clamp_io_ctrl = 0x1508,
2288c2ecf20Sopenharmony_ci	.pd = {
2298c2ecf20Sopenharmony_ci		.name = "gpu_gx_gdsc",
2308c2ecf20Sopenharmony_ci		.power_on = gdsc_gx_do_nothing_enable,
2318c2ecf20Sopenharmony_ci	},
2328c2ecf20Sopenharmony_ci	.pwrsts = PWRSTS_OFF_ON,
2338c2ecf20Sopenharmony_ci	.flags = CLAMP_IO | AON_RESET | POLL_CFG_GDSCR,
2348c2ecf20Sopenharmony_ci};
2358c2ecf20Sopenharmony_ci
2368c2ecf20Sopenharmony_cistatic struct clk_regmap *gpu_cc_sm8150_clocks[] = {
2378c2ecf20Sopenharmony_ci	[GPU_CC_AHB_CLK] = &gpu_cc_ahb_clk.clkr,
2388c2ecf20Sopenharmony_ci	[GPU_CC_CRC_AHB_CLK] = &gpu_cc_crc_ahb_clk.clkr,
2398c2ecf20Sopenharmony_ci	[GPU_CC_CX_APB_CLK] = &gpu_cc_cx_apb_clk.clkr,
2408c2ecf20Sopenharmony_ci	[GPU_CC_CX_GMU_CLK] = &gpu_cc_cx_gmu_clk.clkr,
2418c2ecf20Sopenharmony_ci	[GPU_CC_CX_SNOC_DVM_CLK] = &gpu_cc_cx_snoc_dvm_clk.clkr,
2428c2ecf20Sopenharmony_ci	[GPU_CC_CXO_AON_CLK] = &gpu_cc_cxo_aon_clk.clkr,
2438c2ecf20Sopenharmony_ci	[GPU_CC_CXO_CLK] = &gpu_cc_cxo_clk.clkr,
2448c2ecf20Sopenharmony_ci	[GPU_CC_GMU_CLK_SRC] = &gpu_cc_gmu_clk_src.clkr,
2458c2ecf20Sopenharmony_ci	[GPU_CC_GX_GMU_CLK] = &gpu_cc_gx_gmu_clk.clkr,
2468c2ecf20Sopenharmony_ci	[GPU_CC_PLL1] = &gpu_cc_pll1.clkr,
2478c2ecf20Sopenharmony_ci};
2488c2ecf20Sopenharmony_ci
2498c2ecf20Sopenharmony_cistatic const struct qcom_reset_map gpu_cc_sm8150_resets[] = {
2508c2ecf20Sopenharmony_ci	[GPUCC_GPU_CC_CX_BCR] = { 0x1068 },
2518c2ecf20Sopenharmony_ci	[GPUCC_GPU_CC_GMU_BCR] = { 0x111c },
2528c2ecf20Sopenharmony_ci	[GPUCC_GPU_CC_GX_BCR] = { 0x1008 },
2538c2ecf20Sopenharmony_ci	[GPUCC_GPU_CC_SPDM_BCR] = { 0x1110 },
2548c2ecf20Sopenharmony_ci	[GPUCC_GPU_CC_XO_BCR] = { 0x1000 },
2558c2ecf20Sopenharmony_ci};
2568c2ecf20Sopenharmony_ci
2578c2ecf20Sopenharmony_cistatic struct gdsc *gpu_cc_sm8150_gdscs[] = {
2588c2ecf20Sopenharmony_ci	[GPU_CX_GDSC] = &gpu_cx_gdsc,
2598c2ecf20Sopenharmony_ci	[GPU_GX_GDSC] = &gpu_gx_gdsc,
2608c2ecf20Sopenharmony_ci};
2618c2ecf20Sopenharmony_ci
2628c2ecf20Sopenharmony_cistatic const struct regmap_config gpu_cc_sm8150_regmap_config = {
2638c2ecf20Sopenharmony_ci	.reg_bits	= 32,
2648c2ecf20Sopenharmony_ci	.reg_stride	= 4,
2658c2ecf20Sopenharmony_ci	.val_bits	= 32,
2668c2ecf20Sopenharmony_ci	.max_register	= 0x8008,
2678c2ecf20Sopenharmony_ci	.fast_io	= true,
2688c2ecf20Sopenharmony_ci};
2698c2ecf20Sopenharmony_ci
2708c2ecf20Sopenharmony_cistatic const struct qcom_cc_desc gpu_cc_sm8150_desc = {
2718c2ecf20Sopenharmony_ci	.config = &gpu_cc_sm8150_regmap_config,
2728c2ecf20Sopenharmony_ci	.clks = gpu_cc_sm8150_clocks,
2738c2ecf20Sopenharmony_ci	.num_clks = ARRAY_SIZE(gpu_cc_sm8150_clocks),
2748c2ecf20Sopenharmony_ci	.resets = gpu_cc_sm8150_resets,
2758c2ecf20Sopenharmony_ci	.num_resets = ARRAY_SIZE(gpu_cc_sm8150_resets),
2768c2ecf20Sopenharmony_ci	.gdscs = gpu_cc_sm8150_gdscs,
2778c2ecf20Sopenharmony_ci	.num_gdscs = ARRAY_SIZE(gpu_cc_sm8150_gdscs),
2788c2ecf20Sopenharmony_ci};
2798c2ecf20Sopenharmony_ci
2808c2ecf20Sopenharmony_cistatic const struct of_device_id gpu_cc_sm8150_match_table[] = {
2818c2ecf20Sopenharmony_ci	{ .compatible = "qcom,sm8150-gpucc" },
2828c2ecf20Sopenharmony_ci	{ }
2838c2ecf20Sopenharmony_ci};
2848c2ecf20Sopenharmony_ciMODULE_DEVICE_TABLE(of, gpu_cc_sm8150_match_table);
2858c2ecf20Sopenharmony_ci
2868c2ecf20Sopenharmony_cistatic int gpu_cc_sm8150_probe(struct platform_device *pdev)
2878c2ecf20Sopenharmony_ci{
2888c2ecf20Sopenharmony_ci	struct regmap *regmap;
2898c2ecf20Sopenharmony_ci
2908c2ecf20Sopenharmony_ci	regmap = qcom_cc_map(pdev, &gpu_cc_sm8150_desc);
2918c2ecf20Sopenharmony_ci	if (IS_ERR(regmap))
2928c2ecf20Sopenharmony_ci		return PTR_ERR(regmap);
2938c2ecf20Sopenharmony_ci
2948c2ecf20Sopenharmony_ci	clk_trion_pll_configure(&gpu_cc_pll1, regmap, &gpu_cc_pll1_config);
2958c2ecf20Sopenharmony_ci
2968c2ecf20Sopenharmony_ci	return qcom_cc_really_probe(pdev, &gpu_cc_sm8150_desc, regmap);
2978c2ecf20Sopenharmony_ci}
2988c2ecf20Sopenharmony_ci
2998c2ecf20Sopenharmony_cistatic struct platform_driver gpu_cc_sm8150_driver = {
3008c2ecf20Sopenharmony_ci	.probe = gpu_cc_sm8150_probe,
3018c2ecf20Sopenharmony_ci	.driver = {
3028c2ecf20Sopenharmony_ci		.name = "sm8150-gpucc",
3038c2ecf20Sopenharmony_ci		.of_match_table = gpu_cc_sm8150_match_table,
3048c2ecf20Sopenharmony_ci	},
3058c2ecf20Sopenharmony_ci};
3068c2ecf20Sopenharmony_ci
3078c2ecf20Sopenharmony_cistatic int __init gpu_cc_sm8150_init(void)
3088c2ecf20Sopenharmony_ci{
3098c2ecf20Sopenharmony_ci	return platform_driver_register(&gpu_cc_sm8150_driver);
3108c2ecf20Sopenharmony_ci}
3118c2ecf20Sopenharmony_cisubsys_initcall(gpu_cc_sm8150_init);
3128c2ecf20Sopenharmony_ci
3138c2ecf20Sopenharmony_cistatic void __exit gpu_cc_sm8150_exit(void)
3148c2ecf20Sopenharmony_ci{
3158c2ecf20Sopenharmony_ci	platform_driver_unregister(&gpu_cc_sm8150_driver);
3168c2ecf20Sopenharmony_ci}
3178c2ecf20Sopenharmony_cimodule_exit(gpu_cc_sm8150_exit);
3188c2ecf20Sopenharmony_ci
3198c2ecf20Sopenharmony_ciMODULE_DESCRIPTION("QTI GPUCC SM8150 Driver");
3208c2ecf20Sopenharmony_ciMODULE_LICENSE("GPL v2");
321