drm/rockchip: change 8bit bmp decoder result from BGR565 to RGB565

Signed-off-by: Sandy Huang <hjc@rock-chips.com>
Change-Id: I0ca715bd69bc9ff1a61c98f766ecab2458737b27
This commit is contained in:
Sandy Huang 2020-06-17 15:32:11 +08:00 committed by Jianhong Chen
parent f0e8414b2a
commit 859836bc0c
1 changed files with 2 additions and 2 deletions

View File

@ -180,9 +180,9 @@ int bmpdecoder(void *bmp_addr, void *pdst, int dst_bpp)
/* Set color map */
for (i = 0; i < 256; i++) {
ushort colreg = ((cmap_base[0] << 8) & 0xf800) |
ushort colreg = ((cmap_base[2] << 8) & 0xf800) |
((cmap_base[1] << 3) & 0x07e0) |
((cmap_base[2] >> 3) & 0x001f) ;
((cmap_base[0] >> 3) & 0x001f) ;
cmap_base += 4;
cmap[i] = colreg;
}