Linux Perf
kmod-path.c File Reference
#include <stdbool.h>
#include <stdlib.h>
#include "tests.h"
#include "dso.h"
#include "debug.h"
Include dependency graph for kmod-path.c:

Go to the source code of this file.

Macros

#define T(path, an, ae, k, c, n, e)   TEST_ASSERT_VAL("failed", !test(path, an, ae, k, c, n, e))
 
#define M(path, c, e)   TEST_ASSERT_VAL("failed", !test_is_kernel_module(path, c, e))
 

Functions

static int test (const char *path, bool alloc_name, bool alloc_ext, bool kmod, bool comp, const char *name, const char *ext)
 
static int test_is_kernel_module (const char *path, int cpumode, bool expect)
 
int test__kmod_path__parse (struct test *t __maybe_unused, int subtest __maybe_unused)
 

Macro Definition Documentation

◆ M

#define M (   path,
  c,
 
)    TEST_ASSERT_VAL("failed", !test_is_kernel_module(path, c, e))

Definition at line 51 of file kmod-path.c.

◆ T

#define T (   path,
  an,
  ae,
  k,
  c,
  n,
 
)    TEST_ASSERT_VAL("failed", !test(path, an, ae, k, c, n, e))

Definition at line 48 of file kmod-path.c.

Function Documentation

◆ test()

static int test ( const char *  path,
bool  alloc_name,
bool  alloc_ext,
bool  kmod,
bool  comp,
const char *  name,
const char *  ext 
)
static

Definition at line 8 of file kmod-path.c.

Here is the call graph for this function:

◆ test__kmod_path__parse()

int test__kmod_path__parse ( struct test *t  __maybe_unused,
int subtest  __maybe_unused 
)

Definition at line 54 of file kmod-path.c.

◆ test_is_kernel_module()

static int test_is_kernel_module ( const char *  path,
int  cpumode,
bool  expect 
)
static

Definition at line 39 of file kmod-path.c.

Here is the call graph for this function: