[statefs] Initial implementation of back cover handling

This is a back cover state detector using the TOH evdev device.
Added Jolla copyright
Avoid race condition with thread access to m_fd
Take care to close the directory if we get an exception from std::stringstream
algorithm is not used for anything so no need to include it
Remove the call to pthread_kill(). It doesn't make much sense.
Use C++ thread and mutex instead of the C equivalents

The only issue is the usage of pthread_cancel() since there is no C++ equivalent
Use std::lock_guard instead of locking and unlocking the mutex in our read call
Merge pull request #11 from foolab/master

back cover state provider