mirror of
https://github.com/torvalds/linux.git
synced 2024-12-05 10:32:35 +00:00
drm: bridge: adv7511: Make connector creation optional
Now that the driver supports all the connector-related bridge operations, make the connector creation optional. This enables usage of the adv7511 with the DRM bridge connector helper. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Acked-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Link: https://patchwork.freedesktop.org/patch/msgid/20200526011505.31884-5-laurent.pinchart+renesas@ideasonboard.com
This commit is contained in:
parent
7c9361578b
commit
0bae6020b8
@ -902,17 +902,14 @@ static int adv7511_bridge_attach(struct drm_bridge *bridge,
|
|||||||
enum drm_bridge_attach_flags flags)
|
enum drm_bridge_attach_flags flags)
|
||||||
{
|
{
|
||||||
struct adv7511 *adv = bridge_to_adv7511(bridge);
|
struct adv7511 *adv = bridge_to_adv7511(bridge);
|
||||||
int ret;
|
int ret = 0;
|
||||||
|
|
||||||
if (flags & DRM_BRIDGE_ATTACH_NO_CONNECTOR) {
|
if (!(flags & DRM_BRIDGE_ATTACH_NO_CONNECTOR)) {
|
||||||
DRM_ERROR("Fix bridge driver to make connector optional!");
|
ret = adv7511_connector_init(adv);
|
||||||
return -EINVAL;
|
if (ret < 0)
|
||||||
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
ret = adv7511_connector_init(adv);
|
|
||||||
if (ret < 0)
|
|
||||||
return ret;
|
|
||||||
|
|
||||||
if (adv->type == ADV7533 || adv->type == ADV7535)
|
if (adv->type == ADV7533 || adv->type == ADV7535)
|
||||||
ret = adv7533_attach_dsi(adv);
|
ret = adv7533_attach_dsi(adv);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user