project:cfg:BoardConfig_IPC: Added fastboot BoardConfig file and firmware post-scripts, distinguishing between the BoardConfigs for Luckfox Pico Pro and Luckfox Pico Max. project:app: Added fastboot_client and rk_smart_door for quick boot applications; updated rkipc app to adapt to the latest media library. media:samples: Added more usage examples. media:rockit: Fixed bugs; removed support for retrieving data frames from VPSS. media:isp: Updated rkaiq library and related tools to support connection to RKISP_Tuner. sysdrv:Makefile: Added support for compiling drv_ko on Luckfox Pico Ultra W using Ubuntu; added support for custom root filesystem. sysdrv:tools:board: Updated Buildroot optional mirror sources, updated some software versions, and stored device tree files and configuration files that undergo multiple modifications for U-Boot and kernel separately. sysdrv:source:mcu: Used RISC-V MCU SDK with RT-Thread system, mainly for initializing camera AE during quick boot. sysdrv:source:uboot: Added support for fastboot; added high baud rate DDR bin for serial firmware upgrades. sysdrv:source:kernel: Upgraded to version 5.10.160; increased NPU frequency for RV1106G3; added support for fastboot. Signed-off-by: luckfox-eng29 <eng29@luckfox.com>
100 lines
3.1 KiB
Diff
100 lines
3.1 KiB
Diff
From 94a0b2232c729c757547b88f2cbc035cef7e0bc1 Mon Sep 17 00:00:00 2001
|
|
From: luckfox-eng29 <eng29@luckfox.com>
|
|
Date: Tue, 8 Oct 2024 21:50:54 +0800
|
|
Subject: [PATCH] patch:logo_center
|
|
|
|
Signed-off-by: luckfox-eng29 <eng29@luckfox.com>
|
|
---
|
|
.../source/kernel/drivers/video/fbdev/core/fbcon.c | 14 +++++++++++++-
|
|
.../source/kernel/drivers/video/fbdev/core/fbmem.c | 7 ++++++-
|
|
2 files changed, 19 insertions(+), 2 deletions(-)
|
|
|
|
diff --git a/sysdrv/source/kernel/drivers/video/fbdev/core/fbcon.c b/sysdrv/source/kernel/drivers/video/fbdev/core/fbcon.c
|
|
index 27828435d..c3ac676bb 100644
|
|
--- a/sysdrv/source/kernel/drivers/video/fbdev/core/fbcon.c
|
|
+++ b/sysdrv/source/kernel/drivers/video/fbdev/core/fbcon.c
|
|
@@ -88,6 +88,9 @@
|
|
# define DPRINTK(fmt, args...)
|
|
#endif
|
|
|
|
+#define CURSOR_ENABLE 0
|
|
+#define SHOW_CENTER 1
|
|
+
|
|
/*
|
|
* FIXME: Locking
|
|
*
|
|
@@ -365,6 +368,7 @@ static int get_color(struct vc_data *vc, struct fb_info *info,
|
|
|
|
static void fb_flashcursor(struct work_struct *work)
|
|
{
|
|
+#if CURSOR_ENABLE
|
|
struct fb_info *info = container_of(work, struct fb_info, queue);
|
|
struct fbcon_ops *ops = info->fbcon_par;
|
|
struct vc_data *vc = NULL;
|
|
@@ -395,6 +399,7 @@ static void fb_flashcursor(struct work_struct *work)
|
|
ops->cursor(vc, info, mode, get_color(vc, info, c, 1),
|
|
get_color(vc, info, c, 0));
|
|
console_unlock();
|
|
+#endif
|
|
}
|
|
|
|
static void cursor_timer_handler(struct timer_list *t)
|
|
@@ -601,7 +606,12 @@ static void fbcon_prepare_logo(struct vc_data *vc, struct fb_info *info,
|
|
if (fb_get_color_depth(&info->var, &info->fix) == 1)
|
|
erase &= ~0x400;
|
|
logo_height = fb_prepare_logo(info, ops->rotate);
|
|
- logo_lines = DIV_ROUND_UP(logo_height, vc->vc_font.height);
|
|
+
|
|
+#if SHOW_CENTER
|
|
+ logo_height += (info->var.yres/2) - (logo_height/2);
|
|
+#endif
|
|
+
|
|
+ logo_lines = DIV_ROUND_UP(logo_height, vc->vc_font.height);
|
|
q = (unsigned short *) (vc->vc_origin +
|
|
vc->vc_size_row * rows);
|
|
step = logo_lines * cols;
|
|
@@ -1331,6 +1341,7 @@ static void fbcon_clear_margins(struct vc_data *vc, int bottom_only)
|
|
|
|
static void fbcon_cursor(struct vc_data *vc, int mode)
|
|
{
|
|
+#if CURSOR_ENABLE
|
|
struct fb_info *info = registered_fb[con2fb_map[vc->vc_num]];
|
|
struct fbcon_ops *ops = info->fbcon_par;
|
|
int c = scr_readw((u16 *) vc->vc_pos);
|
|
@@ -1352,6 +1363,7 @@ static void fbcon_cursor(struct vc_data *vc, int mode)
|
|
|
|
ops->cursor(vc, info, mode, get_color(vc, info, c, 1),
|
|
get_color(vc, info, c, 0));
|
|
+#endif
|
|
}
|
|
|
|
static int scrollback_phys_max = 0;
|
|
diff --git a/sysdrv/source/kernel/drivers/video/fbdev/core/fbmem.c b/sysdrv/source/kernel/drivers/video/fbdev/core/fbmem.c
|
|
index d787a344b..690d48fba 100644
|
|
--- a/sysdrv/source/kernel/drivers/video/fbdev/core/fbmem.c
|
|
+++ b/sysdrv/source/kernel/drivers/video/fbdev/core/fbmem.c
|
|
@@ -38,7 +38,7 @@
|
|
|
|
#include <asm/fb.h>
|
|
|
|
-
|
|
+#define SHOW_CENTER 1
|
|
/*
|
|
* Frame buffer device initialization and setup routines
|
|
*/
|
|
@@ -520,6 +520,11 @@ static int fb_show_logo_line(struct fb_info *info, int rotate,
|
|
image.dy = y;
|
|
}
|
|
|
|
+#if SHOW_CENTER
|
|
+image.dx = (info->var.xres - logo->width) / 2;
|
|
+image.dy = (info->var.yres - logo->height) / 2;
|
|
+#endif
|
|
+
|
|
image.width = logo->width;
|
|
image.height = logo->height;
|
|
|
|
--
|
|
2.34.1
|
|
|