public inbox for linux-serial@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] tty/sysrq: make sysrq_replay_logs_op const
@ 2025-04-03  8:38 xiaopeitux
  2025-04-03  8:45 ` Greg KH
  2025-04-11  9:18 ` Pei Xiao
  0 siblings, 2 replies; 3+ messages in thread
From: xiaopeitux @ 2025-04-03  8:38 UTC (permalink / raw)
  To: gregkh, jirislaby, linux-kernel, linux-serial; +Cc: Pei Xiao

From: Pei Xiao <xiaopei01@kylinos.cn>

Mark sysrq_replay_logs_op as const, preventing accidental modification.

Signed-off-by: Pei Xiao <xiaopei01@kylinos.cn>
---
 drivers/tty/sysrq.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/tty/sysrq.c b/drivers/tty/sysrq.c
index f85ce02e4725..e9ada1c14e26 100644
--- a/drivers/tty/sysrq.c
+++ b/drivers/tty/sysrq.c
@@ -454,7 +454,7 @@ static void sysrq_handle_replay_logs(u8 key)
 {
 	console_try_replay_all();
 }
-static struct sysrq_key_op sysrq_replay_logs_op = {
+static const struct sysrq_key_op sysrq_replay_logs_op = {
 	.handler        = sysrq_handle_replay_logs,
 	.help_msg       = "replay-kernel-logs(R)",
 	.action_msg     = "Replay kernel logs on consoles",
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] tty/sysrq: make sysrq_replay_logs_op const
  2025-04-03  8:38 [PATCH] tty/sysrq: make sysrq_replay_logs_op const xiaopeitux
@ 2025-04-03  8:45 ` Greg KH
  2025-04-11  9:18 ` Pei Xiao
  1 sibling, 0 replies; 3+ messages in thread
From: Greg KH @ 2025-04-03  8:45 UTC (permalink / raw)
  To: xiaopeitux; +Cc: jirislaby, linux-kernel, linux-serial, Pei Xiao

On Thu, Apr 03, 2025 at 04:38:18PM +0800, xiaopeitux@foxmail.com wrote:
> From: Pei Xiao <xiaopei01@kylinos.cn>
> 
> Mark sysrq_replay_logs_op as const, preventing accidental modification.
> 
> Signed-off-by: Pei Xiao <xiaopei01@kylinos.cn>
> ---
>  drivers/tty/sysrq.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/tty/sysrq.c b/drivers/tty/sysrq.c
> index f85ce02e4725..e9ada1c14e26 100644
> --- a/drivers/tty/sysrq.c
> +++ b/drivers/tty/sysrq.c
> @@ -454,7 +454,7 @@ static void sysrq_handle_replay_logs(u8 key)
>  {
>  	console_try_replay_all();
>  }
> -static struct sysrq_key_op sysrq_replay_logs_op = {
> +static const struct sysrq_key_op sysrq_replay_logs_op = {
>  	.handler        = sysrq_handle_replay_logs,
>  	.help_msg       = "replay-kernel-logs(R)",
>  	.action_msg     = "Replay kernel logs on consoles",
> -- 
> 2.25.1
> 

Hi,

This is the friendly patch-bot of Greg Kroah-Hartman.  You have sent him
a patch that has triggered this response.  He used to manually respond
to these common problems, but in order to save his sanity (he kept
writing the same thing over and over, yet to different people), I was
created.  Hopefully you will not take offence and will fix the problem
in your patch and resubmit it so that it can be accepted into the Linux
kernel tree.

You are receiving this message because of the following common error(s)
as indicated below:

- This looks like a new version of a previously submitted patch, but you
  did not list below the --- line any changes from the previous version.
  Please read the section entitled "The canonical patch format" in the
  kernel file, Documentation/process/submitting-patches.rst for what
  needs to be done here to properly describe this.

If you wish to discuss this problem further, or you have questions about
how to resolve this issue, please feel free to respond to this email and
Greg will reply once he has dug out from the pending patches received
from other developers.

thanks,

greg k-h's patch email bot

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] tty/sysrq: make sysrq_replay_logs_op const
  2025-04-03  8:38 [PATCH] tty/sysrq: make sysrq_replay_logs_op const xiaopeitux
  2025-04-03  8:45 ` Greg KH
@ 2025-04-11  9:18 ` Pei Xiao
  1 sibling, 0 replies; 3+ messages in thread
From: Pei Xiao @ 2025-04-11  9:18 UTC (permalink / raw)
  To: xiaopeitux, gregkh, jirislaby, linux-kernel, linux-serial

在 2025/4/3 16:38, xiaopeitux@foxmail.com 写道:

> From: Pei Xiao <xiaopei01@kylinos.cn>
>
> Mark sysrq_replay_logs_op as const, preventing accidental modification.
>
> Signed-off-by: Pei Xiao <xiaopei01@kylinos.cn>
> ---
>  drivers/tty/sysrq.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/tty/sysrq.c b/drivers/tty/sysrq.c
> index f85ce02e4725..e9ada1c14e26 100644
> --- a/drivers/tty/sysrq.c
> +++ b/drivers/tty/sysrq.c
> @@ -454,7 +454,7 @@ static void sysrq_handle_replay_logs(u8 key)
>  {
>  	console_try_replay_all();
>  }
> -static struct sysrq_key_op sysrq_replay_logs_op = {
> +static const struct sysrq_key_op sysrq_replay_logs_op = {
>  	.handler        = sysrq_handle_replay_logs,
>  	.help_msg       = "replay-kernel-logs(R)",
>  	.action_msg     = "Replay kernel logs on consoles",

now, split into a single patch.

Thanks!

Pei.


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2025-04-11  9:18 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-04-03  8:38 [PATCH] tty/sysrq: make sysrq_replay_logs_op const xiaopeitux
2025-04-03  8:45 ` Greg KH
2025-04-11  9:18 ` Pei Xiao

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox