<feed xmlns='http://www.w3.org/2005/Atom'>
<title>u-boot.git/test/cmd, branch v2021.04-rc2</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.</subtitle>
<id>http://cgit.235523.xyz/u-boot.git/atom/test/cmd?h=v2021.04-rc2</id>
<link rel='self' href='http://cgit.235523.xyz/u-boot.git/atom/test/cmd?h=v2021.04-rc2'/>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/'/>
<updated>2021-02-02T20:33:42Z</updated>
<entry>
<title>common: Drop asm/global_data.h from common header</title>
<updated>2021-02-02T20:33:42Z</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2020-10-31T03:38:53Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=401d1c4f5d2d29c4bc4beaec95402ca23eb63295'/>
<id>urn:sha1:401d1c4f5d2d29c4bc4beaec95402ca23eb63295</id>
<content type='text'>
Move this out of the common header and include it only where needed.  In
a number of cases this requires adding "struct udevice;" to avoid adding
another large header or in other cases replacing / adding missing header
files that had been pulled in, very indirectly.   Finally, we have a few
cases where we did not need to include &lt;asm/global_data.h&gt; at all, so
remove that include.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
Signed-off-by: Tom Rini &lt;trini@konsulko.com&gt;
</content>
</entry>
<entry>
<title>test: unit test for echo command</title>
<updated>2021-01-25T00:15:33Z</updated>
<author>
<name>Heinrich Schuchardt</name>
<email>xypron.glpk@gmx.de</email>
</author>
<published>2021-01-21T17:41:28Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=c0445c18d3cd97b6ebc81355d239efefe771f0aa'/>
<id>urn:sha1:c0445c18d3cd97b6ebc81355d239efefe771f0aa</id>
<content type='text'>
Provide a unit test for the unit command

Signed-off-by: Heinrich Schuchardt &lt;xypron.glpk@gmx.de&gt;
Reviewed-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
</entry>
<entry>
<title>cmd: Add a pwm command</title>
<updated>2021-01-18T20:23:06Z</updated>
<author>
<name>Pragnesh Patel</name>
<email>pragnesh.patel@sifive.com</email>
</author>
<published>2020-12-22T06:00:05Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=9e9a530a61c01e412a239d8c211d5b1e26b578fa'/>
<id>urn:sha1:9e9a530a61c01e412a239d8c211d5b1e26b578fa</id>
<content type='text'>
Add the command "pwm" for controlling the pwm channels. This
command provides pwm invert/config/enable/disable functionalities
via PWM uclass drivers

Signed-off-by: Pragnesh Patel &lt;pragnesh.patel@sifive.com&gt;
Reviewed-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
</entry>
<entry>
<title>test: correct the test prefix in ut cmd_mem</title>
<updated>2021-01-16T19:49:09Z</updated>
<author>
<name>Patrick Delaunay</name>
<email>patrick.delaunay@st.com</email>
</author>
<published>2020-11-19T09:08:42Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=353df8d3c3ca876704d54a9d2cb94970197ad62f'/>
<id>urn:sha1:353df8d3c3ca876704d54a9d2cb94970197ad62f</id>
<content type='text'>
Align the prefix used in cmd_ut_category function and name of tests
for ut mem.
This patch solves the issues detected by "make qcheck" after previous
patch.

Fixes: 550a9e7902ce ("cmd: Update the memory-search command")
Signed-off-by: Patrick Delaunay &lt;patrick.delaunay@st.com&gt;
Reviewed-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
</entry>
<entry>
<title>setexpr: Add support for strings</title>
<updated>2020-12-01T15:33:38Z</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2020-11-01T21:15:44Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=2c02152a8e2d640fe1d93177fbf523d25cd3e8f9'/>
<id>urn:sha1:2c02152a8e2d640fe1d93177fbf523d25cd3e8f9</id>
<content type='text'>
Add support for dealing with string operands, including reading a string
from memory into an environment variable and concatenating two strings.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
Acked-by: Marek Behún &lt;marek.behun@nic.cz&gt;
</content>
</entry>
<entry>
<title>setexpr: Correct buffer overflow bug and enable tests</title>
<updated>2020-12-01T15:33:38Z</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2020-11-01T21:15:42Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=8f4aa7ddb908369db971d4c31850ca1eef2e3687'/>
<id>urn:sha1:8f4aa7ddb908369db971d4c31850ca1eef2e3687</id>
<content type='text'>
At present when more than one substitution is made this function
overwrites its buffers. Fix this bug and update the tests now that they
can pass.

Also update the debug code to show all substrings, since at present it
omits the final one.

Fixes: 855f18ea0e6 ("setexpr: add regex substring matching and substitution")
Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
</entry>
<entry>
<title>setexpr: Correct dropping of final unmatched string</title>
<updated>2020-12-01T15:33:38Z</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2020-11-01T21:15:41Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=9528229f22b590cc4b5cf8bf0d3212d2ab08ffd5'/>
<id>urn:sha1:9528229f22b590cc4b5cf8bf0d3212d2ab08ffd5</id>
<content type='text'>
At present the 'nlen' variable increases with each loop. If the previous
loop had back references, then subsequent loops without back references
use the wrong value of nlen. The value is larger, meaning that the string
terminator from nbuf is copied along to the main buffer, thus terminating
the string prematurely.

This leads to the final result being truncated, e.g. missing the last
(unmatched) part of the string. So "match match tail" become
"replaced replaced" instead of "replaced replaced tail".

Fix this by resetting nlen to the correct value each time around the lop.

Fixes: 855f18ea0e6 ("setexpr: add regex substring matching and substitution")
Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
</entry>
<entry>
<title>setexpr: Add some tests for buffer overflow and backref</title>
<updated>2020-12-01T15:33:38Z</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2020-11-01T21:15:40Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=d422c77ae8e0cb1211b34eb4af442600b0da8d5b'/>
<id>urn:sha1:d422c77ae8e0cb1211b34eb4af442600b0da8d5b</id>
<content type='text'>
Add tests to check for buffer overflow using simple replacement as well
as back references. At present these don't fully pass.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
</entry>
<entry>
<title>test: Add some setexpr regex tests</title>
<updated>2020-12-01T15:33:38Z</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2020-11-01T21:15:38Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=e713124e352efe3141af6a4ffc83f6dba449a177'/>
<id>urn:sha1:e713124e352efe3141af6a4ffc83f6dba449a177</id>
<content type='text'>
Add tests for the setexpr regex commands.

Note that these tests currently crash on sandbox due to an existing bug in
the setexpr implementation, so two of the tests are commented out.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
</entry>
<entry>
<title>setexpr: Add explicit support for 32- and 64-bit ints</title>
<updated>2020-12-01T15:33:38Z</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2020-11-01T21:15:37Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=25a43ac84a9509b8ccd093808bb39b71e4438cf5'/>
<id>urn:sha1:25a43ac84a9509b8ccd093808bb39b71e4438cf5</id>
<content type='text'>
At present this function assumes that a size of 4 refers to a ulong. This
is true on 32-bit machines but not commonly on 64-bit machines.

This means that the 'l' specify does not work correctly with setexpr.

Add an explicit case for 32-bit values so that 64-bit machines can still
use the 'l' specifier. On 32-bit machines, 64-bit is still not supported.

This corrects the operation of the default size (which is 4 for setexpr),
so update the tests accordingly.

The original code for reading from memory was included in 47ab5ad1457
("cmd_setexpr: allow memory addresses in expressions") but I am not adding
a Fixes: tag since that code was not written with 64-bit machines in mind.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
</entry>
</feed>
