Brijesh-Thakkar commented on code in PR #20842: URL: https://github.com/apache/nuttx/pull/20842#discussion_r4342497981
########## drivers/serial/uart_16550.c: ########## @@ -53,6 +53,19 @@ * Pre-processor Definitions ****************************************************************************/ +/* Optional per-port hooks. Without CONFIG_16550_PORT_HOOKS every port has + * an interrupt and the default attach/detach, which lets the compiler drop + * the code that handles the hooks. + */ + +#ifdef CONFIG_16550_PORT_HOOKS Review Comment: Re-measured after rebasing on a16dbf2100 (GCC 15, whole image): | config | without this option | with it | saved | |---|---|---|---| | qemu-intel64:nsh | +128 B | +0 B | 128 B | | qemu-i486:nsh | +372 B | +128 B | 244 B | | qemu-intel64:nsh_pci | +134 B | +4 B | 130 B | It's paid by every 16550 user for hooks only board-defined ports need, which is why I gated it. But if you'd rather avoid the extra Kconfig symbol and macros, I'll drop the commit. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
