Linux Kernel
3.7.1
|
#include <linux/types.h>
#include <linux/buffer_head.h>
#include <linux/rbtree.h>
#include <linux/fs.h>
#include <linux/blkdev.h>
#include <linux/backing-dev.h>
#include <linux/slab.h>
Go to the source code of this file.
Data Structures | |
struct | the_nilfs |
struct | nilfs_root |
Macros | |
#define | THE_NILFS_FNS(bit, name) |
#define | nilfs_clear_opt(nilfs, opt) do { (nilfs)->ns_mount_opt &= ~NILFS_MOUNT_##opt; } while (0) |
#define | nilfs_set_opt(nilfs, opt) do { (nilfs)->ns_mount_opt |= NILFS_MOUNT_##opt; } while (0) |
#define | nilfs_test_opt(nilfs, opt) ((nilfs)->ns_mount_opt & NILFS_MOUNT_##opt) |
#define | nilfs_write_opt(nilfs, mask, opt) |
#define | NILFS_CPTREE_CURRENT_CNO 0 |
#define | NILFS_SB_FREQ 10 |
Enumerations | |
enum | { THE_NILFS_INIT = 0, THE_NILFS_DISCONTINUED, THE_NILFS_GC_RUNNING, THE_NILFS_SB_DIRTY } |
Functions | |
void | nilfs_set_last_segment (struct the_nilfs *, sector_t, u64, __u64) |
struct the_nilfs * | alloc_nilfs (struct block_device *bdev) |
void | destroy_nilfs (struct the_nilfs *nilfs) |
int | init_nilfs (struct the_nilfs *nilfs, struct super_block *sb, char *data) |
int | load_nilfs (struct the_nilfs *nilfs, struct super_block *sb) |
unsigned long | nilfs_nrsvsegs (struct the_nilfs *nilfs, unsigned long nsegs) |
void | nilfs_set_nsegments (struct the_nilfs *nilfs, unsigned long nsegs) |
int | nilfs_discard_segments (struct the_nilfs *, __u64 *, size_t) |
int | nilfs_count_free_blocks (struct the_nilfs *, sector_t *) |
struct nilfs_root * | nilfs_lookup_root (struct the_nilfs *nilfs, __u64 cno) |
struct nilfs_root * | nilfs_find_or_create_root (struct the_nilfs *nilfs, __u64 cno) |
void | nilfs_put_root (struct nilfs_root *root) |
int | nilfs_near_disk_full (struct the_nilfs *) |
void | nilfs_fall_back_super_block (struct the_nilfs *) |
void | nilfs_swap_super_block (struct the_nilfs *) |
#define nilfs_clear_opt | ( | nilfs, | |
opt | |||
) | do { (nilfs)->ns_mount_opt &= ~NILFS_MOUNT_##opt; } while (0) |
Definition at line 215 of file the_nilfs.h.
#define NILFS_CPTREE_CURRENT_CNO 0 |
Definition at line 249 of file the_nilfs.h.
#define NILFS_SB_FREQ 10 |
Definition at line 252 of file the_nilfs.h.
Definition at line 217 of file the_nilfs.h.
Definition at line 219 of file the_nilfs.h.
Definition at line 220 of file the_nilfs.h.
Definition at line 193 of file the_nilfs.h.
anonymous enum |
Definition at line 38 of file the_nilfs.h.
|
read |
alloc_nilfs - allocate a nilfs object : block device to which the_nilfs is related
Return Value: On success, pointer to the_nilfs is returned. On error, NULL is returned.
Definition at line 68 of file the_nilfs.c.
destroy_nilfs - destroy nilfs object : nilfs object to be released
Definition at line 96 of file the_nilfs.c.
init_nilfs - initialize a NILFS instance. : the_nilfs structure : super block : mount options
init_nilfs() performs common initialization per block device (e.g. reading the super block, getting disk layout information, initializing shared fields in the_nilfs).
Return Value: On success, 0 is returned. On error, a negative error code is returned.
Definition at line 561 of file the_nilfs.c.
int load_nilfs | ( | struct the_nilfs * | nilfs, |
struct super_block * | sb | ||
) |
load_nilfs - load and recover the nilfs : the_nilfs structure to be released : super block isntance used to recover past segment
load_nilfs() searches and load the latest super root, attaches the last segment, and does recovery if needed. The caller must call this exclusively for simultaneous mounts.
Definition at line 211 of file the_nilfs.c.
Definition at line 681 of file the_nilfs.c.
Definition at line 644 of file the_nilfs.c.
Definition at line 464 of file the_nilfs.c.
|
read |
Definition at line 729 of file the_nilfs.c.
|
read |
Definition at line 703 of file the_nilfs.c.
Definition at line 692 of file the_nilfs.c.
nilfs_nrsvsegs - calculate the number of reserved segments : nilfs object : total number of segments
Definition at line 372 of file the_nilfs.c.
void nilfs_put_root | ( | struct nilfs_root * | root | ) |
Definition at line 778 of file the_nilfs.c.
Definition at line 41 of file the_nilfs.c.
Definition at line 379 of file the_nilfs.c.
Definition at line 473 of file the_nilfs.c.