Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

at v5.0-rc3 60 lines 1.7 kB view raw
1/* SPDX-License-Identifier: GPL-2.0 */ 2/* 3 * Copyright (c) 2018 MediaTek Inc. 4 * Author: Chunhui Dai <chunhui.dai@mediatek.com> 5 */ 6 7#ifndef _MTK_HDMI_PHY_H 8#define _MTK_HDMI_PHY_H 9#include <linux/clk.h> 10#include <linux/clk-provider.h> 11#include <linux/delay.h> 12#include <linux/io.h> 13#include <linux/mfd/syscon.h> 14#include <linux/module.h> 15#include <linux/of_device.h> 16#include <linux/phy/phy.h> 17#include <linux/platform_device.h> 18#include <linux/types.h> 19 20struct mtk_hdmi_phy; 21 22struct mtk_hdmi_phy_conf { 23 bool tz_disabled; 24 const struct clk_ops *hdmi_phy_clk_ops; 25 void (*hdmi_phy_enable_tmds)(struct mtk_hdmi_phy *hdmi_phy); 26 void (*hdmi_phy_disable_tmds)(struct mtk_hdmi_phy *hdmi_phy); 27}; 28 29struct mtk_hdmi_phy { 30 void __iomem *regs; 31 struct device *dev; 32 struct mtk_hdmi_phy_conf *conf; 33 struct clk *pll; 34 struct clk_hw pll_hw; 35 unsigned long pll_rate; 36 unsigned char drv_imp_clk; 37 unsigned char drv_imp_d2; 38 unsigned char drv_imp_d1; 39 unsigned char drv_imp_d0; 40 unsigned int ibias; 41 unsigned int ibias_up; 42}; 43 44void mtk_hdmi_phy_clear_bits(struct mtk_hdmi_phy *hdmi_phy, u32 offset, 45 u32 bits); 46void mtk_hdmi_phy_set_bits(struct mtk_hdmi_phy *hdmi_phy, u32 offset, 47 u32 bits); 48void mtk_hdmi_phy_mask(struct mtk_hdmi_phy *hdmi_phy, u32 offset, 49 u32 val, u32 mask); 50struct mtk_hdmi_phy *to_mtk_hdmi_phy(struct clk_hw *hw); 51long mtk_hdmi_pll_round_rate(struct clk_hw *hw, unsigned long rate, 52 unsigned long *parent_rate); 53unsigned long mtk_hdmi_pll_recalc_rate(struct clk_hw *hw, 54 unsigned long parent_rate); 55 56extern struct platform_driver mtk_hdmi_phy_driver; 57extern struct mtk_hdmi_phy_conf mtk_hdmi_phy_8173_conf; 58extern struct mtk_hdmi_phy_conf mtk_hdmi_phy_2701_conf; 59 60#endif /* _MTK_HDMI_PHY_H */