core.c: Add timer mechanism for processing orphan nodes

On each subnet up event, in the case of a non-empty distribution
tree orphan list, a timer is now turned on, and every second
the orphan list is processed and adoption attempted. When the
orphan list no longer contains any nodes, the timer is
shut off.

Signed-off-by: Ilya Nelkenbaum <ilyan@mellanox.com>
Signed-off-by: Hal Rosenstock <hal@mellanox.com>
core.c: Change timeout variables from 'int' to 'time_t' type

Signed-off-by: Ilya Nelkenbaum <ilyan@mellanox.com>
Signed-off-by: Hal Rosenstock <hal@mellanox.com>