Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4f73bc4d authored by Joe Millenbach's avatar Joe Millenbach Committed by Greg Kroah-Hartman
Browse files

tty: Added a CONFIG_TTY option to allow removal of TTY



The option allows you to remove TTY and compile without errors. This
saves space on systems that won't support TTY interfaces anyway.
bloat-o-meter output is below.

The bulk of this patch consists of Kconfig changes adding "depends on
TTY" to various serial devices and similar drivers that require the TTY
layer.  Ideally, these dependencies would occur on a common intermediate
symbol such as SERIO, but most drivers "select SERIO" rather than
"depends on SERIO", and "select" does not respect dependencies.

bloat-o-meter output comparing our previous minimal to new minimal by
removing TTY.  The list is filtered to not show removed entries with awk
'$3 != "-"' as the list was very long.

add/remove: 0/226 grow/shrink: 2/14 up/down: 6/-35356 (-35350)
function                                     old     new   delta
chr_dev_init                                 166     170      +4
allow_signal                                  80      82      +2
static.__warned                              143     142      -1
disallow_signal                               63      62      -1
__set_special_pids                            95      94      -1
unregister_console                           126     121      -5
start_kernel                                 546     541      -5
register_console                             593     588      -5
copy_from_user                                45      40      -5
sys_setsid                                   128     120      -8
sys_vhangup                                   32      19     -13
do_exit                                     1543    1526     -17
bitmap_zero                                   60      40     -20
arch_local_irq_save                          137     117     -20
release_task                                 674     652     -22
static.spin_unlock_irqrestore                308     260     -48

Signed-off-by: default avatarJoe Millenbach <jmillenbach@gmail.com>
Reviewed-by: default avatarJamey Sharp <jamey@minilop.net>
Reviewed-by: default avatarJosh Triplett <josh@joshtriplett.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent a1bf9584
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -125,6 +125,7 @@ choice

config ALPHA_GENERIC
	bool "Generic"
	depends on TTY
	help
	  A generic kernel will run on all supported Alpha hardware.

@@ -491,6 +492,7 @@ config VGA_HOSE

config ALPHA_SRM
	bool "Use SRM as bootloader" if ALPHA_CABRIOLET || ALPHA_AVANTI_CH || ALPHA_EB64P || ALPHA_PC164 || ALPHA_TAKARA || ALPHA_EB164 || ALPHA_ALCOR || ALPHA_MIATA || ALPHA_LX164 || ALPHA_SX164 || ALPHA_NAUTILUS || ALPHA_NONAME
	depends on TTY
	default y if ALPHA_JENSEN || ALPHA_MIKASA || ALPHA_SABLE || ALPHA_LYNX || ALPHA_NORITAKE || ALPHA_DP264 || ALPHA_RAWHIDE || ALPHA_EIGER || ALPHA_WILDFIRE || ALPHA_TITAN || ALPHA_SHARK || ALPHA_MARVEL
	---help---
	  There are two different types of booting firmware on Alphas: SRM,
+1 −0
Original line number Diff line number Diff line
@@ -8,6 +8,7 @@ config HP_SIMETH

config HP_SIMSERIAL
	bool "Simulated serial driver support"
	depends on TTY

config HP_SIMSERIAL_CONSOLE
	bool "Console for HP simulator"
+1 −1
Original line number Diff line number Diff line
@@ -41,7 +41,7 @@ config NFBLOCK

config NFCON
	tristate "NatFeat console driver"
	depends on NATFEAT
	depends on TTY && NATFEAT
	help
	  Say Y to include support for the ARAnyM NatFeat console driver
	  which allows the console output to be redirected to the stderr
+1 −0
Original line number Diff line number Diff line
@@ -23,6 +23,7 @@ config PARISC
	select HAVE_MOD_ARCH_SPECIFIC
	select MODULES_USE_ELF_RELA
	select CLONE_BACKWARDS
	select TTY # Needed for pdc_cons.c

	help
	  The PA-RISC microprocessor is designed by Hewlett-Packard and used
+1 −0
Original line number Diff line number Diff line
@@ -121,6 +121,7 @@ config DEBUG_COPY_FROM_USER
	def_bool n

config HVC_TILE
	depends on TTY
	select HVC_DRIVER
	def_bool y

Loading