Zephyr API Documentation  2.7.0-rc2
A Scalable Open Source RTOS
ring_buf Struct Reference

A structure to represent a ring buffer. More...

#include <ring_buffer.h>

Data Structures

union  ring_buf_buffer
 
union  ring_buf_misc
 

Data Fields

uint32_t head
 
uint32_t tail
 
union ring_buf::ring_buf_misc misc
 
uint32_t size
 
union ring_buf::ring_buf_buffer buf
 
uint32_t mask
 
struct k_spinlock lock
 

Detailed Description

A structure to represent a ring buffer.

Field Documentation

◆ buf

union ring_buf::ring_buf_buffer ring_buf::buf

◆ head

uint32_t ring_buf::head

Index in buf for the head element

◆ lock

struct k_spinlock ring_buf::lock

◆ mask

uint32_t ring_buf::mask

Modulo mask if size is a power of 2

◆ misc

union ring_buf::ring_buf_misc ring_buf::misc

◆ size

uint32_t ring_buf::size

Size of buf in 32-bit chunks

◆ tail

uint32_t ring_buf::tail

Index in buf for the tail element


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