MIPS: Initialize an atomic_t properly with ATOMIC_INIT(0).
PATCH 1/1 MIPS: Initialize an atomic_t properly with ATOMIC_INIT(0).
Signed-off-by Robert P. J. Day <[email protected]>
---
AFAIK, the technically correct way to initialize atomic variables is
with ATOMIC_INIT(n).
arch/mips/kernel/smtc.c +1 -1
@@ -181,7 +181,7 @@ static int vpemask[2][8] = { {0, 0, 0, 0, 0, 0, 0, 1} };int tcnoprog[NR_CPUS ]; -static atomic_t idle_hook_initialized = {0 }; +static atomic_t idle_hook_initialized =ATOMIC_INIT (0 );static int clock_hang_reported[NR_CPUS ];#endif /* CONFIG_SMTC_IDLE_HOOK_DEBUG */
========================================================================
Robert P. J. Day Waterloo, Ontario, CANADA
Linux Consulting, Training and Kernel Pedantry.
Web page: http://crashcourse.ca Twitter: http://twitter.com/rpjday
========================================================================
Quoted 2 lines · Robert P. J. Day
AFAIK, the technically correct way to initialize atomic variables is
withATOMIC_INIT(n).
Indeed, applied.
Thanks!
Ralf