s5j/timerisr: rework up_timerisr()
authorHeesub Shin <heesub.shin@samsung.com>
Tue, 21 Mar 2017 03:28:21 +0000 (12:28 +0900)
committerHeesub Shin <heesub.shin@samsung.com>
Mon, 17 Apr 2017 10:52:06 +0000 (19:52 +0900)
Resetting the timer before calling sched_process_timer() seems more
logical.

Change-Id: I3ea0e3475855d58147ed061a8d8693413ec7a86a
Signed-off-by: Heesub Shin <heesub.shin@samsung.com>
os/arch/arm/src/s5j/s5j_timerisr.c

index e436d6f..998837c 100644 (file)
  ****************************************************************************/
 int up_timerisr(int irq, uint32_t *regs)
 {
-       /* Process timer interrupt */
+       /* Reset timer */
+       s5j_mct_clear_pending(MCT_L0);
 
+       /* Process timer interrupt */
        sched_process_timer();
-       s5j_mct_clear_pending(MCT_L0);
 
        return 0;
 }