lttng-modules.git
9 months agoFix: timer_start changed in linux 6.8.0-rc1
Kienan Stewart [Mon, 22 Jan 2024 16:33:39 +0000 (11:33 -0500)] 
Fix: timer_start changed in linux 6.8.0-rc1

See upstream commit

    commit dbcdcb62b59db2cf6a24113873b90da15c6f0b19
    Author: Anna-Maria Behnsen <anna-maria@linutronix.de>
    Date:   Fri Dec 1 10:26:26 2023 +0100

        tracing/timers: Enhance timer_start tracepoint

        For starting a timer, the timer is enqueued into a bucket of the timer
        wheel. The bucket expiry is the defacto expiry of the timer but it is not
        equal the timer expiry because of increasing granularity when bucket is in
        a higher level of the wheel. To be able to figure out in a trace whether a
        timer expired in time or not, the bucket expiry time is required as well.

        Add bucket expiry time to the timer_start tracepoint and thereby simplify
        the arguments.

Change-Id: I4868092765745b1efd0c48f13c0b837f2007dcb6
Signed-off-by: Kienan Stewart <kstewart@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
9 months agoFix: sched_stat_runtime changed in linux 6.8.0-rc1
Kienan Stewart [Mon, 22 Jan 2024 16:10:37 +0000 (11:10 -0500)] 
Fix: sched_stat_runtime changed in linux 6.8.0-rc1

See upstream commit:

    commit 5fe6ec8f6ab549b6422e41551abb51802bd48bc7
    Author: Peter Zijlstra <peterz@infradead.org>
    Date:   Mon Nov 6 13:41:43 2023 +0100

        sched: Remove vruntime from trace_sched_stat_runtime()

        Tracing the runtime delta makes sense, observer can sum over time.
        Tracing the absolute vruntime makes less sense, inconsistent:
        absolute-vs-delta, but also vruntime delta can be computed from
        runtime delta.

        Removing the vruntime thing also makes the two tracepoint sites
        identical, allowing to unify the code in a later patch.

Change-Id: I24ebb4e06dbb646a1af75ac62b74f3821ff197de
Signed-off-by: Kienan Stewart <kstewart@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 months agodocs: Add links to project resources
Kienan Stewart [Fri, 24 Nov 2023 15:09:46 +0000 (10:09 -0500)] 
docs: Add links to project resources

