NULLOP(9) Kernel Developer's Manual NULLOP(9)

nullopdummy functions

#include <sys/systm.h>

int
nullop(void *v);

void
voidop(void);

int
enodev(void);

int
enxio(void);

int
enoioctl(void);

int
enosys(void);

int
eopnotsupp(void);

The () function provides a generic “null operation”. It always returns the value 0. The () function takes no arguments and does nothing.

The (), (), (), (), and () functions always fail, returning ENODEV, ENXIO, ENOTTY, ENOSYS, and EOPNOTSUPP, respectively.

The following example demonstrates a case where nullop() may be useful:

uint64_t xc;

...

xc = xc_broadcast(0, (xcfunc_t)nullop, NULL, NULL);
xc_wait(xc);
July 25, 2010 NetBSD 11.0