IIOD: Reuse the server socket if possible

This avoids the "bind failed: address already in use" errors.

Signed-off-by: Paul Cercueil <paul.cercueil@analog.com>
Local backend: Enable/disable buffer mode when opening/closing device

Also, return -EBUSY instead of -EAGAIN if the dev node has already
been opened.

Signed-off-by: Paul Cercueil <paul.cercueil@analog.com>
Local backend: Drop libsysfs

The problem is that libsysfs does not provide any function to read
files stored in sub-directories of a device directory.

For instance, it is not possible to read the content of
/sys/bus/iio/devices/iio:device0/scan_elements or the files it
contains.

Signed-off-by: Paul Cercueil <paul.cercueil@analog.com>
Local backend: Load channels from scan_elements

Signed-off-by: Paul Cercueil <paul.cercueil@analog.com>
Local backend: Properly detect "timestamp" as a channel

Signed-off-by: Paul Cercueil <paul.cercueil@analog.com>