android_kernel_xiaomi_sm8350/drivers/char
Neil Horman d6580a9f15 kexec: sysrq: simplify sysrq-c handler
Currently the sysrq-c handler is bit over-engineered.  Its behavior is
dependent on a few compile time and run time factors that alter its
behavior which is really unnecessecary.

If CONFIG_KEXEC is not configured, sysrq-c, crashes the system with a NULL
pointer dereference.  If CONFIG_KEXEC is configured, it calls crash_kexec
directly, which implies that the kexec kernel will either be booted (if
its been previously loaded), or it will simply do nothing (the no kexec
kernel has been loaded).

It would be much easier to just simplify the whole thing to dereference a
NULL pointer all the time regardless of configuration.  That way, it will
always try to crash the system, and if a kexec kernel has been loaded into
reserved space, it will still boot from the page fault trap handler
(assuming panic_on_oops is set appropriately).

[akpm@linux-foundation.org: build fix]
Signed-off-by: Neil Horman <nhorman@tuxdriver.com>
Acked-by: Vivek Goyal <vgoyal@redhat.com>
Cc: Brayan Arraes <brayan@yack.com.br>
Cc: "Eric W. Biederman" <ebiederm@xmission.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2009-06-18 13:03:59 -07:00
..
agp [IA64] Convert ia64 to use int-ll64.h 2009-06-17 09:33:49 -07:00
hw_random MIPS: hwrng: Add TX4939 RNG driver 2009-06-17 11:06:27 +01:00
ip2 tty: rewrite the ldisc locking 2009-06-11 08:51:01 -07:00
ipmi ipmi: remove driver_data direct access of struct device 2009-06-15 21:30:27 -07:00
mwave mwave: struct device - replace bus_id with dev_name(), dev_set_name() 2009-01-06 10:44:38 -08:00
pcmcia tty: Add carrier processing on close to the tty_port core 2009-06-11 08:50:56 -07:00
rio rio: addition has higher precedence than ?: 2009-04-06 14:36:43 -07:00
tpm TPM: get_event_name stack corruption 2009-05-20 08:30:05 +10:00
xilinx_hwicap
.gitignore
amiserial.c trivial: typo (en|dis|avail|remove)bale -> (en|dis|avail|remove)able 2009-06-12 18:01:45 +02:00
apm-emulation.c
applicom.c applicom: Auto-load applicom module when device opened. 2009-04-06 14:36:30 -07:00
applicom.h
bfin_jtag_comm.c tty: bfin_jtag_comm: emulate a TTY over the Blackfin EMUDAT/JTAG interface 2009-06-11 08:51:06 -07:00
bfin-otp.c
briq_panel.c
bsr.c trivial: drivers/char/bsr.c: Storage class should be before const qualifier 2009-03-30 15:22:02 +02:00
cd1865.h
ChangeLog
consolemap.c consolemap: indentation & braces disagree - reindent 2009-01-06 15:59:30 -08:00
cp437.uni
cs5535_gpio.c
cyclades.c tty: rewrite the ldisc locking 2009-06-11 08:51:01 -07:00
defkeymap.c_shipped
defkeymap.map
digi1.h
digiFep1.h
digiPCI.h
ds1302.c
ds1620.c
dsp56k.c
dtlk.c
efirtc.c
epca.c tty: rewrite the ldisc locking 2009-06-11 08:51:01 -07:00
epca.h
epcaconfig.h
esp.c esp: fix section mismatch warning 2009-04-07 08:31:03 -07:00
generic_nvram.c
generic_serial.c tty: Remove some pointless casts 2009-01-02 10:19:40 -08:00
genrtc.c
hangcheck-timer.c
hpet.c irq: change ACPI GSI APIs to also take a device argument 2009-04-28 12:21:17 +02:00
hvc_beat.c powerpc/cell: Use correct types in beat files 2009-01-08 16:25:16 +11:00
hvc_console.c hvc_console: Remove tty->low_latency 2009-01-16 16:15:16 +11:00
hvc_console.h
hvc_irq.c hvc_console: Call free_irq() only if request_irq() was successful 2009-01-13 14:48:01 +11:00
hvc_iseries.c
hvc_iucv.c [S390] pm: hvc_iucv power management callbacks 2009-06-16 10:31:19 +02:00
hvc_rtas.c
hvc_udbg.c
hvc_vio.c
hvc_xen.c
hvcs.c hvcs: remove driver_data direct access of struct device 2009-06-15 21:30:27 -07:00
hvsi.c hvc_console: Remove tty->low_latency on pseries backends 2009-03-11 10:44:26 +11:00
i8k.c i8k: Add Dell Vostro systems 2009-01-02 10:28:32 -08:00
isicom.c Char: isicom: fix build warning 2009-06-18 13:03:54 -07:00
istallion.c tty: Add carrier processing on close to the tty_port core 2009-06-11 08:50:56 -07:00
Kconfig drivers/char/rtc: disable legacy RTC driver on Blackfin systems 2009-06-18 13:03:43 -07:00
keyboard.c
lp.c
Makefile tty: bfin_jtag_comm: emulate a TTY over the Blackfin EMUDAT/JTAG interface 2009-06-11 08:51:06 -07:00
mbcs.c
mbcs.h
mem.c drivers/char/mem.c: memory_open() cleanup: lookup minor device number from devlist 2009-06-18 13:03:54 -07:00
misc.c Driver Core: misc: add nodename support for misc devices. 2009-06-15 21:30:25 -07:00
mmtimer.c
moxa.c moxa: prevent opening unavailable ports 2009-06-11 08:51:09 -07:00
moxa.h
mspec.c
mxser.c tty: Add carrier processing on close to the tty_port core 2009-06-11 08:50:56 -07:00
mxser.h
n_hdlc.c tty: rewrite the ldisc locking 2009-06-11 08:51:01 -07:00
n_r3964.c tty: Remove some pointless casts 2009-01-02 10:19:40 -08:00
n_tty.c tty: simplify buffer allocator cleanups 2009-06-11 08:51:02 -07:00
nozomi.c tty: kref nozomi 2009-01-02 10:19:40 -08:00
nsc_gpio.c
nvram.c
nwbutton.c
nwbutton.h
nwflash.c
pc8736x_gpio.c
ppdev.c ppdev: reduce kernel log spam 2009-06-18 13:03:54 -07:00
ps3flash.c ps3flash: Always read chunks of 256 KiB, and cache them 2009-06-15 16:47:27 +10:00
pty.c pty: Narrow the race on ldisc locking 2009-06-16 12:01:16 -07:00
random.c Avoid ICE in get_random_int() with gcc-3.4.5 2009-05-19 11:25:35 -07:00
raw.c Driver Core: raw: add nodename for raw devices 2009-06-15 21:30:26 -07:00
riscom8_reg.h
riscom8.c riscom8: Auto-load riscom8 module when device opened. 2009-04-06 14:36:31 -07:00
riscom8.h
rocket_int.h tty: rocketport uses different port flags to everyone else 2009-01-02 10:19:39 -08:00
rocket.c rocket: fix test_bit parameters 2009-06-11 08:50:58 -07:00
rocket.h tty: rocketport uses different port flags to everyone else 2009-01-02 10:19:39 -08:00
rtc.c RTC: Remove the BKL. 2009-01-08 16:44:03 -07:00
scc.h m68k: atari - Rename "mfp" to "st_mfp" 2009-02-22 09:23:02 -08:00
scx200_gpio.c
selection.c tty: rewrite the ldisc locking 2009-06-11 08:51:01 -07:00
ser_a2232.c m68k: ser_a2232 - Kill warn_unused_result warnings 2009-01-12 20:56:39 +01:00
ser_a2232.h
ser_a2232fw.ax
ser_a2232fw.h
serial167.c tty: Remove some pointless casts 2009-01-02 10:19:40 -08:00
snsc_event.c
snsc.c
snsc.h
sonypi.c Rationalize fasync return values 2009-03-16 08:34:35 -06:00
specialix_io8.h
specialix.c specialix: Auto-load specialix module when device opened. 2009-04-06 14:36:31 -07:00
stallion.c tty: Add carrier processing on close to the tty_port core 2009-06-11 08:50:56 -07:00
sx.c sx.c: avoid referencing freed memory if copy_from_user() fails 2009-02-20 17:57:49 -08:00
sx.h
sxboards.h
sxwindow.h
synclink_gt.c tty: synclink_gt add receive pio mode 2009-06-11 08:50:57 -07:00
synclink.c tty: Add carrier processing on close to the tty_port core 2009-06-11 08:50:56 -07:00
synclinkmp.c tty: Add carrier processing on close to the tty_port core 2009-06-11 08:50:56 -07:00
sysrq.c kexec: sysrq: simplify sysrq-c handler 2009-06-18 13:03:59 -07:00
tb0219.c
tlclk.c
toshiba.c
tty_audit.c tty: remove buffer special casing 2009-06-11 08:51:02 -07:00
tty_buffer.c
tty_io.c tty: fix sanity check 2009-06-16 12:01:16 -07:00
tty_ioctl.c tty: fix unused warning when TCGETX is not defined 2009-06-16 12:01:16 -07:00
tty_ldisc.c ldisc: debug aids 2009-06-16 12:01:16 -07:00
tty_port.c tty: use prepare/finish_wait 2009-06-11 08:51:07 -07:00
vc_screen.c vcs: hook sysfs devices into object lifetime instead of "binding" 2009-03-24 16:38:26 -07:00
viotape.c tape: beyond ARRAY_SIZE of viocd_diskinfo 2009-06-02 10:32:34 +10:00
virtio_console.c virtio: find_vqs/del_vqs virtio operations 2009-06-12 22:16:36 +09:30
vme_scc.c m68k: vme_scc - Kill warn_unused_result warnings 2009-01-12 20:56:38 +01:00
vr41xx_giu.c
vt_ioctl.c vt: Add a note on the historical abuse of CLOCK_TICK_RATE 2009-05-06 14:47:13 -07:00
vt.c console: make blank timeout value a boot option 2009-06-16 19:47:52 -07:00