fs/xfs/xfs_refcount_item.h

Source file repositories/reference/linux-study-clean/fs/xfs/xfs_refcount_item.h

File Facts

System
Linux kernel
Corpus path
fs/xfs/xfs_refcount_item.h
Extension
.h
Size
2443 bytes
Lines
83
Domain
Core OS
Bucket
VFS And Filesystem Core
Inferred role
Core OS: implementation source
Status
source implementation candidate

Why This File Exists

Core operating-system implementation surface: boot, tasks, memory, VFS, syscall-facing interfaces, synchronization, credentials, and isolation.

Dependency Surface

Detected Declarations

Annotated Snippet

struct xfs_cui_log_item {
	struct xfs_log_item		cui_item;
	atomic_t			cui_refcount;
	atomic_t			cui_next_extent;
	struct xfs_cui_log_format	cui_format;
};

static inline size_t
xfs_cui_log_item_sizeof(
	unsigned int		nr)
{
	return offsetof(struct xfs_cui_log_item, cui_format) +
			xfs_cui_log_format_sizeof(nr);
}

/*
 * This is the "refcount update done" log item.  It is used to log the
 * fact that some refcountbt updates mentioned in an earlier cui item
 * have been performed.
 */
struct xfs_cud_log_item {
	struct xfs_log_item		cud_item;
	struct xfs_cui_log_item		*cud_cuip;
	struct xfs_cud_log_format	cud_format;
};

extern struct kmem_cache	*xfs_cui_cache;
extern struct kmem_cache	*xfs_cud_cache;

struct xfs_refcount_intent;

void xfs_refcount_defer_add(struct xfs_trans *tp,
		struct xfs_refcount_intent *ri);

unsigned int xfs_cui_log_space(unsigned int nr);
unsigned int xfs_cud_log_space(void);

#endif	/* __XFS_REFCOUNT_ITEM_H__ */

Annotation

Implementation Notes