#include "xfs.h"
#include "xfs_shared.h"
#include "xfs_format.h"
#include "xfs_fs.h"
#include "xfs_log_format.h"
#include "xfs_trans_resv.h"
#include "xfs_mount.h"
#include "xfs_errortag.h"
#include "xfs_error.h"
#include "xfs_sysfs.h"
#include "xfs_inode.h"
#ifdef DEBUG
static unsigned int xfs_errortag_random_default[] = …;
struct xfs_errortag_attr { … };
static inline struct xfs_errortag_attr *
to_attr(struct attribute *attr)
{ … }
static inline struct xfs_mount *
to_mp(struct kobject *kobject)
{ … }
STATIC ssize_t
xfs_errortag_attr_store(
struct kobject *kobject,
struct attribute *attr,
const char *buf,
size_t count)
{ … }
STATIC ssize_t
xfs_errortag_attr_show(
struct kobject *kobject,
struct attribute *attr,
char *buf)
{ … }
static const struct sysfs_ops xfs_errortag_sysfs_ops = …;
#define XFS_ERRORTAG_ATTR_RW(_name, _tag) …
#define XFS_ERRORTAG_ATTR_LIST(_name) …
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
XFS_ERRORTAG_ATTR_RW(…);
static struct attribute *xfs_errortag_attrs[] = …;
ATTRIBUTE_GROUPS(…);
static const struct kobj_type xfs_errortag_ktype = …;
int
xfs_errortag_init(
struct xfs_mount *mp)
{ … }
void
xfs_errortag_del(
struct xfs_mount *mp)
{ … }
static bool
xfs_errortag_valid(
unsigned int error_tag)
{ … }
bool
xfs_errortag_enabled(
struct xfs_mount *mp,
unsigned int tag)
{ … }
bool
xfs_errortag_test(
struct xfs_mount *mp,
const char *expression,
const char *file,
int line,
unsigned int error_tag)
{ … }
int
xfs_errortag_get(
struct xfs_mount *mp,
unsigned int error_tag)
{ … }
int
xfs_errortag_set(
struct xfs_mount *mp,
unsigned int error_tag,
unsigned int tag_value)
{ … }
int
xfs_errortag_add(
struct xfs_mount *mp,
unsigned int error_tag)
{ … }
int
xfs_errortag_clearall(
struct xfs_mount *mp)
{ … }
#endif
void
xfs_error_report(
const char *tag,
int level,
struct xfs_mount *mp,
const char *filename,
int linenum,
xfs_failaddr_t failaddr)
{ … }
void
xfs_corruption_error(
const char *tag,
int level,
struct xfs_mount *mp,
const void *buf,
size_t bufsize,
const char *filename,
int linenum,
xfs_failaddr_t failaddr)
{ … }
void
xfs_buf_corruption_error(
struct xfs_buf *bp,
xfs_failaddr_t fa)
{ … }
void
xfs_buf_verifier_error(
struct xfs_buf *bp,
int error,
const char *name,
const void *buf,
size_t bufsz,
xfs_failaddr_t failaddr)
{ … }
void
xfs_verifier_error(
struct xfs_buf *bp,
int error,
xfs_failaddr_t failaddr)
{ … }
void
xfs_inode_verifier_error(
struct xfs_inode *ip,
int error,
const char *name,
const void *buf,
size_t bufsz,
xfs_failaddr_t failaddr)
{ … }