Ignore:
Timestamp:
Oct 10, 2020, 5:27:12 PM (4 years ago)
Author:
alain
Message:

Cosmetic.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/kernel/libk/remote_buf.h

    r657 r666  
    3232 * This structure and the associated access functions define a remotely accessible,
    3333 * kernel buffer, handled as a single-reader & single-writer FIFO.
    34  * Each buffer slot contains one byte, and the number of slots is dynamically
    35  * defined by an argument of the "remote_buf_create()" function.
    36  * The "put()" and "get()" access functions defined below move another buffer,
    37  * (can be in kernel or in user space) to/from this circular kernel buffer.
     34 * This kernel buffer is implementes as an array of bytes, whose size is
     35 * dynamically defined by an argument of the "remote_buf_init()" function.
     36 * The "put()" and "get()" functions defined below move the content of another
     37 * buffer (can be in kernel or in user space) to/from this circular kernel buffer.
    3838 * This structure is NOT protected by a lock, as the only shared variable is the
    39  * "sts" variable, that is updated by hal_remote_atomic_add() access primitives.
    40  * It is used by to implement the socket receive buffer.
     39 * "sts" variable, that is updated by the hal_remote_atomic_add() primitive.
     40 * It is used to implement the three socket buffers (rx_buf / r2tq / crqq).
    4141 * - the "ptw" field defines the first empty slot (for write).
    4242 * - the "ptr" field defines the first non empty slot (for read).
     
    5858 * argument. It allocates memory for the data, as defined by the <size> argument,
    5959 * and initializes the buffer as empty. It must be called by a local thread.
     60 * No memory is allocated if <size> value is 0.
    6061 ************************************************************************************
    6162 * @ buf_xp    : [in] extended pointer on buffer descriptor.
    62  * @ size      : [in] number of bytes in buffer.
    63  * @ return  0 if success / return -1 if failure (no memory).
     63 * @ size      : [in] number of bytes in buffer / no memory allocated when null.
     64 * @ return  0 if success / return -1 if memory failure.
    6465 ***********************************************************************************/
    65 error_t remote_buf_create( xptr_t   buf_xp,
    66                            uint32_t size );
     66error_t remote_buf_init( xptr_t   buf_xp,
     67                         uint32_t size );
    6768
    6869/************************************************************************************
Note: See TracChangeset for help on using the changeset viewer.