]> git.baikalelectronics.ru Git - kernel.git/commit
rtc-ds1553: fix races around device registration
authorAtsushi Nemoto <anemo@mba.ocn.ne.jp>
Wed, 16 Dec 2009 00:46:01 +0000 (16:46 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Wed, 16 Dec 2009 15:19:59 +0000 (07:19 -0800)
commit872b4e91294c1508664a18e3383e2fcee9e82c28
treea5c9c77aa4359d023f3c4cd3ebdc2c7b5cc3bf8b
parent91e6ee2e93f88afe95791e4646966a9037852c2c
rtc-ds1553: fix races around device registration

* Call dev_set_drvdata before rtc device creation
* Use its own spinlock instead of rtc->irq_lock
* Check pdata->rtc before calling rtc_update_irq
* Use {alarm,update}_irq_enable and remove ioctl routine
* Use devres APIs and simplify error/remove path

Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Acked-by: Alessandro Zummo <a.zummo@towertech.it>
Cc: David Brownell <david-b@pacbell.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/rtc/rtc-ds1553.c