Motr  M0
layout.h File Reference
#include "client.h"
#include "client_internal.h"
#include "lib/types.h"
Include dependency graph for layout.h:

Go to the source code of this file.

Data Structures

struct  m0_capture_layout
 
struct  m0_client_pdclust_layout
 
struct  m0_composite_extent
 
struct  m0_composite_layer
 
struct  m0_client_composite_layout
 
struct  m0_op_layout_ops
 
struct  m0_op_layout
 
struct  m0_op_composite_io
 

Macros

#define __MOTR_LAYOUT_H__
 
#define M0_OBJ_LAYOUT_ID(lid)   (lid & 0x0000ffffffffffff)
 
#define M0_OBJ_LAYOUT_TYPE(lid)   ((lid & 0xffff000000000000) >> 48UL)
 
#define M0_OBJ_LAYOUT_MAKE_LID(lid, type)   ((uint64_t)lid | ((uint64_t)type << 48UL))
 

Functions

M0_INTERNAL int m0_layout_op_launch (struct m0_op_layout *ol)
 
M0_INTERNAL int m0_client__layout_get (struct m0_client_layout *layout)
 
M0_INTERNAL void m0_client__layout_put (struct m0_client_layout *layout)
 
M0_INTERNAL int m0__composite_container_init (struct m0_client *cinst)
 
M0_INTERNAL int m0__obj_layout_send (struct m0_obj *obj, struct m0_op_layout *ol)
 
M0_INTERNAL int m0__dix_layout_get_sync (struct m0_obj *obj, struct m0_dix_layout *dlayout)
 
M0_INTERNAL struct m0_dix_client_dixc (const struct m0_entity *ent)
 
M0_INTERNAL struct m0_dix_cliol_dixc (const struct m0_op_layout *ol)
 

Variables

const struct m0_op_layout_ops m0_op_layout_composite_ops
 
const struct m0_client_layout_ops layout_composite_ops
 
struct m0_fid composite_extent_rd_idx_fid
 
struct m0_fid composite_extent_wr_idx_fid
 
const struct m0_bob_type ol_bobtype
 

Macro Definition Documentation

◆ __MOTR_LAYOUT_H__

#define __MOTR_LAYOUT_H__

Definition at line 26 of file layout.h.

◆ M0_OBJ_LAYOUT_ID

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

Client makes use of layout id attribute and stores the layout type in the highest 16 bits of layout id.

Definition at line 107 of file layout.h.

◆ M0_OBJ_LAYOUT_MAKE_LID

#define M0_OBJ_LAYOUT_MAKE_LID (   lid,
  type 
)    ((uint64_t)lid | ((uint64_t)type << 48UL))

Definition at line 109 of file layout.h.

◆ M0_OBJ_LAYOUT_TYPE

#define M0_OBJ_LAYOUT_TYPE (   lid)    ((lid & 0xffff000000000000) >> 48UL)

Definition at line 108 of file layout.h.

Function Documentation

◆ m0__composite_container_init()

M0_INTERNAL int m0__composite_container_init ( struct m0_client cinst)

Definition at line 1330 of file composite_layout.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ m0__dix_layout_get_sync()

M0_INTERNAL int m0__dix_layout_get_sync ( struct m0_obj obj,
struct m0_dix_layout dlayout 
)

Definition at line 328 of file composite_layout.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ m0__obj_layout_send()

M0_INTERNAL int m0__obj_layout_send ( struct m0_obj obj,
struct m0_op_layout ol 
)

Definition at line 2043 of file cob.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ m0_client__layout_get()

M0_INTERNAL int m0_client__layout_get ( struct m0_client_layout layout)

-------------------------------------------------------------------------—*

Client LAYOUT APIS *

Definition at line 276 of file layout.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ m0_client__layout_put()

M0_INTERNAL void m0_client__layout_put ( struct m0_client_layout layout)

Definition at line 288 of file layout.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ m0_layout_op_launch()

M0_INTERNAL int m0_layout_op_launch ( struct m0_op_layout ol)

Definition at line 297 of file composite_layout.c.

Here is the call graph for this function:

Variable Documentation

◆ composite_extent_rd_idx_fid

struct m0_fid composite_extent_rd_idx_fid

---------------------------------------------------------------------——*

Client Composite Layout Extent Index API and routines *

2 global extent indices are created for composite objects' extents: one is for read extents and another is for write extents. Client uses two reserved FIDs for these 2 global extent indices. The format for key/value pairs is defined as: key = {layer_id, extent offset} and value = extent length To ensure that the key/value pairs are stored in key's lexicographical, order (so that extents for a layer is stored in increasing offset order), client transforms the keys input by the application in big-endian format.

To create these internal extent indices, client also has to maintain an container for it.

Definition at line 1225 of file composite_layout.c.

◆ composite_extent_wr_idx_fid

struct m0_fid composite_extent_wr_idx_fid

Definition at line 1226 of file composite_layout.c.

◆ layout_composite_ops

const struct m0_client_layout_ops layout_composite_ops

Definition at line 528 of file composite_layout.c.

◆ m0_op_layout_composite_ops

const struct m0_op_layout_ops m0_op_layout_composite_ops

Definition at line 447 of file composite_layout.c.

◆ ol_bobtype

const struct m0_bob_type ol_bobtype

Definition at line 37 of file layout.c.