diff options
| author | Sandeep Panda <spanda@codeaurora.org> | 2016-01-13 10:09:56 +0530 |
|---|---|---|
| committer | David Keitel <dkeitel@codeaurora.org> | 2016-03-23 21:14:08 -0700 |
| commit | 58ee64bfb78183841604c2b7d95d158543fc51bd (patch) | |
| tree | e9fddc304a4b792379ee8b2db004d3d6835ba1e6 /drivers/video/fbdev | |
| parent | d2440dd653cb1ba4b5b43c4e02e5ce733885a057 (diff) | |
msm: mdss: update DSI PHY panel timing dt parsing logic
In current implementation there are two entries in DSI
panel specific dt file for specifying panel timing parameters.
But in case only one entry is specified in panel dt, then if the
first entry is not there in dt, driver is returning failure
and because of this the second entry is not getting parsed at all.
Update the parsing logic so that driver parses both the entries
to get proper dsi panel timing parameters.
Change-Id: I1774421fd9686de123cb669a745ac110fe8667da
Signed-off-by: Sandeep Panda <spanda@codeaurora.org>
Diffstat (limited to 'drivers/video/fbdev')
| -rw-r--r-- | drivers/video/fbdev/msm/mdss_dsi_panel.c | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/drivers/video/fbdev/msm/mdss_dsi_panel.c b/drivers/video/fbdev/msm/mdss_dsi_panel.c index 4b7a00fbd3f2..9b6a8f705ef5 100644 --- a/drivers/video/fbdev/msm/mdss_dsi_panel.c +++ b/drivers/video/fbdev/msm/mdss_dsi_panel.c @@ -1857,6 +1857,7 @@ static int mdss_dsi_panel_timing_from_dt(struct device_node *np, const char *data; struct mdss_dsi_ctrl_pdata *ctrl_pdata; struct mdss_panel_info *pinfo; + bool phy_timings_present; pinfo = &panel_data->panel_info; @@ -1951,12 +1952,13 @@ static int mdss_dsi_panel_timing_from_dt(struct device_node *np, data = of_get_property(np, "qcom,mdss-dsi-panel-timings", &len); if ((!data) || (len != 12)) { - pr_err("%s:%d, Unable to read Phy timing settings", + pr_debug("%s:%d, Unable to read Phy timing settings", __func__, __LINE__); - return -EINVAL; + } else { + for (i = 0; i < len; i++) + pt->phy_timing[i] = data[i]; + phy_timings_present = true; } - for (i = 0; i < len; i++) - pt->phy_timing[i] = data[i]; data = of_get_property(np, "qcom,mdss-dsi-panel-timings-8996", &len); if ((!data) || (len != 40)) { @@ -1965,6 +1967,11 @@ static int mdss_dsi_panel_timing_from_dt(struct device_node *np, } else { for (i = 0; i < len; i++) pt->phy_timing_8996[i] = data[i]; + phy_timings_present = true; + } + if (!phy_timings_present) { + pr_err("%s: phy timing settings not present\n", __func__); + return -EINVAL; } rc = of_property_read_u32(np, "qcom,mdss-dsi-t-clk-pre", &tmp); |
