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

Commit de0a5345 authored by Linus Torvalds's avatar Linus Torvalds
Browse files

Merge branch 'for-linus' of git://github.com/richardweinberger/linux

* 'for-linus' of git://github.com/richardweinberger/linux: (90 commits)
  um: fix ubd cow size
  um: Fix kmalloc argument order in um/vdso/vma.c
  um: switch to use of drivers/Kconfig
  UserModeLinux-HOWTO.txt: fix a typo
  UserModeLinux-HOWTO.txt: remove ^H characters
  um: we need sys/user.h only on i386
  um: merge delay_{32,64}.c
  um: distribute exports to where exported stuff is defined
  um: kill system-um.h
  um: generic ftrace.h will do...
  um: segment.h is x86-only and needed only there
  um: asm/pda.h is not needed anymore
  um: hw_irq.h can go generic as well
  um: switch to generic-y
  um: clean Kconfig up a bit
  um: a couple of missing dependencies...
  um: kill useless argument of free_chan() and free_one_chan()
  um: unify ptrace_user.h
  um: unify KSTK_...
  um: fix gcov build breakage
  ...
parents 994c0e99 85356398
Loading
Loading
Loading
Loading
+266 −266

File changed.

Preview size limit exceeded, changes collapsed.

+1 −113
Original line number Original line Diff line number Diff line

menu "UML Character Devices"
menu "Character Devices"


config STDERR_CONSOLE
config STDERR_CONSOLE
	bool "stderr console"
	bool "stderr console"
@@ -105,92 +104,6 @@ config SSL_CHAN
          this if you expect the UML that you build to be run in environments
          this if you expect the UML that you build to be run in environments
          which don't have a set of /dev/pty* devices.
          which don't have a set of /dev/pty* devices.


config UNIX98_PTYS
	bool "Unix98 PTY support"
	help
	  A pseudo terminal (PTY) is a software device consisting of two
	  halves: a master and a slave. The slave device behaves identical to
	  a physical terminal; the master device is used by a process to
	  read data from and write data to the slave, thereby emulating a
	  terminal. Typical programs for the master side are telnet servers
	  and xterms.

	  Linux has traditionally used the BSD-like names /dev/ptyxx for
	  masters and /dev/ttyxx for slaves of pseudo terminals. This scheme
	  has a number of problems. The GNU C library glibc 2.1 and later,
	  however, supports the Unix98 naming standard: in order to acquire a
	  pseudo terminal, a process opens /dev/ptmx; the number of the pseudo
	  terminal is then made available to the process and the pseudo
	  terminal slave can be accessed as /dev/pts/<number>. What was
	  traditionally /dev/ttyp2 will then be /dev/pts/2, for example.

	  All modern Linux systems use the Unix98 ptys.  Say Y unless
	  you're on an embedded system and want to conserve memory.

config LEGACY_PTYS
	bool "Legacy (BSD) PTY support"
	default y
	help
	  A pseudo terminal (PTY) is a software device consisting of two
	  halves: a master and a slave. The slave device behaves identical to
	  a physical terminal; the master device is used by a process to
	  read data from and write data to the slave, thereby emulating a
	  terminal. Typical programs for the master side are telnet servers
	  and xterms.

	  Linux has traditionally used the BSD-like names /dev/ptyxx
	  for masters and /dev/ttyxx for slaves of pseudo
	  terminals. This scheme has a number of problems, including
	  security.  This option enables these legacy devices; on most
	  systems, it is safe to say N.

config RAW_DRIVER
        tristate "RAW driver (/dev/raw/rawN)"
	depends on BLOCK
        help
          The raw driver permits block devices to be bound to /dev/raw/rawN.
          Once bound, I/O against /dev/raw/rawN uses efficient zero-copy I/O.
          See the raw(8) manpage for more details.

          Applications should preferably open the device (eg /dev/hda1)
          with the O_DIRECT flag.

config MAX_RAW_DEVS
        int "Maximum number of RAW devices to support (1-8192)"
        depends on RAW_DRIVER
        default "256"
        help
          The maximum number of RAW devices that are supported.
          Default is 256. Increase this number in case you need lots of
          raw devices.

config LEGACY_PTY_COUNT
	int "Maximum number of legacy PTY in use"
	depends on LEGACY_PTYS
	default "256"
	help
	  The maximum number of legacy PTYs that can be used at any one time.
	  The default is 256, and should be more than enough.  Embedded
	  systems may want to reduce this to save memory.

	  When not in use, each legacy PTY occupies 12 bytes on 32-bit
	  architectures and 24 bytes on 64-bit architectures.

config WATCHDOG
	bool "Watchdog Timer Support"

config WATCHDOG_NOWAYOUT
	bool "Disable watchdog shutdown on close"
	depends on WATCHDOG

config SOFT_WATCHDOG
	tristate "Software Watchdog"
	depends on WATCHDOG

config UML_WATCHDOG
	tristate "UML watchdog"
	depends on WATCHDOG

