<feed xmlns='http://www.w3.org/2005/Atom'>
<title>u-boot.git/cmd/ubi.c, branch v2023.04</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.
</subtitle>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/'/>
<entry>
<title>cmd: ubi: Add 'ubi list' command for printing list of all UBI volumes</title>
<updated>2022-10-12T12:55:31+00:00</updated>
<author>
<name>Pali Rohár</name>
<email>pali@kernel.org</email>
</author>
<published>2022-09-12T09:38:55+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=6de1daf64b1acc3d2249ceed34756435a1b13d98'/>
<id>6de1daf64b1acc3d2249ceed34756435a1b13d98</id>
<content type='text'>
To allow easily iterate over all UBI volumes, add a new command which
either print all user UBI volumes on output or set them into env variable.

As UBI volumes can have arbitrary name/label, in most cases it is useful to
iterate them by their numbers. This can be achieved by -numeric flag.

This functionality is similar to already existing 'part list' command which
prints partitions on formatted block device.

Signed-off-by: Pali Rohár &lt;pali@kernel.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
To allow easily iterate over all UBI volumes, add a new command which
either print all user UBI volumes on output or set them into env variable.

As UBI volumes can have arbitrary name/label, in most cases it is useful to
iterate them by their numbers. This can be achieved by -numeric flag.

This functionality is similar to already existing 'part list' command which
prints partitions on formatted block device.

Signed-off-by: Pali Rohár &lt;pali@kernel.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>cmd: ubi.c: skip part command if right partition is already attached</title>
<updated>2022-04-14T19:39:15+00:00</updated>
<author>
<name>Alexandre Besnard</name>
<email>alexandre.besnard@softathome.com</email>
</author>
<published>2022-04-04T15:50:14+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=af298f3dcdae31b49791ff7aa1a6d75a27e57f3a'/>
<id>af298f3dcdae31b49791ff7aa1a6d75a27e57f3a</id>
<content type='text'>
Attaching a UBI partition may take a while, since scanning the memory is
required.
It thus makes sense to avoid a detach/scan/attach cycle when the right
partition is already attached, and let the calling process call 'detach'
beforehand if it needs it.

This commit checks for the currently attached UBI partition, and skips
reattaching if not needed, showing an information.

Signed-off-by: Alexandre Besnard &lt;alexandre.besnard@softathome.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Attaching a UBI partition may take a while, since scanning the memory is
required.
It thus makes sense to avoid a detach/scan/attach cycle when the right
partition is already attached, and let the calling process call 'detach'
beforehand if it needs it.

This commit checks for the currently attached UBI partition, and skips
reattaching if not needed, showing an information.

Signed-off-by: Alexandre Besnard &lt;alexandre.besnard@softathome.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>global: Convert simple_strtoul() with hex to hextoul()</title>
<updated>2021-08-02T17:32:14+00:00</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2021-07-24T15:03:29+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=7e5f460ec457fe310156e399198a41eb0ce1e98c'/>
<id>7e5f460ec457fe310156e399198a41eb0ce1e98c</id>
<content type='text'>
It is a pain to have to specify the value 16 in each call. Add a new
hextoul() function and update the code to use it.

Add a proper comment to simple_strtoul() while we are here.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It is a pain to have to specify the value 16 in each call. Add a new
hextoul() function and update the code to use it.

Add a proper comment to simple_strtoul() while we are here.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>cmd: ubi: don't allow to rename a volume to a name that already exist</title>
<updated>2021-01-04T14:10:17+00:00</updated>
<author>
<name>Philippe Reynes</name>
<email>philippe.reynes@softathome.com</email>
</author>
<published>2020-12-23T14:33:07+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=1639988fa4c0049e6580dc781fe9bb2c94258c02'/>
<id>1639988fa4c0049e6580dc781fe9bb2c94258c02</id>
<content type='text'>
This commits add a check on the command ubi rename. This check avoids
to rename a volume to with a name that is already used on another ubi
volume. If two volumes has the same name, then the ubi device can't be
mounted anymore.

Signed-off-by: Philippe Reynes &lt;philippe.reynes@softathome.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This commits add a check on the command ubi rename. This check avoids
to rename a volume to with a name that is already used on another ubi
volume. If two volumes has the same name, then the ubi device can't be
mounted anymore.

