summaryrefslogtreecommitdiff
path: root/drivers/video
diff options
context:
space:
mode:
authorVasily Khoruzhick <anarsoul@gmail.com>2017-09-20 23:29:07 -0700
committerAnatolij Gustschin <agust@denx.de>2017-10-26 14:17:01 +0200
commitfdb5525572ec7dc240ccc960888ae969253fede4 (patch)
tree647dfc8451b384d2c1310f2ba883c0f97490a4e0 /drivers/video
parentbe5b96f0e4110976a284aefe8b43fe09dee40957 (diff)
downloadu-boot-fdb5525572ec7dc240ccc960888ae969253fede4.tar.gz
u-boot-fdb5525572ec7dc240ccc960888ae969253fede4.tar.bz2
u-boot-fdb5525572ec7dc240ccc960888ae969253fede4.zip
dm: video: bridge: add operation to read EDID
Add an operation to read EDID, since bridge may have ability to read EDID from the panel that is connected to it, for example LCD<->eDP bridge. Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
Diffstat (limited to 'drivers/video')
-rw-r--r--drivers/video/bridge/video-bridge-uclass.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/video/bridge/video-bridge-uclass.c b/drivers/video/bridge/video-bridge-uclass.c
index 07270bac9e..79facd02a6 100644
--- a/drivers/video/bridge/video-bridge-uclass.c
+++ b/drivers/video/bridge/video-bridge-uclass.c
@@ -8,6 +8,7 @@
#include <common.h>
#include <dm.h>
#include <errno.h>
+#include <edid.h>
#include <video_bridge.h>
int video_bridge_set_backlight(struct udevice *dev, int percent)
@@ -45,6 +46,15 @@ int video_bridge_check_attached(struct udevice *dev)
return ops->check_attached(dev);
}
+int video_bridge_read_edid(struct udevice *dev, u8 *buf, int buf_size)
+{
+ struct video_bridge_ops *ops = video_bridge_get_ops(dev);
+
+ if (!ops || !ops->read_edid)
+ return -ENOSYS;
+ return ops->read_edid(dev, buf, buf_size);
+}
+
static int video_bridge_pre_probe(struct udevice *dev)
{
struct video_bridge_priv *uc_priv = dev_get_uclass_priv(dev);