Added state transition in gptimer_start/stop functions. So that it's not possible to make a stopped timer continue to run because of race condition.