[FE training-materials-updates] Do not mention CONFIG_DEBUG since it doesn't exist

thomas.petazzoni at free-electrons.com thomas.petazzoni at free-electrons.com
Thu Jun 7 19:17:29 CEST 2012


- Log -----------------------------------------------------------------
http://git.free-electrons.com/training-materials/commit/?id=4e9298891e3e7d3485463c7b132eda39c3e87c7f

commit 4e9298891e3e7d3485463c7b132eda39c3e87c7f
Author: Thomas Petazzoni <thomas.petazzoni at free-electrons.com>
Date:   Thu Jun 7 19:16:40 2012 +0200

    Do not mention CONFIG_DEBUG since it doesn't exist
    
    Rather, it's #define DEBUUG at the beginning of the driver or, passing
    -DDEBUG in the cflags.
    
    I've used {\tt \#define DEBUG} because \code{#define DEBUG} does not
    compile. I don't have time to figure this out now.
    
    Signed-off-by: Thomas Petazzoni <thomas.petazzoni at free-electrons.com>

diff --git a/slides/kernel-driver-development-debugging/kernel-driver-development-debugging.tex b/slides/kernel-driver-development-debugging/kernel-driver-development-debugging.tex
index 2783810..91fb017 100644
--- a/slides/kernel-driver-development-debugging/kernel-driver-development-debugging.tex
+++ b/slides/kernel-driver-development-debugging/kernel-driver-development-debugging.tex
@@ -34,9 +34,11 @@
 \begin{frame}
   \frametitle{pr\_debug() and dev\_dbg()}
   \begin{itemize}
-  \item When the kernel is compiled with \code{CONFIG_DEBUG}, all
-    those messages are compiled and printed at the debug level with
-    \code{printk}
+  \item When the driver is compiled with \code{DEBUG} defined, all
+    those messages are compiled and printed at the debug level.
+    \code{DEBUG} can be defined by {\tt \#define DEBUG} at the
+    beginning of the driver, or using
+    \code{ccflags-$(CONFIG_DRIVER) += -DDEBUG} in the \code{Makefile}
   \item When the kernel is compiled with \code{CONFIG_DYNAMIC_DEBUG},
     then those messages can dynamically be enabled on a per-file,
     per-module or per-message basis
@@ -45,8 +47,8 @@
     \item Very powerful feature to only get the debug messages you're
       interested in.
     \end{itemize}
-  \item When neither \code{CONFIG_DEBUG} nor
-    \code{CONFIG_DYNAMIC_DEBUG} are enabled, those messages are not
+  \item When \code{DEBUG} is not defined and
+    \code{CONFIG_DYNAMIC_DEBUG} is enabled, those messages are not
     compiled in.
   \end{itemize}
 \end{frame}

http://git.free-electrons.com/training-materials/commit/?id=4acc6fee9f839ef024d46e090de3e5f44ce4b543

commit 4acc6fee9f839ef024d46e090de3e5f44ce4b543
Author: Thomas Petazzoni <thomas.petazzoni at free-electrons.com>
Date:   Thu Jun 7 19:16:25 2012 +0200

    Do not mention CONFIG_DEBUG, which doesn't exist
    
    Signed-off-by: Thomas Petazzoni <thomas.petazzoni at free-electrons.com>

diff --git a/labs/kernel-debugging/kernel-debugging.tex b/labs/kernel-debugging/kernel-debugging.tex
index 6849747..478ed4f 100644
--- a/labs/kernel-debugging/kernel-debugging.tex
+++ b/labs/kernel-debugging/kernel-debugging.tex
@@ -10,8 +10,9 @@ add a similar \code{pr_debug()} call in your interrupt handler to show
 each character being received.
 
 Check what happens with your module. Do you see the debugging messages
-that you added ? Your kernel probably has neither \code{CONFIG_DEBUG} nor
-\code{CONFIG_DYNAMIC_DEBUG} set, so you shouldn't see any message.
+that you added ? Your kernel probably does not have
+\code{CONFIG_DYNAMIC_DEBUG} set and your driver is not compiled with
+\code{DEBUG} defined., so you shouldn't see any message.
 
 Now, recompile your kernel with \code{CONFIG_DYNAMIC_DEBUG} and reboot. The
 dynamic debug feature can be configured using debugfs, so you'll have

-----------------------------------------------------------------------

Summary of changes:
 labs/kernel-debugging/kernel-debugging.tex         |    5 +++--
 .../kernel-driver-development-debugging.tex        |   12 +++++++-----
 2 files changed, 10 insertions(+), 7 deletions(-)


More information about the training-materials-updates mailing list