[PATCH 1/2] cli: allow users to disable history if unused at all

Tom Rini trini at konsulko.com
Fri Mar 1 22:37:02 CET 2024


On Sat, Feb 17, 2024 at 09:54:43PM +0800, Hanyuan Zhao wrote:

> This commit allows user to determine whether to have history recording
> in command-line. Previously the history data as uninitialized static
> array would not directly take much space in binary file since it only
> marks size in the binary. However now it asks to allocate space. By
> connecting the original CMD_HISTORY flag in Kconfig, users could unset
> the whole history function, and the memory usage could be eased, if the
> history function is not used at all.
> 
> Signed-off-by: Hanyuan Zhao <hanyuan-z at qq.com>
> ---
>  cmd/Kconfig           |  1 +
>  common/cli_readline.c | 44 ++++++++++++++++++++++++-------------------
>  2 files changed, 26 insertions(+), 19 deletions(-)

This breaks current tests, please re-test, thanks.

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20240301/8dd05dd9/attachment.sig>


More information about the U-Boot mailing list