Use bitmask for bonded

Also move bitmask to utility and f_thread_t to forcerec-threading.h.
This introduces a cycle because listed-forces now depends on
mdlib/forcerec-threading.h. There is not yet a module where
forcerec-threading.h can go.

Change-Id: Ic220be2880f7263aa0e50b13f07ed509eb86e1b3