[PATCH] Add getnstimestamp function