Hi,
I noticed while using ck_ring_enqueue_mpsc() that it behaves a little differently than the other ck_ring_enqueue_* WRT the entry parameter. When ck_ring_enqueue_mpsc calls the static function _ck_ring_enqueue_mp(), it passes entry as is:
ck_ring_enqueue_mpsc(struct ck_ring *ring,
struct ck_ring_buffer *buffer,
const void *entry)
{
return _ck_ring_enqueue_mp(ring, buffer, entry,
sizeof(entry), NULL);
}
This differs from the way that ck_ring_enqueue_mpmc() calls the static function. Note how it passes entry.
ck_ring_enqueue_mpmc(struct ck_ring *ring,
struct ck_ring_buffer *buffer,
const void *entry)
{
return _ck_ring_enqueue_mp(ring, buffer, &entry,
sizeof(entry), NULL);
}
The second syntax matches how the rest of the static _ck_ring_enqueue_* functions are called by the other public enqueue APIs. They all pass
&entry. Could you take a look?
Thanks!
Darryl