bcm2835 video: Map frame buffer as 32bpp
authorAlexander Graf <agraf@suse.de>
Wed, 2 Nov 2016 09:36:19 +0000 (10:36 +0100)
committerTom Rini <trini@konsulko.com>
Tue, 29 Nov 2016 01:15:20 +0000 (20:15 -0500)
To enable working efifb support, let's map the frame buffer as 32bpp
instead of 16bpp.

Signed-off-by: Alexander Graf <agraf@suse.de>
Acked-by: Stephen Warren <swarren@wwwdotorg.org>
drivers/video/bcm2835.c
include/configs/rpi.h

index cd605e632cb606c84754c24b6ca1590db9a22ab7..cc6454f10d4c5f98809d054bd9d017381cabf859 100644 (file)
@@ -71,9 +71,9 @@ void lcd_ctrl_init(void *lcdbase)
        msg_setup->virtual_w_h.body.req.width = w;
        msg_setup->virtual_w_h.body.req.height = h;
        BCM2835_MBOX_INIT_TAG(&msg_setup->depth, SET_DEPTH);
-       msg_setup->depth.body.req.bpp = 16;
+       msg_setup->depth.body.req.bpp = 32;
        BCM2835_MBOX_INIT_TAG(&msg_setup->pixel_order, SET_PIXEL_ORDER);
-       msg_setup->pixel_order.body.req.order = BCM2835_MBOX_PIXEL_ORDER_BGR;
+       msg_setup->pixel_order.body.req.order = BCM2835_MBOX_PIXEL_ORDER_RGB;
        BCM2835_MBOX_INIT_TAG(&msg_setup->alpha_mode, SET_ALPHA_MODE);
        msg_setup->alpha_mode.body.req.alpha = BCM2835_MBOX_ALPHA_MODE_IGNORED;
        BCM2835_MBOX_INIT_TAG(&msg_setup->virtual_offset, SET_VIRTUAL_OFFSET);
@@ -103,7 +103,7 @@ void lcd_ctrl_init(void *lcdbase)
 
        panel_info.vl_col = w;
        panel_info.vl_row = h;
-       panel_info.vl_bpix = LCD_COLOR16;
+       panel_info.vl_bpix = LCD_COLOR32;
 
        gd->fb_base = bus_to_phys(
                msg_setup->allocate_buffer.body.resp.fb_address);
index fa959ef7e3492bbfc8d92635460dcbb5f0c5ead5..4406366b18619957b749de6b2068af636b1ff27d 100644 (file)
@@ -71,7 +71,7 @@
 #define CONFIG_BCM2835_GPIO
 /* LCD */
 #define CONFIG_LCD_DT_SIMPLEFB
-#define LCD_BPP                                LCD_COLOR16
+#define LCD_BPP                                LCD_COLOR32
 /*
  * Prevent allocation of RAM for FB; the real FB address is queried
  * dynamically from the VideoCore co-processor, and comes from RAM