rtc: mc13xxx: request IRQs after RTC registration
authorAlexander Shiyan <shc_work@mail.ru>
Thu, 3 Apr 2014 21:49:57 +0000 (14:49 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Thu, 3 Apr 2014 23:21:20 +0000 (16:21 -0700)
commit589e501439f9866b4bc415743b0ae0bb9a461c69
treeaa56c1a2b0fbc1528497d4d08e1aedd52667a92a
parent77bf2ea8de78ce7dd842409a847b888e720f62d8
rtc: mc13xxx: request IRQs after RTC registration

Interrupts can appear after request_irq and interrupt handlers can use
the RTC device, but currently we register RTC after IRQs.  This patch
changes this order and simplify error path a bit.

Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
Cc: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Cc: Sascha Hauer <kernel@pengutronix.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/rtc/rtc-mc13xxx.c