forked from luck/tmp_suning_uos_patched
dc52ddc0e6
This patch implements a new freezer subsystem in the control groups framework. It provides a way to stop and resume execution of all tasks in a cgroup by writing in the cgroup filesystem. The freezer subsystem in the container filesystem defines a file named freezer.state. Writing "FROZEN" to the state file will freeze all tasks in the cgroup. Subsequently writing "RUNNING" will unfreeze the tasks in the cgroup. Reading will return the current state. * Examples of usage : # mkdir /containers/freezer # mount -t cgroup -ofreezer freezer /containers # mkdir /containers/0 # echo $some_pid > /containers/0/tasks to get status of the freezer subsystem : # cat /containers/0/freezer.state RUNNING to freeze all tasks in the container : # echo FROZEN > /containers/0/freezer.state # cat /containers/0/freezer.state FREEZING # cat /containers/0/freezer.state FROZEN to unfreeze all tasks in the container : # echo RUNNING > /containers/0/freezer.state # cat /containers/0/freezer.state RUNNING This is the basic mechanism which should do the right thing for user space task in a simple scenario. It's important to note that freezing can be incomplete. In that case we return EBUSY. This means that some tasks in the cgroup are busy doing something that prevents us from completely freezing the cgroup at this time. After EBUSY, the cgroup will remain partially frozen -- reflected by freezer.state reporting "FREEZING" when read. The state will remain "FREEZING" until one of these things happens: 1) Userspace cancels the freezing operation by writing "RUNNING" to the freezer.state file 2) Userspace retries the freezing operation by writing "FROZEN" to the freezer.state file (writing "FREEZING" is not legal and returns EIO) 3) The tasks that blocked the cgroup from entering the "FROZEN" state disappear from the cgroup's set of tasks. [akpm@linux-foundation.org: coding-style fixes] [akpm@linux-foundation.org: export thaw_process] Signed-off-by: Cedric Le Goater <clg@fr.ibm.com> Signed-off-by: Matt Helsley <matthltc@us.ibm.com> Acked-by: Serge E. Hallyn <serue@us.ibm.com> Tested-by: Matt Helsley <matthltc@us.ibm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
230 lines
5.6 KiB
Plaintext
230 lines
5.6 KiB
Plaintext
#
|
|
# For a description of the syntax of this configuration file,
|
|
# see Documentation/kbuild/kconfig-language.txt.
|
|
#
|
|
|
|
mainmenu "uClinux/h8300 (w/o MMU) Kernel Configuration"
|
|
|
|
config H8300
|
|
bool
|
|
default y
|
|
select HAVE_IDE
|
|
|
|
config MMU
|
|
bool
|
|
default n
|
|
|
|
config SWAP
|
|
bool
|
|
default n
|
|
|
|
config ZONE_DMA
|
|
bool
|
|
default y
|
|
|
|
config FPU
|
|
bool
|
|
default n
|
|
|
|
config RWSEM_GENERIC_SPINLOCK
|
|
bool
|
|
default y
|
|
|
|
config RWSEM_XCHGADD_ALGORITHM
|
|
bool
|
|
default n
|
|
|
|
config ARCH_HAS_ILOG2_U32
|
|
bool
|
|
default n
|
|
|
|
config ARCH_HAS_ILOG2_U64
|
|
bool
|
|
default n
|
|
|
|
config GENERIC_FIND_NEXT_BIT
|
|
bool
|
|
default y
|
|
|
|
config GENERIC_HWEIGHT
|
|
bool
|
|
default y
|
|
|
|
config GENERIC_HARDIRQS
|
|
bool
|
|
default y
|
|
|
|
config GENERIC_CALIBRATE_DELAY
|
|
bool
|
|
default y
|
|
|
|
config GENERIC_TIME
|
|
bool
|
|
default y
|
|
|
|
config GENERIC_BUG
|
|
bool
|
|
depends on BUG
|
|
|
|
config TIME_LOW_RES
|
|
bool
|
|
default y
|
|
|
|
config NO_IOPORT
|
|
def_bool y
|
|
|
|
config NO_DMA
|
|
def_bool y
|
|
|
|
config ISA
|
|
bool
|
|
default y
|
|
|
|
config PCI
|
|
bool
|
|
default n
|
|
|
|
config HZ
|
|
int
|
|
default 100
|
|
|
|
source "init/Kconfig"
|
|
|
|
source "kernel/Kconfig.freezer"
|
|
|
|
source "arch/h8300/Kconfig.cpu"
|
|
|
|
menu "Executable file formats"
|
|
|
|
source "fs/Kconfig.binfmt"
|
|
|
|
endmenu
|
|
|
|
source "net/Kconfig"
|
|
|
|
source "drivers/base/Kconfig"
|
|
|
|
source "drivers/mtd/Kconfig"
|
|
|
|
source "drivers/block/Kconfig"
|
|
|
|
source "drivers/ide/Kconfig"
|
|
|
|
source "arch/h8300/Kconfig.ide"
|
|
|
|
source "drivers/net/Kconfig"
|
|
|
|
#
|
|
# input - input/joystick depends on it. As does USB.
|
|
#
|
|
source "drivers/input/Kconfig"
|
|
|
|
menu "Character devices"
|
|
|
|
config VT
|
|
bool "Virtual terminal"
|
|
---help---
|
|
If you say Y here, you will get support for terminal devices with
|
|
display and keyboard devices. These are called "virtual" because you
|
|
can run several virtual terminals (also called virtual consoles) on
|
|
one physical terminal. This is rather useful, for example one
|
|
virtual terminal can collect system messages and warnings, another
|
|
one can be used for a text-mode user session, and a third could run
|
|
an X session, all in parallel. Switching between virtual terminals
|
|
is done with certain key combinations, usually Alt-<function key>.
|
|
|
|
The setterm command ("man setterm") can be used to change the
|
|
properties (such as colors or beeping) of a virtual terminal. The
|
|
man page console_codes(4) ("man console_codes") contains the special
|
|
character sequences that can be used to change those properties
|
|
directly. The fonts used on virtual terminals can be changed with
|
|
the setfont ("man setfont") command and the key bindings are defined
|
|
with the loadkeys ("man loadkeys") command.
|
|
|
|
You need at least one virtual terminal device in order to make use
|
|
of your keyboard and monitor. Therefore, only people configuring an
|
|
embedded system would want to say N here in order to save some
|
|
memory; the only way to log into such a system is then via a serial
|
|
or network connection.
|
|
|
|
If unsure, say Y, or else you won't be able to do much with your new
|
|
shiny Linux system :-)
|
|
|
|
config VT_CONSOLE
|
|
bool "Support for console on virtual terminal"
|
|
depends on VT
|
|
---help---
|
|
The system console is the device which receives all kernel messages
|
|
and warnings and which allows logins in single user mode. If you
|
|
answer Y here, a virtual terminal (the device used to interact with
|
|
a physical terminal) can be used as system console. This is the most
|
|
common mode of operations, so you should say Y here unless you want
|
|
the kernel messages be output only to a serial port (in which case
|
|
you should say Y to "Console on serial port", below).
|
|
|
|
If you do say Y here, by default the currently visible virtual
|
|
terminal (/dev/tty0) will be used as system console. You can change
|
|
that with a kernel command line option such as "console=tty3" which
|
|
would use the third virtual terminal as system console. (Try "man
|
|
bootparam" or see the documentation of your boot loader (lilo or
|
|
loadlin) about how to pass options to the kernel at boot time.)
|
|
|
|
If unsure, say Y.
|
|
|
|
config HW_CONSOLE
|
|
bool
|
|
depends on VT && !S390 && !UM
|
|
default y
|
|
|
|
comment "Unix98 PTY support"
|
|
|
|
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.
|
|
|
|
The entries in /dev/pts/ are created on the fly by a virtual
|
|
file system; therefore, if you say Y here you should say Y to
|
|
"/dev/pts file system for Unix98 PTYs" as well.
|
|
|
|
If you want to say Y here, you need to have the C library glibc 2.1
|
|
or later (equal to libc-6.1, check with "ls -l /lib/libc.so.*").
|
|
Read the instructions in <file:Documentation/Changes> pertaining to
|
|
pseudo terminals. It's safe to say N.
|
|
|
|
source "drivers/char/pcmcia/Kconfig"
|
|
|
|
source "drivers/serial/Kconfig"
|
|
|
|
source "drivers/i2c/Kconfig"
|
|
|
|
source "drivers/hwmon/Kconfig"
|
|
|
|
source "drivers/usb/Kconfig"
|
|
|
|
endmenu
|
|
|
|
source "fs/Kconfig"
|
|
|
|
source "arch/h8300/Kconfig.debug"
|
|
|
|
source "security/Kconfig"
|
|
|
|
source "crypto/Kconfig"
|
|
|
|
source "lib/Kconfig"
|