Indicate that Gerrit (https://review.lttng.org) is the principal place
where patches are submitted and reviewed, rather than the mailing list.

Based on feedback received on the mailing list:
https://lists.lttng.org/pipermail/lttng-dev/2023-November/030670.html

Change-Id: I611deeec26393fc25c9a103c022687198100df0c
Signed-off-by: Kienan Stewart <kstewart@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 months agoFix: Disable IBT around indirect function calls
Mathieu Desnoyers [Mon, 8 Jan 2024 18:31:04 +0000 (13:31 -0500)] 
Fix: Disable IBT around indirect function calls

When the Intel IBT feature is enabled, a CPU supporting this feature
validates that all indirect jumps/calls land on an ENDBR64 instruction.

The kernel seals functions which are not meant to be called indirectly,
which means that calling functions indirectly from their address fetched
using kallsyms or kprobes trigger a crash.

Use the MSR_IA32_S_CET CET_ENDBR_EN MSR bit to temporarily disable ENDBR
validation around indirect calls to kernel functions. Considering that
the main purpose of this feature is to prevent ROP-style attacks,
disabling the ENDBR validation temporarily around the call from a kernel
module does not affect the ROP protection.

Fixes #1408
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: I97f5d8efce093c1e956cede1f44de2fcebf30227

10 months agoRemove splice_to_pipe kallsyms wrapper
Michael Jeanson [Mon, 8 Jan 2024 21:05:22 +0000 (16:05 -0500)] 
Remove splice_to_pipe kallsyms wrapper

Starting from kernel v4.2, the splice_to_pipe symbol is exported for GPL
modules. Use it rather than the kallsyms wrapper.

This fixes commit 0e5e973df5 which should have removed the wrapper
rather than using it all the time.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: I52ce8cc99c3174fea30479af8fcf72879ef8aa47

10 months agoInline implementation of task_prio()
Mathieu Desnoyers [Tue, 9 Jan 2024 15:36:31 +0000 (10:36 -0500)] 
Inline implementation of task_prio()

The task_prio() function has been implemented as "return p->prio -
MAX_RT_PRIO;" since at least kernel v3.0, so inline it into
lttng-modules rather than using kallsyms to call the kernel
implementation.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: I7dd482a2da72a005c16b3e5864767b47d7bc3fd3

10 months agoFix: prio context NULL pointer exception
Mathieu Desnoyers [Tue, 9 Jan 2024 15:33:13 +0000 (10:33 -0500)] 
Fix: prio context NULL pointer exception

A missing call to wrapper_task_prio_init() causes the function pointer
for task_prio to stay NULL, which triggers a OOPS when trying to use the
prio context.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: I417e84cb8a07db624e682c7ec2c033fbc2a7b8e7

10 months agoSet version to 2.14-pre
Michael Jeanson [Mon, 8 Jan 2024 19:36:51 +0000 (14:36 -0500)] 
Set version to 2.14-pre

Change-Id: If3952a982001ca334d1cc7069d8a63c478dfde8d
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 months agoCleanup: combine ifdefs for arm thumb2
Mathieu Desnoyers [Fri, 22 Dec 2023 02:01:51 +0000 (21:01 -0500)] 
Cleanup: combine ifdefs for arm thumb2

Those two ifdefs can be combined into a single preprocessor conditional
with a &&.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: Icc2c11f1fd033af475cf69f14140dd710417cf10

10 months agoCleanup: kallsyms wrapper refactoring
Mathieu Desnoyers [Thu, 21 Dec 2023 20:10:22 +0000 (15:10 -0500)] 
Cleanup: kallsyms wrapper refactoring

Move the Christmas tree of #ifdef which was implemented in
do_get_kallsyms() into separate functions:

- kallsyms_pre_arch_adjust(),
- kallsyms_get_arch_call_addr().

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: I1bfdb43682e466f446d376ba7a122e295a2f0ea1

10 months agoFix: MODULE_IMPORT_NS is introduced in kernel 5.4
Mathieu Desnoyers [Mon, 18 Dec 2023 18:17:07 +0000 (13:17 -0500)] 
Fix: MODULE_IMPORT_NS is introduced in kernel 5.4

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: I4c5faafb3a3ff8178b45c0e411113b17643bbc78

10 months agoAndroid: Import VFS namespace for android common kernel
Lei wang [Mon, 18 Dec 2023 10:16:33 +0000 (05:16 -0500)] 
Android: Import VFS namespace for android common kernel

Android GKI kernel add limitation on fs interface usage.
Need to import VFS namespace explicitly to make it workable
for lttng-modules.

Signed-off-by: Lei wang <quic_leiwan@quicinc.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
11 months agofix: lookup_fd_rcu replaced by lookup_fdget_rcu in linux 6.7.0-rc1
Kienan Stewart [Mon, 20 Nov 2023 16:34:40 +0000 (11:34 -0500)] 
fix: lookup_fd_rcu replaced by lookup_fdget_rcu in linux 6.7.0-rc1

See upstream commit:

    commit 0ede61d8589cc2d93aa78230d74ac58b5b8d0244
    Author: Christian Brauner <brauner@kernel.org>
    Date:   Fri Sep 29 08:45:59 2023 +0200

        file: convert to SLAB_TYPESAFE_BY_RCU

        In recent discussions around some performance improvements in the file
        handling area we discussed switching the file cache to rely on
        SLAB_TYPESAFE_BY_RCU which allows us to get rid of call_rcu() based
        freeing for files completely. This is a pretty sensitive change overall
        but it might actually be worth doing.

        The main downside is the subtlety. The other one is that we should
        really wait for Jann's patch to land that enables KASAN to handle
        SLAB_TYPESAFE_BY_RCU UAFs. Currently it doesn't but a patch for this
        exists.

        With SLAB_TYPESAFE_BY_RCU objects may be freed and reused multiple times
        which requires a few changes. So it isn't sufficient anymore to just
        acquire a reference to the file in question under rcu using
        atomic_long_inc_not_zero() since the file might have already been
        recycled and someone else might have bumped the reference.

        In other words, callers might see reference count bumps from newer
        users. For this reason it is necessary to verify that the pointer is the
        same before and after the reference count increment. This pattern can be
        seen in get_file_rcu() and __files_get_rcu().

        In addition, it isn't possible to access or check fields in struct file
        without first aqcuiring a reference on it. Not doing that was always
        very dodgy and it was only usable for non-pointer data in struct file.
        With SLAB_TYPESAFE_BY_RCU it is necessary that callers first acquire a
        reference under rcu or they must hold the files_lock of the fdtable.
        Failing to do either one of this is a bug.

        Thanks to Jann for pointing out that we need to ensure memory ordering
        between reallocations and pointer check by ensuring that all subsequent
        loads have a dependency on the second load in get_file_rcu() and
        providing a fixup that was folded into this patch.

Signed-off-by: Kienan Stewart <kstewart@efficios.com>
Change-Id: Iba3663f19a54820afd31a8eeec24b3b5d4b06589
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
11 months agofix: mm, vmscan signatures changed in linux 6.7.0-rc1
Kienan Stewart [Mon, 20 Nov 2023 16:33:14 +0000 (11:33 -0500)] 
fix: mm, vmscan signatures changed in linux 6.7.0-rc1

See upstream commit:

    commit 3dfbb555c98ac55b9d911f9af0e35014b445fb41
    Author: Vlastimil Babka <vbabka@suse.cz>
    Date:   Thu Sep 14 15:16:39 2023 +0200

        mm, vmscan: remove ISOLATE_UNMAPPED

        This isolate_mode_t flag is effectively unused since 89f6c88a6ab4 ("mm:
        __isolate_lru_page_prepare() in isolate_migratepages_block()") as
        sc->may_unmap is now checked directly (and only node_reclaim has a mode
        that sets it to 0).  The last remaining place is mm_vmscan_lru_isolate
        tracepoint for the isolate_mode parameter.  That one was mainly used to
        indicate the active/inactive mode, which the trace-vmscan-postprocess.pl
        script consumed, but that got silently broken.  After fixing the script by
        the previous patch, it does not need the isolate_mode anymore.  So just
        remove the parameter and with that the whole ISOLATE_UNMAPPED flag.

Signed-off-by: Kienan Stewart <kstewart@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: Ie7346886d926a1a9d20bcb1570c587c5e943a1c3

11 months agofix: phys_proc_id and cpu_core_id moved in linux 6.7.0-rc1
Kienan Stewart [Mon, 20 Nov 2023 16:27:12 +0000 (11:27 -0500)] 
fix: phys_proc_id and cpu_core_id moved in linux 6.7.0-rc1

See upstream commit:

    commit 02fb601d27a7abf60d52b21bdf5b100a8d63da3f
    Author: Thomas Gleixner <tglx@linutronix.de>
    Date:   Mon Aug 14 10:18:30 2023 +0200

        x86/cpu: Move phys_proc_id into topology info

        Rename it to pkg_id which is the terminology used in the kernel.

        No functional change.

See upstream commit:

    commit e95256335d45cc965cd12c423535002974313340
    Author: Thomas Gleixner <tglx@linutronix.de>
    Date:   Mon Aug 14 10:18:34 2023 +0200

        x86/cpu: Move cpu_core_id into topology info

        Rename it to core_id and stick it to the other ID fields.

        No functional change.

Signed-off-by: Kienan Stewart <kstewart@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: I574b02430210d5bb72c4b9db901d0e3a6dc7bea0

12 months agoFix build for RHEL 8.8 with linux 4.18.0-477.10.1+
Kienan Stewart [Mon, 16 Oct 2023 14:10:09 +0000 (10:10 -0400)] 
Fix build for RHEL 8.8 with linux 4.18.0-477.10.1+

4.18.0-477.10.1 introduces backports a change which updates the
`kfree_skb` trace event to the 3-argument version used in more recent
kernel versions.

Change-Id: I5a1071a59659b76e1499beae3388159ca8ced1f7
Signed-off-by: Kienan Stewart <kstewart@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
13 months agoFix: bytecode validator: oops during validation of immediate string
Jérémie Galarneau [Thu, 5 Oct 2023 21:02:57 +0000 (17:02 -0400)] 
Fix: bytecode validator: oops during validation of immediate string

Issue observed
--------------

Running Linux 6.5.5, lttng-modules @ 6be48c9f, all built with gcc
13.2.1, I got a 'BUG' in dmesg while enabling the following event
rule:

  $ lttng enable-event --kernel --syscall --channel chanK --all --filter '$ctx.procname == "UST reg*"'

The relevant parts of the 'BUG' output follow:

  [  +0.715480] detected buffer overflow in strnlen
  [  +0.000001] kernel BUG at lib/string_helpers.c:1031!
  [  +0.000008] invalid opcode: 0000 [#1] PREEMPT SMP NOPTI
  [  +0.000003] CPU: 2 PID: 157174 Comm: Client manageme Tainted: G S   U     OE      6.5.5-arch1-1 #1 d82a0f532dd8cfe67d5795c1738d9c01059a0c62
  [  +0.000001] RIP: 0010:fortify_panic+0x13/0x20
  [  +0.000006] Code: 41 5d c3 cc cc cc cc 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 48 89 fe 48 c7 c7 90 22 c8 86 e8 3d aa b1 ff <0f> 0b 66 66 2e 0f 1f 84 00 00 00 00 00 90 90 90 90 90 90 90 90 90
  [  +0.000002] RSP: 0018:ffffa7c7c106f918 EFLAGS: 00010246
  [  +0.000002] RAX: 0000000000000023 RBX: 000000000000000b RCX: 0000000000000000
  [  +0.000002] RDX: 0000000000000000 RSI: ffff92766e4a16c0 RDI: ffff92766e4a16c0
  [  +0.000001] RBP: 0000000000000000 R08: 0000000000000000 R09: ffffa7c7c106f7c0
  [  +0.000001] R10: 0000000000000003 R11: ffffffff874ca068 R12: ffff927618202480
  [  +0.000001] R13: ffff9276182024d2 R14: ffff927453999c08 R15: ffff9273dc7aa478
  [  +0.000001] FS:  00007f06553f9680(0000) GS:ffff92766e480000(0000) knlGS:0000000000000000
  [  +0.000002] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
  [  +0.000002] CR2: 0000556d54eceaa8 CR3: 00000001ad9de002 CR4: 00000000003706e0
  [  +0.000001] Call Trace:
  [  +0.000002]  <TASK>
  [  +0.000002]  ? die+0x36/0x90
  [  +0.000004]  ? do_trap+0xda/0x100
  [  +0.000003]  ? fortify_panic+0x13/0x20
  [  +0.000002]  ? do_error_trap+0x6a/0x90
  [  +0.000002]  ? fortify_panic+0x13/0x20
  [  +0.000002]  ? exc_invalid_op+0x50/0x70
  [  +0.000003]  ? fortify_panic+0x13/0x20
  [  +0.000002]  ? asm_exc_invalid_op+0x1a/0x20
  [  +0.000005]  ? fortify_panic+0x13/0x20
  [  +0.000002]  ? fortify_panic+0x13/0x20
  [  +0.000003]  bytecode_validate_overflow+0x155/0x1f0 [lttng_tracer 759e3e4fee0e774ef575e93b67e8dc7955d0c2c2]
  [  +0.000330]  lttng_bytecode_validate_load+0x32/0x1e0 [lttng_tracer 759e3e4fee0e774ef575e93b67e8dc7955d0c2c2]
  [  +0.000183]  lttng_enabler_link_bytecode+0x135/0x5a0 [lttng_tracer 759e3e4fee0e774ef575e93b67e8dc7955d0c2c2]
  [  +0.000132]  lttng_sync_event_list+0xef/0x650 [lttng_tracer 759e3e4fee0e774ef575e93b67e8dc7955d0c2c2]
  [  +0.000123]  ? __wake_up_common+0x73/0x180
  [  +0.000004]  lttng_session_enable+0x3e/0x130 [lttng_tracer 759e3e4fee0e774ef575e93b67e8dc7955d0c2c2]
  [  +0.000121]  lttng_session_ioctl+0x5db/0x720 [lttng_tracer 759e3e4fee0e774ef575e93b67e8dc7955d0c2c2]
  [  +0.000120]  ? __slab_free+0xf1/0x330
  [  +0.000004]  ? __scm_recv_common.isra.0+0x144/0x180
  [  +0.000004]  ? unix_stream_read_generic+0x233/0xb60
  [  +0.000006]  __x64_sys_ioctl+0x94/0xd0
  [  +0.000004]  do_syscall_64+0x5d/0x90
  [  +0.000004]  ? switch_fpu_return+0x50/0xe0
  [  +0.000004]  ? exit_to_user_mode_prepare+0x132/0x1e0
  [  +0.000003]  ? syscall_exit_to_user_mode+0x2b/0x40
  [  +0.000002]  ? do_syscall_64+0x6c/0x90
  [  +0.000003]  ? do_syscall_64+0x6c/0x90
  [  +0.000002]  ? do_syscall_64+0x6c/0x90
  [  +0.000002]  ? do_syscall_64+0x6c/0x90
  [  +0.000002]  ? syscall_exit_to_user_mode+0x2b/0x40
  [  +0.000002]  ? do_syscall_64+0x6c/0x90
  [  +0.000002]  ? do_syscall_64+0x6c/0x90
  [  +0.000002]  ? do_syscall_64+0x6c/0x90
  [  +0.000002]  ? do_syscall_64+0x6c/0x90
  [  +0.000002]  ? exc_page_fault+0x7f/0x180
  [  +0.000003]  entry_SYSCALL_64_after_hwframe+0x6e/0xd8

Cause
-----

`struct load_op` has a trailing 0-length array `data` member that is
used to refer, in the context of BYTECODE_OP_LOAD_STAR_GLOB_STRING, to
an immediate string operand that follows it.

During the validation of a filtering bytecode, strnlen is properly used
to determine the size of the immediate string operand, with a `maxlen`
parameter that is used to ensure the string operand is contained within
the bytecode (see lttng-bytecode-validator.c:434).

However, recent KSPP-related changes have enabled additional overrun
checks when statically-sized and flexible arrays are used. Those are
enabled when the kernel is built with CONFIG_UBSAN_BOUNDS and/or
CONFIG_FORTIFY_SOURCE configured.

The KBUILD CFLAGS now contain `-fstrict-flex-arrays=3`, which is
recognized by gcc 13+[1] and allows proper coverage of dynamically sized
trailing arrays when those configuration options are used.

With those validations in place, the kernel assumes that the `data`
array is truly of length 0 and it BUGs to warn of an invalid access.

The commit linked above contains a number of links explaining the
rationale for transitioning uses of the trailing zero-length arrays (a
gcc extension) to C99 flexible array members (FAM).

This was discussed at this year's GNU Cauldron [2].

Solution
--------

Uses of zero-length arrays (`foo[0]`) are replaced by flexible array
members (`foo[]`). The only cases that are left untouched are those
where the zero-length array is used to indicate the end of a
structure (i.e. it doesn't indicate that a variable number of elements
follow), see the `metadata_packet_header`, `metadata_record_header`,
`event_notifier_packet_header`, and `event_notifier_record_header`
structures.

It may be desirable to use the new `counted_by` attribute for some of
those in the future (`lttng_kernel_abi_filter_bytecode`,
`lttng_kernel_abi_capture_bytecode`, and `bytecode_runtime`) [3].

Note
----

While this is tagged as a memory handling 'fix', it has no security
implication as far as I can tell. The accesses that are flagged by the
new validations were valid.

This merely allows the runtime validations to understand the memory
layout properly.

[1] https://github.com/torvalds/linux/commit/df8fc4e934c12b906d08050d7779f292b9c5c6b5
[2] https://gcc.gnu.org/wiki/cauldron2023talks?action=AttachFile&do=get&target=Most-wanted+Security+Features+in+GCC+for+Linux+Kernel.pdf
[3] https://lwn.net/Articles/930943/

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: Id39b101aaafe68f8fae6b86cd61806cba8cb1e6a

13 months agofix: lttng-probe-kvm-x86-mmu build with linux 6.6
Kienan Stewart [Tue, 26 Sep 2023 18:45:09 +0000 (14:45 -0400)] 
fix: lttng-probe-kvm-x86-mmu build with linux 6.6

A small change was made upstream in `spte.h` that requires
`arch/x86/kvm` to be added to the search path when
building lttng-probe-kvm.x86-mmu.o.

See upstream commit :

  commit d10f3780bc2f80744d291e118c0c8bade54ed3b8
  Author: Sean Christopherson <seanjc@google.com>
  Date:   Tue Aug 8 15:40:59 2023 -0700

      KVM: x86/mmu: Include mmu.h in spte.h

      Explicitly include mmu.h in spte.h instead of relying on the "parent" to
      include mmu.h.  spte.h references a variety of macros and variables that
      are defined/declared in mmu.h, and so including spte.h before (or instead
      of) mmu.h will result in build errors, e.g.

Signed-off-by: Kienan Stewart <kstewart@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: I5c3fc87d3b006cefbcca198e6e15868a342cb8dd

14 months agofix: built-in lttng with kernel >= v6.1
Michael Jeanson [Fri, 18 Aug 2023 15:28:30 +0000 (11:28 -0400)] 
fix: built-in lttng with kernel >= v6.1

In kernel v6.1 the list of subdirectories was moved from Makefile to
Kbuild. Adjust our built-in.sh script to detect this change and use the
appropriate file to graft ourself to the kernel build system.

Thanks to Richa Bharti for the initial patch.

See upstream commit:

  commit 5750121ae7382ebac8d47ce6d68012d6cd1d7926
  Author: Masahiro Yamada <masahiroy@kernel.org>
  Date:   Sun Sep 25 03:19:10 2022 +0900

    kbuild: list sub-directories in ./Kbuild

    Use the ordinary obj-y syntax to list subdirectories.

Change-Id: Ifc0f1bdea5ee59b0e0b96cdb31c9c689deb20559
Reported-by: Richa Bharti <Richa.Bharti@siemens.com>
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
16 months agofix: ubuntu kinetic kernel range for jdb2
Michael Jeanson [Fri, 7 Jul 2023 17:27:15 +0000 (13:27 -0400)] 
fix: ubuntu kinetic kernel range for jdb2

Kinetic introduces a 'lowlatency' kernel with a different ABI number
than the 'generic' flavor, add 2 ranges accordingly.

Change-Id: I89427e30672f3f25b2f6d698d6e1cabfb45d9366
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
17 months agoAdd ordered extents tracepoints to btrfs probe
Michael Jeanson [Mon, 21 Nov 2022 20:51:21 +0000 (15:51 -0500)] 
Add ordered extents tracepoints to btrfs probe

See upstream commit:

  commit 5bea2508811ec76105b01c90c1f1661024c257a9
  Author: Johannes Thumshirn <johannes.thumshirn@wdc.com>
  Date:   Thu Jun 9 09:28:04 2022 -0700

    btrfs: add tracepoints for ordered extents

    When debugging a reference counting issue with ordered extents, I've found
    we're lacking a lot of tracepoint coverage in the ordered extent code.

    Close these gaps by adding tracepoints after every refcount_inc() in the
    ordered extent code.

Change-Id: I3af5bd593f4b7beb835f4c87442e7e1d407a2e3d
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
18 months agoAdd support for RHEL 9.1
Michael Jeanson [Fri, 14 Apr 2023 19:09:25 +0000 (15:09 -0400)] 
Add support for RHEL 9.1

Change-Id: I2aaa8e385448b1e46c3c16edc4f36f2eb6906e76
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
18 months agoAdd support for RHEL 9.0
Michael Jeanson [Tue, 19 Jul 2022 19:07:22 +0000 (15:07 -0400)] 
Add support for RHEL 9.0

Change-Id: Ia01527c3d6243805445734f00f4f2f945efd16e7
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
19 months agofix: kallsyms wrapper on CONFIG_PPC64_ELF_ABI_V1
Michael Jeanson [Tue, 29 Nov 2022 17:10:17 +0000 (12:10 -0500)] 
fix: kallsyms wrapper on CONFIG_PPC64_ELF_ABI_V1

Change-Id: Ibdff5792a1511b678f7776f5d032758db739c5ad
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
20 months agofix: net: add location to trace_consume_skb() (v6.3)
Michael Jeanson [Tue, 7 Mar 2023 16:10:26 +0000 (11:10 -0500)] 
fix: net: add location to trace_consume_skb() (v6.3)

See upstream commit :

  commit dd1b527831a3ed659afa01b672d8e1f7e6ca95a5
  Author: Eric Dumazet <edumazet@google.com>
  Date:   Thu Feb 16 15:47:18 2023 +0000

    net: add location to trace_consume_skb()

    kfree_skb() includes the location, it makes sense
    to add it to consume_skb() as well.

Change-Id: I8d871187d90e7fe113a63e209b00aebe0df475f3
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
20 months agofix: btrfs: pass find_free_extent_ctl to allocator tracepoints (v6.3)
Michael Jeanson [Tue, 7 Mar 2023 16:26:25 +0000 (11:26 -0500)] 
fix: btrfs: pass find_free_extent_ctl to allocator tracepoints (v6.3)

See upstream commit :

  commit cfc2de0fce015d4249c674ef9f5e0b4817ba5c53
  Author: Boris Burkov <boris@bur.io>
  Date:   Thu Dec 15 16:06:31 2022 -0800

    btrfs: pass find_free_extent_ctl to allocator tracepoints

    The allocator tracepoints currently have a pile of values from ffe_ctl.
    In modifying the allocator and adding more tracepoints, I found myself
    adding to the already long argument list of the tracepoints. It makes it
    a lot simpler to just send in the ffe_ctl itself.

Change-Id: Iab4132a9d3df3a6369591a50fb75374b1e399fa4
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
20 months agofix: uuid: Decouple guid_t and uuid_le types and respective macros (v6.3)
Michael Jeanson [Tue, 7 Mar 2023 17:05:00 +0000 (12:05 -0500)] 
fix: uuid: Decouple guid_t and uuid_le types and respective macros (v6.3)

See upstream commit :

  commit 5e6a51787fef20b849682d8c49ec9c2beed5c373
  Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
  Date:   Tue Jan 24 15:38:38 2023 +0200

    uuid: Decouple guid_t and uuid_le types and respective macros

    The guid_t type and respective macros are being used internally only.
    The uuid_le has its user outside the kernel. Decouple these types and
    macros, and make guid_t completely internal type to the kernel.

Change-Id: I8644fd139b0630e9cf18886b84e33bffab1e5abd
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
20 months agofix: mm: introduce vma->vm_flags wrapper functions (v6.3)
Michael Jeanson [Tue, 7 Mar 2023 16:41:14 +0000 (11:41 -0500)] 
fix: mm: introduce vma->vm_flags wrapper functions (v6.3)

See upstream commit :

  commit bc292ab00f6c7a661a8a605c714e8a148f629ef6
  Author: Suren Baghdasaryan <surenb@google.com>
  Date:   Thu Jan 26 11:37:47 2023 -0800

    mm: introduce vma->vm_flags wrapper functions

    vm_flags are among VMA attributes which affect decisions like VMA merging
    and splitting.  Therefore all vm_flags modifications are performed after
    taking exclusive mmap_lock to prevent vm_flags updates racing with such
    operations.  Introduce modifier functions for vm_flags to be used whenever
    flags are updated.  This way we can better check and control correct
    locking behavior during these updates.

Change-Id: I2cf662420d9d7748e5e310d3ea4bac98ba7d7f94
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
21 months agofix: jbd2: use the correct print format (v5.4.229)
Michael Jeanson [Wed, 18 Jan 2023 21:32:04 +0000 (16:32 -0500)] 
fix: jbd2: use the correct print format (v5.4.229)

See upstream commit :

  commit ecb9d0d2e123874bcdd2efdecda0f4e0c3dc566d
  Author: Bixuan Cui <cuibixuan@linux.alibaba.com>
  Date:   Tue Oct 11 19:33:44 2022 +0800

    jbd2: use the correct print format

    [ Upstream commit d87a7b4c77a997d5388566dd511ca8e6b8e8a0a8 ]

    The print format error was found when using ftrace event:
        <...>-1406 [000] .... 23599442.895823: jbd2_end_commit: dev 252,8 transaction -1866216965 sync 0 head -1866217368
        <...>-1406 [000] .... 23599442.896299: jbd2_start_commit: dev 252,8 transaction -1866216964 sync 0

    Use the correct print format for transaction, head and tid.

Change-Id: Ieee3d39ed1f2515e096e87d18b5ea8f921c54bd0
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
21 months agofix: jbd2 upper bound for v5.10.163
Michael Jeanson [Tue, 17 Jan 2023 17:16:04 +0000 (12:16 -0500)] 
fix: jbd2 upper bound for v5.10.163

Use the correct upper bound of 5,11,0.

Change-Id: I435b44b940c7346ed8c3ef0d445365ed156702d0
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
21 months agofix: jbd2: use the correct print format (v5.10.163)
Michael Jeanson [Tue, 17 Jan 2023 16:03:12 +0000 (11:03 -0500)] 
fix: jbd2: use the correct print format (v5.10.163)

See upstream commit :

  commit d87a7b4c77a997d5388566dd511ca8e6b8e8a0a8
  Author: Bixuan Cui <cuibixuan@linux.alibaba.com>
  Date:   Tue Oct 11 19:33:44 2022 +0800

    jbd2: use the correct print format

    The print format error was found when using ftrace event:
        <...>-1406 [000] .... 23599442.895823: jbd2_end_commit: dev 252,8 transaction -1866216965 sync 0 head -1866217368
        <...>-1406 [000] .... 23599442.896299: jbd2_start_commit: dev 252,8 transaction -1866216964 sync 0

    Use the correct print format for transaction, head and tid.

Change-Id: I7601f5cbb86495c2607be7b11e02724c90b3ebf9
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
21 months agofix: btrfs: move accessor helpers into accessors.h (v6.2)
Michael Jeanson [Mon, 16 Jan 2023 20:01:51 +0000 (15:01 -0500)] 
fix: btrfs: move accessor helpers into accessors.h (v6.2)

See upstream commit :

  commit 07e81dc94474eb62705c6f96d9ab1a5a797b8703
  Author: Josef Bacik <josef@toxicpanda.com>
  Date:   Wed Oct 19 10:51:00 2022 -0400

    btrfs: move accessor helpers into accessors.h

    This is a large patch, but because they're all macros it's impossible to
    split up.  Simply copy all of the item accessors in ctree.h and paste
    them in accessors.h, and then update any files to include the header so
    everything compiles.

Change-Id: I1f0876dd8b7a8687f6802b60c3e3baabd017cc52
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
21 months agofix: jbd2: use the correct print format
Michael Jeanson [Thu, 12 Jan 2023 18:52:22 +0000 (13:52 -0500)] 
fix: jbd2: use the correct print format

See upstream commit :

  commit d87a7b4c77a997d5388566dd511ca8e6b8e8a0a8
  Author: Bixuan Cui <cuibixuan@linux.alibaba.com>
  Date:   Tue Oct 11 19:33:44 2022 +0800

    jbd2: use the correct print format

    The print format error was found when using ftrace event:
        <...>-1406 [000] .... 23599442.895823: jbd2_end_commit: dev 252,8 transaction -1866216965 sync 0 head -1866217368
        <...>-1406 [000] .... 23599442.896299: jbd2_start_commit: dev 252,8 transaction -1866216964 sync 0

    Use the correct print format for transaction, head and tid.

Change-Id: Ic053f0e0c1e24ebc75bae51d07696aaa5e1c0094
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
22 months agosyscall inout table: fix old_select and old_mmap
Michael Jeanson [Thu, 15 Dec 2022 21:11:03 +0000 (16:11 -0500)] 
syscall inout table: fix old_select and old_mmap

Change-Id: I2e3c7a75ef6d4434daa06c389b1fa5bd1857df33
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
22 months agoFix syscall generator scripts
Michael Jeanson [Thu, 15 Dec 2022 20:34:37 +0000 (15:34 -0500)] 
Fix syscall generator scripts

Two small fixes for the syscall header generation scripts.

Check that the number of arguments match between the architecture
syscall list and the inout table definition.

Remove the duplication of arguments to make sure the per architecture
overrides are applied.

Change-Id: Ie20ef9030e57134265ae0ae885a87c5e8b3f61b1
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
22 months agoUpdate syscall inout table
Michael Jeanson [Tue, 6 Dec 2022 16:33:11 +0000 (11:33 -0500)] 
Update syscall inout table

Change-Id: I515c8f68aa5c2dce1e7433746ccbf64e0ce376d1
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
22 months agoSplit syscalls headers and tools
Michael Jeanson [Thu, 1 Dec 2022 18:32:33 +0000 (13:32 -0500)] 
Split syscalls headers and tools

Move the syscall headers tooling out of the include/ directory.

Change-Id: Icd507326aeac9cf28178f0e74b1d3f4812900303
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
22 months agoCleanup unused Makefile
Michael Jeanson [Tue, 22 Nov 2022 16:30:59 +0000 (11:30 -0500)] 
Cleanup unused Makefile

The syscall extractor module was moved to 'src' directory, remove the
unused Makefile that was left over.

Change-Id: Id249cac6f7b87988c2e0b548c08b708f72335da6
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
22 months agoBuild fix: arm64: incomplete landlock_rule_type type
Jérémie Galarneau [Tue, 13 Dec 2022 17:32:30 +0000 (12:32 -0500)] 
Build fix: arm64: incomplete landlock_rule_type type

While building the arm32 compatibility syscall instrumentation for
arm64, the build fails because types related to `landlock` are unknown.

Fixes:

/root/lttng-modules/src/../include/instrumentation/syscalls/headers/arm-32-syscalls_pointers.h:1428:138: error: conversion to incomplete type
 1428 |  TP_FIELDS(sc_exit(ctf_integer(long, ret, ret)) sc_inout(ctf_integer(const int, ruleset_fd, ruleset_fd)) sc_inout(ctf_integer(const enum landlock_rule_type, rule
_type, rule_type)) sc_inout(ctf_integer(const void *const, rule_attr, rule_attr)) sc_inout(ctf_integer(const __u32, flags, flags)))

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: Id898958b33ec241be792a731560f227917e35010

22 months agoFix: define old_sigaction as compat_old_sigaction in arm32 compat
Jérémie Galarneau [Tue, 13 Dec 2022 17:32:06 +0000 (12:32 -0500)] 
Fix: define old_sigaction as compat_old_sigaction in arm32 compat

In a follow-up patch which updates the instrumentation for arm32, the
instrumentation of the old_sigaction() syscall would fail to build when
targeting a 64-bit kernel.

In that context, old_sigaction becomes compat_old_sigaction which is a
syscall that can be disabled (it was superseded by rt_sigaction a long
time ago).

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: I3d9e155f7943cc4b768e13ebd25b671e46df9659

23 months agoFix: in_x32_syscall was introduced in v4.7.0
Mathieu Desnoyers [Thu, 1 Dec 2022 16:33:20 +0000 (11:33 -0500)] 
Fix: in_x32_syscall was introduced in v4.7.0

Prior to v4.7.0, is_x32_task() was the API to query whether the current
system call is following the x32 ABI.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: I783bd3bb46ec5e863ae209f79cee2f1bb415e661

23 months agoExplicitly skip tracing x32 system calls
Mathieu Desnoyers [Wed, 30 Nov 2022 20:41:02 +0000 (15:41 -0500)] 
Explicitly skip tracing x32 system calls

x86 x32 system calls are not supported by LTTng. They are currently not
traced simply because their system call number is beyond the range of
NR_compat_syscalls.

However, this mostly happens by accident rather than by design.

Enforce this with an explicit check for in_x32_syscall(), which clearly
documents that those are not supported.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: I1235c32c5cf03612bf9c36785cf7c4f8f49d292b

23 months agofix: kallsyms wrapper on ppc64el
Michael Jeanson [Thu, 24 Nov 2022 19:25:33 +0000 (14:25 -0500)] 
fix: kallsyms wrapper on ppc64el

The 'PPC64_ELF_ABI_v2' macro in 'asm/types.h' was removed in v5.19 and
replaced by a config option 'CONFIG_PPC64_ELF_ABI_V2'.

See upstream commit :

  commit 5b89492c03e5c0a2c259b97d7d4c1bb9b02860aa
  Author: Christophe Leroy <christophe.leroy@csgroup.eu>
  Date:   Mon May 9 07:36:08 2022 +0200

    powerpc: Finalise cleanup around ABI use

    Now that we have CONFIG_PPC64_ELF_ABI_V1 and CONFIG_PPC64_ELF_ABI_V2,
    get rid of all indirect detection of ABI version.

Link: https://lore.kernel.org/r/709d9d69523c14c8a9fba4486395dca0f2d675b1.1652074503.git.christophe.leroy@csgroup.eu
Change-Id: Ibd00e35cab5516a6224bdfa5a6b540119b42dc55
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoFix: don't build 64-bit counter client on 32-bit arch
Michael Jeanson [Mon, 21 Nov 2022 19:45:24 +0000 (14:45 -0500)] 
Fix: don't build 64-bit counter client on 32-bit arch

A typo in the Makefile resulted in the 64-bit counter client being built
regardless of the bitness of the architecture.

Change-Id: Icde0f15485ace2f3a7935c1e333dc0abd378b610
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoRemove obsolete -ckt debian kernel version support
Michael Jeanson [Mon, 21 Nov 2022 18:50:43 +0000 (13:50 -0500)] 
Remove obsolete -ckt debian kernel version support

Change-Id: I71ee764a0e6371dea6265d44d4056385335b717c
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoCleanup duplicated include in wrapper/timer.h
Michael Jeanson [Mon, 21 Nov 2022 18:38:52 +0000 (13:38 -0500)] 
Cleanup duplicated include in wrapper/timer.h

Change-Id: I7a2682d4a584954118fc110a1e374a107c4361ab
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from writeback instrumentation
Michael Jeanson [Mon, 21 Nov 2022 17:28:17 +0000 (12:28 -0500)] 
Drop support for kernels < 4.4 from writeback instrumentation

Change-Id: I92959e40f44371fad4a857f57726e243fb2920dd
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from workqueue instrumentation
Michael Jeanson [Mon, 21 Nov 2022 17:23:34 +0000 (12:23 -0500)] 
Drop support for kernels < 4.4 from workqueue instrumentation

Change-Id: Ic1e7a4a7516d2091093b726aa351c1ac2ff3ec0a
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from timer instrumentation
Michael Jeanson [Mon, 21 Nov 2022 17:22:40 +0000 (12:22 -0500)] 
Drop support for kernels < 4.4 from timer instrumentation

Change-Id: I17bbdaf79a548d0b9f3247a705c44a753c19b26b
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from scsi instrumentation
Michael Jeanson [Mon, 21 Nov 2022 17:21:11 +0000 (12:21 -0500)] 
Drop support for kernels < 4.4 from scsi instrumentation

Change-Id: I714da0df56c0101dd6a05c19477c0658f18de053
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from sched instrumentation
Michael Jeanson [Mon, 21 Nov 2022 17:18:45 +0000 (12:18 -0500)] 
Drop support for kernels < 4.4 from sched instrumentation

Change-Id: I14e8ceb3ed5dedb294dbbfecce454cd05d3417b8
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from rpc instrumentation
Michael Jeanson [Mon, 21 Nov 2022 17:14:57 +0000 (12:14 -0500)] 
Drop support for kernels < 4.4 from rpc instrumentation

Change-Id: I972d7b1397faacf901f43783fb0375a2e1c6a8f1
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from rcu instrumentation
Michael Jeanson [Mon, 21 Nov 2022 17:12:40 +0000 (12:12 -0500)] 
Drop support for kernels < 4.4 from rcu instrumentation

Change-Id: I4c1aabf233f4f8ccfdd6c93469c10efe79507cd8
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from random instrumentation
Michael Jeanson [Mon, 21 Nov 2022 17:05:12 +0000 (12:05 -0500)] 
Drop support for kernels < 4.4 from random instrumentation

Change-Id: I6f314c2ceb86e72ebad35089169885161cda30de
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from printk instrumentation
Michael Jeanson [Mon, 21 Nov 2022 17:03:16 +0000 (12:03 -0500)] 
Drop support for kernels < 4.4 from printk instrumentation

Change-Id: Ibb707f10a386fba1971081d380c46da247bf688f
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from power instrumentation
Michael Jeanson [Mon, 21 Nov 2022 17:02:09 +0000 (12:02 -0500)] 
Drop support for kernels < 4.4 from power instrumentation

Change-Id: I775b227042965a946d5ff1f42d2b350eae044742
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from net instrumentation
Michael Jeanson [Mon, 21 Nov 2022 17:01:13 +0000 (12:01 -0500)] 
Drop support for kernels < 4.4 from net instrumentation

Change-Id: I0fdf030897f01eec18931e416a2cfe241c780795
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from module instrumentation
Michael Jeanson [Mon, 21 Nov 2022 17:00:15 +0000 (12:00 -0500)] 
Drop support for kernels < 4.4 from module instrumentation

Change-Id: Idcd0cd197272d2efbd511c05afff6240b72740ae
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from mm_vmscan instrumentation
Michael Jeanson [Mon, 21 Nov 2022 16:58:56 +0000 (11:58 -0500)] 
Drop support for kernels < 4.4 from mm_vmscan instrumentation

Change-Id: If1fa6ff0239241b4039bb8ad8d7ed38072079032
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from lttng-statedump instrumentation
Michael Jeanson [Mon, 21 Nov 2022 16:54:30 +0000 (11:54 -0500)] 
Drop support for kernels < 4.4 from lttng-statedump instrumentation

Change-Id: I70f8b7da3355f29c206d691b48bf801f3103a527
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from kmem instrumentation
Michael Jeanson [Mon, 21 Nov 2022 16:52:05 +0000 (11:52 -0500)] 
Drop support for kernels < 4.4 from kmem instrumentation

Change-Id: I83541b99c0e1960cb5b8e4df69a46ed8e0ee7ee9
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from jbd instrumentation
Michael Jeanson [Mon, 21 Nov 2022 16:50:36 +0000 (11:50 -0500)] 
Drop support for kernels < 4.4 from jbd instrumentation

Change-Id: I881e5fb26808ffb903748ab72554fddd8bdbec55
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from jbd2 instrumentation
Michael Jeanson [Mon, 21 Nov 2022 16:49:45 +0000 (11:49 -0500)] 
Drop support for kernels < 4.4 from jbd2 instrumentation

Change-Id: Ia954795f4a5cc4d718eec70b4e6d9919e32bbf27
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from ext4 instrumentation
Michael Jeanson [Mon, 21 Nov 2022 16:48:00 +0000 (11:48 -0500)] 
Drop support for kernels < 4.4 from ext4 instrumentation

Change-Id: I4b9635ad3519e080db77020979aeba25cb01d892
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from compaction instrumentation
Michael Jeanson [Mon, 21 Nov 2022 16:39:21 +0000 (11:39 -0500)] 
Drop support for kernels < 4.4 from compaction instrumentation

Change-Id: Ic9305d3860ff3951f08e15e25d2a2f2bd0ef7913
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from btrfs instrumentation
Michael Jeanson [Mon, 21 Nov 2022 16:37:39 +0000 (11:37 -0500)] 
Drop support for kernels < 4.4 from btrfs instrumentation

Change-Id: Ib54ad6745ba214cb7f9829ca75a2685145985441
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from block instrumentation
Michael Jeanson [Mon, 21 Nov 2022 16:31:06 +0000 (11:31 -0500)] 
Drop support for kernels < 4.4 from block instrumentation

Change-Id: I8b0ae2055fabf21274221d0a25a11615c34fbc22
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from asoc instrumentation
Michael Jeanson [Fri, 18 Nov 2022 23:18:28 +0000 (18:18 -0500)] 
Drop support for kernels < 4.4 from asoc instrumentation

Change-Id: Ie0ba36a8aaa9106a17e5819767ab3fdee5cdd260
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from kvm instrumentation
Michael Jeanson [Fri, 18 Nov 2022 23:14:46 +0000 (18:14 -0500)] 
Drop support for kernels < 4.4 from kvm instrumentation

Change-Id: I01297f0e1b3e0e1121f8b7222059ef32e634d137
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
23 months agoDrop support for kernels < 4.4 from LTTng tracer core
Michael Jeanson [Fri, 18 Nov 2022 22:49:02 +0000 (17:49 -0500)] 
Drop support for kernels < 4.4 from LTTng tracer core

Change-Id: I16a57b7d7361d902b18de38faa33943430dedb97
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
23 months agoDrop support for kernels < 4.4 from ext3 and kvm probes
Michael Jeanson [Fri, 18 Nov 2022 22:38:49 +0000 (17:38 -0500)] 
Drop support for kernels < 4.4 from ext3 and kvm probes

This effectively removes the ext3 probe.

Change-Id: I77480103b4ef1f8d29e792a4f2d27e162d1fa94d
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from perf counters context
Michael Jeanson [Fri, 18 Nov 2022 22:18:26 +0000 (17:18 -0500)] 
Drop support for kernels < 4.4 from perf counters context

Change-Id: I6b839954b0d9bacc81e4d943bfe1d32471ba9962
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from ns contexts
Michael Jeanson [Fri, 18 Nov 2022 22:15:27 +0000 (17:15 -0500)] 
Drop support for kernels < 4.4 from ns contexts

Change-Id: Ie10299af93193415adfafeccb1c59c4b8c0a0bc0
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from 'wrapper/splice.h'
Michael Jeanson [Fri, 18 Nov 2022 22:00:31 +0000 (17:00 -0500)] 
Drop support for kernels < 4.4 from 'wrapper/splice.h'

Change-Id: I7dfcb85e2d0195fd21523646cbdf938f526a3c1e
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from 'wrapper/irqdesc.h'
Michael Jeanson [Fri, 18 Nov 2022 21:55:55 +0000 (16:55 -0500)] 
Drop support for kernels < 4.4 from 'wrapper/irqdesc.h'

Change-Id: I29331b3cef4e59b6d5d34d869374dc8ed92a010d
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from 'wrapper/writeback.h'
Michael Jeanson [Fri, 18 Nov 2022 21:50:59 +0000 (16:50 -0500)] 
Drop support for kernels < 4.4 from 'wrapper/writeback.h'

Change-Id: Ie9589e8eee3ca74694dd0671e4eb5dbb53882225
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from 'wrapper/vmalloc.h'
Michael Jeanson [Fri, 18 Nov 2022 21:48:32 +0000 (16:48 -0500)] 
Drop support for kernels < 4.4 from 'wrapper/vmalloc.h'

Change-Id: I4191d7b2899e8ebf754ce03566cc87220557742e
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from 'wrapper/tracepoint.h'
Michael Jeanson [Fri, 18 Nov 2022 21:42:38 +0000 (16:42 -0500)] 
Drop support for kernels < 4.4 from 'wrapper/tracepoint.h'

Change-Id: Icab9656bc3d9d22d9887191af2f7f465323c5c2a
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from 'wrapper/trace-clock.h'
Michael Jeanson [Fri, 18 Nov 2022 21:37:22 +0000 (16:37 -0500)] 
Drop support for kernels < 4.4 from 'wrapper/trace-clock.h'

Change-Id: I252af5b4e7948e4798ad9f70a57ac42a62d506ef
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from 'wrapper/page_alloc.h'
Michael Jeanson [Fri, 18 Nov 2022 21:34:33 +0000 (16:34 -0500)] 
Drop support for kernels < 4.4 from 'wrapper/page_alloc.h'

Change-Id: I1a702b78a5293ce631a7955fe67145fdf7445cb6
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from 'wrapper/mm.h'
Michael Jeanson [Fri, 18 Nov 2022 21:28:56 +0000 (16:28 -0500)] 
Drop support for kernels < 4.4 from 'wrapper/mm.h'

Change-Id: I9bdbecf08654d699f8f45fbc7ba862b1fbd822eb
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop support for kernels < 4.4 from 'wrapper/fdtable.h'
Michael Jeanson [Fri, 18 Nov 2022 21:26:21 +0000 (16:26 -0500)] 
Drop support for kernels < 4.4 from 'wrapper/fdtable.h'

Change-Id: Ib398db572d18c9ad3d08a5f21fe9285261fae0d1
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop 'linux/user_namespace.h' wrapper
Michael Jeanson [Fri, 18 Nov 2022 20:59:56 +0000 (15:59 -0500)] 
Drop 'linux/user_namespace.h' wrapper

Change-Id: I38bb6ff741126e18a4a1deb59471adb68dacdcb0
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop 'linux/uprobes.h' wrapper
Michael Jeanson [Fri, 18 Nov 2022 17:34:26 +0000 (12:34 -0500)] 
Drop 'linux/uprobes.h' wrapper

Change-Id: I6870122c24a9b8cb3cf8c5c0c75a78c2ec96f32b
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop 'wrapper/time.h' wrapper
Michael Jeanson [Fri, 18 Nov 2022 17:30:39 +0000 (12:30 -0500)] 
Drop 'wrapper/time.h' wrapper

Change-Id: I15ae7f5436e5fc2dfa2b0f9b878810a07fe8a5e9
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop 'linux/perf_events.h' wrapper
Michael Jeanson [Fri, 18 Nov 2022 17:27:19 +0000 (12:27 -0500)] 
Drop 'linux/perf_events.h' wrapper

Change-Id: Id4be9d9fbb70aa8213b12b2073a847cb81238993
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop 'linux/percpu-defs.h' wrapper
Michael Jeanson [Fri, 18 Nov 2022 17:25:25 +0000 (12:25 -0500)] 
Drop 'linux/percpu-defs.h' wrapper

Change-Id: Ie9fb775602f78fc205d0b2a3b9adeb2874eab8fc
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop 'wrapper/namespace.h' wrapper
Michael Jeanson [Fri, 18 Nov 2022 17:07:09 +0000 (12:07 -0500)] 
Drop 'wrapper/namespace.h' wrapper

Change-Id: Ib7ff96f36310cdcbe29fed279ab4a03ca96195e8
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop 'linux/irq.h' wrapper
Michael Jeanson [Fri, 18 Nov 2022 16:57:22 +0000 (11:57 -0500)] 
Drop 'linux/irq.h' wrapper

Change-Id: Idaebcb77e3cad262661385234fba284fa03676a9
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop 'linux/file.h' wrapper
Michael Jeanson [Fri, 18 Nov 2022 16:52:46 +0000 (11:52 -0500)] 
Drop 'linux/file.h' wrapper

Change-Id: I1f4e0630be4af0f8af98655c7771974f41d73517
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop 'asm/barrier.h' wrapper
Michael Jeanson [Fri, 18 Nov 2022 16:47:53 +0000 (11:47 -0500)] 
Drop 'asm/barrier.h' wrapper

Change-Id: I2901758329083bceabcf2cb6f4a3ffae7fa87df7
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoDrop 'linux/atomic.h' wrapper
Michael Jeanson [Fri, 18 Nov 2022 16:42:33 +0000 (11:42 -0500)] 
Drop 'linux/atomic.h' wrapper

Change-Id: Ia4341ded38739dbdd7db5fcd4b5bc192b2150c11
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoSet kernel baseline to v4.4
Michael Jeanson [Fri, 18 Nov 2022 19:36:53 +0000 (14:36 -0500)] 
Set kernel baseline to v4.4

Change-Id: Ic1b6596b1c49e57660538322ec9dbbc84ee9a036
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
23 months agoFix: Use ifdef for CONFIG_COMPAT_OLD_SIGACTION
Mathieu Desnoyers [Fri, 18 Nov 2022 15:31:32 +0000 (10:31 -0500)] 
Fix: Use ifdef for CONFIG_COMPAT_OLD_SIGACTION

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: I7ad6e10b134b328293013ca11474cfff58dbc559

23 months agoFix: system call instrumentation build failure on v3.0-v3.10 RT kernel
Mathieu Desnoyers [Fri, 18 Nov 2022 15:01:53 +0000 (10:01 -0500)] 
Fix: system call instrumentation build failure on v3.0-v3.10 RT kernel

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: I3f6f8e428c226b950138208f88a46015d843d2f9

23 months agoFix: add missing typedef and forward declarations for old kernels
Mathieu Desnoyers [Thu, 17 Nov 2022 20:28:12 +0000 (15:28 -0500)] 
Fix: add missing typedef and forward declarations for old kernels

While we are updating this, remove duplicated code between header and
implementation.

Reorganise list by alphabetical order.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: I79f1877d965084a77a1fdd573f8e227cd7f5ce74

23 months agoAdd generated arm-32 syscall instrumentation for kernel 6.0.7
Jérémie Galarneau [Fri, 11 Nov 2022 17:07:12 +0000 (12:07 -0500)] 
Add generated arm-32 syscall instrumentation for kernel 6.0.7

Generated by running:
  ./lttng-syscalls-generate-headers.sh pointers 6.0.7 arm-32-syscalls arm-32 32 && ./lttng-syscalls-generate-headers.sh integers 6.0.7 arm-32-syscalls arm-32 32

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: I2d76629b150627670fed23d94e80ae808c09d24b

23 months agoAdd generated x86-32 syscall instrumentation for kernel 6.0.7
Jérémie Galarneau [Tue, 8 Nov 2022 22:49:51 +0000 (17:49 -0500)] 
Add generated x86-32 syscall instrumentation for kernel 6.0.7

Generated by running:
  ./lttng-syscalls-generate-headers.sh pointers 6.0.7 x86-32-syscalls x86-32 32 && ./lttng-syscalls-generate-headers.sh integers 6.0.7 x86-32-syscalls x86-32 32

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: Ia6513b25b4556a774317f89210c6f8ad8cbc8723

23 months agoFix: define old_sigaction as compat_old_sigaction in x86-32 compat
Jérémie Galarneau [Wed, 9 Nov 2022 22:20:06 +0000 (17:20 -0500)] 
Fix: define old_sigaction as compat_old_sigaction in x86-32 compat

In a follow-up patch which updates the instrumentation for x86-32, the
instrumentation of the old_sigaction() syscall would fail to build when
targeting a 64-bit kernel.

In that context, old_sigaction becomes compat_old_sigaction which is a
syscall that can be disabled (it was superseded by rt_sigaction a long
time ago).

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: I633c80e03947a81d1b5c93f8f95a61feb7c34884

23 months agoAdd generated arm-64 syscall instrumentation for kernel 6.0.7
Jérémie Galarneau [Wed, 9 Nov 2022 19:34:30 +0000 (14:34 -0500)] 
Add generated arm-64 syscall instrumentation for kernel 6.0.7

Generated by running:
  ./lttng-syscalls-generate-headers.sh pointers 6.0.7 arm-64-syscalls arm-64 64 && ./lttng-syscalls-generate-headers.sh integers 6.0.7 arm-64-syscalls arm-64 64

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: I8cc65d1a16d66158a580cb492a82549f7f8c6ef1

This page took 0.052356 seconds and 4 git commands to generate.