Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Enumerations | Functions
blocklayout.h File Reference
#include <linux/device-mapper.h>
#include <linux/nfs_fs.h>
#include <linux/sunrpc/rpc_pipe_fs.h>
#include "../pnfs.h"
#include "../netns.h"

Go to the source code of this file.

Data Structures

struct  block_mount_id
 
struct  pnfs_block_dev
 
struct  my_tree
 
struct  pnfs_inval_markings
 
struct  pnfs_inval_tracking
 
struct  pnfs_block_extent
 
struct  pnfs_block_short_extent
 
struct  pnfs_block_layout
 
struct  bl_pipe_msg
 
struct  bl_msg_hdr
 

Macros

#define PAGE_CACHE_SECTORS   (PAGE_CACHE_SIZE >> SECTOR_SHIFT)
 
#define PAGE_CACHE_SECTOR_SHIFT   (PAGE_CACHE_SHIFT - SECTOR_SHIFT)
 
#define SECTOR_SIZE   (1 << SECTOR_SHIFT)
 
#define MY_MAX_TAGS   (15) /* tag bitnums used must be less than this */
 
#define BLK_ID(lo)   ((struct block_mount_id *)(NFS_SERVER(lo->plh_inode)->pnfs_ld_data))
 
#define BL_DEVICE_UMOUNT   0x0 /* Umount--delete devices */
 
#define BL_DEVICE_MOUNT   0x1 /* Mount--create devices*/
 
#define BL_DEVICE_REQUEST_INIT   0x0 /* Start request */
 
#define BL_DEVICE_REQUEST_PROC   0x1 /* User level process succeeds */
 
#define BL_DEVICE_REQUEST_ERR   0x2 /* User level process fails */
 

Enumerations

enum  exstate4 { PNFS_BLOCK_READWRITE_DATA = 0, PNFS_BLOCK_READ_DATA = 1, PNFS_BLOCK_INVALID_DATA = 2, PNFS_BLOCK_NONE_DATA = 3 }
 
enum  extentclass4 { RW_EXTENT = 0, RO_EXTENT = 1, EXTENT_LISTS = 2 }
 

Functions

ssize_t bl_pipe_downcall (struct file *, const char __user *, size_t)
 
void bl_pipe_destroy_msg (struct rpc_pipe_msg *)
 
int nfs4_blkdev_put (struct block_device *bdev)
 
struct pnfs_block_devnfs4_blk_decode_device (struct nfs_server *server, struct pnfs_device *dev)
 
int nfs4_blk_process_layoutget (struct pnfs_layout_hdr *lo, struct nfs4_layoutget_res *lgr, gfp_t gfp_flags)
 
void bl_free_block_dev (struct pnfs_block_dev *bdev)
 
struct pnfs_block_extentbl_find_get_extent (struct pnfs_block_layout *bl, sector_t isect, struct pnfs_block_extent **cow_read)
 
int bl_mark_sectors_init (struct pnfs_inval_markings *marks, sector_t offset, sector_t length)
 
void bl_put_extent (struct pnfs_block_extent *be)
 
struct pnfs_block_extentbl_alloc_extent (void)
 
int bl_is_sector_init (struct pnfs_inval_markings *marks, sector_t isect)
 
int encode_pnfs_block_layoutupdate (struct pnfs_block_layout *bl, struct xdr_stream *xdr, const struct nfs4_layoutcommit_args *arg)
 
void clean_pnfs_block_layoutupdate (struct pnfs_block_layout *bl, const struct nfs4_layoutcommit_args *arg, int status)
 
int bl_add_merge_extent (struct pnfs_block_layout *bl, struct pnfs_block_extent *new)
 
int bl_mark_for_commit (struct pnfs_block_extent *be, sector_t offset, sector_t length, struct pnfs_block_short_extent *new)
 
int bl_push_one_short_extent (struct pnfs_inval_markings *marks)
 
struct pnfs_block_short_extentbl_pop_one_short_extent (struct pnfs_inval_markings *marks)
 
void bl_free_short_extents (struct pnfs_inval_markings *marks, int num_to_free)
 

Macro Definition Documentation

#define BL_DEVICE_MOUNT   0x1 /* Mount--create devices*/

Definition at line 168 of file blocklayout.h.

#define BL_DEVICE_REQUEST_ERR   0x2 /* User level process fails */

Definition at line 171 of file blocklayout.h.

#define BL_DEVICE_REQUEST_INIT   0x0 /* Start request */

