From: Ahmad Fatoum <ahmad@a3f.at>
To: barebox@lists.infradead.org
Subject: [PATCH 1/4] video: edid: make accessible without i2c
Date: Fri, 1 Jan 2021 23:52:25 +0100 [thread overview]
Message-ID: <20210101225228.2166084-1-ahmad@a3f.at> (raw)
Users can already populate fb_info::edid_data for cases where the EDID
doesn't come via an i2c controller managed by barebox.
Only thing missing is to be able to compile without i2c, thus drop
the dependency.
Signed-off-by: Ahmad Fatoum <ahmad@a3f.at>
---
drivers/video/Kconfig | 1 -
drivers/video/edid.c | 3 +++
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/video/Kconfig b/drivers/video/Kconfig
index a26bace176a1..56d009529ea4 100644
--- a/drivers/video/Kconfig
+++ b/drivers/video/Kconfig
@@ -106,7 +106,6 @@ config DRIVER_VIDEO_SIMPLEFB
based on the active barebox framebuffer.
config DRIVER_VIDEO_EDID
- depends on I2C
bool "Add EDID support"
help
This enabled support for reading and parsing EDID data from an attached
diff --git a/drivers/video/edid.c b/drivers/video/edid.c
index bee4594118bb..41d40d0297b6 100644
--- a/drivers/video/edid.c
+++ b/drivers/video/edid.c
@@ -858,6 +858,9 @@ void *edid_read_i2c(struct i2c_adapter *adapter)
{
u8 *block;
+ if (!IS_ENABLED(CONFIG_I2C))
+ return NULL;
+
block = xmalloc(EDID_LENGTH);
if (edid_do_read_i2c(adapter, block, 0, EDID_LENGTH))
--
2.29.2
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
next reply other threads:[~2021-01-01 22:52 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-01-01 22:52 Ahmad Fatoum [this message]
2021-01-01 22:52 ` [PATCH 2/4] video: edid: make edid_check_header externally visible Ahmad Fatoum
2021-01-01 22:52 ` [PATCH 3/4] video: implement bochs dispi / QEMU VGA driver for PCI and ISA Ahmad Fatoum
2021-01-02 11:10 ` [PATCH] fixup! " Ahmad Fatoum
2021-01-05 12:19 ` [PATCH 3/4] " Sascha Hauer
2021-01-01 22:52 ` [PATCH 4/4] MIPS: qemu-malta_defconfig: enable VGA output Ahmad Fatoum
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210101225228.2166084-1-ahmad@a3f.at \
--to=ahmad@a3f.at \
--cc=barebox@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox