timespec.tv_nsec is long, so use %ld instead of %jd as printf format.
Provide __sync_and_and_fetch_2 and __sync_and_and_fetch_1 for pre-ARMv6,
they are needed for the C++ 2011 <atomic> stuff.
Add MAC config register bit definitions
When link status changes, update MAC configuration accordingly.
Add C++ 2011 <atomic> support functions.