<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/barebox.git/include/clock.h, branch master</title>
<subtitle>git.pengutronix.de: git/barebox.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/barebox.git/'/>
<entry>
<title>clock: implement CLOCKSOURCE_MASK in terms of GENMASK_ULL</title>
<updated>2023-04-17T07:00:44+00:00</updated>
<author>
<name>Ahmad Fatoum</name>
<email>a.fatoum@pengutronix.de</email>
</author>
<published>2023-04-04T10:19:14+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/barebox.git/commit/?id=764c5889016510b9528c1276321bbd5b62043094'/>
<id>764c5889016510b9528c1276321bbd5b62043094</id>
<content type='text'>
Clang doesn't like our implementation of CLOCKSOURCE_MASK:

  common/clock.c:33:10: warning: shift count &gt;= width of type [-Wshift-count-overflow]
	.mask = CLOCKSOURCE_MASK(64),
                ^~~~~~~~~~~~~~~~~~~~
  include/clock.h:8:63: note: expanded from macro 'CLOCKSOURCE_MASK'
	 #define CLOCKSOURCE_MASK(bits) (uint64_t)((bits) &lt; 64 ? ((1ULL&lt;&lt;(bits))-1) : -1)

So the bits &lt; 64 check we have is apparently not enough to suppress the
warning when built with clang.

Let's do what the kernel does and use GENMASK_ULL instead to get rid of
the last remaining warning when building ARCH=sandbox targettools_defconfig
with clang version 16.0.1.

Not functional change intended.

Signed-off-by: Ahmad Fatoum &lt;a.fatoum@pengutronix.de&gt;
Link: https://lore.barebox.org/20230404101914.2244083-1-a.fatoum@pengutronix.de
Signed-off-by: Sascha Hauer &lt;s.hauer@pengutronix.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Clang doesn't like our implementation of CLOCKSOURCE_MASK:

  common/clock.c:33:10: warning: shift count &gt;= width of type [-Wshift-count-overflow]
	.mask = CLOCKSOURCE_MASK(64),
                ^~~~~~~~~~~~~~~~~~~~
  include/clock.h:8:63: note: expanded from macro 'CLOCKSOURCE_MASK'
	 #define CLOCKSOURCE_MASK(bits) (uint64_t)((bits) &lt; 64 ? ((1ULL&lt;&lt;(bits))-1) : -1)

So the bits &lt; 64 check we have is apparently not enough to suppress the
warning when built with clang.

Let's do what the kernel does and use GENMASK_ULL instead to get rid of
the last remaining warning when building ARCH=sandbox targettools_defconfig
with clang version 16.0.1.

Not functional change intended.

Signed-off-by: Ahmad Fatoum &lt;a.fatoum@pengutronix.de&gt;
Link: https://lore.barebox.org/20230404101914.2244083-1-a.fatoum@pengutronix.de
Signed-off-by: Sascha Hauer &lt;s.hauer@pengutronix.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Subject: [PATCH 1/1] ARM:lib32: add architected timer</title>
<updated>2023-03-09T10:59:16+00:00</updated>
<author>
<name>Renaud Barbier</name>
<email>Renaud.Barbier@ametek.com</email>
</author>
<published>2023-03-07T16:17:08+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/barebox.git/commit/?id=f913e2170a2ba1a1c9a1b833e9a4e8e00ffe24db'/>
<id>f913e2170a2ba1a1c9a1b833e9a4e8e00ffe24db</id>
<content type='text'>
In preparation for the introduction of the LS1021A support,
add a specific timer support based on the LS1046A support so
that delays can be used in the PBL.

Signed-off-by: Renaud Barbier &lt;renaud.barbier@ametek.com&gt;
Link: https://lore.barebox.org/BL0PR07MB566565603B9BFC2D40141142ECB79@BL0PR07MB5665.namprd07.prod.outlook.com
Signed-off-by: Sascha Hauer &lt;s.hauer@pengutronix.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In preparation for the introduction of the LS1021A support,
add a specific timer support based on the LS1046A support so
that delays can be used in the PBL.

