mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-21 11:44:01 +08:00
f212ec4b7b
This patch adds a new configuration option, which adds support for a new early_param which gets checked in arch/x86/kernel/setup_{32,64}.c:setup_arch() to decide wether OHCI-1394 FireWire controllers should be initialized and enabled for physical DMA access to allow remote debugging of early problems like issues ACPI or other subsystems which are executed very early. If the config option is not enabled, no code is changed, and if the boot paramenter is not given, no new code is executed, and independent of that, all new code is freed after boot, so the config option can be even enabled in standard, non-debug kernels. With specialized tools, it is then possible to get debugging information from machines which have no serial ports (notebooks) such as the printk buffer contents, or any data which can be referenced from global pointers, if it is stored below the 4GB limit and even memory dumps of of the physical RAM region below the 4GB limit can be taken without any cooperation from the CPU of the host, so the machine can be crashed early, it does not matter. In the extreme, even kernel debuggers can be accessed in this way. I wrote a small kgdb module and an accompanying gdb stub for FireWire which allows to gdb to talk to kgdb using remote remory reads and writes over FireWire. An version of the gdb stub fore FireWire is able to read all global data from a system which is running a a normal kernel without any kernel debugger, without any interruption or support of the system's CPU. That way, e.g. the task struct and so on can be read and even manipulated when the physical DMA access is granted. A HOWTO is included in this patch, in Documentation/debugging-via-ohci1394.txt and I've put a copy online at ftp://ftp.suse.de/private/bk/firewire/docs/debugging-via-ohci1394.txt It also has links to all the tools which are available to make use of it another copy of it is online at: ftp://ftp.suse.de/private/bk/firewire/kernel/ohci1394_dma_early-v2.diff Signed-Off-By: Bernhard Kaindl <bk@suse.de> Tested-By: Thomas Renninger <trenn@suse.de> Signed-off-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
19 lines
600 B
Makefile
19 lines
600 B
Makefile
#
|
|
# Makefile for the Linux IEEE 1394 implementation
|
|
#
|
|
|
|
ieee1394-objs := ieee1394_core.o ieee1394_transactions.o hosts.o \
|
|
highlevel.o csr.o nodemgr.o dma.o iso.o \
|
|
csr1212.o config_roms.o
|
|
|
|
obj-$(CONFIG_IEEE1394) += ieee1394.o
|
|
obj-$(CONFIG_IEEE1394_PCILYNX) += pcilynx.o
|
|
obj-$(CONFIG_IEEE1394_OHCI1394) += ohci1394.o
|
|
obj-$(CONFIG_IEEE1394_VIDEO1394) += video1394.o
|
|
obj-$(CONFIG_IEEE1394_RAWIO) += raw1394.o
|
|
obj-$(CONFIG_IEEE1394_SBP2) += sbp2.o
|
|
obj-$(CONFIG_IEEE1394_DV1394) += dv1394.o
|
|
obj-$(CONFIG_IEEE1394_ETH1394) += eth1394.o
|
|
|
|
obj-$(CONFIG_PROVIDE_OHCI1394_DMA_INIT) += init_ohci1394_dma.o
|