Create threads for each device & log device events.

Before creating multiple threads, all signals are blocked.
The main thread is used catch the signals in a synchronous manner.

The other threads log their respective device events as and
when they are received.