FD.io VPP  v21.06-3-gbb25fbf28
Vector Packet Processing
External region APIs
+ Collaboration diagram for External region APIs:


typedef uint32_t() memif_get_external_buffer_offset_t(void *private_ctx)
 Get external buffer offset (optional) More...
typedef int() memif_add_external_region_t(void **addr, uint32_t size, int *fd, void *private_ctx)
 Add external region. More...
typedef void *() memif_get_external_region_addr_t(uint32_t size, int fd, void *private_ctx)
 Get external region address. More...
typedef int() memif_del_external_region_t(void *addr, uint32_t size, int fd, void *private_ctx)
 Delete external region. More...


void memif_register_external_region (memif_add_external_region_t *ar, memif_get_external_region_addr_t *gr, memif_del_external_region_t *dr, memif_get_external_buffer_offset_t *go)
 Register external region. More...

Detailed Description

Typedef Documentation

◆ memif_add_external_region_t

typedef int() memif_add_external_region_t(void **addr, uint32_t size, int *fd, void *private_ctx)

#include <extras/libmemif/src/libmemif.h>

Add external region.

[out]addr- region address
size- requested region size
fd[out]- file descriptor
private_ctx- private context

Called by slave. Add external region created by client.

Definition at line 206 of file libmemif.h.

◆ memif_del_external_region_t

typedef int() memif_del_external_region_t(void *addr, uint32_t size, int fd, void *private_ctx)

#include <extras/libmemif/src/libmemif.h>

Delete external region.

addr- region address
size- region size
fd- file descriptor
private_ctx- private context

Delete external region.

Definition at line 229 of file libmemif.h.

◆ memif_get_external_buffer_offset_t

typedef uint32_t() memif_get_external_buffer_offset_t(void *private_ctx)

#include <extras/libmemif/src/libmemif.h>

Get external buffer offset (optional)

private_ctx- private context

Find unallocated external buffer and return its offset.

Definition at line 196 of file libmemif.h.

◆ memif_get_external_region_addr_t

typedef void*() memif_get_external_region_addr_t(uint32_t size, int fd, void *private_ctx)

#include <extras/libmemif/src/libmemif.h>

Get external region address.

size- requested region size
fd- file descriptor
private_ctx- private context

Called by master. Get region address from client.

region address

Definition at line 218 of file libmemif.h.

Function Documentation

◆ memif_register_external_region()

#include <extras/libmemif/src/libmemif.h>

Register external region.

ar- add external region callback
gr- get external region addr callback
dr- delete external region callback
go- get external buffer offset callback (optional)

Definition at line 431 of file main.c.

+ Here is the caller graph for this function: