#include <linux/cpu.h>
#include <linux/delay.h>
#include <linux/fs.h>
#include <linux/nmi.h>
#include <linux/slab.h>
#include <linux/stop_machine.h>
#include "ifs.h"
#define CREATE_TRACE_POINTS
#include <trace/events/intel_ifs.h>
#define MAX_IFS_RETRIES …
struct run_params { … };
struct sbaf_run_params { … };
#define IFS_THREAD_WAIT …
enum ifs_status_err_code { … };
static const char * const scan_test_status[] = …;
static void message_not_tested(struct device *dev, int cpu, union ifs_status status)
{ … }
static void message_fail(struct device *dev, int cpu, union ifs_status status)
{ … }
static bool can_restart(union ifs_status status)
{ … }
#define SPINUNIT …
static atomic_t array_cpus_in;
static atomic_t scan_cpus_in;
static atomic_t sbaf_cpus_in;
static void wait_for_sibling_cpu(atomic_t *t, long long timeout)
{ … }
static int doscan(void *data)
{ … }
static void ifs_test_core(int cpu, struct device *dev)
{ … }
static int do_array_test(void *data)
{ … }
static void ifs_array_test_core(int cpu, struct device *dev)
{ … }
#define ARRAY_GEN1_TEST_ALL_ARRAYS …
#define ARRAY_GEN1_STATUS_FAIL …
static int do_array_test_gen1(void *status)
{ … }
static void ifs_array_test_gen1(int cpu, struct device *dev)
{ … }
#define SBAF_STATUS_PASS …
#define SBAF_STATUS_SIGN_FAIL …
#define SBAF_STATUS_INTR …
#define SBAF_STATUS_TEST_FAIL …
enum sbaf_status_err_code { … };
static const char * const sbaf_test_status[] = …;
static void sbaf_message_not_tested(struct device *dev, int cpu, u64 status_data)
{ … }
static void sbaf_message_fail(struct device *dev, int cpu, union ifs_sbaf_status status)
{ … }
static bool sbaf_bundle_completed(union ifs_sbaf_status status)
{ … }
static bool sbaf_can_restart(union ifs_sbaf_status status)
{ … }
static int dosbaf(void *data)
{ … }
static void ifs_sbaf_test_core(int cpu, struct device *dev)
{ … }
int do_core_test(int cpu, struct device *dev)
{ … }