| 1 |
/* SPDX-License-Identifier: GPL-2.0-only */ |
| 2 |
/* |
| 3 |
* Copyright (c) 2022 MediaTek Inc. |
| 4 |
* Author: Edward-JW Yang <[email protected]> |
| 5 |
*/ |
| 6 |
|
| 7 |
#ifndef __CLK_FHCTL_H |
| 8 |
#define __CLK_FHCTL_H |
| 9 |
|
| 10 |
#include "clk-pllfh.h" |
| 11 |
|
| 12 |
enum fhctl_variant { |
| 13 |
FHCTL_PLLFH_V1, |
| 14 |
FHCTL_PLLFH_V2, |
| 15 |
}; |
| 16 |
|
| 17 |
struct fhctl_offset { |
| 18 |
u32 offset_hp_en; |
| 19 |
u32 offset_clk_con; |
| 20 |
u32 offset_rst_con; |
| 21 |
u32 offset_slope0; |
| 22 |
u32 offset_slope1; |
| 23 |
u32 offset_cfg; |
| 24 |
u32 offset_updnlmt; |
| 25 |
u32 offset_dds; |
| 26 |
u32 offset_dvfs; |
| 27 |
u32 offset_mon; |
| 28 |
}; |
| 29 |
const struct fhctl_offset *fhctl_get_offset_table(enum fhctl_variant v); |
| 30 |
const struct fh_operation *fhctl_get_ops(void); |
| 31 |
void fhctl_hw_init(struct mtk_fh *fh); |
| 32 |
|
| 33 |
#endif |