- 14 4月, 2017 1 次提交
-
-
由 Hans de Goede 提交于
On some systems (e.g. Intel Bay Trail systems) the legacy PIC is not used, in this case virq 8 will be a random irq, rather then hw_irq 8 from the PIC. Requesting virq 8 in this case will not help us to get alarm irqs and may cause problems for other drivers which actually do need virq 8, for example on an Asus Transformer T100TA this leads to: [ 28.745155] genirq: Flags mismatch irq 8. 00000088 (mmc0) vs. 00000080 (rtc0) <snip oops> [ 28.753700] mmc0: Failed to request IRQ 8: -16 [ 28.975934] sdhci-acpi: probe of 80860F14:01 failed with error -16 This commit fixes this by making the rtc-cmos driver continue without using an irq rather then claiming irq 8 when no irq is specified in the pnp-info and there are no legacy-irqs. Signed-off-by: NHans de Goede <hdegoede@redhat.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
- 04 4月, 2017 1 次提交
-
-
由 Chris Brandt 提交于
This same RTC is used in RZ/A series MPUs, therefore with some slight changes, this driver can be reused. Additionally, since ARM architectures require Device Tree configurations, device tree support has been added. Signed-off-by: NChris Brandt <chris.brandt@renesas.com> Reviewed-by: NGeert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
- 17 3月, 2017 2 次提交
-
-
由 Dan Carpenter 提交于
We shouldn't kfree(rtc) because is devm_ managed memory. It leads to a double free. Fixes: dd3bf50b ("rtc: cpcap: new rtc driver") Signed-off-by: NDan Carpenter <dan.carpenter@oracle.com> Acked-By: NSebastian Reichel <sre@kernel.org> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Nobuhiro Iwamatsu 提交于
The to_wm8350_from_rtc_dev macro is not used by anything in the rtc-wm8350 driver. Signed-off-by: NNobuhiro Iwamatsu <iwamatsu@nigauri.org> Acked-by: NCharles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
- 09 3月, 2017 16 次提交
-
-
由 Sebastian Reichel 提交于
This driver supports the Motorola CPCAP PMIC found on some of Motorola's mobile phones, such as the Droid 4. Tested-by: NTony Lindgren <tony@atomide.com> Signed-off-by: NSebastian Reichel <sre@kernel.org> Acked-by: NRob Herring <robh@kernel.org> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Dmitry Torokhov 提交于
Instead of using #ifdef guards around PM methods, let's annotate them as __maybe_unused, as it provides better compile coverage. Also drop empty stub for omap_rtc_runtime_resume(). Signed-off-by: NDmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Dmitry Torokhov 提交于
Even if bus is not hot-pluggable, devices can be unbound from the driver via sysfs, so we should not be using __exit annotations on remove() methods. The only exception is drivers registered with platform_driver_probe(), which specifically disables sysfs bind/unbind attributes. Signed-off-by: NDmitry Torokhov <dmitry.torokhov@gmail.com> Reviewed-By: NSebastian Reichel <sre@kernel.org> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Javier Martinez Canillas 提交于
The driver doesn't have a struct of_device_id table but supported devices are registered via Device Trees. This is working on the assumption that a I2C device registered via OF will always match a legacy I2C device ID and that the MODALIAS reported will always be of the form i2c:<device>. But this could change in the future so the correct approach is to have an OF device ID table if the devices are registered via OF. Signed-off-by: NJavier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Javier Martinez Canillas 提交于
The driver doesn't have a struct of_device_id table but supported devices are registered via Device Trees. This is working on the assumption that a I2C device registered via OF will always match a legacy I2C device ID and that the MODALIAS reported will always be of the form i2c:<device>. But this could change in the future so the correct approach is to have an OF device ID table if the devices are registered via OF. Signed-off-by: NJavier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Javier Martinez Canillas 提交于
The driver doesn't have a struct of_device_id table but supported devices are registered via Device Trees. This is working on the assumption that a I2C device registered via OF will always match a legacy I2C device ID and that the MODALIAS reported will always be of the form i2c:<device>. But this could change in the future so the correct approach is to have an OF device ID table if the devices are registered via OF. Signed-off-by: NJavier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Javier Martinez Canillas 提交于
The driver doesn't have a struct of_device_id table but supported devices are registered via Device Trees. This is working on the assumption that a I2C device registered via OF will always match a legacy I2C device ID and that the MODALIAS reported will always be of the form i2c:<device>. But this could change in the future so the correct approach is to have an OF device ID table if the devices are registered via OF. Signed-off-by: NJavier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Javier Martinez Canillas 提交于
The driver doesn't have a struct of_device_id table but supported devices are registered via Device Trees. This is working on the assumption that a I2C device registered via OF will always match a legacy I2C device ID and that the MODALIAS reported will always be of the form i2c:<device>. But this could change in the future so the correct approach is to have an OF device ID table if the devices are registered via OF. Signed-off-by: NJavier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Javier Martinez Canillas 提交于
The driver has a OF device ID table but the struct i2c_driver .of_match_table field is not set. Signed-off-by: NJavier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Javier Martinez Canillas 提交于
The driver doesn't have a struct of_device_id table but supported devices are registered via Device Trees. This is working on the assumption that a I2C device registered via OF will always match a legacy I2C device ID and that the MODALIAS reported will always be of the form i2c:<device>. But this could change in the future so the correct approach is to have an OF device ID table if the devices are registered via OF. Signed-off-by: NJavier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Javier Martinez Canillas 提交于
The driver doesn't have a struct of_device_id table but supported devices are registered via Device Trees. This is working on the assumption that a I2C device registered via OF will always match a legacy I2C device ID and that the MODALIAS reported will always be of the form i2c:<device>. But this could change in the future so the correct approach is to have an OF device ID table if the devices are registered via OF. Signed-off-by: NJavier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Javier Martinez Canillas 提交于
The driver doesn't have a struct of_device_id table but supported devices are registered via Device Trees. This is working on the assumption that a I2C device registered via OF will always match a legacy I2C device ID and that the MODALIAS reported will always be of the form i2c:<device>. But this could change in the future so the correct approach is to have an OF device ID table if the devices are registered via OF. Signed-off-by: NJavier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Javier Martinez Canillas 提交于
The driver doesn't have a struct of_device_id table but supported devices are registered via Device Trees. This is working on the assumption that a I2C device registered via OF will always match a legacy I2C device ID and that the MODALIAS reported will always be of the form i2c:<device>. But this could change in the future so the correct approach is to have an OF device ID table if the devices are registered via OF. Signed-off-by: NJavier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Javier Martinez Canillas 提交于
The driver doesn't have a struct of_device_id table but supported devices are registered via Device Trees. This is working on the assumption that a I2C device registered via OF will always match a legacy I2C device ID and that the MODALIAS reported will always be of the form i2c:<device>. But this could change in the future so the correct approach is to have an OF device ID table if the devices are registered via OF. Signed-off-by: NJavier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Javier Martinez Canillas 提交于
The driver doesn't have a struct of_device_id table but supported devices are registered via Device Trees. This is working on the assumption that a I2C device registered via OF will always match a legacy I2C device ID and that the MODALIAS reported will always be of the form i2c:<device>. But this could change in the future so the correct approach is to have an OF device ID table if the devices are registered via OF. Signed-off-by: NJavier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Javier Martinez Canillas 提交于
The driver doesn't have a struct of_device_id table but supported devices are registered via Device Trees. This is working on the assumption that a I2C device registered via OF will always match a legacy I2C device ID and that the MODALIAS reported will always be of the form i2c:<device>. But this could change in the future so the correct approach is to have an OF device ID table if the devices are registered via OF. Signed-off-by: NJavier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
- 02 3月, 2017 1 次提交
-
-
由 Ingo Molnar 提交于
sched/headers: Prepare to move signal wakeup & sigpending methods from <linux/sched.h> into <linux/sched/signal.h> Fix up affected files that include this signal functionality via sched.h. Acked-by: NLinus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-kernel@vger.kernel.org Signed-off-by: NIngo Molnar <mingo@kernel.org>
-
- 24 2月, 2017 2 次提交
-
-
由 Phil Reid 提交于
The wakealarm attribute is currently not exposed in the sysfs interface as the device has not been set as doing wakealarm when device_register is called. Changing the order of the calls fixes that problem. Interrupts are cleared in check_rtc_status prior to requesting the interrupt. This is only set if an irq is defined. If irq registration fails then set wakeup_capable to false. With this change the sysfs wakealarm attribute will be left visible but it is non functional. rtcwake still returns that the device is not enabled for wakeup. Signed-off-by: NPhil Reid <preid@electromag.com.au> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Sean Nyekjaer 提交于
Read control registers one by one and bulk read time registers. This fixes when the clock is read, the watchdog counter register is zeroed. Signed-off-by: NSean Nyekjaer <sean.nyekjaer@prevas.dk> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
- 22 2月, 2017 6 次提交
-
-
由 Gregory CLEMENT 提交于
The Armada 7K/8K use the same RTC IP than the Armada 38x. However the SOC integration differs in 2 points: - MBUS bridge timing initialization - IRQ configuration at SoC level Moreover the Armada 7K/8K have an issue preventing to get the interrupt from alarm 1. This commit allows to use alarm 2 for these A7K/8K but to still use alarm 1 for the Armada 38x. Signed-off-by: NGregory CLEMENT <gregory.clement@free-electrons.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Gregory CLEMENT 提交于
In order to prepare the introduction of the A7K/A8K version of the RTC, this commit introduces a new data structure. This structure allows to handle the differences between the integration of the RTC IP in the SoCs. It will be: - MBUS bridge timing initialization - IRQ configuration at SoC level Signed-off-by: NGregory CLEMENT <gregory.clement@free-electrons.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Phil Reid 提交于
Add the max_register to the regmap_config definition. This allows dumping of the device's registers via the regmap debugfs interface. Signed-off-by: NPhil Reid <preid@electromag.com.au> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Phil Reid 提交于
Whitespace was a combination of spaces and tabs. Use spaces and align register / bit definitions. Signed-off-by: NPhil Reid <preid@electromag.com.au> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 H Hartley Sweeten 提交于
All users of this driver have been updated to allow the driver to manage it's own resources and do the read/write operations internally. The m48t86_ops are no longer used. Remove the platform_data header and the support code in the driver. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 H Hartley Sweeten 提交于
The RTC is an optional feature at purchase time on some Technologic Systems boards. Verify that it actually exists by checking if the last two bytes of the NVRAM can be changed. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
- 12 2月, 2017 4 次提交
-
-
由 H Hartley Sweeten 提交于
This RTC has 114 bytes of NVRAM. Provide access to it via a binary sysfs 'nvram' attribute file. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 H Hartley Sweeten 提交于
Allow this driver to, optionally, manage it's own resources and do the read/write operations if the platform does not provide them. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 H Hartley Sweeten 提交于
For aesthetics. Shorten all the register names by removing '_REG' from all of them. This helps fix all the checkpatch.pl issues. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Wei Yongjun 提交于
In case of error, the function of_io_request_and_map() returns ERR_PTR() and never returns NULL. The NULL test in the return value check should be replaced with IS_ERR(). Fixes: 847b8bf62eb4 ("rtc: sun6i: Expose the 32kHz oscillator") Signed-off-by: NWei Yongjun <weiyongjun1@huawei.com> Acked-by: NMaxime Ripard <maxime.ripard@free-electrons.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
- 01 2月, 2017 7 次提交
-
-
由 Alexandre Belloni 提交于
COMPILE_TEST was wrongly placed, move it to the "depends on" line. Also depend on COMMON_CLK as the driver now needs it to be properly compiled. Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com> -
由 Chen-Yu Tsai 提交于
Commit 847b8bf62eb4 ("rtc: sun6i: Expose the 32kHz oscillator") adds a new clock for the rtc block with a 2 step probe mechanism. To share the register region between both the clock and rtc instance, a static pointer is used to keep the related data structure. To preserve compatibility with the old binding, the data structure should be saved as soon as the registers are mapped in, regardless of the presence of the clock bindings, so that the rtc device can retrieve it when it is probed. This fixes the rtc device not probing when we use the updated driver with an old device tree blob. Fixes: 847b8bf62eb4 ("rtc: sun6i: Expose the 32kHz oscillator") Signed-off-by: NChen-Yu Tsai <wens@csie.org> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com> -
由 Guy Shapiro 提交于
The clear of the LPTA_EN flag should be synced before writing to the alarm register. Omitting this synchronization creates a race when trying to change existing alarm. Signed-off-by: NGuy Shapiro <guy.shapiro@mobi-wize.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Enric Balletbo i Serra 提交于
The bq32000 includes a trickle charge circuit to maintain the charge of the backup supply when a super capacitor is used. You can enable the charging circuit by setting 'trickle-resistor-ohms', additionally you can set TCFE to 1 to bypass the internal diode and boost the charge voltage of the backup supply. You might want to enable/disable the TCFE switch from userspace (e.g when device is only connected to a battery) This patch introduces a new sysfs entry to enable and disable this FET form userspace. Signed-off-by: NEnric Balletbo i Serra <enric.balletbo@collabora.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Maxime Ripard 提交于
Now that we have a devm variant of rtc_device_register, switch to it. Signed-off-by: NMaxime Ripard <maxime.ripard@free-electrons.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Maxime Ripard 提交于
The RTC controls the input source of the main 32kHz oscillator in the system, feeding it to the clock unit too. By default, this is using an internal, very inaccurate (+/- 30%) oscillator with a divider to make it roughly around 32kHz. This is however quite impractical for the RTC, since our time will not be tracked properly. Since this oscillator is an input of the main clock unit, and since that clock unit will be probed using CLK_OF_DECLARE, we have to use it as well, leading to a two stage probe: one to enable the clock, the other one to enable the RTC. There is also a slight change in the binding that is required (and should have been from the beginning), since we'll need a phandle to the external oscillator used on that board. We support the old binding by not allowing to switch to the external oscillator and only using the internal one (which was the previous behaviour) in the case where we're missing that phandle. Signed-off-by: NMaxime Ripard <maxime.ripard@free-electrons.com> Acked-by: NRob Herring <robh@kernel.org> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-
由 Maxime Ripard 提交于
The RTC is clocked from either an internal, imprecise, oscillator or an external one, which is usually much more accurate. The difference perceived between the time elapsed and the time reported by the RTC is in a 10% scale, which prevents the RTC from being useful at all. Fortunately, the external oscillator is reported to be mandatory in the Allwinner datasheet, so we can just switch to it. Cc: stable@vger.kernel.org Fixes: 9765d2d9 ("rtc: sun6i: Add sun6i RTC driver") Signed-off-by: NMaxime Ripard <maxime.ripard@free-electrons.com> Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
-