Signed-off-by: Renaud Barbier &lt;renaud.barbier@ametek.com&gt;
Link: https://lore.barebox.org/BL0PR07MB566565603B9BFC2D40141142ECB79@BL0PR07MB5665.namprd07.prod.outlook.com
Signed-off-by: Sascha Hauer &lt;s.hauer@pengutronix.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>clock: Change cyc2ns return type to uint64_t</title>
<updated>2021-03-26T08:02:55+00:00</updated>
<author>
<name>Jules Maselbas</name>
<email>jmaselbas@kalray.eu</email>
</author>
<published>2021-03-25T13:38:34+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/barebox.git/commit/?id=d1c7791012db9d891064a52e52e12c9618398bba'/>
<id>d1c7791012db9d891064a52e52e12c9618398bba</id>
<content type='text'>
Using an uint32_t to count nanosec will overflow every ~4sec, this means
that if get_time_ns is not called often enough the time keeping will be
wrong. By changing the return type to uint64_t doesn't fix the underlying
overflow issue but it will take more than 500 years to happen and I think
it's safe to assume this won't be an issue.

Signed-off-by: Jules Maselbas &lt;jmaselbas@kalray.eu&gt;
Signed-off-by: Sascha Hauer &lt;s.hauer@pengutronix.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Using an uint32_t to count nanosec will overflow every ~4sec, this means
that if get_time_ns is not called often enough the time keeping will be
wrong. By changing the return type to uint64_t doesn't fix the underlying
overflow issue but it will take more than 500 years to happen and I think
it's safe to assume this won't be an issue.

Signed-off-by: Jules Maselbas &lt;jmaselbas@kalray.eu&gt;
Signed-off-by: Sascha Hauer &lt;s.hauer@pengutronix.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>include: add SPDX GPL-2.0-only license tags for files without licensing information</title>
<updated>2020-02-17T09:08:47+00:00</updated>
<author>
<name>Roland Hieber</name>
<email>rohieb@rohieb.name</email>
</author>
<published>2020-02-13T12:12:50+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/barebox.git/commit/?id=2c74908aeb17a204039aab382b4ab731d1b5dd8b'/>
<id>2c74908aeb17a204039aab382b4ab731d1b5dd8b</id>
<content type='text'>
According to our /README, GPL-2.0-only applies for the whole project
except noted otherwise.

Signed-off-by: Roland Hieber &lt;rohieb@rohieb.name&gt;
Reviewed-by: Ahmad Fatoum &lt;a.fatoum@pengutronix.de&gt;
Signed-off-by: Sascha Hauer &lt;s.hauer@pengutronix.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
According to our /README, GPL-2.0-only applies for the whole project
except noted otherwise.

Signed-off-by: Roland Hieber &lt;rohieb@rohieb.name&gt;
Reviewed-by: Ahmad Fatoum &lt;a.fatoum@pengutronix.de&gt;
Signed-off-by: Sascha Hauer &lt;s.hauer@pengutronix.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>include: Add definitnion for HZ</title>
<updated>2019-02-18T13:25:51+00:00</updated>
<author>
<name>Andrey Smirnov</name>
<email>andrew.smirnov@gmail.com</email>
</author>
<published>2019-02-12T06:40:19+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/barebox.git/commit/?id=40050e44274be96bc07e7f915c3f708f228160a6'/>
<id>40050e44274be96bc07e7f915c3f708f228160a6</id>
<content type='text'>
Add definitnion for HZ to simplify porting Linux kernel code.

Signed-off-by: Andrey Smirnov &lt;andrew.smirnov@gmail.com&gt;
Signed-off-by: Sascha Hauer &lt;s.hauer@pengutronix.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add definitnion for HZ to simplify porting Linux kernel code.

