RTEMS  5.1
Data Fields
POSIX_Shm_Object_operations Struct Reference

Operations on POSIX Shared Memory Objects. More...

#include <shm.h>

Data Fields

int(* object_create )(POSIX_Shm_Object *shm_obj, size_t size)
 Allocates a new shm_obj with initial size. More...
 
int(* object_resize )(POSIX_Shm_Object *shm_obj, size_t size)
 Changes the shm_obj size to size. More...
 
int(* object_delete )(POSIX_Shm_Object *shm_obj)
 Deletes the shm_obj. More...
 
int(* object_read )(POSIX_Shm_Object *shm_obj, void *buf, size_t count)
 Copies up to @count bytes of the shm_obj data into buf. More...
 
void *(* object_mmap )(POSIX_Shm_Object *shm_obj, size_t len, int prot, off_t off)
 Maps a shared memory object. More...
 

Detailed Description

Operations on POSIX Shared Memory Objects.

Field Documentation

◆ object_create

int( * POSIX_Shm_Object_operations::object_create) (POSIX_Shm_Object *shm_obj, size_t size)

Allocates a new shm_obj with initial size.

New shared memory is initialized to zeroes.

Returns 0 for success.

◆ object_delete

int( * POSIX_Shm_Object_operations::object_delete) (POSIX_Shm_Object *shm_obj)

Deletes the shm_obj.

Zeroes out the memory.

Returns 0 for success.

◆ object_mmap

void*( * POSIX_Shm_Object_operations::object_mmap) (POSIX_Shm_Object *shm_obj, size_t len, int prot, off_t off)

Maps a shared memory object.

Establishes a memory mapping between the shared memory object and the caller.

Returns the mapped address of the object.

◆ object_read

int( * POSIX_Shm_Object_operations::object_read) (POSIX_Shm_Object *shm_obj, void *buf, size_t count)

Copies up to @count bytes of the shm_obj data into buf.

Returns the number of bytes read (copied) into buf.

◆ object_resize

int( * POSIX_Shm_Object_operations::object_resize) (POSIX_Shm_Object *shm_obj, size_t size)

Changes the shm_obj size to size.

Zeroes out the portion of the shared memory object that shrinks or grows.

Returns 0 for success.


The documentation for this struct was generated from the following file: