Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

at v6.17-rc2 28 lines 643 B view raw
1// SPDX-License-Identifier: GPL-2.0 2/* Copyright (c) 2024 Meta Platforms, Inc. and affiliates. */ 3 4#include <test_progs.h> 5#include "raw_tp_null.skel.h" 6#include "raw_tp_null_fail.skel.h" 7 8void test_raw_tp_null(void) 9{ 10 struct raw_tp_null *skel; 11 12 RUN_TESTS(raw_tp_null_fail); 13 14 skel = raw_tp_null__open_and_load(); 15 if (!ASSERT_OK_PTR(skel, "raw_tp_null__open_and_load")) 16 return; 17 18 skel->bss->tid = sys_gettid(); 19 20 if (!ASSERT_OK(raw_tp_null__attach(skel), "raw_tp_null__attach")) 21 goto end; 22 23 ASSERT_OK(trigger_module_test_read(2), "trigger testmod read"); 24 ASSERT_EQ(skel->bss->i, 3, "invocations"); 25 26end: 27 raw_tp_null__destroy(skel); 28}