config UML_SOUND
config UML_SOUND
	tristate "Sound support"
	tristate "Sound support"
	help
	help
@@ -211,29 +124,4 @@ config HOSTAUDIO
	tristate
	tristate
	default UML_SOUND
	default UML_SOUND


#It is selected elsewhere, so kconfig would warn without this.
config HW_RANDOM
	tristate
	default n

config UML_RANDOM
	tristate "Hardware random number generator"
	help
	  This option enables UML's "hardware" random number generator.  It
	  attaches itself to the host's /dev/random, supplying as much entropy
	  as the host has, rather than the small amount the UML gets from its
	  own drivers.  It registers itself as a standard hardware random number
	  generator, major 10, minor 183, and the canonical device name is
	  /dev/hwrng.
	  The way to make use of this is to install the rng-tools package
	  (check your distro, or download from
	  http://sourceforge.net/projects/gkernel/).  rngd periodically reads
	  /dev/hwrng and injects the entropy into /dev/random.

config MMAPPER
	tristate "iomem emulation driver"
	help
	  This driver allows a host file to be used as emulated IO memory inside
	  UML.

endmenu
endmenu
+1 −22
Original line number Original line Diff line number Diff line
@@ -2,20 +2,14 @@ source "init/Kconfig"


source "kernel/Kconfig.freezer"
source "kernel/Kconfig.freezer"


source "drivers/block/Kconfig"

source "arch/um/Kconfig.char"
source "arch/um/Kconfig.char"


source "drivers/base/Kconfig"
source "drivers/Kconfig"


source "net/Kconfig"
source "net/Kconfig"


source "arch/um/Kconfig.net"
source "arch/um/Kconfig.net"


source "drivers/net/Kconfig"

source "drivers/connector/Kconfig"

source "fs/Kconfig"
source "fs/Kconfig"


source "security/Kconfig"
source "security/Kconfig"
@@ -24,19 +18,4 @@ source "crypto/Kconfig"


source "lib/Kconfig"
source "lib/Kconfig"


source "drivers/scsi/Kconfig"

source "drivers/md/Kconfig"

if BROKEN
	source "drivers/mtd/Kconfig"
endif

source "drivers/leds/Kconfig"

#This is just to shut up some Kconfig warnings, so no prompt.
config INPUT
	tristate
	default n

source "arch/um/Kconfig.debug"
source "arch/um/Kconfig.debug"
+6 −0
Original line number Original line Diff line number Diff line
@@ -148,5 +148,11 @@ config KERNEL_STACK_ORDER
	  be 1 << order pages.  The default is OK unless you're running Valgrind
	  be 1 << order pages.  The default is OK unless you're running Valgrind
	  on UML, in which case, set this to 3.
	  on UML, in which case, set this to 3.


config MMAPPER
	tristate "iomem emulation driver"
	help
	  This driver allows a host file to be used as emulated IO memory inside
	  UML.

config NO_DMA
config NO_DMA
	def_bool y
	def_bool y
+26 −23
Original line number Original line Diff line number Diff line
@@ -20,15 +20,27 @@ core-y += $(ARCH_DIR)/kernel/ \


MODE_INCLUDE	+= -I$(srctree)/$(ARCH_DIR)/include/shared/skas
MODE_INCLUDE	+= -I$(srctree)/$(ARCH_DIR)/include/shared/skas


HEADER_ARCH 	:= $(SUBARCH)

# Additional ARCH settings for x86
ifeq ($(SUBARCH),i386)
        HEADER_ARCH := x86
endif
ifeq ($(SUBARCH),x86_64)
        HEADER_ARCH := x86
endif

HOST_DIR := arch/$(HEADER_ARCH)

include $(srctree)/$(ARCH_DIR)/Makefile-skas
include $(srctree)/$(ARCH_DIR)/Makefile-skas
include $(srctree)/$(HOST_DIR)/Makefile.um

core-y += $(HOST_DIR)/um/


SHARED_HEADERS	:= $(ARCH_DIR)/include/shared
SHARED_HEADERS	:= $(ARCH_DIR)/include/shared
ARCH_INCLUDE	:= -I$(srctree)/$(SHARED_HEADERS)
ARCH_INCLUDE	:= -I$(srctree)/$(SHARED_HEADERS)
ARCH_INCLUDE	+= -I$(srctree)/$(ARCH_DIR)/sys-$(SUBARCH)/shared
ARCH_INCLUDE	+= -I$(srctree)/$(HOST_DIR)/um/shared
ifneq ($(KBUILD_SRC),)
KBUILD_CPPFLAGS += -I$(srctree)/$(HOST_DIR)/um
ARCH_INCLUDE	+= -I$(SHARED_HEADERS)
endif
KBUILD_CPPFLAGS += -I$(srctree)/$(ARCH_DIR)/sys-$(SUBARCH)


# -Dvmap=kernel_vmap prevents anything from referencing the libpcap.o symbol so
# -Dvmap=kernel_vmap prevents anything from referencing the libpcap.o symbol so
# named - it's a common symbol in libpcap, so we get a binary which crashes.
# named - it's a common symbol in libpcap, so we get a binary which crashes.
@@ -47,14 +59,12 @@ KBUILD_AFLAGS += $(ARCH_INCLUDE)


USER_CFLAGS = $(patsubst $(KERNEL_DEFINES),,$(patsubst -D__KERNEL__,,\
USER_CFLAGS = $(patsubst $(KERNEL_DEFINES),,$(patsubst -D__KERNEL__,,\
	$(patsubst -I%,,$(KBUILD_CFLAGS)))) $(ARCH_INCLUDE) $(MODE_INCLUDE) \
	$(patsubst -I%,,$(KBUILD_CFLAGS)))) $(ARCH_INCLUDE) $(MODE_INCLUDE) \
	$(filter -I%,$(CFLAGS)) -D_FILE_OFFSET_BITS=64
	$(filter -I%,$(CFLAGS)) -D_FILE_OFFSET_BITS=64 -idirafter include

include $(srctree)/$(ARCH_DIR)/Makefile-$(SUBARCH)


#This will adjust *FLAGS accordingly to the platform.
#This will adjust *FLAGS accordingly to the platform.
include $(srctree)/$(ARCH_DIR)/Makefile-os-$(OS)
include $(srctree)/$(ARCH_DIR)/Makefile-os-$(OS)


KBUILD_CPPFLAGS += -I$(srctree)/arch/$(HEADER_ARCH)/include
KBUILD_CPPFLAGS += -I$(srctree)/$(HOST_DIR)/include


# -Derrno=kernel_errno - This turns all kernel references to errno into
# -Derrno=kernel_errno - This turns all kernel references to errno into
# kernel_errno to separate them from the libc errno.  This allows -fno-common
# kernel_errno to separate them from the libc errno.  This allows -fno-common
@@ -84,10 +94,9 @@ define archhelp
  echo '		   find in the kernel root.'
  echo '		   find in the kernel root.'
endef
endef


KBUILD_KCONFIG := arch/um/Kconfig.$(HEADER_ARCH)
KBUILD_KCONFIG := $(HOST_DIR)/um/Kconfig


archprepare: $(SHARED_HEADERS)/user_constants.h
archprepare: include/generated/user_constants.h
archprepare: $(SHARED_HEADERS)/kern_constants.h


LINK-$(CONFIG_LD_SCRIPT_STATIC) += -static
LINK-$(CONFIG_LD_SCRIPT_STATIC) += -static
LINK-$(CONFIG_LD_SCRIPT_DYN) += -Wl,-rpath,/lib
LINK-$(CONFIG_LD_SCRIPT_DYN) += -Wl,-rpath,/lib
@@ -118,9 +127,7 @@ endef


# When cleaning we don't include .config, so we don't include
# When cleaning we don't include .config, so we don't include
# TT or skas makefiles and don't clean skas_ptregs.h.
# TT or skas makefiles and don't clean skas_ptregs.h.
CLEAN_FILES += linux x.i gmon.out \
CLEAN_FILES += linux x.i gmon.out
	$(SHARED_HEADERS)/user_constants.h \
	$(SHARED_HEADERS)/kern_constants.h


archclean:
archclean:
	@find . \( -name '*.bb' -o -name '*.bbg' -o -name '*.da' \
	@find . \( -name '*.bb' -o -name '*.bbg' -o -name '*.da' \
@@ -128,8 +135,8 @@ archclean:


# Generated files
# Generated files


$(ARCH_DIR)/sys-$(SUBARCH)/user-offsets.s: FORCE
$(HOST_DIR)/um/user-offsets.s: FORCE
	$(Q)$(MAKE) $(build)=$(ARCH_DIR)/sys-$(SUBARCH) $@
	$(Q)$(MAKE) $(build)=$(HOST_DIR)/um $@


define filechk_gen-asm-offsets
define filechk_gen-asm-offsets
        (set -e; \
        (set -e; \
@@ -144,11 +151,7 @@ define filechk_gen-asm-offsets
         echo ""; )
         echo ""; )
endef
endef


$(SHARED_HEADERS)/user_constants.h: $(ARCH_DIR)/sys-$(SUBARCH)/user-offsets.s
include/generated/user_constants.h: $(HOST_DIR)/um/user-offsets.s
	$(call filechk,gen-asm-offsets)
	$(call filechk,gen-asm-offsets)


$(SHARED_HEADERS)/kern_constants.h:
export SUBARCH USER_CFLAGS CFLAGS_NO_HARDENING OS DEV_NULL_PATH
	$(Q)mkdir -p $(dir $@)
	$(Q)echo '#include "../../../../include/generated/asm-offsets.h"' >$@

export SUBARCH USER_CFLAGS CFLAGS_NO_HARDENING OS HEADER_ARCH DEV_NULL_PATH
Loading