Re: [PATCH v2 1/3] printk: Constify name for add_preferred_console()

From: Petr Mladek
Date: Wed Sep 20 2023 - 06:17:32 EST


On Tue 2023-09-12 14:03:43, Tony Lindgren wrote:
> While adding a preferred console handling for serial_core for serial port
> hardware based device addressing, Jiri suggested we constify name for
> add_preferred_console(). The gets copied anyways. This allows serial core
> to add a preferred console using serial drv->dev_name without copying it.
>
> Note that constifying options causes changes all over the place because of
> struct console for match().
>
> Cc: John Ogness <john.ogness@xxxxxxxxxxxxx>
> Cc: Petr Mladek <pmladek@xxxxxxxx>
> Cc: Sergey Senozhatsky <senozhatsky@xxxxxxxxxxxx>
> Cc: Steven Rostedt <rostedt@xxxxxxxxxxx>
> Suggested-by: Jiri Slaby <jirislaby@xxxxxxxxxx>
> Signed-off-by: Tony Lindgren <tony@xxxxxxxxxxx>

Makes sense:

Reviewed-by: Petr Mladek <pmladek@xxxxxxxx>

I assume that this patch would via Greg's tree together with
the rest of the patchset. Please, tell me if you would prefer to
queue this via printk tree.

Best Regards,
Petr