ringbuffer: add convenience functions
ringbuffer: remove pointer to the end

There is no need for an explicit pointer to the end of the buffer.
ringbuffer: don't overwrite in `ringbuffer_add`