arping: Use monotonic clock for timeouts

Currently arping uses gettimeofday() to check if its timeout parameter has
expired.  This can cause problems if the system time is adjusted backwards
with settimeofday() while arping is running, causing arping to freeze for
long periods of time.

This situation can occur when running arping for duplicate address
detection during network bringup at boot.  With modern parallel init script
setups, the arping could well run in parallel with hwclock operations which
could adjust the date backwards.  For some reason this seems to be
particularly common when running under VMware.

This patch switches arping to using clock_gettime(CLOCK_MONOTONIC) to avoid
this problem.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
arping: Clarify and correct interaction of -c and -w options

The man page is a little unclear, but it seems to say that when -w is not
used, -c causes arping to terminate after sending 'count' packets, but if
-w *is* specified then it terminates only after *receiving* 'count'
packets (or when the timeout expires).  That's not what the code actually
does, or ever did.

This patch clarifies the man page slightly, and corrects the code to
actually implement the descibed behaviour.  This has repeatedly been fixed
incorrectly in Red Hat's packages, causing other problems.  With any luck
this will finally fix it properly.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>