2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-16 17:23:55 +08:00
linux-next/include/trace/events
Mathieu Desnoyers 66cc69e34e Fix: module signature vs tracepoints: add new TAINT_UNSIGNED_MODULE
Users have reported being unable to trace non-signed modules loaded
within a kernel supporting module signature.

This is caused by tracepoint.c:tracepoint_module_coming() refusing to
take into account tracepoints sitting within force-loaded modules
(TAINT_FORCED_MODULE). The reason for this check, in the first place, is
that a force-loaded module may have a struct module incompatible with
the layout expected by the kernel, and can thus cause a kernel crash
upon forced load of that module on a kernel with CONFIG_TRACEPOINTS=y.

Tracepoints, however, specifically accept TAINT_OOT_MODULE and
TAINT_CRAP, since those modules do not lead to the "very likely system
crash" issue cited above for force-loaded modules.

With kernels having CONFIG_MODULE_SIG=y (signed modules), a non-signed
module is tainted re-using the TAINT_FORCED_MODULE taint flag.
Unfortunately, this means that Tracepoints treat that module as a
force-loaded module, and thus silently refuse to consider any tracepoint
within this module.

Since an unsigned module does not fit within the "very likely system
crash" category of tainting, add a new TAINT_UNSIGNED_MODULE taint flag
to specifically address this taint behavior, and accept those modules
within Tracepoints. We use the letter 'X' as a taint flag character for
a module being loaded that doesn't know how to sign its name (proposed
by Steven Rostedt).

Also add the missing 'O' entry to trace event show_module_flags() list
for the sake of completeness.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Acked-by: Steven Rostedt <rostedt@goodmis.org>
NAKed-by: Ingo Molnar <mingo@redhat.com>
CC: Thomas Gleixner <tglx@linutronix.de>
CC: David Howells <dhowells@redhat.com>
CC: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2014-03-13 12:11:51 +10:30
..
9p.h 9p: trace: use %*ph to dump buffer 2013-05-28 13:42:08 -05:00
asoc.h ASoC: trace: Make sure trace header doesnt depend on any headers 2013-09-17 00:37:03 +01:00
bcache.h bcache: Add struct btree_keys 2014-01-08 13:05:13 -08:00
block.h block: Abstract out bvec iterator 2013-11-23 22:33:47 -08:00
btrfs.h Btrfs/tracepoint: update new flags for ordered extent TP 2014-01-28 13:19:38 -08:00
compaction.h mm: compaction: trace compaction begin and end 2014-01-21 16:19:48 -08:00
context_tracking.h context_tracking: User/kernel broundary cross trace events 2013-08-14 17:14:48 +02:00
ext3.h jbd: change journal_invalidatepage() to accept length 2013-05-21 23:26:36 -04:00
ext4.h ext4: isolate ext4_extents.h file 2013-08-28 14:47:06 -04:00
f2fs.h Merge branch 'for-3.14/core' of git://git.kernel.dk/linux-block 2014-01-30 11:19:05 -08:00
filemap.h mm: trace filemap add and del 2013-04-29 15:54:28 -07:00
gfpflags.h mm: add a __GFP_KMEMCG flag 2012-12-18 15:02:12 -08:00
gpio.h
host1x.h gpu: host1x: Add channel support 2013-04-22 12:32:43 +02:00
iommu.h iommu: Add iommu_error class event to iommu trace 2013-09-25 11:07:04 +02:00
irq.h
jbd2.h jbd2: trace when lock_buffer in do_get_write_access takes a long time 2013-04-21 16:47:54 -04:00
jbd.h jbd: Write journal superblock with WRITE_FUA after checkpointing 2012-05-15 23:34:37 +02:00
kmem.h mm: get rid of unnecessary overhead of trace_mm_page_alloc_extfrag() 2013-11-13 12:09:10 +09:00
kvm.h KVM: Drop FOLL_GET in GUP when doing async page fault 2013-10-15 13:43:37 +03:00
lock.h
mce.h
migrate.h mm: numa: trace tasks that fail migration due to rate limiting 2014-01-21 16:19:48 -08:00
module.h Fix: module signature vs tracepoints: add new TAINT_UNSIGNED_MODULE 2014-03-13 12:11:51 +10:30
napi.h
net.h net: Add trace events for all receive entry points, exposing more skb fields 2014-01-14 14:46:02 -08:00
nmi.h x86: Add NMI duration tracepoints 2013-06-23 11:52:58 +02:00
oom.h mm, oom: change type of oom_score_adj to short 2012-12-11 17:22:27 -08:00
pagemap.h mm: add tracepoints for LRU activation and insertions 2013-07-03 16:07:31 -07:00
power_cpu_migrate.h ARM: bL_switcher/trace: Add trace trigger for trace bootstrapping 2013-09-23 18:47:30 -04:00
power.h intel_pstate: Remove energy reporting from pstate_sample tracepoint 2014-02-13 02:11:18 +01:00
printk.h printk/tracing: rework console tracing 2013-04-29 18:28:13 -07:00
random.h random: convert DEBUG_ENT to tracepoints 2013-10-10 14:32:23 -04:00
ras.h PCI, AER: Fix severity usage in aer trace event 2013-12-08 15:39:10 +01:00
rcu.h rcu: Avoid sparse warnings in rcu_nocb_wake trace event 2013-09-23 09:18:17 -07:00
regmap.h regmap: Add support for discarding parts of the register cache 2013-05-12 18:46:47 +04:00
regulator.h
rpm.h
sched.h sched: add tracepoints related to NUMA task migration 2014-01-21 16:19:48 -08:00
scsi.h
signal.h
skb.h
sock.h
spi.h spi: Provide common spi_message processing loop 2013-10-11 20:09:50 +01:00
sunrpc.h SUNRPC: Fix oops when trace sunrpc_task events in nfs client 2014-03-07 19:10:08 -05:00
swiotlb.h tracing/events: Add bounce tracing to swiotbl 2013-10-02 12:53:26 -04:00
syscalls.h
target.h target: Fix assignment of LUN in tracepoints 2013-10-09 01:54:44 -07:00
task.h mm, oom: change type of oom_score_adj to short 2012-12-11 17:22:27 -08:00
timer.h Merge branch 'timers-nohz-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2013-05-05 13:23:27 -07:00
udp.h
v4l2.h [media] v4l2-dev: Add tracepoints for QBUF and DQBUF 2013-12-10 15:53:43 -02:00
vmscan.h shrinker: Kill old ->shrink API. 2013-09-10 18:56:32 -04:00
workqueue.h workqueue: rename cpu_workqueue to pool_workqueue 2013-02-13 19:29:12 -08:00
writeback.h Revert "writeback: do not sync data dirtied after sync start" 2014-02-22 02:02:28 +01:00
xen.h xen/mmu: Use Xen specific TLB flush instead of the generic one. 2012-10-31 12:38:31 -04:00