5042 stop using deprecated atomic functions