Signed-off-by: Philippe Reynes &lt;philippe.reynes@softathome.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>command: Remove the cmd_tbl_t typedef</title>
<updated>2020-05-18T22:36:55+00:00</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2020-05-10T17:40:03+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=09140113108541b95d340f3c7b6ee597d31ccc73'/>
<id>09140113108541b95d340f3c7b6ee597d31ccc73</id>
<content type='text'>
We should not use typedefs in U-Boot. They cannot be used as forward
declarations which means that header files must include the full header to
access them.

Drop the typedef and rename the struct to remove the _s suffix which is
now not useful.

This requires quite a few header-file additions.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We should not use typedefs in U-Boot. They cannot be used as forward
declarations which means that header files must include the full header to
access them.

Drop the typedef and rename the struct to remove the _s suffix which is
now not useful.

This requires quite a few header-file additions.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>cmd: ubi: add a command to rename volume</title>
<updated>2020-04-20T04:34:56+00:00</updated>
<author>
<name>Philippe Reynes</name>
<email>philippe.reynes@softathome.com</email>
</author>
<published>2020-03-23T18:20:47+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=83f7078b688528f1f5c117e404c056e048970012'/>
<id>83f7078b688528f1f5c117e404c056e048970012</id>
<content type='text'>
This commit adds the command ubi rename to rename an ubi volume.
The format of the command is: ubi rename &lt;oldname&gt; &lt;newname&gt;.
To enable this command, the option CMD_UBI_RENAME must be selected.

Signed-off-by: Philippe Reynes &lt;philippe.reynes@softathome.com&gt;
Reviewed-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This commit adds the command ubi rename to rename an ubi volume.
The format of the command is: ubi rename &lt;oldname&gt; &lt;newname&gt;.
To enable this command, the option CMD_UBI_RENAME must be selected.

Signed-off-by: Philippe Reynes &lt;philippe.reynes@softathome.com&gt;
Reviewed-by: Simon Glass &lt;sjg@chromium.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>dm: core: Create a new header file for 'compat' features</title>
<updated>2020-02-06T02:33:46+00:00</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2020-02-03T14:36:16+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=336d4615f8fa774557d14f9b3245daa9e5fe3dbc'/>
<id>336d4615f8fa774557d14f9b3245daa9e5fe3dbc</id>
<content type='text'>
At present dm/device.h includes the linux-compatible features. This
requires including linux/compat.h which in turn includes a lot of headers.
One of these is malloc.h which we thus end up including in every file in
U-Boot. Apart from the inefficiency of this, it is problematic for sandbox
which needs to use the system malloc() in some files.

Move the compatibility features into a separate header file.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
At present dm/device.h includes the linux-compatible features. This
requires including linux/compat.h which in turn includes a lot of headers.
One of these is malloc.h which we thus end up including in every file in
U-Boot. Apart from the inefficiency of this, it is problematic for sandbox
which needs to use the system malloc() in some files.

Move the compatibility features into a separate header file.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>dm: core: Require users of devres to include the header</title>
<updated>2020-02-06T02:33:46+00:00</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2020-02-03T14:36:15+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=61b29b82683863a970fd4609a7c58512872616bc'/>
<id>61b29b82683863a970fd4609a7c58512872616bc</id>
<content type='text'>
At present devres.h is included in all files that include dm.h but few
make use of it. Also this pulls in linux/compat which adds several more
headers. Drop the automatic inclusion and require files to include devres
themselves. This provides a good indication of which files use devres.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
Reviewed-by: Anatolij Gustschin &lt;agust@denx.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
At present devres.h is included in all files that include dm.h but few
make use of it. Also this pulls in linux/compat which adds several more
headers. Drop the automatic inclusion and require files to include devres
themselves. This provides a good indication of which files use devres.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
Reviewed-by: Anatolij Gustschin &lt;agust@denx.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>ubi: Add "skipcheck" command to set/clear this bit in the UBI volume hdr</title>
<updated>2019-10-16T03:42:36+00:00</updated>
<author>
<name>Stefan Roese</name>
<email>sr@denx.de</email>
</author>
<published>2019-09-17T07:17:53+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=e6661cf767ce644e6ff835537449979859060c5b'/>
<id>e6661cf767ce644e6ff835537449979859060c5b</id>
<content type='text'>
U-Boot now supports the "skip_check" flag to optionally skip the CRC
check at open time. Currently its only possible to set this bit upon
UBI volume creation. But it might be very useful to also set this bit
on already installed systems (e.g. field upgrade) to make also use of
the boot-time decrease on those systems.

