cmd: pxe: execute the cls command only when supported
PATCH 1/1 cmd: pxe: execute the cls command only when supported
Execute the command cls (for clear screen), when the "menu background" keyword is present in extlinux.conf file, only if the command is supported.
This patch avoid the warning "Unknown command 'cls'"
with "menu background" in extlinux.conf when CONFIG_CMD_BMP is activated and CONFIG_CMD_CLS not activated (default for CONFIG_DM_VIDEO).
---
cmd/pxe.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
cmd/pxe.c +2 -1
@@ -1592,7 +1592,8 @@ static void handle_pxe_menu(cmd_tbl_t *cmdtp, struct pxe_menu *cfg)/* display BMP if available */ if (cfg->bmp) {if (get_relfile (cmdtp, cfg->bmp, load_addr)) { -run_command ("cls" ,0 ); +if (CONFIG_IS_ENABLED (CMD_CLS )) +run_command ("cls" ,0 );bmp_display (load_addr,BMP_ALIGN_CENTER ,BMP_ALIGN_CENTER ); }else {
Signature · 1 line
2.17.1
PATCH 1/1 cmd: pxe: execute the cls command only when supported
Hi Patrick
Quoted 18 lines · Patrick Delaunay
Execute the command cls (for clear screen), when the "menu background" keyword is present in extlinux.conf file, only if the command is supported.
This patch avoid the warning "Unknown command 'cls'"
with "menu background" in extlinux.conf whenCONFIG_CMD_BMPis activated andCONFIG_CMD_CLSnot activated (default forCONFIG_DM_VIDEO).Signed-off-by Patrick Delaunay <[email protected]>---
cmd/pxe.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)cmd/pxe.c +0
-0
cmd/pxe.c static void handle_pxe_menu(cmd_tbl_t *cmdtp, struct pxe_menu *cfg) · line 1599
Quoted 9 lines
cmd/pxe.c +2
-1@@ -1592,7 +1592,8 @@ static void handle_pxe_menu(cmd_tbl_t *cmdtp, struct pxe_menu *cfg)/* display BMP if available */ if (cfg->bmp) {if (get_relfile (cmdtp, cfg->bmp, load_addr)) { -run_command ("cls" ,0 ); +if (CONFIG_IS_ENABLED (CMD_CLS )) +run_command ("cls" ,0 );bmp_display (load_addr,BMP_ALIGN_CENTER ,BMP_ALIGN_CENTER ); }else {
Thanks
PATCH 1/1 cmd: pxe: execute the cls command only when supported
In reply to Patrick DelaunayQuoted 9 lines · Patrick Delaunay
Execute the command cls (for clear screen), when the "menu background" keyword is present in extlinux.conf file, only if the command is supported.
This patch avoid the warning "Unknown command 'cls'"
with "menu background" in extlinux.conf whenCONFIG_CMD_BMPis activated andCONFIG_CMD_CLSnot activated (default forCONFIG_DM_VIDEO).Signed-off-by Patrick Delaunay <[email protected]>Reviewed-by Patrice Chotard <[email protected]>
Applied to u-boot/master, thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 833 bytes Desc: not available URL: <https://lists.denx.de/pipermail/u-boot/attachments/20200123/d86f22b7/attachment.sig>