Definition at line 169 of file blocklayout.h.

#define BL_DEVICE_REQUEST_PROC   0x1 /* User level process succeeds */

Definition at line 170 of file blocklayout.h.

#define BL_DEVICE_UMOUNT   0x0 /* Umount--delete devices */

Definition at line 167 of file blocklayout.h.

#define BLK_ID (   lo)    ((struct block_mount_id *)(NFS_SERVER(lo->plh_inode)->pnfs_ld_data))

Definition at line 143 of file blocklayout.h.

#define MY_MAX_TAGS   (15) /* tag bitnums used must be less than this */

Definition at line 65 of file blocklayout.h.

#define PAGE_CACHE_SECTOR_SHIFT   (PAGE_CACHE_SHIFT - SECTOR_SHIFT)

Definition at line 43 of file blocklayout.h.

#define PAGE_CACHE_SECTORS   (PAGE_CACHE_SIZE >> SECTOR_SHIFT)

Definition at line 42 of file blocklayout.h.

#define SECTOR_SIZE   (1 << SECTOR_SHIFT)

Definition at line 44 of file blocklayout.h.

Enumeration Type Documentation

enum exstate4
Enumerator:
PNFS_BLOCK_READWRITE_DATA 
PNFS_BLOCK_READ_DATA 
PNFS_BLOCK_INVALID_DATA 
PNFS_BLOCK_NONE_DATA 

Definition at line 58 of file blocklayout.h.

Enumerator:
RW_EXTENT 
RO_EXTENT 
EXTENT_LISTS 

Definition at line 118 of file blocklayout.h.

Function Documentation

int bl_add_merge_extent ( struct pnfs_block_layout bl,
struct pnfs_block_extent new 
)

Definition at line 495 of file extents.c.

struct pnfs_block_extent* bl_alloc_extent ( void  )
read

Definition at line 449 of file extents.c.

struct pnfs_block_extent* bl_find_get_extent ( struct pnfs_block_layout bl,
sector_t  isect,
struct pnfs_block_extent **  cow_read 
)
read

Definition at line 590 of file extents.c.

void bl_free_block_dev ( struct pnfs_block_dev bdev)

Definition at line 102 of file blocklayoutdm.c.

void bl_free_short_extents ( struct pnfs_inval_markings marks,
int  num_to_free 
)

Definition at line 891 of file extents.c.

int bl_is_sector_init ( struct pnfs_inval_markings marks,
sector_t  isect 
)

Definition at line 178 of file extents.c.

int bl_mark_for_commit ( struct pnfs_block_extent be,
sector_t  offset,
sector_t  length,
struct pnfs_block_short_extent new 
)

Definition at line 375 of file extents.c.

int bl_mark_sectors_init ( struct pnfs_inval_markings marks,
sector_t  offset,
sector_t  length 
)

Definition at line 234 of file extents.c.

void bl_pipe_destroy_msg ( struct rpc_pipe_msg *  )

Definition at line 83 of file blocklayoutdev.c.

ssize_t bl_pipe_downcall ( struct file ,
const char __user ,
size_t   
)

Definition at line 66 of file blocklayoutdev.c.

struct pnfs_block_short_extent* bl_pop_one_short_extent ( struct pnfs_inval_markings marks)
read

Definition at line 876 of file extents.c.

int bl_push_one_short_extent ( struct pnfs_inval_markings marks)

Definition at line 860 of file extents.c.

void bl_put_extent ( struct pnfs_block_extent be)

Definition at line 440 of file extents.c.

void clean_pnfs_block_layoutupdate ( struct pnfs_block_layout bl,
const struct nfs4_layoutcommit_args arg,
int  status 
)

Definition at line 833 of file extents.c.

int encode_pnfs_block_layoutupdate ( struct pnfs_block_layout bl,
struct xdr_stream *  xdr,
const struct nfs4_layoutcommit_args arg 
)

Definition at line 657 of file extents.c.

struct pnfs_block_dev* nfs4_blk_decode_device ( struct nfs_server server,
struct pnfs_device *  dev 
)
read

Definition at line 96 of file blocklayoutdev.c.

int nfs4_blk_process_layoutget ( struct pnfs_layout_hdr *  lo,
struct nfs4_layoutget_res lgr,
gfp_t  gfp_flags 
)

Definition at line 267 of file blocklayoutdev.c.

int nfs4_blkdev_put ( struct block_device bdev)

Definition at line 59 of file blocklayoutdev.c.