This patch now adds a new "ubi" command "ubi skipcheck" to set or clear
this bit in the UBI volume header:

=&gt; ubi skipcheck rootfs0 on
Setting skip_check on volume rootfs0

BTW: This saves approx. 10 seconds Linux bootup time on a MT7688 based
target with 128MiB of SPI NAND.

Signed-off-by: Stefan Roese &lt;sr@denx.de&gt;
Reviewed-by: Heiko Schocher &lt;hs@denx.de&gt;
Cc: Quentin Schulz &lt;quentin.schulz@bootlin.com&gt;
Cc: Boris Brezillon &lt;boris.brezillon@collabora.com&gt;
Cc: Heiko Schocher &lt;hs@denx.de&gt;
Cc: Andreas Dannenberg &lt;dannenberg@ti.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
U-Boot now supports the "skip_check" flag to optionally skip the CRC
check at open time. Currently its only possible to set this bit upon
UBI volume creation. But it might be very useful to also set this bit
on already installed systems (e.g. field upgrade) to make also use of
the boot-time decrease on those systems.

This patch now adds a new "ubi" command "ubi skipcheck" to set or clear
this bit in the UBI volume header:

=&gt; ubi skipcheck rootfs0 on
Setting skip_check on volume rootfs0

BTW: This saves approx. 10 seconds Linux bootup time on a MT7688 based
target with 128MiB of SPI NAND.

Signed-off-by: Stefan Roese &lt;sr@denx.de&gt;
Reviewed-by: Heiko Schocher &lt;hs@denx.de&gt;
Cc: Quentin Schulz &lt;quentin.schulz@bootlin.com&gt;
Cc: Boris Brezillon &lt;boris.brezillon@collabora.com&gt;
Cc: Heiko Schocher &lt;hs@denx.de&gt;
Cc: Andreas Dannenberg &lt;dannenberg@ti.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>ubi: provide a way to skip CRC checks</title>
<updated>2019-10-16T03:42:27+00:00</updated>
<author>
<name>Quentin Schulz</name>
<email>quentin.schulz@bootlin.com</email>
</author>
<published>2019-09-12T14:41:01+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=386f20cade50ed36674e3e5827cb282eb1da95c2'/>
<id>386f20cade50ed36674e3e5827cb282eb1da95c2</id>
<content type='text'>
Some users of static UBI volumes implement their own integrity check,
thus making the volume CRC check done at open time useless. For
instance, this is the case when one use the ubiblock + dm-verity +
squashfs combination, where dm-verity already checks integrity of the
block device but this time at the block granularity instead of verifying
the whole volume.

Skipping this test drastically improves the boot-time.

Adapted to U-Boot by Stefan Roese.

Signed-off-by: Quentin Schulz &lt;quentin.schulz@bootlin.com&gt;
Signed-off-by: Stefan Roese &lt;sr@denx.de&gt;
Reviewed-by: Heiko Schocher &lt;hs@denx.de&gt;
Cc: Quentin Schulz &lt;quentin.schulz@bootlin.com&gt;
Cc: Boris Brezillon &lt;boris.brezillon@bootlin.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Some users of static UBI volumes implement their own integrity check,
thus making the volume CRC check done at open time useless. For
instance, this is the case when one use the ubiblock + dm-verity +
squashfs combination, where dm-verity already checks integrity of the
block device but this time at the block granularity instead of verifying
the whole volume.

Skipping this test drastically improves the boot-time.

Adapted to U-Boot by Stefan Roese.

Signed-off-by: Quentin Schulz &lt;quentin.schulz@bootlin.com&gt;
Signed-off-by: Stefan Roese &lt;sr@denx.de&gt;
Reviewed-by: Heiko Schocher &lt;hs@denx.de&gt;
Cc: Quentin Schulz &lt;quentin.schulz@bootlin.com&gt;
Cc: Boris Brezillon &lt;boris.brezillon@bootlin.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
