[bootlin/training-materials updates] master: Flash filesystem: U-Boot tools now mature (ca612aee)

Michael Opdenacker michael.opdenacker at bootlin.com
Fri Sep 25 16:04:37 CEST 2020


Repository : https://github.com/bootlin/training-materials
On branch  : master
Link       : https://github.com/bootlin/training-materials/commit/ca612aeee60217c0f01c73f4654e94f62801a0df

>---------------------------------------------------------------

commit ca612aeee60217c0f01c73f4654e94f62801a0df
Author: Michael Opdenacker <michael.opdenacker at bootlin.com>
Date:   Fri Sep 25 16:04:37 2020 +0200

    Flash filesystem: U-Boot tools now mature
    
    - Stop advising against the use of U-Boot commands
      that modify UBI volumes. Made multiple tests and had
      no issues in Linux and in U-Boot either.
    
    Signed-off-by: Michael Opdenacker <michael.opdenacker at bootlin.com>


>---------------------------------------------------------------

ca612aeee60217c0f01c73f4654e94f62801a0df
 .../sysdev-flash-filesystems.tex                   | 33 ++++++++++++++--------
 1 file changed, 21 insertions(+), 12 deletions(-)

diff --git a/slides/sysdev-flash-filesystems/sysdev-flash-filesystems.tex b/slides/sysdev-flash-filesystems/sysdev-flash-filesystems.tex
index 5245ad1c..5e81cd6d 100644
--- a/slides/sysdev-flash-filesystems/sysdev-flash-filesystems.tex
+++ b/slides/sysdev-flash-filesystems/sysdev-flash-filesystems.tex
@@ -727,27 +727,36 @@ Device 0 bad blocks:
 \end{frame}
 
 \begin{frame}
-  \frametitle{U-Boot: UBI tools}
+  \frametitle{U-Boot: UBI tools (1)}
   Grouped under the \code{ubi} command
     \begin{itemize}
     \item \code{ubi part <part-name>}\\
-	Attach an MTD partition to the UBI layer
+	Attach an MTD partition to the UBI layer. Example:\\
+	\code{ubi part UBI}
     \item \code{ubi info [layout]}\\
 	Display UBI device information\\
 	(or volume information if the \code{layout} string is passed)
     \item \code{ubi check <vol-name>}\\
 	Check if a volume exists
     \item \code{ubi readvol <dest-addr> <vol-name> [<size>]}\\
-	Read volume contents
-    \item U-Boot also provides tools to update the UBI device contents
-    \item Using them is highly discouraged (the U-Boot UBI implementation
-      is not entirely stable, and using commands that do not touch the UBI
-      metadata is safer)
-      \begin{itemize}
-      \item \code{ubi createvol <vol-name> [<size>] [<type>]}
-      \item \code{ubi removevol <vol-name>}
-      \item \code{ubi writevol <src-addr> <vol-name> <size>}
-      \end{itemize}
+	Read volume contents. Example:\\
+	\code{ubi readvol 0x21000000 kernel}
+    \end{itemize}
+\end{frame}
+
+\begin{frame}
+  \frametitle{U-Boot: UBI tools (2)}
+  U-Boot also has commands to modify the UBI volumes:
+    \begin{itemize}
+    \item \code{ubi createvol <vol-name> [<size>] [<type>]}\\
+	Create a new volume. Example:\\
+        \code{ubi createvol initramfs 0x100000 static}
+    \item \code{ubi removevol <vol-name>}\\
+	Remove an existing volume
+    \item \code{ubi writevol <src-addr> <vol-name> <size>}\\
+        Write to volume. Example:\\
+	\code{tftp 0x21000000 data.ubifs}\\
+	\code{ubi writevol 0x21000000 data ${filesize}}
     \end{itemize}
 \end{frame}
 




More information about the training-materials-updates mailing list