v4l2-compliance: detect no-mmu systems

Check if the OS has an MMU. If not, then skip tests that only work for
systems that have an MMU.

The safest and most generic method I found is the FIONBIO ioctl that is
available for any file descriptor and is a write-only ioctl, so no memory
will be accidentally written. On a MMU system this will return EFAULT, and
on a ucLinux system this will return 0.

Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
5 files changed