mirror of
https://xff.cz/git/u-boot/
synced 2025-11-02 03:17:29 +01:00
video: consolidate splash screen alignment code
Code for checking "splashpos" environment variable is duplicated in drivers, move it to the common function. Call this function also in the bmp display command to consider "splashpos" settings. Signed-off-by: Anatolij Gustschin <agust@denx.de> Acked-by: Otavio Salvador <otavio@ossystems.com.br>
This commit is contained in:
@@ -31,6 +31,7 @@
|
||||
#include <command.h>
|
||||
#include <asm/byteorder.h>
|
||||
#include <malloc.h>
|
||||
#include <splash.h>
|
||||
#include <video.h>
|
||||
|
||||
static int bmp_info (ulong addr);
|
||||
@@ -125,6 +126,8 @@ static int do_bmp_display(cmd_tbl_t * cmdtp, int flag, int argc, char * const ar
|
||||
ulong addr;
|
||||
int x = 0, y = 0;
|
||||
|
||||
splash_get_pos(&x, &y);
|
||||
|
||||
switch (argc) {
|
||||
case 1: /* use load_addr as default address */
|
||||
addr = load_addr;
|
||||
|
||||
Reference in New Issue
Block a user