Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Fields
ubifs_wbuf Struct Reference

#include <ubifs.h>

Data Fields

struct ubifs_infoc
 
voidbuf
 
int lnum
 
int offs
 
int avail
 
int used
 
int size
 
int jhead
 
int(* sync_callback )(struct ubifs_info *c, int lnum, int free, int pad)
 
struct mutex io_mutex
 
spinlock_t lock
 
ktime_t softlimit
 
unsigned long long delta
 
struct hrtimer timer
 
unsigned int no_timer:1
 
unsigned int need_sync:1
 
int next_ino
 
ino_tinodes
 

Detailed Description

struct ubifs_wbuf - UBIFS write-buffer. : UBIFS file-system description object : write-buffer (of min. flash I/O unit size) : logical eraseblock number the write-buffer points to : write-buffer offset in this logical eraseblock : number of bytes available in the write-buffer : number of used bytes in the write-buffer : write-buffer size (in [->min_io_size, ->max_write_size] range) : journal head the mutex belongs to (note, needed only to shut lockdep up by 'mutex_lock_nested()). : write-buffer synchronization callback : serializes write-buffer I/O : serializes , , , , , and fields : soft write-buffer timeout interval : hard and soft timeouts delta (the timer expire inteval is and + ) : write-buffer timer : non-zero if this write-buffer does not have a timer : non-zero if the timer expired and the wbuf needs sync'ing : points to the next position of the following inode number : stores the inode numbers of the nodes which are in wbuf

The write-buffer synchronization callback is called when the write-buffer is synchronized in order to notify how much space was wasted due to write-buffer padding and how much free space is left in the LEB.

Note: the fields , , , and can be read under spin-lock or mutex because they are written under both mutex and spin-lock. is appended to under mutex but overwritten under both mutex and spin-lock. Thus the data between and + can be read under spinlock.

Definition at line 677 of file ubifs.h.

Field Documentation

int avail

Definition at line 682 of file ubifs.h.

Definition at line 679 of file ubifs.h.

Definition at line 678 of file ubifs.h.

unsigned long long delta

Definition at line 690 of file ubifs.h.

ino_t* inodes

Definition at line 695 of file ubifs.h.

struct mutex io_mutex

Definition at line 687 of file ubifs.h.

int jhead

Definition at line 685 of file ubifs.h.

int lnum

Definition at line 680 of file ubifs.h.

spinlock_t lock

Definition at line 688 of file ubifs.h.

unsigned int need_sync

Definition at line 693 of file ubifs.h.

int next_ino

Definition at line 694 of file ubifs.h.

unsigned int no_timer

Definition at line 692 of file ubifs.h.

int offs

Definition at line 681 of file ubifs.h.

int size

Definition at line 684 of file ubifs.h.

ktime_t softlimit

Definition at line 689 of file ubifs.h.

int(* sync_callback)(struct ubifs_info *c, int lnum, int free, int pad)

Definition at line 686 of file ubifs.h.

Definition at line 691 of file ubifs.h.

int used

Definition at line 683 of file ubifs.h.


The documentation for this struct was generated from the following file: