xref: /linux/fs/bcachefs/disk_accounting_types.h (revision 9f9a53472452b83d44d5e1d77b6dea6eaa043204)
1 /* SPDX-License-Identifier: GPL-2.0 */
2 #ifndef _BCACHEFS_DISK_ACCOUNTING_TYPES_H
3 #define _BCACHEFS_DISK_ACCOUNTING_TYPES_H
4 
5 #include "darray.h"
6 
7 struct accounting_mem_entry {
8 	struct bpos				pos;
9 	struct bversion				bversion;
10 	unsigned				nr_counters;
11 	u64 __percpu				*v[2];
12 };
13 
14 struct bch_accounting_mem {
15 	DARRAY(struct accounting_mem_entry)	k;
16 	bool					gc_running;
17 };
18 
19 #endif /* _BCACHEFS_DISK_ACCOUNTING_TYPES_H */
20