printf: Remove unused 'bprintf'
[drm/drm-misc.git] / drivers / clk / mediatek / clk-mt8188-mfg.c
blob2ddfb1a3de471eea595bfb4bb12b1ec99b6aad5b
1 // SPDX-License-Identifier: GPL-2.0-only
2 /*
3 * Copyright (c) 2022 MediaTek Inc.
4 * Author: Garmin Chang <garmin.chang@mediatek.com>
5 */
7 #include <dt-bindings/clock/mediatek,mt8188-clk.h>
8 #include <linux/clk-provider.h>
9 #include <linux/platform_device.h>
11 #include "clk-gate.h"
12 #include "clk-mtk.h"
14 static const struct mtk_gate_regs mfgcfg_cg_regs = {
15 .set_ofs = 0x4,
16 .clr_ofs = 0x8,
17 .sta_ofs = 0x0,
20 #define GATE_MFG(_id, _name, _parent, _shift) \
21 GATE_MTK_FLAGS(_id, _name, _parent, &mfgcfg_cg_regs, _shift, \
22 &mtk_clk_gate_ops_setclr, CLK_SET_RATE_PARENT)
24 static const struct mtk_gate mfgcfg_clks[] = {
25 GATE_MFG(CLK_MFGCFG_BG3D, "mfgcfg_bg3d", "mfg_ck_fast_ref", 0),
28 static const struct mtk_clk_desc mfgcfg_desc = {
29 .clks = mfgcfg_clks,
30 .num_clks = ARRAY_SIZE(mfgcfg_clks),
33 static const struct of_device_id of_match_clk_mt8188_mfgcfg[] = {
34 { .compatible = "mediatek,mt8188-mfgcfg", .data = &mfgcfg_desc },
35 { /* sentinel */ }
37 MODULE_DEVICE_TABLE(of, of_match_clk_mt8188_mfgcfg);
39 static struct platform_driver clk_mt8188_mfgcfg_drv = {
40 .probe = mtk_clk_simple_probe,
41 .remove = mtk_clk_simple_remove,
42 .driver = {
43 .name = "clk-mt8188-mfgcfg",
44 .of_match_table = of_match_clk_mt8188_mfgcfg,
48 module_platform_driver(clk_mt8188_mfgcfg_drv);
50 MODULE_DESCRIPTION("MediaTek MT8186 GPU mfg clocks driver");
51 MODULE_LICENSE("GPL");