Files
threeeye bc1d038eac REVVL 6 Pro kernel bring-up: full working tree snapshot (2026-09-12)
Squashed backup commit (no shallow-clone history issues) of
xiaomi-mt6833-dev/kernel_xiaomi_mt6833 (lineage-23.2 branch, upstream
commit 9eece662e) plus all fixes applied to get everpal_defconfig building
clean against a modern (GCC 15.2.0) toolchain -- see the previous commit
message on the lineage-23.2 branch (also in this repo history is not
available here since this is a squashed snapshot; full incremental history
lives in the local DL380 checkout and the upstream GitHub remote).

Upstream: https://github.com/xiaomi-mt6833-dev/kernel_xiaomi_mt6833 (lineage-23.2)
2026-09-12 13:36:46 +00:00

71 lines
1.6 KiB
C

/* SPDX-License-Identifier: GPL-2.0 */
/*
* Copyright (c) 2020 MediaTek Inc.
* Author: Yu-Chang Wang <Yu-Chang.Wang@mediatek.com>
*/
#ifndef __CLK_FHCTL_PLL_H
#define __CLK_FHCTL_PLL_H
#include <linux/types.h>
#include <linux/bitops.h>
#include <linux/iopoll.h>
struct fh_pll_data {
char *name;
unsigned int dds_mask;
unsigned int slope0_value;
unsigned int slope1_value;
unsigned int sfstrx_en;
unsigned int frddsx_en;
unsigned int fhctlx_en;
unsigned int tgl_org;
unsigned int dvfs_tri;
unsigned int pcwchg;
unsigned int dt_val;
unsigned int df_val;
unsigned int updnlmt_shft;
unsigned int msk_frddsx_dys;
unsigned int msk_frddsx_dts;
};
struct fh_pll_offset {
int offset_fhctl;
int offset_con_pcw;
int offset_hp_en;
int offset_clk_con;
int offset_rst_con;
int offset_slope0;
int offset_slope1;
int offset_cfg;
int offset_updnlmt;
int offset_dds;
int offset_dvfs;
int offset_mon;
};
struct fh_pll_regs {
void __iomem *reg_hp_en;
void __iomem *reg_clk_con;
void __iomem *reg_rst_con;
void __iomem *reg_slope0;
void __iomem *reg_slope1;
void __iomem *reg_cfg;
void __iomem *reg_updnlmt;
void __iomem *reg_dds;
void __iomem *reg_dvfs;
void __iomem *reg_mon;
void __iomem *reg_con_pcw;
};
struct fh_pll_domain {
char *name;
struct fh_pll_data *data;
struct fh_pll_offset *offset;
struct fh_pll_regs *regs;
int (*init)(struct fh_pll_domain *d,
void __iomem *fhctl_base,
void __iomem *apmixed_base);
};
extern struct fh_pll_domain *get_fh_domain(const char *name);
extern void init_fh_domain(const char *domain_name,
char *comp_name,
void __iomem *fhctl_base,
void __iomem *apmixed_base);
#endif