RTEMS | Draft: cpukit: add support for common CAN/CAN FD stack (!49)

Pavel Pisa (@ppisa) gitlab at rtems.org
Fri Jun 28 11:55:15 UTC 2024




Pavel Pisa commented on a discussion on cpukit/dev/can/can-queue.c: https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/49#note_108458

 > + *
 > + * @param fifo     Pointer to the FIFO structure.
 > + *
 > + * @return The nonzero value indicates that queue has not been
 > + * empty before the function call.
 > + *
 > + */
 > +int canque_fifo_flush_slots( struct canque_fifo_t *fifo )
 > +{
 > +  struct canque_slot_t *slot;
 > +  int ret = 0;
 > +
 > +  rtems_mutex_lock( &fifo->fifo_lock );
 > +  slot = fifo->head;
 > +  if ( slot ) {
 > +    *fifo->tail = fifo->flist;

flist is documented as This member holds the pointer to list of the free slots associated with queue

The name can be more descriptive (free_list or head_of_free_list) but it is internal to low level FIFO implementation and should not be used directly by code outside of this low level.

-- 
View it on GitLab: https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/49#note_108458
You're receiving this email because of your account on gitlab.rtems.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/bugs/attachments/20240628/79515cea/attachment-0001.htm>


More information about the bugs mailing list