lib/counter: add some docunits

Signed-off-by: Jean Privat <jean@pryen.org>