Motr  M0
io.c File Reference
#include "lib/trace.h"
#include "be/io.h"
#include <unistd.h>
#include "lib/memory.h"
#include "lib/errno.h"
#include "lib/ext.h"
#include "lib/locality.h"
#include "stob/io.h"
#include "stob/stob.h"
#include "be/op.h"
#include "be/ha.h"
Include dependency graph for io.c:

Go to the source code of this file.

Macros

#define M0_TRACE_SUBSYSTEM   M0_TRACE_SUBSYS_BE
 
#define EXT(start, end)   (struct m0_ext){ .e_start = (start), .e_end = (end) }
 

Functions

static bool be_io_cb (struct m0_clink *link)
 
static m0_bindex_t be_io_stob_offset_pack (m0_bindex_t offset, uint32_t bshift)
 
static m0_bcount_t be_io_size_pack (m0_bcount_t size, uint32_t bshift)
 
static m0_bcount_t be_io_size_unpack (m0_bcount_t size, uint32_t bshift)
 
static void be_io_free (struct m0_be_io *bio)
 
static void be_io_part_init (struct m0_be_io_part *bip, struct m0_be_io *bio)
 
static void be_io_part_fini (struct m0_be_io_part *bip)
 
static bool be_io_part_invariant (struct m0_be_io_part *bip)
 
static int be_io_part_launch (struct m0_be_io_part *bip)
 
static void be_io_part_reset (struct m0_be_io_part *bip)
 
static bool be_io_part_add (struct m0_be_io_part *bip, void *ptr_user, m0_bindex_t offset_stob, m0_bcount_t size)
 
M0_INTERNAL int m0_be_io_init (struct m0_be_io *bio)
 
M0_INTERNAL int m0_be_io_allocate (struct m0_be_io *bio, struct m0_be_io_credit *iocred)
 
M0_INTERNAL void m0_be_io_deallocate (struct m0_be_io *bio)
 
M0_INTERNAL void m0_be_io_fini (struct m0_be_io *bio)
 
M0_INTERNAL bool m0_be_io__invariant (struct m0_be_io *bio)
 
static void be_io_vec_cut (struct m0_be_io *bio, struct m0_be_io_part *bip)
 
M0_INTERNAL void m0_be_io_add (struct m0_be_io *bio, struct m0_stob *stob, void *ptr_user, m0_bindex_t offset_stob, m0_bcount_t size)
 
M0_INTERNAL void m0_be_io_add_nostob (struct m0_be_io *bio, void *ptr_user, m0_bindex_t offset_stob, m0_bcount_t size)
 
static void be_io_vec_fork (struct m0_be_io *bio, unsigned index)
 
static unsigned be_io_vec_index_by_ptr (struct m0_be_io *bio, m0_bindex_t *iv_ptr)
 
M0_INTERNAL void m0_be_io_stob_assign (struct m0_be_io *bio, struct m0_stob *stob, m0_bindex_t offset, m0_bcount_t size)
 
M0_INTERNAL void m0_be_io_stob_move (struct m0_be_io *bio, struct m0_stob *stob, m0_bindex_t offset, m0_bindex_t win_start, m0_bcount_t win_size)
 
M0_INTERNAL void m0_be_io_vec_pack (struct m0_be_io *bio)
 
M0_INTERNAL m0_bcount_t m0_be_io_size (struct m0_be_io *bio)
 
M0_INTERNAL void m0_be_io_configure (struct m0_be_io *bio, enum m0_stob_io_opcode opcode)
 
static void be_io_finished (struct m0_be_io *bio)
 
static void be_io_empty_ast (struct m0_sm_group *grp, struct m0_sm_ast *ast)
 
M0_INTERNAL void m0_be_io_launch (struct m0_be_io *bio, struct m0_be_op *op)
 
M0_INTERNAL void m0_be_io_sync_enable (struct m0_be_io *bio)
 
M0_INTERNAL bool m0_be_io_sync_is_enabled (struct m0_be_io *bio)
 
M0_INTERNAL enum m0_stob_io_opcode m0_be_io_opcode (struct m0_be_io *io)
 
M0_INTERNAL bool m0_be_io_is_empty (struct m0_be_io *bio)
 
M0_INTERNAL void m0_be_io_reset (struct m0_be_io *bio)
 
M0_INTERNAL void m0_be_io_sort (struct m0_be_io *bio)
 
M0_INTERNAL void m0_be_io_user_data_set (struct m0_be_io *bio, void *data)
 
M0_INTERNAL void * m0_be_io_user_data (struct m0_be_io *bio)
 
M0_INTERNAL int m0_be_io_single (struct m0_stob *stob, enum m0_stob_io_opcode opcode, void *ptr_user, m0_bindex_t offset_stob, m0_bcount_t size)
 
static bool be_io_part_intersect (const struct m0_be_io_part *bip1, const struct m0_be_io_part *bip2)
 
M0_INTERNAL bool m0_be_io_intersect (const struct m0_be_io *bio1, const struct m0_be_io *bio2)
 
M0_INTERNAL bool m0_be_io_ptr_user_is_eq (const struct m0_be_io *bio1, const struct m0_be_io *bio2)
 
M0_INTERNAL bool m0_be_io_offset_stob_is_eq (const struct m0_be_io *bio1, const struct m0_be_io *bio2)
 
M0_INTERNAL void m0_be_io_credit_add (struct m0_be_io_credit *iocred0, const struct m0_be_io_credit *iocred1)
 
M0_INTERNAL bool m0_be_io_credit_le (const struct m0_be_io_credit *iocred0, const struct m0_be_io_credit *iocred1)
 

Macro Definition Documentation

◆ EXT

#define EXT (   start,
  end 
)    (struct m0_ext){ .e_start = (start), .e_end = (end) }

◆ M0_TRACE_SUBSYSTEM

#define M0_TRACE_SUBSYSTEM   M0_TRACE_SUBSYS_BE

Definition at line 23 of file io.c.