/* Tail memsets can be optimized away by compilers. To sidestep this problem, we cast the pointer to volatile and then operate on it.  */
static void osdp_memzero(void *mem, size_t size)
/* Tail memsets can be optimized away by compilers. To sidestep this problem, we cast the pointer to volatile and then operate on it.  */
static void osdp_memzero(void *mem, size_t size)
{
	size_t i;
	volatile uint8_t *p = mem;
	for (i = 0; i < size; i++) {
		p[i] = 0;
	}
}