Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Typedefs | Functions
ext4_extents.h File Reference
#include "ext4.h"

Go to the source code of this file.

Data Structures

struct  ext4_extent_tail
 
struct  ext4_extent
 
struct  ext4_extent_idx
 
struct  ext4_extent_header
 
struct  ext4_ext_path
 

Macros

#define AGGRESSIVE_TEST_
 
#define EXTENTS_STATS__
 
#define CHECK_BINSEARCH__
 
#define EXT_DEBUG__
 
#define ext_debug(fmt,...)   no_printk(fmt, ##__VA_ARGS__)
 
#define EXT_STATS_
 
#define EXT4_EXT_MAGIC   cpu_to_le16(0xf30a)
 
#define EXT4_EXTENT_TAIL_OFFSET(hdr)
 
#define EXT_CONTINUE   0
 
#define EXT_BREAK   1
 
#define EXT_REPEAT   2
 
#define EXT_MAX_BLOCKS   0xffffffff
 
#define EXT_INIT_MAX_LEN   (1UL << 15)
 
#define EXT_UNINIT_MAX_LEN   (EXT_INIT_MAX_LEN - 1)
 
#define EXT_FIRST_EXTENT(__hdr__)
 
#define EXT_FIRST_INDEX(__hdr__)
 
#define EXT_HAS_FREE_INDEX(__path__)
 
#define EXT_LAST_EXTENT(__hdr__)   (EXT_FIRST_EXTENT((__hdr__)) + le16_to_cpu((__hdr__)->eh_entries) - 1)
 
#define EXT_LAST_INDEX(__hdr__)   (EXT_FIRST_INDEX((__hdr__)) + le16_to_cpu((__hdr__)->eh_entries) - 1)
 
#define EXT_MAX_EXTENT(__hdr__)   (EXT_FIRST_EXTENT((__hdr__)) + le16_to_cpu((__hdr__)->eh_max) - 1)
 
#define EXT_MAX_INDEX(__hdr__)   (EXT_FIRST_INDEX((__hdr__)) + le16_to_cpu((__hdr__)->eh_max) - 1)
 

Typedefs

typedef int(* ext_prepare_callback )(struct inode *, ext4_lblk_t, struct ext4_ext_cache *, struct ext4_extent *, void *)
 

Functions

int ext4_ext_calc_metadata_amount (struct inode *inode, ext4_lblk_t lblocks)
 
int ext4_extent_tree_init (handle_t *, struct inode *)
 
int ext4_ext_calc_credits_for_single_extent (struct inode *inode, int num, struct ext4_ext_path *path)
 
int ext4_can_extents_be_merged (struct inode *inode, struct ext4_extent *ex1, struct ext4_extent *ex2)
 
int ext4_ext_insert_extent (handle_t *, struct inode *, struct ext4_ext_path *, struct ext4_extent *, int)
 
struct ext4_ext_pathext4_ext_find_extent (struct inode *, ext4_lblk_t, struct ext4_ext_path *)
 
void ext4_ext_drop_refs (struct ext4_ext_path *)
 
int ext4_ext_check_inode (struct inode *inode)
 
int ext4_find_delalloc_cluster (struct inode *inode, ext4_lblk_t lblk, int search_hint_reverse)
 

Macro Definition Documentation

#define AGGRESSIVE_TEST_

Definition at line 30 of file ext4_extents.h.

#define CHECK_BINSEARCH__

Definition at line 43 of file ext4_extents.h.

#define EXT4_EXT_MAGIC   cpu_to_le16(0xf30a)

Definition at line 115 of file ext4_extents.h.

#define EXT4_EXTENT_TAIL_OFFSET (   hdr)
Value:

Definition at line 117 of file ext4_extents.h.

#define EXT_BREAK   1

Definition at line 157 of file ext4_extents.h.

#define EXT_CONTINUE   0

Definition at line 156 of file ext4_extents.h.

