[DTrace-devel] DTrace-V1-ized 5.11.6 pushed to github

Nick Alcock nick.alcock at oracle.com
Wed Mar 17 07:42:24 PDT 2021


Tests passed on x86-64 and AArch64 with https://github.com/oracle/dtrace-utils
(1.x-branch-dev branch). (Non-stress tests only: one stress test
currently fails on x86-64. This is unlikely to affect normal use unless
you do something most unusual like chill()ing on all fbt probes at once.)

The dtrace-utils 1.x-branch-dev branch has changed for this release due
to new translators in 5.11: you'll need to rebuild dtrace-utils after
booting into this kernel.

Pushed to <https://github.com/oracle/dtrace-linux-kernel>, as a branch
with v1 in the name.

This push is of DTrace v1, using a specialized kernel module rather than BPF.


Changes since 5.10.12 are mostly trivial conflict adjustments and
catering to changes in names of things in the AArch64 entry code: but
there is also one buffer overrun fix when using very high-resolution
profile or tick timers whose names are >16 chars in length.  This is,
obviously, only exploitable if you are already root, so this is in
practice a stability fix, not a security fix.

 1:  ee291dd05f9c !  1:  9b2f2261e2f5 ctf: generate CTF information for the kernel
    @@ scripts/Makefile.modfinal
      
      PHONY := __modfinal
      __modfinal:
    - 
    -+include include/config/auto.conf
    - include $(srctree)/scripts/Kbuild.include
    - 
    - # for c_flags
     @@ scripts/Makefile.modfinal: quiet_cmd_cc_o_c = CC [M]  $@
      %.mod.o: %.mod.c FORCE
      	$(call if_changed_dep,cc_o_c)
    @@ scripts/Makefile.modfinal: quiet_cmd_cc_o_c = CC [M]  $@
     +        $(OBJCOPY) $(module-ctf-flags) $@.tmp $@ && rm -f $@.tmp ;	\
      	$(if $(ARCH_POSTLINK), $(MAKE) -f $(ARCH_POSTLINK) $@, true)
      
    --$(modules): %.ko: %.o %.mod.o scripts/module.lds FORCE
    -+$(modules): %.ko: %.o %.mod.o scripts/module.lds $(module-ctfs-modular-prereq) FORCE
    -+	$(call cmd_touch_ctf)
    - 	+$(call if_changed,ld_ko_o)
    + quiet_cmd_btf_ko = BTF [M] $@
    +@@ scripts/Makefile.modfinal: if_changed_except = $(if $(call newer_prereqs_except,$(2))$(cmd-check),      \
    + 	$(cmd);                                                              \
    + 	printf '%s\n' 'cmd_$@ := $(make-cmd)' > $(dot-target).cmd, @:)
      
    - targets += $(modules) $(modules:.ko=.mod.o)
    +-# Re-generate module BTFs if either module's .ko or vmlinux changed
    +-$(modules): %.ko: %.o %.mod.o scripts/module.lds $(if $(KBUILD_BUILTIN),vmlinux) FORCE
    ++# Re-generate module BTFs and any linked-in CTF if either module's .ko or vmlinux changed
    ++$(modules): %.ko: %.o %.mod.o scripts/module.lds $(if $(KBUILD_BUILTIN),vmlinux) $(module-ctfs-modular-prereq) FORCE
    ++	$(call cmd_touch_ctf)
    + 	+$(call if_changed_except,ld_ko_o,vmlinux)
    + ifdef CONFIG_DEBUG_INFO_BTF_MODULES
    + 	+$(if $(newer-prereqs),$(call cmd,btf_ko))
     
      ## scripts/dwarf2ctf/.gitignore (new) ##
     @@
 2:  6ded42dd1578 !  2:  c63a36a9ca35 kallsyms: introduce new /proc/kallmodsyms including builtin modules too
    @@ scripts/Makefile: hostprogs-always-$(CONFIG_MODULE_SIG_FORMAT)		+= sign-file
     +
      HOSTCFLAGS_sorttable.o = -I$(srctree)/tools/include
      HOSTCFLAGS_asn1_compiler.o = -I$(srctree)/include
    - HOSTLDLIBS_sign-file = -lcrypto
    + HOSTCFLAGS_sign-file.o = $(CRYPTO_CFLAGS)
     
      ## scripts/kallsyms.c ##
     @@
 3:  7cbd018b36da !  3:  291708a48979 waitfd: new syscall implementing waitpid() over fds
    @@ Commit message
     
      ## arch/x86/entry/syscalls/syscall_32.tbl ##
     @@
    - 438	i386	pidfd_getfd		sys_pidfd_getfd
      439	i386	faccessat2		sys_faccessat2
      440	i386	process_madvise		sys_process_madvise
    + 441	i386	epoll_pwait2		sys_epoll_pwait2		compat_sys_epoll_pwait2
     +# This one is a temporary number, designed for no clashes.
     +# Nothing but DTrace should use it.
     +473	i386	waitfd			sys_waitfd
     
      ## arch/x86/entry/syscalls/syscall_64.tbl ##
     @@
    - 438	common	pidfd_getfd		sys_pidfd_getfd
      439	common	faccessat2		sys_faccessat2
      440	common	process_madvise		sys_process_madvise
    + 441	common	epoll_pwait2		sys_epoll_pwait2
     +# This one is a temporary number, designed for no clashes.
     +# Nothing but DTrace should use it.
     +473	common	waitfd			sys_waitfd
    @@ fs/aio.c: struct aio_poll_table {
     
      ## fs/eventpoll.c ##
     @@ fs/eventpoll.c: struct epitem {
    - 	/* Number of active wait queue attached to poll operations */
    - 	int nwait;
    + 	/* The file descriptor information this item refers to */
    + 	struct epoll_filefd ffd;
      
     +	/* fd always raises this fixed event. */
     +	unsigned long fixed_event;
     +
      	/* List containing poll wait queues */
    - 	struct list_head pwqlist;
    + 	struct eppoll_entry *pwqlist;
      
    -@@ fs/eventpoll.c: static int ep_eventpoll_release(struct inode *inode, struct file *file)
    - static __poll_t ep_read_events_proc(struct eventpoll *ep, struct list_head *head,
    - 			       void *priv);
    - static void ep_ptable_queue_proc(struct file *file, wait_queue_head_t *whead,
    --				 poll_table *pt);
    -+				 poll_table *pt, unsigned long fixed_event);
    - 
    - /*
    -  * Differs from ep_eventpoll_poll() in that internal callers already have
     @@ fs/eventpoll.c: static int ep_poll_callback(wait_queue_entry_t *wait, unsigned mode, int sync, v
      	if (!(epi->event.events & EPOLLEXCLUSIVE))
      		ewake = 1;
    @@ fs/eventpoll.c: static int ep_poll_callback(wait_queue_entry_t *wait, unsigned m
     -				 poll_table *pt)
     +				 poll_table *pt, unsigned long fixed_event)
      {
    - 	struct epitem *epi = ep_item_from_epqueue(pt);
    - 	struct eppoll_entry *pwq;
    + 	struct ep_pqueue *epq = container_of(pt, struct ep_pqueue, pt);
    + 	struct epitem *epi = epq->epi;
    +@@ fs/eventpoll.c: static void ep_ptable_queue_proc(struct file *file, wait_queue_head_t *whead,
    + 	if (unlikely(!epi))	// an earlier allocation has failed
    + 		return;
      
     +	if (fixed_event & !(epi->event.events & fixed_event))
     +		return;
    @@ fs/eventpoll.c: static int ep_poll_callback(wait_queue_entry_t *wait, unsigned m
     +	if (fixed_event)
     +		epi->fixed_event = fixed_event;
     +
    - 	if (epi->nwait >= 0 && (pwq = kmem_cache_alloc(pwq_cache, GFP_KERNEL))) {
    - 		init_waitqueue_func_entry(&pwq->wait, ep_poll_callback);
    - 		pwq->whead = whead;
    + 	pwq = kmem_cache_alloc(pwq_cache, GFP_KERNEL);
    + 	if (unlikely(!pwq)) {
    + 		epq->epi = NULL;
     @@ fs/eventpoll.c: static int ep_insert(struct eventpoll *ep, const struct epoll_event *event,
    + 	epi->ep = ep;
      	ep_set_ffd(&epi->ffd, tfile, fd);
      	epi->event = *event;
    - 	epi->nwait = 0;
     +	epi->fixed_event = 0;
      	epi->next = EP_UNACTIVE_PTR;
    - 	if (epi->event.events & EPOLLWAKEUP) {
    - 		error = ep_create_wakeup_source(epi);
    -@@ fs/eventpoll.c: static int __init eventpoll_init(void)
    - 	 * We can have many thousands of epitems, so prevent this from
    - 	 * using an extra cache line on 64-bit (and smaller) CPUs
    - 	 */
    --	BUILD_BUG_ON(sizeof(void *) <= 8 && sizeof(struct epitem) > 128);
      
    - 	/* Allocates slab cache used to allocate "struct epitem" items */
    - 	epi_cache = kmem_cache_create("eventpoll_epi", sizeof(struct epitem),
    + 	if (tep)
     
      ## fs/io_uring.c ##
     @@ fs/io_uring.c: static void __io_queue_proc(struct io_poll_iocb *poll, struct io_poll_table *pt,
    @@ include/linux/syscalls.h: long ksys_old_shmctl(int shmid, int cmd, struct shmid_
      		int __user *optlen);
     
      ## include/uapi/asm-generic/unistd.h ##
    -@@ include/uapi/asm-generic/unistd.h: __SYSCALL(__NR_faccessat2, sys_faccessat2)
    - #define __NR_process_madvise 440
    - __SYSCALL(__NR_process_madvise, sys_process_madvise)
    +@@ include/uapi/asm-generic/unistd.h: __SYSCALL(__NR_process_madvise, sys_process_madvise)
    + #define __NR_epoll_pwait2 441
    + __SC_COMP(__NR_epoll_pwait2, sys_epoll_pwait2, compat_sys_epoll_pwait2)
      
     +#define __NR_waitfd 473
     +__SYSCALL(__NR_waitfd, sys_waitfd)
     +
      #undef __NR_syscalls
    --#define __NR_syscalls 441
    +-#define __NR_syscalls 442
     +#define __NR_syscalls 474
      
      /*
 4:  6b71ecc990f6 !  4:  91d1b20f3df7 dtrace: core and x86
    @@ arch/x86/mm/fault.c: void do_user_addr_fault(struct pt_regs *regs,
     
      ## fs/exec.c ##
     @@
    - #include <linux/compat.h>
      #include <linux/vmalloc.h>
      #include <linux/io_uring.h>
    + #include <linux/syscall_user_dispatch.h>
     +#include <linux/dtrace_os.h>
      
      #include <linux/uaccess.h>
    @@ include/linux/rwlock.h: do {								\
     
      ## include/linux/sched.h ##
     @@
    - #include <linux/rseq.h>
      #include <linux/seqlock.h>
      #include <linux/kcsan.h>
    + #include <asm/kmap_size.h>
     +#include <linux/dtrace_task.h>
      
      /* task_struct member predeclarations (sorted alphabetically): */
    @@ kernel/Makefile: obj-$(CONFIG_TORTURE_TEST) += torture.o
      obj-$(CONFIG_WATCH_QUEUE) += watch_queue.o
     +obj-$(CONFIG_DTRACE) += dtrace/
      
    + obj-$(CONFIG_RESOURCE_KUNIT_TEST) += resource_kunit.o
      obj-$(CONFIG_SYSCTL_KUNIT_TEST) += sysctl-test.o
    - 
     
      ## kernel/dtrace/Kconfig (new) ##
     @@
    @@ kernel/sched/sched.h: extern bool dl_cpu_busy(unsigned int cpu);
      
      struct cfs_rq;
     @@ kernel/sched/sched.h: struct rq {
    - 	/* Must be inspected within a rcu lock section */
    - 	struct cpuidle_state	*idle_state;
      #endif
    + 	unsigned int		push_busy;
    + 	struct cpu_stop_work	push_work;
    ++
     +#ifdef CONFIG_DTRACE
    -+	struct cpuinfo *dtrace_cpu_info;
    ++	struct cpuinfo		*dtrace_cpu_info;
     +#endif
      };
      
 5:  4b3eec83a54c =  5:  212fc90e5cc8 dtrace: modular components and x86 support
 6:  a71a23031f2c =  6:  92d2c47016cb dtrace: systrace provider core components
 7:  5d684eeadb4a =  7:  f6d3e605d306 dtrace: systrace provider
 8:  0bf2a2a85df1 !  8:  0fd149269149 dtrace: sdt provider core components
    @@ arch/x86/kernel/dtrace_util.c: int dtrace_die_notifier(struct notifier_block *nb
      {
      	unsigned long	dummy;
     
    - ## arch/x86/kernel/vmlinux.lds.S ##
    -@@ arch/x86/kernel/vmlinux.lds.S: INIT_PER_CPU(irq_stack_backing_store);
    - /*
    -  * Build-time check on the image size:
    -  */
    --. = ASSERT((_end - _text <= KERNEL_IMAGE_SIZE),
    -+. = ASSERT(((_end < _text) ? (_end < KERNEL_IMAGE_SIZE)
    -+			   : (_end - _text <= KERNEL_IMAGE_SIZE)),
    - 	   "kernel image bigger than KERNEL_IMAGE_SIZE");
    - 
    - #ifdef CONFIG_SMP
    -
      ## include/asm-generic/vmlinux.lds.h ##
     @@
      #define ERROR_INJECT_WHITELIST()
    @@ scripts/Makefile.modfinal: vmlinux.ctfa: $(ctf-filelist)
      $(ctf-stamp): $(ctf-filelist)
      	$(call if_changed,ctf)
      	@shopt -s nullglob; \
    -@@ scripts/Makefile.modfinal: quiet_cmd_ld_ko_o = LD [M]  $@
    -         $(OBJCOPY) $(module-ctf-flags) $@.tmp $@ && rm -f $@.tmp ;	\
    - 	$(if $(ARCH_POSTLINK), $(MAKE) -f $(ARCH_POSTLINK) $@, true)
    +@@ scripts/Makefile.modfinal: if_changed_except = $(if $(call newer_prereqs_except,$(2))$(cmd-check),      \
    + 	printf '%s\n' 'cmd_$@ := $(make-cmd)' > $(dot-target).cmd, @:)
      
    --$(modules): %.ko: %.o %.mod.o scripts/module.lds $(module-ctfs-modular-prereq) FORCE
    -+$(modules): %.ko: %.o %.mod.o %.sdtinfo.o scripts/module.lds $(module-sdt-modular-prereq) $(module-ctfs-modular-prereq) FORCE
    + # Re-generate module BTFs and any linked-in CTF if either module's .ko or vmlinux changed
    +-$(modules): %.ko: %.o %.mod.o scripts/module.lds $(if $(KBUILD_BUILTIN),vmlinux) $(module-ctfs-modular-prereq) FORCE
    ++$(modules): %.ko: %.o %.mod.o %.sdtinfo.o scripts/module.lds $(if $(KBUILD_BUILTIN),vmlinux) $(module-sdt-modular-prereq) $(module-ctfs-modular-prereq) FORCE
      	$(call cmd_touch_ctf)
    - 	+$(call if_changed,ld_ko_o)
    - 
    + 	+$(call if_changed_except,ld_ko_o,vmlinux)
    + ifdef CONFIG_DEBUG_INFO_BTF_MODULES
     
      ## scripts/dtrace_sdt.sh (new) ##
     @@
    @@ scripts/link-vmlinux.sh: if [ -n "${CONFIG_KALLSYMS}" ]; then
      if [ -n "${CONFIG_DEBUG_INFO_BTF}" -a -n "${CONFIG_BPF}" ]; then
     
      ## scripts/mod/modpost.c ##
    -@@ scripts/mod/modpost.c: static int check_exports(struct module *mod)
    +@@ scripts/mod/modpost.c: static void check_exports(struct module *mod)
      		const char *basename;
      		exp = find_symbol(s->name);
      		if (!exp || exp->module == mod) {
    --			if (have_vmlinux && !s->weak) {
    +-			if (have_vmlinux && !s->weak)
     +			if (have_vmlinux && !s->weak &&
     +			    !strstarts(s->name, "__dtrace_probe_") &&
    -+			    !strstarts(s->name, "__dtrace_isenabled_")) {
    ++			    !strstarts(s->name, "__dtrace_isenabled_"))
      				modpost_log(warn_unresolved ? LOG_WARN : LOG_ERROR,
      					    "\"%s\" [%s.ko] undefined!\n",
      					    s->name, mod->name);
    -@@ scripts/mod/modpost.c: static int check_modname_len(struct module *mod)
    +@@ scripts/mod/modpost.c: static void check_modname_len(struct module *mod)
       **/
      static void add_header(struct buffer *b, struct module *mod)
      {
 9:  33bb9a2aab1f =  9:  91314397f4dc dtrace: sdt provider for x86
10:  59b5eca72202 = 10:  fc95b75f13de dtrace: profile provider and test probe core components
11:  f7a0d3e1af25 = 11:  62b31fce6163 dtrace: profile and tick providers built on cyclics
12:  18dbf51fb9a2 = 12:  11f900afb25c dtrace: USDT and pid provider core and x86 components
13:  209f98383b91 = 13:  446783fa5e7b dtrace: USDT and pid providers
14:  bc81b22d39f0 ! 14:  71de58a6174f dtrace: function boundary tracing (FBT) core and x86 components
    @@ arch/x86/hyperv/hv_init.c: DEFINE_IDTENTRY_SYSVEC(sysvec_hyperv_reenlightenment)
      void set_hv_tscchange_cb(void (*cb)(void))
     
      ## arch/x86/include/asm/idtentry.h ##
    -@@ arch/x86/include/asm/idtentry.h: void idtentry_exit_nmi(struct pt_regs *regs, bool irq_state);
    +@@
      #define DECLARE_IDTENTRY(vector, func)					\
      	asmlinkage void asm_##func(void);				\
      	asmlinkage void xen_asm_##func(void);				\
    @@ arch/x86/include/asm/idtentry.h: void idtentry_exit_nmi(struct pt_regs *regs, bo
      
      /**
       * DEFINE_IDTENTRY - Emit code for simple IDT entry points
    -@@ arch/x86/include/asm/idtentry.h: void idtentry_exit_nmi(struct pt_regs *regs, bool irq_state);
    +@@
       * which has to run before returning to the low level assembly code.
       */
      #define DEFINE_IDTENTRY(func)						\
    @@ arch/x86/kernel/traps.c: DEFINE_IDTENTRY_ERRORCODE(exc_general_protection)
      	}
      
      	tsk = current;
    +@@ arch/x86/kernel/traps.c: DEFINE_IDTENTRY_ERRORCODE(exc_general_protection)
    + 		tsk->thread.trap_nr = X86_TRAP_GP;
    + 
    + 		if (fixup_vdso_exception(regs, X86_TRAP_GP, error_code, 0))
    +-			return;
    ++			return 0;
    + 
    + 		show_signal(tsk, SIGSEGV, "", desc, regs, error_code);
    + 		force_sig(SIGSEGV);
     @@ arch/x86/kernel/traps.c: DEFINE_IDTENTRY_ERRORCODE(exc_general_protection)
      		goto exit;
      
    @@ arch/x86/kernel/traps.c: DEFINE_IDTENTRY_RAW(exc_int3)
      		instrumentation_end();
      		irqentry_exit_to_user_mode(regs);
      	} else {
    - 		bool irq_state = idtentry_enter_nmi(regs);
    + 		irqentry_state_t irq_state = irqentry_nmi_enter(regs);
    + 
      		instrumentation_begin();
     -		if (!do_int3(regs))
     +		if (!do_int3(regs, &ret))
      			die("int3", regs, 0);
      		instrumentation_end();
    - 		idtentry_exit_nmi(regs, irq_state);
    + 		irqentry_nmi_exit(regs, irq_state);
      	}
     +	return ret;
      }
    @@ arch/x86/xen/enlighten_pv.c: DEFINE_IDTENTRY_RAW(xenpv_exc_debug)
     +		return exc_debug(regs);
      }
      
    - struct trap_array_entry {
    + DEFINE_IDTENTRY_RAW(exc_xen_unknown_trap)
     
      ## include/linux/dtrace_fbt.h (new) ##
     @@
    @@ kernel/dtrace/dtrace_os.c: void __init dtrace_os_init(void)
     
      ## kernel/kprobes.c ##
     @@
    + #include <linux/jump_label.h>
      #include <linux/perf_event.h>
    - #include <linux/static_call.h>
      
     +#ifdef CONFIG_DTRACE
     +#include <linux/dtrace_fbt.h>
15:  b3955b4ec46d = 15:  4866f2c488d4 dtrace: fbt provider, modular components
16:  7448665d4354 ! 16:  a1a769c19e4a dtrace, arm: arm64 port
    @@ arch/arm64/include/asm/dtrace_util.h (new)
     +
     +#endif /* _ASM_ARM64_DTRACE_UTIL_H */
     
    + ## arch/arm64/include/asm/exception.h ##
    +@@ arch/arm64/include/asm/exception.h: static inline u32 disr_to_esr(u64 disr)
    + 	return esr;
    + }
    + 
    +-asmlinkage void el1_sync_handler(struct pt_regs *regs);
    ++asmlinkage int el1_sync_handler(struct pt_regs *regs);
    + asmlinkage void el0_sync_handler(struct pt_regs *regs);
    + asmlinkage void el0_sync_compat_handler(struct pt_regs *regs);
    + 
    +
      ## arch/arm64/include/asm/kdebug.h (new) ##
     @@
     +/* SPDX-License-Identifier: GPL-2.0 */
    @@ arch/arm64/kernel/entry.S: alternative_else_nop_endif
     +	.macro	kernel_exit, el, fbt_emu = 0
      	.if	\el != 0
      	disable_daif
    - 
    + 	.endif
     @@ arch/arm64/kernel/entry.S: alternative_else_nop_endif
      
      	msr	elr_el1, x21			// set up the return data
    @@ arch/arm64/kernel/entry.S: alternative_else_nop_endif
     +	msr	elr_el1, x0			// set exception link reg
     +
     +	ldp	x0, x1, [sp, #16 * 0]		// done with x0, restore orig
    - 	add	sp, sp, #S_FRAME_SIZE		// restore sp
    + 	add	sp, sp, #PT_REGS_SIZE		// restore sp
     +	mov	x29, sp				// instr we put probe on
     +	b	9f				// FBT done -> branch to eret
     +
    @@ arch/arm64/kernel/entry.S: alternative_else_nop_endif
     +						// simulate the 'ret' instr.
     +
     +	ldp	x0, x1, [sp, #16 * 0]		// done with x0, restore orig
    -+	add	sp, sp, #S_FRAME_SIZE		// restore sp
    ++	add	sp, sp, #PT_REGS_SIZE		// restore sp
     +	b	9f				// FBT done -> branch to eret
     +
     +8:
     +	ldp	x0, x1, [sp, #16 * 0]		// done with x0, restore orig
    -+	add	sp, sp, #S_FRAME_SIZE		// restore sp
    ++	add	sp, sp, #PT_REGS_SIZE		// restore sp
     +9:
     +	.else
     +	ldp	x0, x1, [sp, #16 * 0]		// done with x0, restore orig
    -+	add	sp, sp, #S_FRAME_SIZE		// restore sp
    ++	add	sp, sp, #PT_REGS_SIZE		// restore sp
     +
     +	.endif
      
    @@ arch/arm64/kernel/sys.c: asmlinkage long __arm64_sys_ni_syscall(const struct pt_
     
      ## arch/arm64/mm/fault.c ##
     @@
    - #include <linux/mm.h>
      #include <linux/hardirq.h>
      #include <linux/init.h>
    + #include <linux/kasan.h>
     +#include <linux/kdebug.h>
      #include <linux/kprobes.h>
      #include <linux/uaccess.h>
    @@ arch/arm64/mm/fault.c: static inline const struct fault_info *esr_to_debug_fault
      static void data_abort_decode(unsigned int esr)
      {
      	pr_alert("Data abort info:\n");
    -@@ arch/arm64/mm/fault.c: static int __kprobes do_page_fault(unsigned long addr, unsigned int esr,
    +@@ arch/arm64/mm/fault.c: static int __kprobes do_page_fault(unsigned long far, unsigned int esr,
      
      	if (kprobe_page_fault(regs, esr))
      		return 0;
17:  5694e5386d32 ! 17:  e5ed75159888 dtrace: add SDT probes
    @@ block/blk-core.c: static noinline_for_stack bool submit_bio_checks(struct bio *b
     
      ## fs/exec.c ##
     @@
    - #include <linux/compat.h>
      #include <linux/vmalloc.h>
      #include <linux/io_uring.h>
    + #include <linux/syscall_user_dispatch.h>
     +#include <linux/sdt.h>
      #include <linux/dtrace_os.h>
      
    @@ fs/exec.c: static int bprm_execve(struct linux_binprm *bprm,
      	if (IS_ERR(file))
      		goto out_unmark;
     @@ fs/exec.c: static int bprm_execve(struct linux_binprm *bprm,
    + 	rseq_execve(current);
    + 	acct_update_integrals(current);
      	task_numa_free(current, false);
    - 	if (displaced)
    - 		put_files_struct(displaced);
     +
     +	DTRACE_PROC(exec__success);
      	return retval;
    @@ kernel/sched/core.c: prepare_task_switch(struct rq *rq, struct task_struct *prev
     +	DTRACE_SCHED(off__cpu, struct task_struct * : (lwpsinfo_t *,
     +						       psinfo_t *), next);
      	fire_sched_out_preempt_notifiers(prev, next);
    + 	kmap_local_sched_out();
      	prepare_task(next);
    - 	prepare_arch_switch(next);
     @@ kernel/sched/core.c: static struct rq *finish_task_switch(struct task_struct *prev)
    - 	finish_arch_post_lock_switch();
    - 	kcov_finish_switch(current);
    + 	 */
    + 	kmap_local_sched_in();
      
     +	DTRACE_SCHED(on__cpu);
      	fire_sched_in_preempt_notifiers(current);
    @@ kernel/sched/core.c: static void __sched notrace __schedule(bool preempt)
      	next = pick_next_task(rq, prev, &rf);
      	clear_tsk_need_resched(prev);
     @@ kernel/sched/core.c: static void __sched notrace __schedule(bool preempt)
    - 		rq = context_switch(rq, prev, next, &rf);
      	} else {
      		rq->clock_update_flags &= ~(RQCF_ACT_SKIP|RQCF_REQ_SKIP);
    -+		DTRACE_SCHED(remain__cpu);
    - 		rq_unlock_irq(rq, &rf);
    - 	}
      
    ++		DTRACE_SCHED(remain__cpu);
    + 		rq_unpin_lock(rq, &rf);
    + 		__balance_callbacks(rq);
    + 		raw_spin_unlock_irq(&rq->lock);
     @@ kernel/sched/core.c: void set_user_nice(struct task_struct *p, long nice)
      	old_prio = p->prio;
      	p->prio = effective_prio(p);
    @@ net/ipv4/tcp_input.c: static int tcp_rcv_synsent_state_process(struct sock *sk,
     +				   sk ? sk->sk_state : TCP_CLOSE,
     +				   int, sk ? sk->sk_state : TCP_CLOSE,
     +				   int, DTRACE_NET_PROBE_INBOUND);
    - 			tcp_reset(sk);
    + 			tcp_reset(sk, skb);
      			goto discard;
      		}
     @@ net/ipv4/tcp_input.c: int tcp_rcv_state_process(struct sock *sk, struct sk_buff *skb)
18:  6e49525673d6 = 18:  12cf1f142394 dtrace: add sample script for building DTrace on Fedora
19:  cbc0fec32fc0 = 19:  aa20923cb3fa locking: publicize mutex_owner and mutex_owned again
 -:  ------------ > 20:  40e922e0d9dc dtrace: fix buffer overflow in profile provider



More information about the DTrace-devel mailing list