diff options
author | Wolfram Sang <w.sang@pengutronix.de> | 2011-05-25 12:56:51 +0200 |
---|---|---|
committer | John Stultz <john.stultz@linaro.org> | 2011-07-01 18:09:55 -0700 |
commit | a91d2bab355f3a5caa767d7316f80422bfcd2ad6 (patch) | |
tree | d195bca36a8b606c58280011ef06cd6c5ec616bc /kernel | |
parent | 46b21218145ecef0936eb4338a9e0ffef84f00cf (diff) | |
download | op-kernel-dev-a91d2bab355f3a5caa767d7316f80422bfcd2ad6.zip op-kernel-dev-a91d2bab355f3a5caa767d7316f80422bfcd2ad6.tar.gz |
rtc: stmp3xxx: Initialize drvdata before registering device
Commit f44f7f96a20 ("RTC: Initialize kernel state from RTC") uncovered
an issue in a number of RTC drivers, where the drivers call
rtc_device_register before initializing the device or platform drvdata.
This frequently results in null pointer dereferences when the
rtc_device_register immediately makes use of the rtc device, calling
rtc_read_alarm.
The solution is to ensure the drvdata is initialized prior to registering
the rtc device.
Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>
Tested-by: Shawn Guo <shawn.guo@freescale.com>
Signed-off-by: John Stultz <john.stultz@linaro.org>
Diffstat (limited to 'kernel')
0 files changed, 0 insertions, 0 deletions