Lely core libraries 2.3.4
|
The implementation of a CAN channel. More...
Data Fields | |
const struct io_dev_vtbl * | dev_vptr |
A pointer to the virtual table for the I/O device interface. | |
const struct io_can_chan_vtbl * | chan_vptr |
A pointer to the virtual table for the CAN channel interface. | |
io_poll_t * | poll |
A pointer to the polling instance used to watch for I/O events. More... | |
struct io_svc | svc |
The I/O service representing the channel. | |
io_ctx_t * | ctx |
A pointer to the I/O context with which the channel is registered. | |
ev_exec_t * | exec |
A pointer to the executor used to execute all I/O tasks. | |
struct io_poll_watch | watch |
The object used to monitor the file descriptor for I/O events. | |
struct ev_task | rxbuf_task |
The task responsible for filling the receive queue. | |
struct ev_task | read_task |
The task responsible for initiating read operations. | |
struct ev_task | write_task |
The task responsible for initiating write operations. | |
pthread_mutex_t | c_mtx |
The mutex protecting the receive queue consumer. | |
struct spscring | rxring |
The ring buffer used to control the receive queue. | |
struct io_can_frame * | rxbuf |
The receive queue. | |
pthread_mutex_t | mtx |
The mutex protecting the file descriptor, the flags and the queues of pending operations. | |
int | fd |
The SocketCAN file descriptor. | |
int | flags |
The flags with which fd has been opened. | |
int | events |
The I/O events currently being monitored by poll for fd. | |
unsigned | shutdown: 1 |
A flag indicating whether the I/O service has been shut down. | |
unsigned | rxbuf_posted: 1 |
A flag indicating whether rxbuf_task has been posted to exec. | |
unsigned | read_posted: 1 |
A flag indicating whether read_task has been posted to exec. | |
unsigned | write_posted: 1 |
A flag indicating whether write_task has been posted to exec. | |
struct sllist | read_queue |
The queue containing pending read operations. | |
struct sllist | write_queue |
The queue containing pending write operations. | |
struct sllist | confirm_queue |
The queue containing write operations waiting to be confirmed. | |
struct ev_task * | current_write |
The write operation currently being executed. | |
The implementation of a CAN channel.
Definition at line 133 of file can_chan.c.
io_poll_t* io_can_chan_impl::poll |
A pointer to the polling instance used to watch for I/O events.
If poll is NULL, operations are performed in blocking mode and the executor is used as a worker thread.
Definition at line 143 of file can_chan.c.