mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <s.hauer@pengutronix.de>
To: Barebox List <barebox@lists.infradead.org>
Cc: Sam Ravnborg <sam@ravnborg.org>
Subject: [PATCH] atmel_lcdfb: fix atmel,lcd-wiring-mode; BGR => BRG
Date: Tue, 13 Apr 2021 11:10:02 +0200	[thread overview]
Message-ID: <20210413091002.10153-1-s.hauer@pengutronix.de> (raw)

From: Sam Ravnborg <sam@ravnborg.org>

Fix spelling error that prevented us from getting
the atmel,lcd-wiring-mode

The Bindings mandate the use of BRG.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
---
 drivers/video/atmel_lcdfb_core.c | 14 +++++++-------
 include/video/atmel_lcdc.h       |  4 ++--
 2 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/drivers/video/atmel_lcdfb_core.c b/drivers/video/atmel_lcdfb_core.c
index d8c35b2755..daabfe92d2 100644
--- a/drivers/video/atmel_lcdfb_core.c
+++ b/drivers/video/atmel_lcdfb_core.c
@@ -129,7 +129,7 @@ static int atmel_lcdfb_check_var(struct fb_info *info)
 			= info->bits_per_pixel;
 		break;
 	case 16:
-		/* Older SOCs use BGR:555 rather than BGR:565. */
+		/* Older SOCs use BRG:555 rather than BRG:565. */
 		if (sinfo->have_intensity_bit)
 			info->green.length = 5;
 		else
@@ -139,7 +139,7 @@ static int atmel_lcdfb_check_var(struct fb_info *info)
 			info->red.offset = info->green.length + 5;
 			info->blue.offset = 0;
 		} else {
-			/* BGR:5X5 mode */
+			/* BRG:5X5 mode */
 			info->red.offset = 0;
 			info->blue.offset = info->green.length + 5;
 		}
@@ -156,7 +156,7 @@ static int atmel_lcdfb_check_var(struct fb_info *info)
 			info->red.offset = 16;
 			info->blue.offset = 0;
 		} else {
-			/* BGR:888 mode */
+			/* BRG:888 mode */
 			info->red.offset = 0;
 			info->blue.offset = 16;
 		}
@@ -279,7 +279,7 @@ static int power_control_init(struct device_d *dev,
 }
 
 /*
- * Syntax: atmel,lcd-wiring-mode: lcd wiring mode "RGB", "BGR"
+ * Syntax: atmel,lcd-wiring-mode: lcd wiring mode "RGB", "BRG"
  */
 static int of_get_wiring_mode(struct device_node *np,
 			      struct atmel_lcdfb_info *sinfo)
@@ -290,12 +290,12 @@ static int of_get_wiring_mode(struct device_node *np,
 	ret = of_property_read_string(np, "atmel,lcd-wiring-mode", &mode);
 	if (ret < 0) {
 		/* Not present, use defaults */
-		sinfo->lcd_wiring_mode = ATMEL_LCDC_WIRING_BGR;
+		sinfo->lcd_wiring_mode = ATMEL_LCDC_WIRING_BRG;
 		return 0;
 	}
 
-	if (!strcasecmp(mode, "BGR")) {
-		sinfo->lcd_wiring_mode = ATMEL_LCDC_WIRING_BGR;
+	if (!strcasecmp(mode, "BRG")) {
+		sinfo->lcd_wiring_mode = ATMEL_LCDC_WIRING_BRG;
 	} else if (!strcasecmp(mode, "RGB")) {
 		sinfo->lcd_wiring_mode = ATMEL_LCDC_WIRING_RGB;
 	} else {
diff --git a/include/video/atmel_lcdc.h b/include/video/atmel_lcdc.h
index 07a30e2e6f..7e3f95873c 100644
--- a/include/video/atmel_lcdc.h
+++ b/include/video/atmel_lcdc.h
@@ -23,10 +23,10 @@
 #define __ATMEL_LCDC_H__
 
 /* Way LCD wires are connected to the chip:
- * Some Atmel chips use BGR color mode (instead of standard RGB)
+ * Some Atmel chips use BRG color mode (instead of standard RGB)
  * A swapped wiring onboard can bring to RGB mode.
  */
-#define ATMEL_LCDC_WIRING_BGR	0
+#define ATMEL_LCDC_WIRING_BRG	0
 #define ATMEL_LCDC_WIRING_RGB	1
 #define ATMEL_LCDC_WIRING_RGB555	2
 
-- 
2.29.2


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox


                 reply	other threads:[~2021-04-13  9:11 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20210413091002.10153-1-s.hauer@pengutronix.de \
    --to=s.hauer@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    --cc=sam@ravnborg.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