Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9ddd9cf2 authored by Vineet Bajaj's avatar Vineet Bajaj Committed by Dhaval Patel
Browse files

msm: mdss: unregister wled in case of probe failure



If the DSI probe fails and wled has been registered, then
when the next time probe comes there are failures seen.
Fix this by unregistering the wled in case of DSI probe
failures.

Conflicts:
	drivers/video/msm/mdss/mdss_dsi.h
	drivers/video/msm/mdss/mdss_dsi_panel.c

Change-Id: Ia3fd2fa2b5f5bd446c15bc4c28602846f8540a68
Signed-off-by: default avatarVineet Bajaj <vbajaj@codeaurora.org>
parent 69ac846d
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -2581,6 +2581,7 @@ static int mdss_dsi_ctrl_probe(struct platform_device *pdev)
	return 0;

error_pan_node:
	mdss_dsi_unregister_bl_settings(ctrl_pdata);
	of_node_put(dsi_pan_node);
	return rc;
}
+1 −0
Original line number Diff line number Diff line
@@ -596,6 +596,7 @@ int mdss_panel_get_dst_fmt(u32 bpp, char mipi_mode, u32 pixel_packing,
int mdss_dsi_register_recovery_handler(struct mdss_dsi_ctrl_pdata *ctrl,
		struct mdss_intf_recovery *recovery);
void mdss_dsi_panel_dsc_pps_send(struct mdss_dsi_ctrl_pdata *ctrl);
void mdss_dsi_unregister_bl_settings(struct mdss_dsi_ctrl_pdata *ctrl_pdata);

static inline const char *__mdss_dsi_pm_name(enum dsi_pm_type module)
{
+6 −0
Original line number Diff line number Diff line
@@ -2101,6 +2101,12 @@ int mdss_dsi_panel_timing_switch(struct mdss_dsi_ctrl_pdata *ctrl,
	return 0;
}

void mdss_dsi_unregister_bl_settings(struct mdss_dsi_ctrl_pdata *ctrl_pdata)
{
	if (ctrl_pdata->bklt_ctrl == BL_WLED)
		led_trigger_unregister_simple(bl_led_trigger);
}

static int mdss_dsi_panel_timing_from_dt(struct device_node *np,
		struct dsi_panel_timing *pt,
		struct mdss_panel_data *panel_data)