linux/kernel/kcsan/debugfs.c

// SPDX-License-Identifier: GPL-2.0
/*
 * KCSAN debugfs interface.
 *
 * Copyright (C) 2019, Google LLC.
 */

#define pr_fmt(fmt)

#include <linux/atomic.h>
#include <linux/bsearch.h>
#include <linux/bug.h>
#include <linux/debugfs.h>
#include <linux/init.h>
#include <linux/kallsyms.h>
#include <linux/sched.h>
#include <linux/seq_file.h>
#include <linux/slab.h>
#include <linux/sort.h>
#include <linux/string.h>
#include <linux/uaccess.h>

#include "kcsan.h"

atomic_long_t kcsan_counters[KCSAN_COUNTER_COUNT];
static const char *const counter_names[] =;
static_assert();

/*
 * Addresses for filtering functions from reporting. This list can be used as a
 * whitelist or blacklist.
 */
static struct {} report_filterlist =;
static DEFINE_SPINLOCK(report_filterlist_lock);

/*
 * The microbenchmark allows benchmarking KCSAN core runtime only. To run
 * multiple threads, pipe 'microbench=<iters>' from multiple tasks into the
 * debugfs file. This will not generate any conflicts, and tests fast-path only.
 */
static noinline void microbenchmark(unsigned long iters)
{}

static int cmp_filterlist_addrs(const void *rhs, const void *lhs)
{}

bool kcsan_skip_report_debugfs(unsigned long func_addr)
{}

static void set_report_filterlist_whitelist(bool whitelist)
{}

/* Returns 0 on success, error-code otherwise. */
static ssize_t insert_report_filterlist(const char *func)
{}

static int show_info(struct seq_file *file, void *v)
{}

static int debugfs_open(struct inode *inode, struct file *file)
{}

static ssize_t
debugfs_write(struct file *file, const char __user *buf, size_t count, loff_t *off)
{}

static const struct file_operations debugfs_ops =;

static int __init kcsan_debugfs_init(void)
{}

late_initcall(kcsan_debugfs_init);