[bootlin/training-materials updates] master: Embedded Linux: minor improvements (032d34d7)

Michael Opdenacker michael.opdenacker at bootlin.com
Wed Sep 2 17:44:47 CEST 2020


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

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

commit 032d34d78b991f880343a118b8ff4a8691796f41
Author: Michael Opdenacker <michael.opdenacker at bootlin.com>
Date:   Wed Sep 2 17:44:47 2020 +0200

    Embedded Linux: minor improvements
    
    Signed-off-by: Michael Opdenacker <michael.opdenacker at bootlin.com>


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

032d34d78b991f880343a118b8ff4a8691796f41
 slides/sysdev-busybox/sysdev-busybox.tex            |  2 +-
 .../sysdev-flash-filesystems.tex                    |  4 ++--
 .../sysdev-kernel-building.tex                      | 21 ++++++++++++++++-----
 .../sysdev-root-filesystem-contents.tex             |  3 ++-
 .../sysdev-root-filesystem-minimal.tex              |  2 +-
 .../sysdev-root-filesystem-principles.tex           |  2 +-
 .../sysdev-root-filesystem-virtual-fs.tex           |  2 +-
 7 files changed, 24 insertions(+), 12 deletions(-)

diff --git a/slides/sysdev-busybox/sysdev-busybox.tex b/slides/sysdev-busybox/sysdev-busybox.tex
index 59100928..e788a0b5 100644
--- a/slides/sysdev-busybox/sysdev-busybox.tex
+++ b/slides/sysdev-busybox/sysdev-busybox.tex
@@ -10,7 +10,7 @@
     \item Various basic utilities for file manipulation and system
       configuration
     \end{itemize}
-  \item In normal Linux systems, these programs are provided by
+  \item In normal GNU/Linux systems, these programs are provided by
     different projects
     \begin{itemize}
     \item \code{coreutils}, \code{bash}, \code{grep}, \code{sed},
diff --git a/slides/sysdev-flash-filesystems/sysdev-flash-filesystems.tex b/slides/sysdev-flash-filesystems/sysdev-flash-filesystems.tex
index 9e7f7625..8d70a274 100644
--- a/slides/sysdev-flash-filesystems/sysdev-flash-filesystems.tex
+++ b/slides/sysdev-flash-filesystems/sysdev-flash-filesystems.tex
@@ -33,10 +33,10 @@
       \item MLC: {\em Multi Level Cell} - Multiple bits per cell)
     \end{itemize}
   \item Start with all bits set to 1
-  \item Programming implies changing some bits from 1 to 0
+  \item Writing implies changing some bits from 1 to 0
         (assuming 1 bit per cell)
   \item Restoring bits to 1 is done via the ERASE operation
-  \item Programming and erasing is not done on a per bit or per byte
+  \item Writing and erasing are not done on a per bit or per byte
     basis
   \item Organization
     \begin{itemize}
diff --git a/slides/sysdev-kernel-building/sysdev-kernel-building.tex b/slides/sysdev-kernel-building/sysdev-kernel-building.tex
index 37208e34..96d9402a 100644
--- a/slides/sysdev-kernel-building/sysdev-kernel-building.tex
+++ b/slides/sysdev-kernel-building/sysdev-kernel-building.tex
@@ -187,7 +187,8 @@
       used to declare what features a hardware architecture supports.
     \end{itemize}
   \column{0.4\textwidth}
-    \includegraphics[width=\textwidth]{slides/sysdev-kernel-building/kconfig-dependencies.png}
+    \includegraphics[width=\textwidth]{slides/sysdev-kernel-building/kconfig-dependencies.png}\\
+    \footnotesize Kconfig file excerpt
   \end{columns}
   \item With the \code{Show All Options} option, \code{make xconfig} allows
     to see all options, even the ones that cannot be selected because of
@@ -392,7 +393,10 @@ tools (\code{gcc}, \code{as}, \code{ld}, \code{objcopy}, \code{strip}...).
     \begin{itemize}
     \item In the main kernel source directory!
     \item Remember to run multiple jobs in parallel
-          if you have multiple CPU cores. Example: \code{make -j 8}
+          if you have multiple CPU cores. Our advice:
+          \code{ncpus * 2} or \code{ncpus + 2}, to fully load
+          the CPU and I/Os at all times.\\
+          Example: \code{make -j 8}
     \item No need to run as root!
     \end{itemize}
   \item Generates
@@ -521,17 +525,23 @@ tools (\code{gcc}, \code{as}, \code{ld}, \code{objcopy}, \code{strip}...).
 \subsection{Booting the kernel}
 
 \begin{frame}
-  \frametitle{Device Tree (DT)}
+  \frametitle{Device Tree (1)}
   \begin{itemize}
   \item Many embedded architectures have a lot of non-discoverable
-    hardware.
+    hardware (serial, Ethernet, I2C, Nand flash, USB  controllers...)
   \item Depending on the architecture, such hardware is either
     described in BIOS ACPI tables (x86), using C code directly within the kernel,
     or using a special hardware description language in a {\em Device Tree}.
-  \item The DT was created for PowerPC, and later was
+  \item The Device Tree (DT) was created for PowerPC, and later was
     adopted by other architectures (ARM, ARC...). Now Linux
     has DT support in most architectures, at least for specific
     systems (for example for the OLPC on x86).
+  \end{itemize}
+\end{frame}
+
+\begin{frame}
+  \frametitle{Device Tree (2)}
+  \begin{itemize}
   \item A {\em Device Tree Source}, written by kernel developers,
     is compiled into a binary {\em Device Tree Blob}, and needs to
     be passed to the kernel at boot time.
@@ -608,6 +618,7 @@ tools (\code{gcc}, \code{as}, \code{ld}, \code{objcopy}, \code{strip}...).
     \item It is very important for system configuration
     \item \code{root=} for the root filesystem (covered later)
     \item \code{console=} for the destination of kernel messages
+    \item Example: \code{console=ttyS0 root=/dev/mmcblk0p2 rootwait}
     \item Many more exist. The most important ones are documented
           in \kerneldochtml{admin-guide/kernel-parameters} in kernel
           documentation.
diff --git a/slides/sysdev-root-filesystem-contents/sysdev-root-filesystem-contents.tex b/slides/sysdev-root-filesystem-contents/sysdev-root-filesystem-contents.tex
index aedd30dc..587122ab 100644
--- a/slides/sysdev-root-filesystem-contents/sysdev-root-filesystem-contents.tex
+++ b/slides/sysdev-root-filesystem-contents/sysdev-root-filesystem-contents.tex
@@ -20,7 +20,8 @@
   \frametitle{Important directories (1)}
   \begin{description}
   \item[/bin] Basic programs
-  \item[/boot] Kernel image (only when the kernel is loaded from a
+  \item[/boot] Kernel images, configurations and initramfs
+    (only when the kernel is loaded from a
     filesystem, not common on non-x86 architectures)
   \item[/dev] Device files (covered later)
   \item[/etc] System-wide configuration
diff --git a/slides/sysdev-root-filesystem-minimal/sysdev-root-filesystem-minimal.tex b/slides/sysdev-root-filesystem-minimal/sysdev-root-filesystem-minimal.tex
index c762b914..c43a50aa 100644
--- a/slides/sysdev-root-filesystem-minimal/sysdev-root-filesystem-minimal.tex
+++ b/slides/sysdev-root-filesystem-minimal/sysdev-root-filesystem-minimal.tex
@@ -14,7 +14,7 @@
     \item Otherwise, it tries to run \code{/sbin/init}, \code{/bin/init},
       \code{/etc/init} and \code{/bin/sh}.
     \item In the case of an initramfs, it will only look for
-      \code{/init}. Another path can be supplied by the \code{rdinit}
+      \code{/init}. Another path can be supplied by the \code{rdinit=}
       kernel argument.
     \item If none of this works, the kernel panics and the boot
       process is stopped.
diff --git a/slides/sysdev-root-filesystem-principles/sysdev-root-filesystem-principles.tex b/slides/sysdev-root-filesystem-principles/sysdev-root-filesystem-principles.tex
index 06dab423..7f303eb3 100644
--- a/slides/sysdev-root-filesystem-principles/sysdev-root-filesystem-principles.tex
+++ b/slides/sysdev-root-filesystem-principles/sysdev-root-filesystem-principles.tex
@@ -149,7 +149,7 @@ Kernel panic - not syncing: VFS: Unable to mount root fs on unknown block(0,0)
 
   \begin{itemize}
   \item Makes it very easy to update files on the root filesystem,
-    without rebooting. Much faster than through the serial port.
+    without rebooting.
   \item Can have a big root filesystem even if you don't have support
     for internal or external storage yet.
   \item The root filesystem can be huge. You can even build native
diff --git a/slides/sysdev-root-filesystem-virtual-fs/sysdev-root-filesystem-virtual-fs.tex b/slides/sysdev-root-filesystem-virtual-fs/sysdev-root-filesystem-virtual-fs.tex
index a4b20854..69a9591e 100644
--- a/slides/sysdev-root-filesystem-virtual-fs/sysdev-root-filesystem-virtual-fs.tex
+++ b/slides/sysdev-root-filesystem-virtual-fs/sysdev-root-filesystem-virtual-fs.tex
@@ -41,7 +41,7 @@
     \begin{itemize}
     \item They are called {\em sysctl}. See \kerneldoctext{sysctl/}
       in kernel sources.
-    \item Example\\
+    \item Example (free the page cache and slab objects):\\
       \code{echo 3 > /proc/sys/vm/drop_caches}
     \end{itemize}
   \end{itemize}




More information about the training-materials-updates mailing list