sys/socket.h: reconcile bsd and osv variants

Some structures are duplicated; deduplicate them.

A few are source-compatible but not binary-compatible; use the ones from
<bits/socket.h>.

Others are both source- and binary- compatible; put them in a new header
<sys/__socket.h> which is included from both.

Work around a problem with the byteorder functions/macros.

Signed-off-by: Avi Kivity <avi@cloudius-systems.com>
Tested-By: Benoit Canet <benoit@irqsave.net>
netinet/in.h: reconcile osv and bsd headers

Some structures are duplicated; move the duplicates to a common header
<netinet/__in.h>.

Signed-off-by: Avi Kivity <avi@cloudius-systems.com>
Tested-By: Benoit Canet <benoit@irqsave.net>
arpa/inet.h: reconcile osv and bsd headers

Workaround a bytorder function conflict, and reconcile a declaration.

Signed-off-by: Avi Kivity <avi@cloudius-systems.com>
Tested-By: Benoit Canet <benoit@irqsave.net>
bsd: rename ifaddr

The bsd ifaddr struct conflicts with the osv ifaddr struct, which is a
public interface.  Rename the bsd struct to avoid conflict.

Signed-off-by: Avi Kivity <avi@cloudius-systems.com>
Tested-By: Benoit Canet <benoit@irqsave.net>
bsd: rename ifconf

bsd's ifconf conflicts with osv's; rename it.

We use the bsd version in <osv/ioctl.h>, since we currently don't support
the Linux-ABI variants of these ioctls.

Signed-off-by: Avi Kivity <avi@cloudius-systems.com>
Tested-By: Benoit Canet <benoit@irqsave.net>
bsd: rename osv ticks macro to bsd_ticks to avoid conflict with boost ticks usage

Signed-off-by: Benoit Canet <benoit@irqsave.net>
Signed-off-by: Avi Kivity <avi@cloudius-systems.com>
net/if.h: reconcile osv and bsd headers

Signed-off-by: Benoit Canet <benoit@irqsave.net>
Signed-off-by: Avi Kivity <avi@cloudius-systems.com>
sys/socket.h: rename bsd_sockaddr using functions into bsd_*

Signed-off-by: Benoit Canet <benoit@irqsave.net>
Signed-off-by: Avi Kivity <avi@cloudius-systems.com>