Staging
v0.8.1
https://github.com/torvalds/linux
Raw File
Tip revision: 8c2ffd9174779014c3fe1f96d9dc3641d9175f00 authored by Linus Torvalds on 24 March 2019, 21:02:26 UTC
Linux 5.1-rc2
Tip revision: 8c2ffd9
error-injection.h
/* SPDX-License-Identifier: GPL-2.0 */
#ifndef _LINUX_ERROR_INJECTION_H
#define _LINUX_ERROR_INJECTION_H

#ifdef CONFIG_FUNCTION_ERROR_INJECTION

#include <asm/error-injection.h>

extern bool within_error_injection_list(unsigned long addr);
extern int get_injectable_error_type(unsigned long addr);

#else /* !CONFIG_FUNCTION_ERROR_INJECTION */

#include <asm-generic/error-injection.h>
static inline bool within_error_injection_list(unsigned long addr)
{
	return false;
}

static inline int get_injectable_error_type(unsigned long addr)
{
	return EI_ETYPE_NONE;
}

#endif

#endif /* _LINUX_ERROR_INJECTION_H */
back to top