HAL creates shm after locking the softPLL
In case somebody configures GrandMaster mode without having 1-PPS and 10MHz reference connected, the HAL waits forever for the SoftPLL to be locked. This is good, but in this case HAL never creates its shm. In this case:
- there is no shm, so we don't have any information for remote diagnostics what's happening
- other processes wait for HAL to create its shm
- RTU quits when it does not see the shm from HAL and is restarted by monit
- monit is configured to restart the whole switch when it fails to run one of the processes several times (in this case, RTU)
We should move the creation of HAL shm before it locks the SoftPLL. Probably HAL should also export in its shm the information if SoftPLL is locked or not. PPSi should then be active only when HAL has created the shm and this shm says that SoftPLL is locked.
Having all this would also let us diagnose remotely situations when GrandMaster cannot lock to external reference.