[V1 3/3] RTC: sa1100: support sa1100, pxa and mmp soc families
Robert Jarzmik
robert.jarzmik at free.fr
Fri Nov 25 15:14:37 EST 2011
"Jett.Zhou" <jtzhou at marvell.com> writes:
> Since the regmap of rtc on sa1100, pxa and mmp Marvell soc families are
> almost the same, so re-arch the rtc-sa1100 to support them.
Hi Jett.Zhou,
That's a very good work.
...zip...
> static int sa1100_rtc_remove(struct platform_device *pdev)
> {
> - struct rtc_device *rtc = platform_get_drvdata(pdev);
> + struct sa1100_rtc *sa1100_rtc = platform_get_drvdata(pdev);
>
> - if (rtc)
> - rtc_device_unregister(rtc);
> + rtc_device_unregister(sa1100_rtc->rtc);
> + if (sa1100_rtc->id == RTC_MMP) {
> + clk_unprepare(sa1100_rtc->clk);
> + clk_disable(sa1100_rtc->clk);
> + }
>
> + spin_lock_irq(&sa1100_rtc->lock);
> + iounmap(sa1100_rtc->base);
> + spin_unlock_irq(&sa1100_rtc->lock);
Why the spin lock here ?
Cheers.
--
Robert
More information about the linux-arm-kernel
mailing list