/Linux-v5.4/drivers/gpu/drm/bridge/synopsys/ |
D | dw-hdmi.c | 3 * DesignWare High-Definition Multimedia Interface (HDMI) driver 12 #include <linux/hdmi.h> 35 #include "dw-hdmi-audio.h" 36 #include "dw-hdmi-cec.h" 37 #include "dw-hdmi.h" 43 /* DW-HDMI Controller >= 0x200a are at least compliant with SCDC version 1 */ 128 int (*configure)(struct dw_hdmi *hdmi, 189 void (*enable_audio)(struct dw_hdmi *hdmi); 190 void (*disable_audio)(struct dw_hdmi *hdmi); 204 static inline void hdmi_writeb(struct dw_hdmi *hdmi, u8 val, int offset) in hdmi_writeb() argument [all …]
|
/Linux-v5.4/drivers/gpu/drm/sun4i/ |
D | sun4i_hdmi_i2c.c | 25 static int fifo_transfer(struct sun4i_hdmi *hdmi, u8 *buf, int len, bool read) in fifo_transfer() argument 41 (hdmi->variant->ddc_fifo_thres_incl ? 0 : 1); in fifo_transfer() 50 if (regmap_field_read_poll_timeout(hdmi->field_ddc_int_status, reg, in fifo_transfer() 59 readsb(hdmi->base + hdmi->variant->ddc_fifo_reg, buf, len); in fifo_transfer() 61 writesb(hdmi->base + hdmi->variant->ddc_fifo_reg, buf, len); in fifo_transfer() 64 regmap_field_force_write(hdmi->field_ddc_int_status, in fifo_transfer() 70 static int xfer_msg(struct sun4i_hdmi *hdmi, struct i2c_msg *msg) in xfer_msg() argument 76 if (hdmi->variant->ddc_fifo_has_dir) { in xfer_msg() 77 reg = readl(hdmi->base + SUN4I_HDMI_DDC_CTRL_REG); in xfer_msg() 82 writel(reg, hdmi->base + SUN4I_HDMI_DDC_CTRL_REG); in xfer_msg() [all …]
|
D | sun4i_hdmi_enc.c | 45 static int sun4i_hdmi_setup_avi_infoframes(struct sun4i_hdmi *hdmi, in sun4i_hdmi_setup_avi_infoframes() argument 53 &hdmi->connector, mode); in sun4i_hdmi_setup_avi_infoframes() 66 writeb(buffer[i], hdmi->base + SUN4I_HDMI_AVI_INFOFRAME_REG(i)); in sun4i_hdmi_setup_avi_infoframes() 85 struct sun4i_hdmi *hdmi = drm_encoder_to_sun4i_hdmi(encoder); in sun4i_hdmi_disable() local 88 DRM_DEBUG_DRIVER("Disabling the HDMI Output\n"); in sun4i_hdmi_disable() 90 val = readl(hdmi->base + SUN4I_HDMI_VID_CTRL_REG); in sun4i_hdmi_disable() 92 writel(val, hdmi->base + SUN4I_HDMI_VID_CTRL_REG); in sun4i_hdmi_disable() 94 clk_disable_unprepare(hdmi->tmds_clk); in sun4i_hdmi_disable() 100 struct sun4i_hdmi *hdmi = drm_encoder_to_sun4i_hdmi(encoder); in sun4i_hdmi_enable() local 103 DRM_DEBUG_DRIVER("Enabling the HDMI Output\n"); in sun4i_hdmi_enable() [all …]
|
D | sun8i_dw_hdmi.c | 21 struct sun8i_dw_hdmi *hdmi = encoder_to_sun8i_dw_hdmi(encoder); in sun8i_dw_hdmi_encoder_mode_set() local 23 if (hdmi->quirks->set_rate) in sun8i_dw_hdmi_encoder_mode_set() 24 clk_set_rate(hdmi->clk_tmds, mode->crtc_clock * 1000); in sun8i_dw_hdmi_encoder_mode_set() 110 if (!of_device_is_compatible(remote, "hdmi-connector")) { in sun8i_dw_hdmi_find_connector_pdev() 132 struct sun8i_dw_hdmi *hdmi; in sun8i_dw_hdmi_bind() local 138 hdmi = devm_kzalloc(&pdev->dev, sizeof(*hdmi), GFP_KERNEL); in sun8i_dw_hdmi_bind() 139 if (!hdmi) in sun8i_dw_hdmi_bind() 142 plat_data = &hdmi->plat_data; in sun8i_dw_hdmi_bind() 143 hdmi->dev = &pdev->dev; in sun8i_dw_hdmi_bind() 144 encoder = &hdmi->encoder; in sun8i_dw_hdmi_bind() [all …]
|
/Linux-v5.4/drivers/gpu/drm/rockchip/ |
D | rk3066_hdmi.c | 62 static inline u8 hdmi_readb(struct rk3066_hdmi *hdmi, u16 offset) in hdmi_readb() argument 64 return readl_relaxed(hdmi->regs + offset); in hdmi_readb() 67 static inline void hdmi_writeb(struct rk3066_hdmi *hdmi, u16 offset, u32 val) in hdmi_writeb() argument 69 writel_relaxed(val, hdmi->regs + offset); in hdmi_writeb() 72 static inline void hdmi_modb(struct rk3066_hdmi *hdmi, u16 offset, in hdmi_modb() argument 75 u8 temp = hdmi_readb(hdmi, offset) & ~msk; in hdmi_modb() 78 hdmi_writeb(hdmi, offset, temp); in hdmi_modb() 81 static void rk3066_hdmi_i2c_init(struct rk3066_hdmi *hdmi) in rk3066_hdmi_i2c_init() argument 85 ddc_bus_freq = (hdmi->tmdsclk >> 2) / HDMI_SCL_RATE; in rk3066_hdmi_i2c_init() 87 hdmi_writeb(hdmi, HDMI_DDC_BUS_FREQ_L, ddc_bus_freq & 0xFF); in rk3066_hdmi_i2c_init() [all …]
|
D | inno_hdmi.c | 12 #include <linux/hdmi.h> 148 static inline u8 hdmi_readb(struct inno_hdmi *hdmi, u16 offset) in hdmi_readb() argument 150 return readl_relaxed(hdmi->regs + (offset) * 0x04); in hdmi_readb() 153 static inline void hdmi_writeb(struct inno_hdmi *hdmi, u16 offset, u32 val) in hdmi_writeb() argument 155 writel_relaxed(val, hdmi->regs + (offset) * 0x04); in hdmi_writeb() 158 static inline void hdmi_modb(struct inno_hdmi *hdmi, u16 offset, in hdmi_modb() argument 161 u8 temp = hdmi_readb(hdmi, offset) & ~msk; in hdmi_modb() 164 hdmi_writeb(hdmi, offset, temp); in hdmi_modb() 167 static void inno_hdmi_i2c_init(struct inno_hdmi *hdmi) in inno_hdmi_i2c_init() argument 171 ddc_bus_freq = (hdmi->tmds_rate >> 2) / HDMI_SCL_RATE; in inno_hdmi_i2c_init() [all …]
|
D | dw_hdmi-rockchip.c | 37 /* need to be unset if hdmi or i2c should control voltage */ 57 * @lcdsel_big: reg value of selecting vop big for HDMI 58 * @lcdsel_lit: reg value of selecting vop little for HDMI 73 struct dw_hdmi *hdmi; member 188 static int rockchip_hdmi_parse_dt(struct rockchip_hdmi *hdmi) in rockchip_hdmi_parse_dt() argument 190 struct device_node *np = hdmi->dev->of_node; in rockchip_hdmi_parse_dt() 192 hdmi->regmap = syscon_regmap_lookup_by_phandle(np, "rockchip,grf"); in rockchip_hdmi_parse_dt() 193 if (IS_ERR(hdmi->regmap)) { in rockchip_hdmi_parse_dt() 194 DRM_DEV_ERROR(hdmi->dev, "Unable to get rockchip,grf\n"); in rockchip_hdmi_parse_dt() 195 return PTR_ERR(hdmi->regmap); in rockchip_hdmi_parse_dt() [all …]
|
/Linux-v5.4/drivers/gpu/drm/mediatek/ |
D | mtk_hdmi.c | 10 #include <linux/hdmi.h> 23 #include <sound/hdmi-codec.h> 183 static u32 mtk_hdmi_read(struct mtk_hdmi *hdmi, u32 offset) in mtk_hdmi_read() argument 185 return readl(hdmi->regs + offset); in mtk_hdmi_read() 188 static void mtk_hdmi_write(struct mtk_hdmi *hdmi, u32 offset, u32 val) in mtk_hdmi_write() argument 190 writel(val, hdmi->regs + offset); in mtk_hdmi_write() 193 static void mtk_hdmi_clear_bits(struct mtk_hdmi *hdmi, u32 offset, u32 bits) in mtk_hdmi_clear_bits() argument 195 void __iomem *reg = hdmi->regs + offset; in mtk_hdmi_clear_bits() 203 static void mtk_hdmi_set_bits(struct mtk_hdmi *hdmi, u32 offset, u32 bits) in mtk_hdmi_set_bits() argument 205 void __iomem *reg = hdmi->regs + offset; in mtk_hdmi_set_bits() [all …]
|
/Linux-v5.4/drivers/gpu/drm/omapdrm/dss/ |
D | hdmi4.c | 3 * HDMI interface DSS driver for TI's OMAP4 family of SoCs. 10 #define DSS_SUBSYS_NAME "HDMI" 28 #include <sound/omap-hdmi-audio.h> 35 #include "hdmi.h" 37 static int hdmi_runtime_get(struct omap_hdmi *hdmi) in hdmi_runtime_get() argument 43 r = pm_runtime_get_sync(&hdmi->pdev->dev); in hdmi_runtime_get() 51 static void hdmi_runtime_put(struct omap_hdmi *hdmi) in hdmi_runtime_put() argument 57 r = pm_runtime_put_sync(&hdmi->pdev->dev); in hdmi_runtime_put() 63 struct omap_hdmi *hdmi = data; in hdmi_irq_handler() local 64 struct hdmi_wp_data *wp = &hdmi->wp; in hdmi_irq_handler() [all …]
|
D | hdmi5.c | 3 * HDMI driver for OMAP5 14 #define DSS_SUBSYS_NAME "HDMI" 32 #include <sound/omap-hdmi-audio.h> 38 static int hdmi_runtime_get(struct omap_hdmi *hdmi) in hdmi_runtime_get() argument 44 r = pm_runtime_get_sync(&hdmi->pdev->dev); in hdmi_runtime_get() 52 static void hdmi_runtime_put(struct omap_hdmi *hdmi) in hdmi_runtime_put() argument 58 r = pm_runtime_put_sync(&hdmi->pdev->dev); in hdmi_runtime_put() 64 struct omap_hdmi *hdmi = data; in hdmi_irq_handler() local 65 struct hdmi_wp_data *wp = &hdmi->wp; in hdmi_irq_handler() 88 v = hdmi_read_reg(hdmi->phy.base, HDMI_TXPHY_PAD_CFG_CTRL); in hdmi_irq_handler() [all …]
|
/Linux-v5.4/drivers/gpu/drm/zte/ |
D | zx_hdmi.c | 11 #include <linux/hdmi.h> 24 #include <sound/hdmi-codec.h> 54 static inline u8 hdmi_readb(struct zx_hdmi *hdmi, u16 offset) in hdmi_readb() argument 56 return readl_relaxed(hdmi->mmio + offset * 4); in hdmi_readb() 59 static inline void hdmi_writeb(struct zx_hdmi *hdmi, u16 offset, u8 val) in hdmi_writeb() argument 61 writel_relaxed(val, hdmi->mmio + offset * 4); in hdmi_writeb() 64 static inline void hdmi_writeb_mask(struct zx_hdmi *hdmi, u16 offset, in hdmi_writeb_mask() argument 69 tmp = hdmi_readb(hdmi, offset); in hdmi_writeb_mask() 71 hdmi_writeb(hdmi, offset, tmp); in hdmi_writeb_mask() 74 static int zx_hdmi_infoframe_trans(struct zx_hdmi *hdmi, in zx_hdmi_infoframe_trans() argument [all …]
|
/Linux-v5.4/drivers/gpu/drm/msm/hdmi/ |
D | hdmi.c | 11 #include <sound/hdmi-codec.h> 12 #include "hdmi.h" 14 void msm_hdmi_set_mode(struct hdmi *hdmi, bool power_on) in msm_hdmi_set_mode() argument 19 spin_lock_irqsave(&hdmi->reg_lock, flags); in msm_hdmi_set_mode() 22 if (!hdmi->hdmi_mode) { in msm_hdmi_set_mode() 24 hdmi_write(hdmi, REG_HDMI_CTRL, ctrl); in msm_hdmi_set_mode() 33 hdmi_write(hdmi, REG_HDMI_CTRL, ctrl); in msm_hdmi_set_mode() 34 spin_unlock_irqrestore(&hdmi->reg_lock, flags); in msm_hdmi_set_mode() 35 DBG("HDMI Core: %s, HDMI_CTRL=0x%08x", in msm_hdmi_set_mode() 41 struct hdmi *hdmi = dev_id; in msm_hdmi_irq() local [all …]
|
D | hdmi_connector.c | 12 #include "hdmi.h" 16 struct hdmi *hdmi; member 21 static void msm_hdmi_phy_reset(struct hdmi *hdmi) in msm_hdmi_phy_reset() argument 25 val = hdmi_read(hdmi, REG_HDMI_PHY_CTRL); in msm_hdmi_phy_reset() 29 hdmi_write(hdmi, REG_HDMI_PHY_CTRL, in msm_hdmi_phy_reset() 33 hdmi_write(hdmi, REG_HDMI_PHY_CTRL, in msm_hdmi_phy_reset() 39 hdmi_write(hdmi, REG_HDMI_PHY_CTRL, in msm_hdmi_phy_reset() 43 hdmi_write(hdmi, REG_HDMI_PHY_CTRL, in msm_hdmi_phy_reset() 51 hdmi_write(hdmi, REG_HDMI_PHY_CTRL, in msm_hdmi_phy_reset() 55 hdmi_write(hdmi, REG_HDMI_PHY_CTRL, in msm_hdmi_phy_reset() [all …]
|
D | hdmi_bridge.c | 9 #include "hdmi.h" 13 struct hdmi *hdmi; member 25 struct hdmi *hdmi = hdmi_bridge->hdmi; in msm_hdmi_power_on() local 26 const struct hdmi_platform_config *config = hdmi->config; in msm_hdmi_power_on() 29 pm_runtime_get_sync(&hdmi->pdev->dev); in msm_hdmi_power_on() 32 ret = regulator_enable(hdmi->pwr_regs[i]); in msm_hdmi_power_on() 40 DBG("pixclock: %lu", hdmi->pixclock); in msm_hdmi_power_on() 41 ret = clk_set_rate(hdmi->pwr_clks[0], hdmi->pixclock); in msm_hdmi_power_on() 49 ret = clk_prepare_enable(hdmi->pwr_clks[i]); in msm_hdmi_power_on() 61 struct hdmi *hdmi = hdmi_bridge->hdmi; in power_off() local [all …]
|
D | hdmi_hdcp.c | 5 #include "hdmi.h" 21 /* QFPROM Registers for HDMI/HDCP */ 49 struct hdmi *hdmi; member 78 static int msm_hdmi_ddc_read(struct hdmi *hdmi, u16 addr, u8 offset, in msm_hdmi_ddc_read() argument 99 rc = i2c_transfer(hdmi->i2c, msgs, 2); in msm_hdmi_ddc_read() 116 static int msm_hdmi_ddc_write(struct hdmi *hdmi, u16 addr, u8 offset, in msm_hdmi_ddc_write() argument 141 rc = i2c_transfer(hdmi->i2c, msgs, 1); in msm_hdmi_ddc_write() 159 struct hdmi *hdmi = hdcp_ctrl->hdmi; in msm_hdmi_hdcp_scm_wr() local 167 phy_addr = (u32)hdmi->mmio_phy_addr; in msm_hdmi_hdcp_scm_wr() 190 hdmi_write(hdmi, preg[i], pdata[i]); in msm_hdmi_hdcp_scm_wr() [all …]
|
D | hdmi_i2c.c | 7 #include "hdmi.h" 11 struct hdmi *hdmi; member 19 struct hdmi *hdmi = hdmi_i2c->hdmi; in init_ddc() local 21 hdmi_write(hdmi, REG_HDMI_DDC_CTRL, in init_ddc() 23 hdmi_write(hdmi, REG_HDMI_DDC_CTRL, in init_ddc() 26 hdmi_write(hdmi, REG_HDMI_DDC_SPEED, in init_ddc() 30 hdmi_write(hdmi, REG_HDMI_DDC_SETUP, in init_ddc() 34 hdmi_write(hdmi, REG_HDMI_DDC_REF, in init_ddc() 41 struct hdmi *hdmi = hdmi_i2c->hdmi; in ddc_clear_irq() local 42 struct drm_device *dev = hdmi->dev; in ddc_clear_irq() [all …]
|
D | hdmi.h | 15 #include <linux/hdmi.h> 18 #include "hdmi.xml.h" 39 struct hdmi { struct 69 /* the encoder we are hooked to (outside of hdmi block) */ argument 72 bool hdmi_mode; /* are we in hdmi mode? */ argument 115 void msm_hdmi_set_mode(struct hdmi *hdmi, bool power_on); 117 static inline void hdmi_write(struct hdmi *hdmi, u32 reg, u32 data) in hdmi_write() argument 119 msm_writel(data, hdmi->mmio + reg); in hdmi_write() 122 static inline u32 hdmi_read(struct hdmi *hdmi, u32 reg) in hdmi_read() argument 124 return msm_readl(hdmi->mmio + reg); in hdmi_read() [all …]
|
/Linux-v5.4/drivers/gpu/drm/sti/ |
D | sti_hdmi.c | 10 #include <linux/hdmi.h> 24 #include <sound/hdmi-codec.h> 162 struct sti_hdmi *hdmi; member 169 u32 hdmi_read(struct sti_hdmi *hdmi, int offset) in hdmi_read() argument 171 return readl(hdmi->regs + offset); in hdmi_read() 174 void hdmi_write(struct sti_hdmi *hdmi, u32 val, int offset) in hdmi_write() argument 176 writel(val, hdmi->regs + offset); in hdmi_write() 180 * HDMI interrupt handler threaded 187 struct sti_hdmi *hdmi = arg; in hdmi_irq_thread() local 190 if (hdmi->irq_status & HDMI_INT_HOT_PLUG) { in hdmi_irq_thread() [all …]
|
/Linux-v5.4/drivers/gpu/drm/tegra/ |
D | hdmi.c | 11 #include <linux/hdmi.h> 27 #include "hdmi.h" 60 struct regulator *hdmi; member 103 static inline u32 tegra_hdmi_readl(struct tegra_hdmi *hdmi, in tegra_hdmi_readl() argument 106 u32 value = readl(hdmi->regs + (offset << 2)); in tegra_hdmi_readl() 108 trace_hdmi_readl(hdmi->dev, offset, value); in tegra_hdmi_readl() 113 static inline void tegra_hdmi_writel(struct tegra_hdmi *hdmi, u32 value, in tegra_hdmi_writel() argument 116 trace_hdmi_writel(hdmi->dev, offset, value); in tegra_hdmi_writel() 117 writel(value, hdmi->regs + (offset << 2)); in tegra_hdmi_writel() 412 static void tegra_hdmi_setup_audio_fs_tables(struct tegra_hdmi *hdmi) in tegra_hdmi_setup_audio_fs_tables() argument [all …]
|
/Linux-v5.4/drivers/video/fbdev/omap2/omapfb/dss/ |
D | hdmi5.c | 3 * HDMI driver for OMAP5 14 #define DSS_SUBSYS_NAME "HDMI" 31 #include <sound/omap-hdmi-audio.h> 37 static struct omap_hdmi hdmi; variable 45 r = pm_runtime_get_sync(&hdmi.pdev->dev); in hdmi_runtime_get() 59 r = pm_runtime_put_sync(&hdmi.pdev->dev); in hdmi_runtime_put() 88 v = hdmi_read_reg(hdmi.phy.base, HDMI_TXPHY_PAD_CFG_CTRL); in hdmi_irq_handler() 91 hdmi_write_reg(hdmi.phy.base, HDMI_TXPHY_PAD_CFG_CTRL, v); in hdmi_irq_handler() 98 REG_FLD_MOD(hdmi.phy.base, HDMI_TXPHY_PAD_CFG_CTRL, 0, 15, 15); in hdmi_irq_handler() 113 if (hdmi.vdda_reg != NULL) in hdmi_init_regulator() [all …]
|
D | hdmi4.c | 3 * HDMI interface DSS driver for TI's OMAP4 family of SoCs. 9 #define DSS_SUBSYS_NAME "HDMI" 26 #include <sound/omap-hdmi-audio.h> 31 #include "hdmi.h" 33 static struct omap_hdmi hdmi; variable 41 r = pm_runtime_get_sync(&hdmi.pdev->dev); in hdmi_runtime_get() 55 r = pm_runtime_put_sync(&hdmi.pdev->dev); in hdmi_runtime_put() 94 if (hdmi.vdda_reg != NULL) in hdmi_init_regulator() 97 reg = devm_regulator_get(&hdmi.pdev->dev, "vdda"); in hdmi_init_regulator() 105 hdmi.vdda_reg = reg; in hdmi_init_regulator() [all …]
|
/Linux-v5.4/drivers/gpu/drm/vc4/ |
D | vc4_hdmi.c | 10 * DOC: VC4 Falcon HDMI module 12 * The HDMI core has a state machine and a PHY. On BCM2835, most of 16 * HDMI infoframes are kept within a small packet ram, where each 19 * HDMI audio is implemented entirely within the HDMI IP block. A 20 * register in the HDMI encoder takes SPDIF frames from the DMA engine 25 * The driver's HDMI encoder does not yet support power management. 26 * The HDMI encoder's power domain and the HSM/pixel clocks are kept 27 * continuously running, and only the HDMI logic and packet ram are 30 * The driver does not yet support CEC control, though the HDMI 57 /* HDMI audio information */ [all …]
|
/Linux-v5.4/Documentation/devicetree/bindings/display/msm/ |
D | hdmi.txt | 1 Qualcomm adreno/snapdragon hdmi output 5 * "qcom,hdmi-tx-8996" 6 * "qcom,hdmi-tx-8994" 7 * "qcom,hdmi-tx-8084" 8 * "qcom,hdmi-tx-8974" 9 * "qcom,hdmi-tx-8660" 10 * "qcom,hdmi-tx-8960" 13 - interrupts: The interrupt signal from the hdmi block. 18 - hdmi-mux-supply: phandle to mux regulator 19 - phys: the phandle for the HDMI PHY device [all …]
|
/Linux-v5.4/Documentation/devicetree/bindings/display/exynos/ |
D | exynos_hdmi.txt | 1 Device-Tree bindings for drm hdmi driver 5 1) "samsung,exynos4210-hdmi" 6 2) "samsung,exynos4212-hdmi" 7 3) "samsung,exynos5420-hdmi" 8 4) "samsung,exynos5433-hdmi" 9 - reg: physical base address of the hdmi and length of memory mapped 16 - ddc: phandle to the hdmi ddc node 17 - phy: phandle to the hdmi phy node 23 a) hdmi: Gate of HDMI IP bus clock. 24 b) sclk_hdmi: Gate of HDMI special clock. [all …]
|
/Linux-v5.4/drivers/media/i2c/adv748x/ |
D | adv748x-hdmi.c | 3 * Driver for Analog Devices ADV748X HDMI receiver and Component Processor (CP) 21 * HDMI and CP 90 static void adv748x_hdmi_fill_format(struct adv748x_hdmi *hdmi, in adv748x_hdmi_fill_format() argument 96 fmt->field = hdmi->timings.bt.interlaced ? in adv748x_hdmi_fill_format() 102 fmt->width = hdmi->timings.bt.width; in adv748x_hdmi_fill_format() 103 fmt->height = hdmi->timings.bt.height; in adv748x_hdmi_fill_format() 145 * HDMI CP uses a Data Enable synchronisation timing reference 220 struct adv748x_hdmi *hdmi = adv748x_sd_to_hdmi(sd); in adv748x_hdmi_s_dv_timings() local 221 struct adv748x_state *state = adv748x_hdmi_to_state(hdmi); in adv748x_hdmi_s_dv_timings() 227 if (v4l2_match_dv_timings(&hdmi->timings, timings, 0, false)) in adv748x_hdmi_s_dv_timings() [all …]
|