Motr  M0
io_foms.c File Reference
#include "lib/trace.h"
#include "lib/errno.h"
#include "lib/memory.h"
#include "lib/tlist.h"
#include "lib/assert.h"
#include "lib/misc.h"
#include "lib/finject.h"
#include "lib/cksum_utils.h"
#include "net/net_internal.h"
#include "net/buffer_pool.h"
#include "fop/fop.h"
#include "fop/fom_generic.h"
#include "stob/stob.h"
#include "stob/type.h"
#include "stob/domain.h"
#include "fid/fid.h"
#include "reqh/reqh_service.h"
#include "ioservice/io_foms.h"
#include "ioservice/io_service.h"
#include "ioservice/cob_foms.h"
#include "ioservice/storage_dev.h"
#include "cob/cob.h"
#include "motr/magic.h"
#include "motr/setup.h"
#include "pool/pool.h"
#include "ioservice/io_addb2.h"
#include "sns/cm/cm.h"
#include "ioservice/fid_convert.h"
#include "balloc/balloc.h"
#include "stob/addb2.h"
#include "layout/layout.h"
Include dependency graph for io_foms.c:

Go to the source code of this file.

Macros

#define M0_TRACE_SUBSYSTEM   M0_TRACE_SUBSYS_IOSERVICE
 
#define M0_OBJ_LAYOUT_ID(lid)   (lid & 0x0000ffffffffffff)
 

Enumerations

enum  { IO_FOM_STOB_KEY_MAX = 0x10000000ULL }
 

Functions

 M0_TL_DESCR_DEFINE (stobio, "STOB I/O", static, struct m0_stob_io_desc, siod_linkage, siod_magic, M0_STOB_IO_DESC_LINK_MAGIC, M0_STOB_IO_DESC_HEAD_MAGIC)
 
 M0_TL_DEFINE (stobio, static, struct m0_stob_io_desc)
 
 M0_TL_DESCR_DEFINE (netbufs, "Aquired net buffers", static, struct m0_net_buffer, nb_extern_linkage, nb_magic, M0_NET_BUFFER_LINK_MAGIC, M0_IOS_NET_BUFFER_HEAD_MAGIC)
 
 M0_TL_DEFINE (netbufs, static, struct m0_net_buffer)
 
 M0_TL_DESCR_DEFINE (rpcbulkbufs, "rpc bulk buffers", static, struct m0_rpc_bulk_buf, bb_link, bb_magic, M0_RPC_BULK_BUF_MAGIC, M0_RPC_BULK_MAGIC)
 
 M0_TL_DEFINE (rpcbulkbufs, static, struct m0_rpc_bulk_buf)
 
 M0_TL_DESCR_DECLARE (bufferpools, M0_EXTERN)
 
 M0_TL_DECLARE (bufferpools, M0_EXTERN, struct m0_rios_buffer_pool)
 
M0_INTERNAL bool m0_is_read_fop (const struct m0_fop *fop)
 
M0_INTERNAL bool m0_is_write_fop (const struct m0_fop *fop)
 
M0_INTERNAL bool m0_is_io_fop (const struct m0_fop *fop)
 
M0_INTERNAL struct m0_fop_cob_rwio_rw_get (struct m0_fop *fop)
 
M0_INTERNAL struct m0_fop_cob_rw_replyio_rw_rep_get (struct m0_fop *fop)
 
M0_INTERNAL bool m0_is_cob_create_fop (const struct m0_fop *fop)
 
M0_INTERNAL bool m0_is_cob_delete_fop (const struct m0_fop *fop)
 
static int m0_io_fom_cob_rw_create (struct m0_fop *fop, struct m0_fom **out, struct m0_reqh *reqh)
 
static int m0_io_fom_cob_rw_tick (struct m0_fom *fom)
 
static void m0_io_fom_cob_rw_fini (struct m0_fom *fom)
 
static size_t m0_io_fom_cob_rw_locality_get (const struct m0_fom *fom)
 
M0_INTERNAL const char * m0_io_fom_cob_rw_service_name (struct m0_fom *fom)
 
static bool m0_io_fom_cob_rw_invariant (const struct m0_io_fom_cob_rw *io)
 
static int net_buffer_acquire (struct m0_fom *)
 
static int io_prepare (struct m0_fom *)
 
static int io_launch (struct m0_fom *)
 
static int io_finish (struct m0_fom *)
 
static int io_sync (struct m0_fom *fom)
 
static int zero_copy_initiate (struct m0_fom *)
 
static int zero_copy_finish (struct m0_fom *)
 
static int net_buffer_release (struct m0_fom *)
 
static int nbuf_release_done (struct m0_fom *fom, int still_required)
 
static int cob_bytecount_increment (struct m0_cob *cob, struct m0_cob_bckey *key, uint64_t bytecount, struct m0_be_tx *tx)
 
static void io_fom_addb2_descr (struct m0_fom *fom)
 
static bool m0_stob_io_desc_invariant (const struct m0_stob_io_desc *stobio_desc)
 
static void stobio_complete_cb (struct m0_fom_callback *cb)
 
M0_INTERNAL int m0_io_cob_create (struct m0_cob_domain *cdom, struct m0_fid *fid, struct m0_fid *pver, uint64_t lid, struct m0_be_tx *tx)
 
static struct m0_cob_domainfom_cdom (struct m0_fom *fom)
 
M0_INTERNAL int m0_io_cob_stob_create (struct m0_fom *fom, struct m0_cob_domain *cdom, struct m0_fid *fid, struct m0_fid *pver, uint64_t lid, bool crow, struct m0_cob **out)
 
static int io_fom_cob2file (struct m0_fom *fom, struct m0_fid *fid, struct m0_file **out)
 
static int align_bufvec (struct m0_fom *fom, struct m0_bufvec *obuf, struct m0_bufvec *ibuf, m0_bcount_t ivec_count, uint32_t bshift)
 
static int fom_cob_locate (struct m0_fom *fom)
 
static int stob_object_find (struct m0_fom *fom)
 
static void stio_desc_fini (struct m0_stob_io_desc *stio_desc)
 
M0_INTERNAL uint64_t m0_io_size (struct m0_stob_io *sio, uint32_t bshift)
 
static int indexvec_wire2mem (struct m0_fom *fom)
 
static int stob_io_create (struct m0_fom *fom)
 
static void stob_io_destroy (struct m0_fom *fom)
 
static void stob_be_credit (struct m0_fom *fom)
 

Variables

struct m0_fom_ops ops
 
const struct m0_fom_type_ops io_fom_type_ops
 
static struct m0_io_fom_cob_rw_state_transition io_fom_read_st []
 
static const struct m0_io_fom_cob_rw_state_transition io_fom_write_st []
 
struct m0_sm_state_descr io_phases []
 
struct m0_sm_trans_descr io_phases_trans []
 
struct m0_sm_conf io_conf
 

Macro Definition Documentation

◆ M0_OBJ_LAYOUT_ID

#define M0_OBJ_LAYOUT_ID (   lid)    (lid & 0x0000ffffffffffff)

Definition at line 566 of file io_foms.c.

◆ M0_TRACE_SUBSYSTEM

#define M0_TRACE_SUBSYSTEM   M0_TRACE_SUBSYS_IOSERVICE

Definition at line 22 of file io_foms.c.