1 /* SPDX-License-Identifier: GPL-2.0 */
2 #ifndef _BCACHEFS_CLOCK_TYPES_H
3 #define _BCACHEFS_CLOCK_TYPES_H
7 #define NR_IO_TIMERS (BCH_SB_MEMBERS_MAX * 3)
10 * Clocks/timers in units of sectors of IO:
12 * Note - they use percpu batching, so they're only approximate.
16 typedef void (*io_timer_fn)(struct io_timer *);
23 /* Amount to buffer up on a percpu counter */
24 #define IO_CLOCK_PCPU_SECTORS 128
26 typedef HEAP(struct io_timer *) io_timer_heap;
30 u16 __percpu *pcpu_buf;
33 spinlock_t timer_lock;
37 #endif /* _BCACHEFS_CLOCK_TYPES_H */