lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20131213023239.GA15130@kroah.com>
Date:	Thu, 12 Dec 2013 18:32:39 -0800
From:	Greg Kroah-Hartman <gregkh@...uxfoundation.org>
To:	Shawn Landden <shawn@...rchofgit.com>
Cc:	Jiri Slaby <jslaby@...e.cz>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] tty: only print sysrq help for handlers that are enabled

On Tue, Dec 03, 2013 at 07:55:25AM -0800, Shawn Landden wrote:
> Also print out a notice when sysrq is in selective mode.
> 
> Signed-off-by: Shawn Landden <shawn@...rchofgit.com>
> ---
>  drivers/tty/sysrq.c | 7 ++++++-
>  1 file changed, 6 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/tty/sysrq.c b/drivers/tty/sysrq.c
> index ce396ec..4eee0e4 100644
> --- a/drivers/tty/sysrq.c
> +++ b/drivers/tty/sysrq.c
> @@ -548,9 +548,14 @@ void __handle_sysrq(int key, bool check_mask)
>  					;
>  				if (j != i)
>  					continue;
> -				printk("%s ", sysrq_key_table[i]->help_msg);
> +				/* only print if handler is enabled */
> +				if (sysrq_enabled & 1 ||
> +				    sysrq_enabled & sysrq_key_table[i]->enable_mask)
> +					printk("%s ", sysrq_key_table[i]->help_msg);
>  			}
>  		}
> +		if (!(sysrq_enabled & 1))
> +			printk("(some options are disabled)");
>  		printk("\n");
>  		console_loglevel = orig_log_level;
>  	}

What exactly is this fixing?  What is broken here that this change
resolves?  Where is it applicable?  I need a lot more context here
please.

thanks,

greg k-h
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