FreeBSD ZFS
The Zettabyte File System
Data Structures | Defines | Typedefs | Enumerations | Variables

sys/dmu_impl.h File Reference

This is the locking strategy for the DMU. More...

#include <sys/txg_impl.h>
#include <sys/zio.h>
#include <sys/dnode.h>
#include <sys/kstat.h>
#include <sys/zfs_context.h>
#include <sys/zfs_ioctl.h>
#include <sys/zfs_ioctl.h>
Include dependency graph for dmu_impl.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  dmu_xuio
struct  xuio_stats
struct  dmu_sendarg

Defines

#define XUIOSTAT_INCR(stat, val)   atomic_add_64(&xuio_stats.stat.value.ui64, (val))
#define XUIOSTAT_BUMP(stat)   XUIOSTAT_INCR(stat, 1)

Typedefs

typedef struct dmu_xuio dmu_xuio_t
typedef struct xuio_stats xuio_stats_t
typedef struct dmu_sendarg dmu_sendarg_t

Enumerations

enum  dmu_pendop_t { PENDING_NONE, PENDING_FREE, PENDING_FREEOBJECTS }

Variables

static xuio_stats_t xuio_stats

Detailed Description

This is the locking strategy for the DMU.

Numbers in parenthesis are cases that use that lock order, referenced below:

Todo:
try to improve evicting path?

dp_config_rwlock > os_obj_lock > dn_struct_rwlock > dn_dbufs_mtx > hash_mutexes > db_mtx > dd_lock > leafs

dp_config_rwlock

os_obj_lock

dn_struct_rwlock

dn_dbufs_mtx

hash_mutexes (global)

db_mtx (meta-leaf)

dn_mtx (leaf)

dd_lock

os_lock (leaf)

ds_lock

dr_mtx (leaf)

Definition in file dmu_impl.h.


Define Documentation

#define XUIOSTAT_BUMP (   stat)    XUIOSTAT_INCR(stat, 1)

Definition at line 271 of file dmu_impl.h.

#define XUIOSTAT_INCR (   stat,
  val 
)    atomic_add_64(&xuio_stats.stat.value.ui64, (val))

Definition at line 269 of file dmu_impl.h.


Typedef Documentation

typedef struct dmu_sendarg dmu_sendarg_t
typedef struct dmu_xuio dmu_xuio_t
typedef struct xuio_stats xuio_stats_t

Enumeration Type Documentation

Enumerator:
PENDING_NONE 
PENDING_FREE 
PENDING_FREEOBJECTS 

Definition at line 279 of file dmu_impl.h.


Variable Documentation

Initial value:
 {
        { "onloan_read_buf",    KSTAT_DATA_UINT64 },
        { "onloan_write_buf",   KSTAT_DATA_UINT64 },
        { "read_buf_copied",    KSTAT_DATA_UINT64 },
        { "read_buf_nocopy",    KSTAT_DATA_UINT64 },
        { "write_buf_copied",   KSTAT_DATA_UINT64 },
        { "write_buf_nocopy",   KSTAT_DATA_UINT64 }
}

Definition at line 260 of file dmu_impl.h.

 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines