<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/drivers/clocksource/bcm2835_timer.c, branch v6.18.21</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v6.18.21</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v6.18.21'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2023-08-28T18:30:57+00:00</updated>
<entry>
<title>clocksource: Explicitly include correct DT includes</title>
<updated>2023-08-28T18:30:57+00:00</updated>
<author>
<name>Rob Herring</name>
<email>robh@kernel.org</email>
</author>
<published>2023-07-14T17:44:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=6303d0693f7d6c44bb6eb0b29c906ee28156dd28'/>
<id>urn:sha1:6303d0693f7d6c44bb6eb0b29c906ee28156dd28</id>
<content type='text'>
The DT of_device.h and of_platform.h date back to the separate
of_platform_bus_type before it was merged into the regular platform bus.
As part of that merge prepping Arm DT support 13 years ago, they
"temporarily" include each other. They also include platform_device.h
and of.h. As a result, there's a pretty much random mix of those include
files used throughout the tree. In order to detangle these headers and
replace the implicit includes with struct declarations, users need to
explicitly include the correct includes.

Link: https://lore.kernel.org/r/20230714174409.4053843-1-robh@kernel.org
Signed-off-by: Rob Herring &lt;robh@kernel.org&gt;
</content>
</entry>
<entry>
<title>clocksource: Replace setup_irq() by request_irq()</title>
<updated>2020-02-27T11:15:24+00:00</updated>
<author>
<name>afzal mohammed</name>
<email>afzal.mohd.ma@gmail.com</email>
</author>
<published>2020-02-27T10:59:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=cc2550b421aa30e3da67e5a7f6d14f3ecd3527b3'/>
<id>urn:sha1:cc2550b421aa30e3da67e5a7f6d14f3ecd3527b3</id>
<content type='text'>
request_irq() is preferred over setup_irq(). The early boot setup_irq()
invocations happen either via 'init_IRQ()' or 'time_init()', while
memory allocators are ready by 'mm_init()'.

Per tglx[1], setup_irq() existed in olden days when allocators were not
ready by the time early interrupts were initialized.

Hence replace setup_irq() by request_irq().

Seldom remove_irq() usage has been observed coupled with setup_irq(),
wherever that has been found, it too has been replaced by free_irq().

A build error that was reported by kbuild test robot &lt;lkp@intel.com&gt;
in the previous version of the patch also has been fixed.

[1] https://lkml.kernel.org/r/alpine.DEB.2.20.1710191609480.1971@nanos

Signed-off-by: afzal mohammed &lt;afzal.mohd.ma@gmail.com&gt;
Signed-off-by: Daniel Lezcano &lt;daniel.lezcano@linaro.org&gt;
Link: https://lore.kernel.org/r/91961c77c1cf93d41523f5e1ac52043f32f97077.1582799709.git.afzal.mohd.ma@gmail.com
</content>
</entry>
<entry>
<title>clocksource/drivers/bcm2835_timer: Fix memory leak of timer</title>
<updated>2020-01-16T18:06:57+00:00</updated>
<author>
<name>Colin Ian King</name>
<email>colin.king@canonical.com</email>
</author>
<published>2019-12-19T21:32:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=2052d032c06761330bca4944bb7858b00960e868'/>
<id>urn:sha1:2052d032c06761330bca4944bb7858b00960e868</id>
<content type='text'>
Currently when setup_irq fails the error exit path will leak the
recently allocated timer structure.  Originally the code would
throw a panic but a later commit changed the behaviour to return
via the err_iounmap path and hence we now have a memory leak. Fix
this by adding a err_timer_free error path that kfree's timer.

Addresses-Coverity: ("Resource Leak")
Fixes: 524a7f08983d ("clocksource/drivers/bcm2835_timer: Convert init function to return error")
Signed-off-by: Colin Ian King &lt;colin.king@canonical.com&gt;
Signed-off-by: Daniel Lezcano &lt;daniel.lezcano@linaro.org&gt;
Link: https://lore.kernel.org/r/20191219213246.34437-1-colin.king@canonical.com
</content>
</entry>
<entry>
<title>clocksource/drivers/bcm2835: Switch to SPDX identifier</title>
<updated>2018-12-18T21:22:23+00:00</updated>
<author>
<name>Stefan Wahren</name>
<email>stefan.wahren@i2se.com</email>
</author>
<published>2018-11-10T15:28:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=64db8bb157cb8108ae017f00c2d47f03d4ebe8a6'/>
<id>urn:sha1:64db8bb157cb8108ae017f00c2d47f03d4ebe8a6</id>
<content type='text'>
Adopt the SPDX license identifier headers to ease license compliance
management. Also drop the FSF address.

Cc: Simon Arlott &lt;simon@arlott.org&gt;
Signed-off-by: Stefan Wahren &lt;stefan.wahren@i2se.com&gt;
Reviewed-by: Eric Anholt &lt;eric@anholt.net&gt;
Acked-by: Daniel Lezcano &lt;daniel.lezcano@linaro.org&gt;
Signed-off-by: Daniel Lezcano &lt;daniel.lezcano@linaro.org&gt;
</content>
</entry>
<entry>
<title>locking/atomics: COCCINELLE/treewide: Convert trivial ACCESS_ONCE() patterns to READ_ONCE()/WRITE_ONCE()</title>
<updated>2017-10-25T09:01:08+00:00</updated>
<author>
<name>Mark Rutland</name>
<email>mark.rutland@arm.com</email>
</author>
<published>2017-10-23T21:07:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=6aa7de059173a986114ac43b8f50b297a86f09a8'/>
<id>urn:sha1:6aa7de059173a986114ac43b8f50b297a86f09a8</id>
<content type='text'>
Please do not apply this to mainline directly, instead please re-run the
coccinelle script shown below and apply its output.

For several reasons, it is desirable to use {READ,WRITE}_ONCE() in
preference to ACCESS_ONCE(), and new code is expected to use one of the
former. So far, there's been no reason to change most existing uses of
ACCESS_ONCE(), as these aren't harmful, and changing them results in
churn.

However, for some features, the read/write distinction is critical to
correct operation. To distinguish these cases, separate read/write
accessors must be used. This patch migrates (most) remaining
ACCESS_ONCE() instances to {READ,WRITE}_ONCE(), using the following
coccinelle script:

----
// Convert trivial ACCESS_ONCE() uses to equivalent READ_ONCE() and
// WRITE_ONCE()

// $ make coccicheck COCCI=/home/mark/once.cocci SPFLAGS="--include-headers" MODE=patch

virtual patch

@ depends on patch @
expression E1, E2;
@@

- ACCESS_ONCE(E1) = E2
+ WRITE_ONCE(E1, E2)

@ depends on patch @
expression E;
@@

- ACCESS_ONCE(E)
+ READ_ONCE(E)
----

Signed-off-by: Mark Rutland &lt;mark.rutland@arm.com&gt;
Signed-off-by: Paul E. McKenney &lt;paulmck@linux.vnet.ibm.com&gt;
Cc: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Cc: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: davem@davemloft.net
Cc: linux-arch@vger.kernel.org
Cc: mpe@ellerman.id.au
Cc: shuah@kernel.org
Cc: snitzer@redhat.com
Cc: thor.thayer@linux.intel.com
Cc: tj@kernel.org
Cc: viro@zeniv.linux.org.uk
Cc: will.deacon@arm.com
Link: http://lkml.kernel.org/r/1508792849-3115-19-git-send-email-paulmck@linux.vnet.ibm.com
Signed-off-by: Ingo Molnar &lt;mingo@kernel.org&gt;
</content>
</entry>
<entry>
<title>clocksource/drivers/bcm2835: Remove message for a memory allocation failure</title>
<updated>2017-08-29T13:23:31+00:00</updated>
<author>
<name>Markus Elfring</name>
<email>elfring@users.sourceforge.net</email>
</author>
<published>2017-08-27T19:38:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=ebbe266509d8a5453f51f77277da65d870125b72'/>
<id>urn:sha1:ebbe266509d8a5453f51f77277da65d870125b72</id>
<content type='text'>
The bcm2835_timer_init() function emits an error message in case of a memory
allocation failure. This is pointless as the mm core does that already.

Remove this message.

This issue was detected by using the Coccinelle software.

Signed-off-by: Markus Elfring &lt;elfring@users.sourceforge.net&gt;
Signed-off-by: Daniel Lezcano &lt;daniel.lezcano@linaro.org&gt;
</content>
</entry>
<entry>
<title>clocksource/drivers: Rename CLOCKSOURCE_OF_DECLARE to TIMER_OF_DECLARE</title>
<updated>2017-06-14T09:58:45+00:00</updated>
<author>
<name>Daniel Lezcano</name>
<email>daniel.lezcano@linaro.org</email>
</author>
<published>2017-05-26T14:56:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=1727339590fdb5a1ded881b540cd32121278d414'/>
<id>urn:sha1:1727339590fdb5a1ded881b540cd32121278d414</id>
<content type='text'>
The CLOCKSOURCE_OF_DECLARE macro is used widely for the timers to declare the
clocksource at early stage. However, this macro is also used to initialize
the clockevent if any, or the clockevent only.

It was originally suggested to declare another macro to initialize a
clockevent, so in order to separate the two entities even they belong to the
same IP. This was not accepted because of the impact on the DT where splitting
a clocksource/clockevent definition does not make sense as it is a Linux
concept not a hardware description.

On the other side, the clocksource has not interrupt declared while the
clockevent has, so it is easy from the driver to know if the description is
for a clockevent or a clocksource, IOW it could be implemented at the driver
level.

