[bootlin/training-materials updates] master: Linux patches: add diagram (3ba3fc5f)
Michael Opdenacker
michael.opdenacker at bootlin.com
Mon Sep 7 17:34:33 CEST 2020
Repository : https://github.com/bootlin/training-materials
On branch : master
Link : https://github.com/bootlin/training-materials/commit/3ba3fc5f5943b94a05644849f0c830cd3c8e684d
>---------------------------------------------------------------
commit 3ba3fc5f5943b94a05644849f0c830cd3c8e684d
Author: Michael Opdenacker <michael.opdenacker at bootlin.com>
Date: Mon Sep 7 17:33:46 2020 +0200
Linux patches: add diagram
- To clarify the application of Linux patches
- Easier for us to explain at least!
Signed-off-by: Michael Opdenacker <michael.opdenacker at bootlin.com>
>---------------------------------------------------------------
3ba3fc5f5943b94a05644849f0c830cd3c8e684d
.../linux-patch-example.dia | Bin 0 -> 1887 bytes
.../sysdev-linux-tarballs-and-patches.tex | 54 +++++++++++++--------
2 files changed, 33 insertions(+), 21 deletions(-)
diff --git a/slides/sysdev-linux-tarballs-and-patches/linux-patch-example.dia b/slides/sysdev-linux-tarballs-and-patches/linux-patch-example.dia
new file mode 100644
index 00000000..5506b821
Binary files /dev/null and b/slides/sysdev-linux-tarballs-and-patches/linux-patch-example.dia differ
diff --git a/slides/sysdev-linux-tarballs-and-patches/sysdev-linux-tarballs-and-patches.tex b/slides/sysdev-linux-tarballs-and-patches/sysdev-linux-tarballs-and-patches.tex
index 7d2aa26f..518fc840 100644
--- a/slides/sysdev-linux-tarballs-and-patches/sysdev-linux-tarballs-and-patches.tex
+++ b/slides/sysdev-linux-tarballs-and-patches/sysdev-linux-tarballs-and-patches.tex
@@ -127,26 +127,38 @@ diff -Nru a/Makefile b/Makefile
\begin{frame}[fragile]
\frametitle{Applying a Linux patch}
- \begin{itemize}
- \item Two types of Linux patches:
- \begin{itemize}
- \item Either to be applied to the previous stable version\\
- (from \code{x.<y-1>} to \code{x.y})
- \item Or implementing fixes to the current stable version\\
+ \begin{columns}
+ \column{0.5\textwidth}
+ \begin{itemize}
+ \item Two types of Linux patches:
+ \begin{itemize}
+ \item Either to be applied to the previous stable version\\
+ (from \code{x.<y-1>} to \code{x.y})
+ \item Or implementing fixes to the current stable version\\
(from \code{x.y} to \code{x.y.z})
- \end{itemize}
- \item Can be downloaded in \code{gzip} or \code{xz} (much
- smaller) compressed files.
- \item Always produced for \code{n=1}\\
- (that's what everybody does... do it too!)
- \item Need to run the \code{patch} command inside the {\bf toplevel}
- kernel source directory
- \item Linux patch command line example:\\
-\begin{verbatim}
-cd linux-4.19
-xzcat ../patch-4.20.xz | patch -p1
-xzcat ../patch-4.20.13.xz | patch -p1
-cd ..; mv linux-4.19 linux-4.20.13
-\end{verbatim}
- \end{itemize}
+ \end{itemize}
+ \item Can be downloaded in \code{gzip} or \code{xz} (much
+ smaller) compressed files.
+ \item Always produced for \code{n=1}\\
+ \item Need to run the \code{patch} command inside the {\bf toplevel}
+ kernel source directory
+ \end{itemize}
+ \column{0.5\textwidth}
+ \includegraphics[width=\textwidth]{slides/sysdev-linux-tarballs-and-patches/linux-patch-example.pdf}
+ \footnotesize
+ \begin{block}{}
+ \begin{verbatim}
+cd linux-5.7
+# From 5.7 to 5.8.6
+xzcat ../patch-5.8.xz | patch -p1
+xzcat ../patch-5.8.6.xz | patch -p1
+# Back to 5.8 from 5.8.6
+xzcat ../patch-5.8.6.xz | patch -R -p1
+# From 5.8 to 5.8.7
+xzcat ../patch-5.8.7.xz | patch -p1
+# Renaming directory
+cd ..; mv linux-5.7 linux-5.8.7
+ \end{verbatim}
+ \end{block}
+ \end{columns}
\end{frame}
More information about the training-materials-updates
mailing list