To modify hdmi default output color depth, use following dts:
&hdmi {
rockchip,defaultdepth = <10>;
}
rockchip,defaultdepth could be following value:
<0> auto select color depth, prefer 8bit
<8> 8bit
<10> 10bit
Change-Id: Idce0bd080c042edf3939c5c38b76d4d1860b7a9f
Signed-off-by: Zheng Yang <zhengyang@rock-chips.com>
(cherry picked from commit
905228ba1e43c24b3048820a7f1047a4ed5ef185)
hdmi->vic = hdmi->property->defaultmode;
}
hdmi->colormode = HDMI_VIDEO_DEFAULT_COLORMODE;
- hdmi->colordepth = HDMI_VIDEO_DEFAULT_COLORDEPTH;
+ hdmi->colordepth = hdmi->property->defaultdepth;
hdmi->colorimetry = HDMI_COLORIMETRY_NO_DATA;
hdmi->mode_3d = HDMI_3D_NONE;
hdmi->audio.type = HDMI_AUDIO_DEFAULT_TYPE;
int display;
int feature;
int defaultmode;
+ int defaultdepth;
void *priv;
};
} else {
rk_hdmi_property.defaultmode = HDMI_VIDEO_DEFAULT_MODE;
}
+ if (!of_property_read_u32(np, "rockchip,defaultdepth", &val) &&
+ (val > 0)) {
+ pr_info("default depth is %d\n", val);
+ rk_hdmi_property.defaultdepth = val;
+ } else {
+ rk_hdmi_property.defaultdepth = HDMI_VIDEO_DEFAULT_COLORDEPTH;
+ }
if (of_get_property(np, "rockchip,phy_table", &val)) {
hdmi_dev->phy_table = kmalloc(val, GFP_KERNEL);
if (!hdmi_dev->phy_table) {