forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-05-10 61598093bbdd283a7edc367d900f223070ead8d2
kernel/drivers/clk/mediatek/clk-gate.h
....@@ -1,15 +1,7 @@
1
+/* SPDX-License-Identifier: GPL-2.0-only */
12 /*
23 * Copyright (c) 2014 MediaTek Inc.
34 * Author: James Liao <jamesjj.liao@mediatek.com>
4
- *
5
- * This program is free software; you can redistribute it and/or modify
6
- * it under the terms of the GNU General Public License version 2 as
7
- * published by the Free Software Foundation.
8
- *
9
- * This program is distributed in the hope that it will be useful,
10
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
11
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
- * GNU General Public License for more details.
135 */
146
157 #ifndef __DRV_CLK_GATE_H
....@@ -47,6 +39,22 @@
4739 int clr_ofs,
4840 int sta_ofs,
4941 u8 bit,
50
- const struct clk_ops *ops);
42
+ const struct clk_ops *ops,
43
+ unsigned long flags,
44
+ struct device *dev);
45
+
46
+#define GATE_MTK_FLAGS(_id, _name, _parent, _regs, _shift, \
47
+ _ops, _flags) { \
48
+ .id = _id, \
49
+ .name = _name, \
50
+ .parent_name = _parent, \
51
+ .regs = _regs, \
52
+ .shift = _shift, \
53
+ .ops = _ops, \
54
+ .flags = _flags, \
55
+ }
56
+
57
+#define GATE_MTK(_id, _name, _parent, _regs, _shift, _ops) \
58
+ GATE_MTK_FLAGS(_id, _name, _parent, _regs, _shift, _ops, 0)
5159
5260 #endif /* __DRV_CLK_GATE_H */