]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/blame - drivers/gpu/drm/msm/hdmi/hdmi_phy_8x74.c
drm/msm: rename hdmi symbols
[mirror_ubuntu-artful-kernel.git] / drivers / gpu / drm / msm / hdmi / hdmi_phy_8x74.c
CommitLineData
dada25bd
RC
1/*
2 * Copyright (C) 2013 Red Hat
3 * Author: Rob Clark <robdclark@gmail.com>
4 *
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License version 2 as published by
7 * the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
12 * more details.
13 *
14 * You should have received a copy of the GNU General Public License along with
15 * this program. If not, see <http://www.gnu.org/licenses/>.
16 */
17
18#include "hdmi.h"
19
dada25bd
RC
20static void hdmi_phy_8x74_powerup(struct hdmi_phy *phy,
21 unsigned long int pixclock)
22{
ba3d7bf3
AT
23 hdmi_phy_write(phy, REG_HDMI_8x74_ANA_CFG0, 0x1b);
24 hdmi_phy_write(phy, REG_HDMI_8x74_ANA_CFG1, 0xf2);
25 hdmi_phy_write(phy, REG_HDMI_8x74_BIST_CFG0, 0x0);
26 hdmi_phy_write(phy, REG_HDMI_8x74_BIST_PATN0, 0x0);
27 hdmi_phy_write(phy, REG_HDMI_8x74_BIST_PATN1, 0x0);
28 hdmi_phy_write(phy, REG_HDMI_8x74_BIST_PATN2, 0x0);
29 hdmi_phy_write(phy, REG_HDMI_8x74_BIST_PATN3, 0x0);
30 hdmi_phy_write(phy, REG_HDMI_8x74_PD_CTRL1, 0x20);
dada25bd
RC
31}
32
33static void hdmi_phy_8x74_powerdown(struct hdmi_phy *phy)
34{
ba3d7bf3 35 hdmi_phy_write(phy, REG_HDMI_8x74_PD_CTRL0, 0x7f);
dada25bd
RC
36}
37
15b4a452
AT
38static const char * const hdmi_phy_8x74_reg_names[] = {
39 "core-vdda",
40 "vddio",
41};
42
43static const char * const hdmi_phy_8x74_clk_names[] = {
44 "iface_clk",
45 "alt_iface_clk"
46};
47
fcda50c8 48const struct hdmi_phy_cfg msm_hdmi_phy_8x74_cfg = {
15b4a452
AT
49 .type = MSM_HDMI_PHY_8x74,
50 .powerup = hdmi_phy_8x74_powerup,
51 .powerdown = hdmi_phy_8x74_powerdown,
52 .reg_names = hdmi_phy_8x74_reg_names,
53 .num_regs = ARRAY_SIZE(hdmi_phy_8x74_reg_names),
54 .clk_names = hdmi_phy_8x74_clk_names,
55 .num_clks = ARRAY_SIZE(hdmi_phy_8x74_clk_names),
56};