projects
/
oweals
/
u-boot.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Move ali512x.h
[oweals/u-boot.git]
/
drivers
/
video
/
cfb_console.c
diff --git
a/drivers/video/cfb_console.c
b/drivers/video/cfb_console.c
index d313e9098c932569ae07100f252a20e59bd87bfc..779aa4b53e49da3b7eea4814dce0feeef9d48f14 100644
(file)
--- a/
drivers/video/cfb_console.c
+++ b/
drivers/video/cfb_console.c
@@
-61,7
+61,7
@@
CONFIG_CONSOLE_CURSOR - on/off drawing cursor is done with delay
loop in VIDEO_TSTC_FCT (i8042)
CONFIG_CONSOLE_CURSOR - on/off drawing cursor is done with delay
loop in VIDEO_TSTC_FCT (i8042)
- C
FG
_CONSOLE_BLINK_COUNT - value for delay loop - blink rate
+ C
ONFIG_SYS
_CONSOLE_BLINK_COUNT - value for delay loop - blink rate
CONFIG_CONSOLE_TIME - display time/date in upper right corner,
needs CONFIG_CMD_DATE and CONFIG_CONSOLE_CURSOR
CONFIG_VIDEO_LOGO - display Linux Logo in upper left corner
CONFIG_CONSOLE_TIME - display time/date in upper right corner,
needs CONFIG_CMD_DATE and CONFIG_CONSOLE_CURSOR
CONFIG_VIDEO_LOGO - display Linux Logo in upper left corner
@@
-92,8
+92,6
@@
CONFIG_VIDEO_HW_CURSOR: - Uses the hardware cursor capability of the
#include <common.h>
#include <common.h>
-#ifdef CONFIG_CFB_CONSOLE
-
#include <malloc.h>
/*****************************************************************************/
#include <malloc.h>
/*****************************************************************************/
@@
-316,10
+314,10
@@
void console_cursor (int state);
#else
#define SWAP16(x) (x)
#define SWAP32(x) (x)
#else
#define SWAP16(x) (x)
#define SWAP32(x) (x)
-#if !defined(VIDEO_FB_16BPP_PIXEL_SWAP)
-#define SHORTSWAP32(x) (x)
-#else
+#if defined(VIDEO_FB_16BPP_PIXEL_SWAP)
#define SHORTSWAP32(x) ( ((x) >> 16) | ((x) << 16) )
#define SHORTSWAP32(x) ( ((x) >> 16) | ((x) << 16) )
+#else
+#define SHORTSWAP32(x) (x)
#endif
#endif
#endif
#endif
@@
-826,19
+824,19
@@
int video_display_bitmap (ulong bmp_image, int x, int y)
/*
* Could be a gzipped bmp image, try to decrompress...
*/
/*
* Could be a gzipped bmp image, try to decrompress...
*/
- len = C
FG
_VIDEO_LOGO_MAX_SIZE;
- dst = malloc(C
FG
_VIDEO_LOGO_MAX_SIZE);
+ len = C
ONFIG_SYS
_VIDEO_LOGO_MAX_SIZE;
+ dst = malloc(C
ONFIG_SYS
_VIDEO_LOGO_MAX_SIZE);
if (dst == NULL) {
printf("Error: malloc in gunzip failed!\n");
return(1);
}
if (dst == NULL) {
printf("Error: malloc in gunzip failed!\n");
return(1);
}
- if (gunzip(dst, C
FG
_VIDEO_LOGO_MAX_SIZE, (uchar *)bmp_image, &len) != 0) {
+ if (gunzip(dst, C
ONFIG_SYS
_VIDEO_LOGO_MAX_SIZE, (uchar *)bmp_image, &len) != 0) {
printf ("Error: no valid bmp or bmp.gz image at %lx\n", bmp_image);
free(dst);
return 1;
}
printf ("Error: no valid bmp or bmp.gz image at %lx\n", bmp_image);
free(dst);
return 1;
}
- if (len == C
FG
_VIDEO_LOGO_MAX_SIZE) {
- printf("Image could be truncated (increase C
FG
_VIDEO_LOGO_MAX_SIZE)!\n");
+ if (len == C
ONFIG_SYS
_VIDEO_LOGO_MAX_SIZE) {
+ printf("Image could be truncated (increase C
ONFIG_SYS
_VIDEO_LOGO_MAX_SIZE)!\n");
}
/*
}
/*
@@
-934,12
+932,12
@@
int video_display_bitmap (ulong bmp_image, int x, int y)
xcount = width;
while (xcount--) {
cte = bmp->color_table[*bmap++];
xcount = width;
while (xcount--) {
cte = bmp->color_table[*bmap++];
-#if !defined(VIDEO_FB_16BPP_PIXEL_SWAP)
- FILL_15BIT_555RGB (cte.red, cte.green, cte.blue);
-#else
+#if defined(VIDEO_FB_16BPP_PIXEL_SWAP)
fill_555rgb_pswap (fb, xpos++, cte.red,
cte.green, cte.blue);
fb += 2;
fill_555rgb_pswap (fb, xpos++, cte.red,
cte.green, cte.blue);
fb += 2;
+#else
+ FILL_15BIT_555RGB (cte.red, cte.green, cte.blue);
#endif
}
bmap += padded_line;
#endif
}
bmap += padded_line;
@@
-1008,12
+1006,12
@@
int video_display_bitmap (ulong bmp_image, int x, int y)
WATCHDOG_RESET ();
xcount = width;
while (xcount--) {
WATCHDOG_RESET ();
xcount = width;
while (xcount--) {
-#if !defined(VIDEO_FB_16BPP_PIXEL_SWAP)
- FILL_15BIT_555RGB (bmap[2], bmap[1], bmap[0]);
-#else
+#if defined(VIDEO_FB_16BPP_PIXEL_SWAP)
fill_555rgb_pswap (fb, xpos++, bmap[2],
bmap[1], bmap[0]);
fb += 2;
fill_555rgb_pswap (fb, xpos++, bmap[2],
bmap[1], bmap[0]);
fb += 2;
+#else
+ FILL_15BIT_555RGB (bmap[2], bmap[1], bmap[0]);
#endif
bmap += 3;
}
#endif
bmap += 3;
}
@@
-1138,11
+1136,11
@@
void logo_plot (void *screen, int width, int x, int y)
*dest = ((r >> 5) << 5) | ((g >> 5) << 2) | (b >> 6);
break;
case GDF_15BIT_555RGB:
*dest = ((r >> 5) << 5) | ((g >> 5) << 2) | (b >> 6);
break;
case GDF_15BIT_555RGB:
-#if !defined(VIDEO_FB_16BPP_PIXEL_SWAP)
+#if defined(VIDEO_FB_16BPP_PIXEL_SWAP)
+ fill_555rgb_pswap (dest, xpos++, r, g, b);
+#else
*(unsigned short *) dest =
SWAP16 ((unsigned short) (((r >> 3) << 10) | ((g >> 3) << 5) | (b >> 3)));
*(unsigned short *) dest =
SWAP16 ((unsigned short) (((r >> 3) << 10) | ((g >> 3) << 5) | (b >> 3)));
-#else
- fill_555rgb_pswap (dest, xpos++, r, g, b);
#endif
break;
case GDF_16BIT_565RGB:
#endif
break;
case GDF_16BIT_565RGB:
@@
-1352,4
+1350,3
@@
int drv_video_init (void)
/* No console dev available */
return 0;
}
/* No console dev available */
return 0;
}
-#endif /* CONFIG_CFB_CONSOLE */