diff mbox series

[4/7] tty: serial: samsung: constify UART name

Message ID 20220304080348.218581-4-krzysztof.kozlowski@canonical.com (mailing list archive)
State Superseded
Headers show
Series [1/7] tty: serial: samsung: embed s3c24xx_uart_info in parent structure | expand

Commit Message

Krzysztof Kozlowski March 4, 2022, 8:03 a.m. UTC
The UART name from driver data holds only string literals.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com>
---
 drivers/tty/serial/samsung_tty.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Jiri Slaby March 7, 2022, 6:36 a.m. UTC | #1
On 04. 03. 22, 9:03, Krzysztof Kozlowski wrote:
> The UART name from driver data holds only string literals.
> 
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com>

Reviewed-by: Jiri Slaby <jirislaby@kernel.org>

> ---
>   drivers/tty/serial/samsung_tty.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/tty/serial/samsung_tty.c b/drivers/tty/serial/samsung_tty.c
> index 0b4f40044e87..279c413f2300 100644
> --- a/drivers/tty/serial/samsung_tty.c
> +++ b/drivers/tty/serial/samsung_tty.c
> @@ -63,7 +63,7 @@ enum s3c24xx_port_type {
>   };
>   
>   struct s3c24xx_uart_info {
> -	char			*name;
> +	const char		*name;
>   	enum s3c24xx_port_type	type;
>   	unsigned int		port_type;
>   	unsigned int		fifosize;
diff mbox series

Patch

diff --git a/drivers/tty/serial/samsung_tty.c b/drivers/tty/serial/samsung_tty.c
index 0b4f40044e87..279c413f2300 100644
--- a/drivers/tty/serial/samsung_tty.c
+++ b/drivers/tty/serial/samsung_tty.c
@@ -63,7 +63,7 @@  enum s3c24xx_port_type {
 };
 
 struct s3c24xx_uart_info {
-	char			*name;
+	const char		*name;
 	enum s3c24xx_port_type	type;
 	unsigned int		port_type;
 	unsigned int		fifosize;