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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20160104154305.GA24533@kroah.com>
Date:	Mon, 4 Jan 2016 07:43:05 -0800
From:	Greg KH <gregkh@...uxfoundation.org>
To:	Pierre Paul MINGOT <mingot.pierre@...il.com>
Cc:	jslaby@...e.cz, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] Add possibility to set /dev/tty number

On Mon, Jan 04, 2016 at 04:34:56PM +0100, Pierre Paul MINGOT wrote:
> Hello,
> 
> In Linux there is no way to set the number of tty devices or console
> to create. By default the kernel create 64 /dev/tty devices. what is
> too much for embedded system with limited resources.

Really?  How much memory does a vt device take up?

> As all these 64
> devices are not necessary or mandatory for the kernel proper working,
> I add a config option to set the desired tty. The lowest number you
> can set is 1 and the highest is 63, any value respectively below or
> above that, will cause a kconfig invalid entry pop-up.
> 
> Please keep me update.

Please don't attach patches, I can't do anything with them, you should
include them directly in your email.  Also, if you look at your patch:

> From 430deaf09da90bf0da03b7ca612cd4481ad30fea Mon Sep 17 00:00:00 2001
> From: Pierre Paul MINGOT <mingot.pierre@...il.com>
> Date: Thu, 22 Jan 2015 17:51:49 +0100
> Subject: [PATCH] In Linux there is no way to set the number of tty devices or
>  console to create. By default the kernel create 64 /dev/tty devices. what is
>  too much for embedded system with limited resources. As all these 64 devices
>  are not necessary or mandatory for the kernel proper working, I add a config
>  option to set the desired tty. The lowest number you can set is 1 and the
>  highest is 63, any value respectively below or above that, will cause a
>  kconfig invalid entry pop-up.

The entire changelog entry is in the Subject, which I doubt is what you
want :(

Please fix it up to have a short subject first and resend, after fixing
the errors below as well:

> diff --git a/drivers/tty/Kconfig b/drivers/tty/Kconfig
> index b24aa01..0ec58a2 100644
> --- a/drivers/tty/Kconfig
> +++ b/drivers/tty/Kconfig
> @@ -75,6 +75,19 @@ config VT_CONSOLE_SLEEP
>  	def_bool y
>  	depends on VT_CONSOLE && PM_SLEEP
>  
> +config NR_TTY_DEVICES
> +    int "Maximum tty device number"
> +    depends on VT
> +    range 1 63
> +    default 1
> +    ---help---
> +    This is the highest numbered device created in /dev. You will actually have
> +	NR_TTY_DEVICES+1 devices in /dev. The default is 63, which will result in
> +	64 /dev entries. The lowest number you can set is 1 and the highest is 63,
> +    anything respectively below or above that, is not possible and will cause
> +    a kconfig invalid entry pop-up.
> +    So the default value will be set.
> +

Odd mixture of tabs and spaces, just always use tabs please.

And the default should not be 1, keep it what it is today.

>  config HW_CONSOLE
>  	bool
>  	depends on VT && !UML
> @@ -419,4 +432,5 @@ config DA_CONSOLE
>  	help
>  	  This enables a console on a Dash channel.
>  
> +
>  endif # TTY
> diff --git a/include/uapi/linux/vt.h b/include/uapi/linux/vt.h
> index 978578b..2140496 100644
> --- a/include/uapi/linux/vt.h
> +++ b/include/uapi/linux/vt.h
> @@ -7,8 +7,8 @@
>   * resizing).
>   */
>  #define MIN_NR_CONSOLES 1       /* must be at least 1 */
> -#define MAX_NR_CONSOLES	63	/* serial lines start at 64 */
> -#define MAX_NR_USER_CONSOLES 63	/* must be root to allocate above this */
> +/* serial lines start at 64 */

This doesn't make sense anymore, right?

Are you breaking the serial line minor number with this change?

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