#define ext_debug (   fmt,
  ... 
)    no_printk(fmt, ##__VA_ARGS__)

Definition at line 52 of file ext4_extents.h.

#define EXT_DEBUG__

Definition at line 48 of file ext4_extents.h.

#define EXT_FIRST_EXTENT (   __hdr__)
Value:
((struct ext4_extent *) (((char *) (__hdr__)) + \
sizeof(struct ext4_extent_header)))

Definition at line 187 of file ext4_extents.h.

#define EXT_FIRST_INDEX (   __hdr__)
Value:
((struct ext4_extent_idx *) (((char *) (__hdr__)) + \
sizeof(struct ext4_extent_header)))

Definition at line 190 of file ext4_extents.h.

#define EXT_HAS_FREE_INDEX (   __path__)
Value:
(le16_to_cpu((__path__)->p_hdr->eh_entries) \
< le16_to_cpu((__path__)->p_hdr->eh_max))

Definition at line 193 of file ext4_extents.h.

#define EXT_INIT_MAX_LEN   (1UL << 15)

Definition at line 183 of file ext4_extents.h.

#define EXT_LAST_EXTENT (   __hdr__)    (EXT_FIRST_EXTENT((__hdr__)) + le16_to_cpu((__hdr__)->eh_entries) - 1)

Definition at line 196 of file ext4_extents.h.

#define EXT_LAST_INDEX (   __hdr__)    (EXT_FIRST_INDEX((__hdr__)) + le16_to_cpu((__hdr__)->eh_entries) - 1)

Definition at line 198 of file ext4_extents.h.

#define EXT_MAX_BLOCKS   0xffffffff

Definition at line 164 of file ext4_extents.h.

#define EXT_MAX_EXTENT (   __hdr__)    (EXT_FIRST_EXTENT((__hdr__)) + le16_to_cpu((__hdr__)->eh_max) - 1)

Definition at line 200 of file ext4_extents.h.

#define EXT_MAX_INDEX (   __hdr__)    (EXT_FIRST_INDEX((__hdr__)) + le16_to_cpu((__hdr__)->eh_max) - 1)

Definition at line 202 of file ext4_extents.h.

#define EXT_REPEAT   2

Definition at line 158 of file ext4_extents.h.

#define EXT_STATS_

Definition at line 59 of file ext4_extents.h.

#define EXT_UNINIT_MAX_LEN   (EXT_INIT_MAX_LEN - 1)

Definition at line 184 of file ext4_extents.h.

#define EXTENTS_STATS__

Definition at line 37 of file ext4_extents.h.

Typedef Documentation

typedef int(* ext_prepare_callback)(struct inode *, ext4_lblk_t, struct ext4_ext_cache *, struct ext4_extent *, void *)

Definition at line 152 of file ext4_extents.h.

Function Documentation

int ext4_can_extents_be_merged ( struct inode inode,
struct ext4_extent ex1,
struct ext4_extent ex2 
)

Definition at line 1573 of file extents.c.

int ext4_ext_calc_credits_for_single_extent ( struct inode inode,
int  num,
struct ext4_ext_path path 
)

Definition at line 2233 of file extents.c.

int ext4_ext_calc_metadata_amount ( struct inode inode,
ext4_lblk_t  lblocks 
)

Definition at line 294 of file extents.c.

int ext4_ext_check_inode ( struct inode inode)

Definition at line 459 of file extents.c.

void ext4_ext_drop_refs ( struct ext4_ext_path )

Definition at line 567 of file extents.c.

struct ext4_ext_path* ext4_ext_find_extent ( struct inode ,
ext4_lblk_t  ,
struct ext4_ext_path  
)
read

Definition at line 716 of file extents.c.

int ext4_ext_insert_extent ( handle_t *  ,
struct inode ,
struct ext4_ext_path ,
struct ext4_extent ,
int   
)

Definition at line 1787 of file extents.c.

int ext4_extent_tree_init ( handle_t *  ,
struct inode  
)
int ext4_find_delalloc_cluster ( struct inode inode,
ext4_lblk_t  lblk,
int  search_hint_reverse 
)

Definition at line 3562 of file extents.c.