So instead of dealing with a named clocksource macro, let's use a more generic
one: TIMER_OF_DECLARE.

The patch has not functional changes.

Signed-off-by: Daniel Lezcano &lt;daniel.lezcano@linaro.org&gt;
Acked-by: Heiko Stuebner &lt;heiko@sntech.de&gt;
Acked-by: Neil Armstrong &lt;narmstrong@baylibre.com&gt;
Acked-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Acked-by: Matthias Brugger &lt;matthias.bgg@gmail.com&gt;
Reviewed-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
</content>
</entry>
<entry>
<title>clocksource: Add missing line break to error messages</title>
<updated>2017-04-07T14:23:04+00:00</updated>
<author>
<name>Rafał Miłecki</name>
<email>rafal@milecki.pl</email>
</author>
<published>2017-03-09T09:47:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=ac9ce6d1a0cc29767932d9f2fcb8ebc97c5106c8'/>
<id>urn:sha1:ac9ce6d1a0cc29767932d9f2fcb8ebc97c5106c8</id>
<content type='text'>
Printing with pr_* functions requires adding line break manually.

Signed-off-by: Rafał Miłecki &lt;rafal@milecki.pl&gt;
Acked-by: Thierry Reding &lt;treding@nvidia.com&gt;
Signed-off-by: Daniel Lezcano &lt;daniel.lezcano@linaro.org&gt;
</content>
</entry>
<entry>
<title>clocksource/drivers/bcm2835_timer: Unmap region obtained by of_iomap</title>
<updated>2016-11-22T08:22:59+00:00</updated>
<author>
<name>Arvind Yadav</name>
<email>arvind.yadav.cs@gmail.com</email>
</author>
<published>2016-09-21T17:33:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=84c39b8b7d46883f7a7514c7d55909831aa846fd'/>
<id>urn:sha1:84c39b8b7d46883f7a7514c7d55909831aa846fd</id>
<content type='text'>
Free memory mapping, if bcm2835_timer_init is not successful.

Signed-off-by: Arvind Yadav &lt;arvind.yadav.cs@gmail.com&gt;
Reviewed-by: Eric Anholt &lt;eric@anholt.net&gt;
Signed-off-by: Daniel Lezcano &lt;daniel.lezcano@linaro.org&gt;
</content>
</entry>
<entry>
<title>clocksources: Switch back to the clksrc table</title>
<updated>2016-06-28T08:19:35+00:00</updated>
<author>
<name>Daniel Lezcano</name>
<email>daniel.lezcano@linaro.org</email>
</author>
<published>2016-06-06T22:27:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=177cf6e52b0a1a382b9892d3cc9aafd6e7c5943f'/>
<id>urn:sha1:177cf6e52b0a1a382b9892d3cc9aafd6e7c5943f</id>
<content type='text'>
All the clocksource drivers's init function are now converted to return
an error code. CLOCKSOURCE_OF_DECLARE is no longer used as well as the
clksrc-of table.

Let's convert back the names:
 - CLOCKSOURCE_OF_DECLARE_RET =&gt; CLOCKSOURCE_OF_DECLARE
 - clksrc-of-ret              =&gt; clksrc-of

Signed-off-by: Daniel Lezcano &lt;daniel.lezcano@linaro.org&gt;

For exynos_mct and samsung_pwm_timer:
Acked-by: Krzysztof Kozlowski &lt;k.kozlowski@samsung.com&gt;

For arch/arc:
Acked-by: Vineet Gupta &lt;vgupta@synopsys.com&gt;

For mediatek driver:
Acked-by: Matthias Brugger &lt;matthias.bgg@gmail.com&gt;

For the Rockchip-part
Acked-by: Heiko Stuebner &lt;heiko@sntech.de&gt;

For STi :
Acked-by: Patrice Chotard &lt;patrice.chotard@st.com&gt;

For the mps2-timer.c and versatile.c changes:
Acked-by: Liviu Dudau &lt;Liviu.Dudau@arm.com&gt;

For the OXNAS part :
Acked-by: Neil Armstrong &lt;narmstrong@baylibre.com&gt;

For LPC32xx driver:
Acked-by: Sylvain Lemieux &lt;slemieux.tyco@gmail.com&gt;

For Broadcom Kona timer change:
Acked-by: Ray Jui &lt;ray.jui@broadcom.com&gt;

For Sun4i and Sun5i:
Acked-by: Chen-Yu Tsai &lt;wens@csie.org&gt;

For Meson6:
Acked-by: Carlo Caione &lt;carlo@caione.org&gt;

For Keystone:
Acked-by: Santosh Shilimkar &lt;ssantosh@kernel.org&gt;

For NPS:
Acked-by: Noam Camus &lt;noamca@mellanox.com&gt;

For bcm2835:
Acked-by: Eric Anholt &lt;eric@anholt.net&gt;
</content>
</entry>
</feed>
