forked from mirrors/linux
		
	drm/bridge: analogix_dp: Add support to get panel from the DP AUX bus
The main modification is moving the DP AUX initialization from function analogix_dp_bind() to analogix_dp_probe(). In order to get the EDID of eDP panel during probing, it is also needed to advance PM operations to ensure that eDP controller and phy are prepared for AUX transmission. Signed-off-by: Damon Ding <damon.ding@rock-chips.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Reviewed-by: Douglas Anderson <dianders@chromium.org> Link: https://lore.kernel.org/r/20250310104114.2608063-7-damon.ding@rock-chips.com Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
This commit is contained in:
		
							parent
							
								
									fd073dffef
								
							
						
					
					
						commit
						e5e9fa9f7a
					
				
					 1 changed files with 11 additions and 9 deletions
				
			
		|  | @ -1646,6 +1646,17 @@ analogix_dp_probe(struct device *dev, struct analogix_dp_plat_data *plat_data) | |||
| 		goto err_disable_clk; | ||||
| 	} | ||||
| 
 | ||||
| 	dp->aux.name = "DP-AUX"; | ||||
| 	dp->aux.transfer = analogix_dpaux_transfer; | ||||
| 	dp->aux.dev = dp->dev; | ||||
| 	drm_dp_aux_init(&dp->aux); | ||||
| 
 | ||||
| 	pm_runtime_use_autosuspend(dp->dev); | ||||
| 	pm_runtime_set_autosuspend_delay(dp->dev, 100); | ||||
| 	ret = devm_pm_runtime_enable(dp->dev); | ||||
| 	if (ret) | ||||
| 		goto err_disable_clk; | ||||
| 
 | ||||
| 	return dp; | ||||
| 
 | ||||
| err_disable_clk: | ||||
|  | @ -1696,15 +1707,6 @@ int analogix_dp_bind(struct analogix_dp_device *dp, struct drm_device *drm_dev) | |||
| 	dp->drm_dev = drm_dev; | ||||
| 	dp->encoder = dp->plat_data->encoder; | ||||
| 
 | ||||
| 	pm_runtime_use_autosuspend(dp->dev); | ||||
| 	pm_runtime_set_autosuspend_delay(dp->dev, 100); | ||||
| 	ret = devm_pm_runtime_enable(dp->dev); | ||||
| 	if (ret) | ||||
| 		return ret; | ||||
| 
 | ||||
| 	dp->aux.name = "DP-AUX"; | ||||
| 	dp->aux.transfer = analogix_dpaux_transfer; | ||||
| 	dp->aux.dev = dp->dev; | ||||
| 	dp->aux.drm_dev = drm_dev; | ||||
| 
 | ||||
| 	ret = drm_dp_aux_register(&dp->aux); | ||||
|  |  | |||
		Loading…
	
		Reference in a new issue
	
	 Damon Ding
						Damon Ding