Signed-off-by: Andrey Smirnov &lt;andrew.smirnov@gmail.com&gt;
Signed-off-by: Sascha Hauer &lt;s.hauer@pengutronix.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>clocksource: allow to have multiple device from clock source</title>
<updated>2017-03-09T06:36:15+00:00</updated>
<author>
<name>Jean-Christophe PLAGNIOL-VILLARD</name>
<email>plagnioj@jcrosoft.com</email>
</author>
<published>2017-03-03T12:34:01+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/barebox.git/commit/?id=6bc48eabbfe78906ac2b7fa8e12cc9b0608c76bd'/>
<id>6bc48eabbfe78906ac2b7fa8e12cc9b0608c76bd</id>
<content type='text'>
use the one with the most priority.

We can not select the clocksource at user level.

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD &lt;plagnioj@jcrosoft.com&gt;
Signed-off-by: Sascha Hauer &lt;s.hauer@pengutronix.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
use the one with the most priority.

We can not select the clocksource at user level.

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD &lt;plagnioj@jcrosoft.com&gt;
Signed-off-by: Sascha Hauer &lt;s.hauer@pengutronix.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>clock.h: include &lt;types.h&gt; under guard macro</title>
<updated>2015-10-22T07:33:58+00:00</updated>
<author>
<name>Antony Pavlov</name>
<email>antonynpavlov@gmail.com</email>
</author>
<published>2015-10-22T05:45:26+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/barebox.git/commit/?id=d70cb35e44c2880f17351393db3785855b064bd6'/>
<id>d70cb35e44c2880f17351393db3785855b064bd6</id>
<content type='text'>
Signed-off-by: Antony Pavlov &lt;antonynpavlov@gmail.com&gt;
Signed-off-by: Sascha Hauer &lt;s.hauer@pengutronix.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Antony Pavlov &lt;antonynpavlov@gmail.com&gt;
Signed-off-by: Sascha Hauer &lt;s.hauer@pengutronix.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge branch 'for-next/usb'</title>
<updated>2015-10-07T06:23:51+00:00</updated>
<author>
<name>Sascha Hauer</name>
<email>s.hauer@pengutronix.de</email>
</author>
<published>2015-10-07T06:23:51+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/barebox.git/commit/?id=54bf38665024f797518726d0ecf612c3cf50e4d9'/>
<id>54bf38665024f797518726d0ecf612c3cf50e4d9</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>common: clock: introduce mdelay_non_interruptible()</title>
<updated>2015-10-02T05:50:51+00:00</updated>
<author>
<name>Peter Mamonov</name>
<email>pmamonov@gmail.com</email>
</author>
<published>2015-09-24T16:20:24+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/barebox.git/commit/?id=8165f3131c6515fd7375dce7e2ee5759f237e011'/>
<id>8165f3131c6515fd7375dce7e2ee5759f237e011</id>
<content type='text'>
Signed-off-by: Peter Mamonov &lt;pmamonov@gmail.com&gt;
Signed-off-by: Sascha Hauer &lt;s.hauer@pengutronix.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Peter Mamonov &lt;pmamonov@gmail.com&gt;
Signed-off-by: Sascha Hauer &lt;s.hauer@pengutronix.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>clock: remove duplicate xdelay declarations</title>
<updated>2015-09-23T13:13:11+00:00</updated>
<author>
<name>Sascha Hauer</name>
<email>s.hauer@pengutronix.de</email>
</author>
<published>2015-09-23T13:12:06+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/barebox.git/commit/?id=9d54b6f6b6c42b7078ba8619444089507a0563f3'/>
<id>9d54b6f6b6c42b7078ba8619444089507a0563f3</id>
<content type='text'>
ndelay is declared in include/clock.h, udelay in include/common.h and
mdelay in include/common.h and include/clock.h. Move them all to
include/clock.h and remove duplicates.

Signed-off-by: Sascha Hauer &lt;s.hauer@pengutronix.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
ndelay is declared in include/clock.h, udelay in include/common.h and
mdelay in include/common.h and include/clock.h. Move them all to
include/clock.h and remove duplicates.

Signed-off-by: Sascha Hauer &lt;s.hauer@pengutronix.de&gt;
</pre>
</div>
</content>
</entry>
</feed>
