mirror of
https://github.com/torvalds/linux.git
synced 2024-11-26 14:12:06 +00:00
f5d26fa31e
Add a new superblock section to keep counts of errors seen since filesystem creation: we'll be addingcounters for every distinct fsck error. The new superblock section has entries of the for [ id, count, time_of_last_error ]; this is intended to let us see what errors are occuring - and getting fixed - via show-super output. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
27 lines
614 B
C
27 lines
614 B
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
#ifndef _BCACHEFS_SB_ERRORS_H
|
|
#define _BCACHEFS_SB_ERRORS_H
|
|
|
|
#include "sb-errors_types.h"
|
|
|
|
#define BCH_SB_ERRS()
|
|
|
|
enum bch_sb_error_id {
|
|
#define x(t, n) BCH_FSCK_ERR_##t = n,
|
|
BCH_SB_ERRS()
|
|
#undef x
|
|
BCH_SB_ERR_MAX
|
|
};
|
|
|
|
extern const struct bch_sb_field_ops bch_sb_field_ops_errors;
|
|
|
|
void bch2_sb_error_count(struct bch_fs *, enum bch_sb_error_id);
|
|
|
|
void bch2_sb_errors_from_cpu(struct bch_fs *);
|
|
|
|
void bch2_fs_sb_errors_exit(struct bch_fs *);
|
|
void bch2_fs_sb_errors_init_early(struct bch_fs *);
|
|
int bch2_fs_sb_errors_init(struct bch_fs *);
|
|
|
|
#endif /* _BCACHEFS_SB_ERRORS_H */
|