summaryrefslogtreecommitdiffstats
path: root/drivers/rtc/rtc-st-lpc.c
Commit message (Collapse)AuthorAgeFilesLines
* treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 36Thomas Gleixner2019-05-241-5/+1
| | | | | | | | | | | | | | | | | | | | | | Based on 1 normalized pattern(s): this program is free software you can redistribute it and or modify it under the terms of the gnu general public licence as published by the free software foundation either version 2 of the licence or at your option any later version extracted by the scancode license scanner the SPDX license identifier GPL-2.0-or-later has been chosen to replace the boilerplate/reference in 114 file(s). Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Reviewed-by: Allison Randal <allison@lohutok.net> Reviewed-by: Kate Stewart <kstewart@linuxfoundation.org> Cc: linux-spdx@vger.kernel.org Link: https://lkml.kernel.org/r/20190520170857.552531963@linutronix.de Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* rtc: st-lpc: add rangeAlexandre Belloni2018-05-231-0/+2
| | | | | | | | The RTC has a 64 bit counter. Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Acked-by: Patrice Chotard <patrice.chotard@st.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
* rtc: st-lpc: fix possible race conditionAlexandre Belloni2018-05-231-15/+9
| | | | | | | | | | | | The IRQ is requested before the struct rtc is allocated and registered, but this struct is used in the IRQ handler. This may lead to a NULL pointer dereference. Switch to devm_rtc_allocate_device/rtc_register_device to allocate the rtc before requesting the IRQ. Acked-by: Patrice Chotard <patrice.chotard@st.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
* rtc: st-lpc: remove artificial limitationAlexandre Belloni2018-03-271-16/+0
| | | | | | | The LPC RTC supports dates way beyond 2038, don't limit it artificially as the kernel handles dates after 2038 properly. Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
* rtc: st-lpc: make it robust against y2038/2106 bugBenjamin Gaignard2017-07-091-11/+8
| | | | | | | | | Make driver use u64 variables and functions to be sure that it will support dates after year 2038. Signed-off-by: Benjamin Gaignard <benjamin.gaignard@linaro.org> Acked-by: Patrice Chotard <patrice.chotard@st.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com>
* rtc: st: Update IP layout information to include ClocksourceLee Jones2015-07-231-1/+1
| | | | | | | | | | Initial submission adding support for this IP only included Watchdog and the Real-Time Clock. Now the third (and final) device is enabled this trivial patch is required to update the comment in the RTC driver to encompass Clocksource. Acked-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by: Lee Jones <lee.jones@linaro.org>
* rtc: st: Add new driver for ST's LPC RTCLee Jones2015-04-301-0/+354
ST's Low Power Controller (LPC) controls two devices; watchdog and RTC. Only one of the devices can be used at any one time. This is enforced by the correlating MFD driver. This portion of the driver-set controls the Real Time Clock. Cc: Alessandro Zummo <a.zummo@towertech.it> Signed-off-by: Lee Jones <lee.jones@linaro.org>