[FE training-materials-updates] kernel - device model lab - add sysfs exploration

Michael Opdenacker michael.opdenacker at free-electrons.com
Mon Sep 30 09:39:30 CEST 2013


Repository : git://git.free-electrons.com/training-materials.git

On branch  : kernel-ng
Link       : http://git.free-electrons.com/training-materials/commit/?id=7ed044722ef59e359763d44ddb1c79470188fa5d

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

commit 7ed044722ef59e359763d44ddb1c79470188fa5d
Author: Michael Opdenacker <michael.opdenacker at free-electrons.com>
Date:   Sun Sep 29 22:34:46 2013 +0200

    kernel - device model lab - add sysfs exploration
    
    Signed-off-by: Michael Opdenacker <michael.opdenacker at free-electrons.com>


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

7ed044722ef59e359763d44ddb1c79470188fa5d
 .../kernel-i2c-device-model.tex                    |   15 ++++++++++++++-
 1 file changed, 14 insertions(+), 1 deletion(-)

diff --git a/labs/kernel-i2c-device-model/kernel-i2c-device-model.tex b/labs/kernel-i2c-device-model/kernel-i2c-device-model.tex
index 1f92ec1..5099133 100644
--- a/labs/kernel-i2c-device-model/kernel-i2c-device-model.tex
+++ b/labs/kernel-i2c-device-model/kernel-i2c-device-model.tex
@@ -9,7 +9,9 @@ After this lab, you will be able to:
 \begin{itemize}
 \item Add an I2C device to a device tree
 \item Implement basic \code{probe()} and \code{remove()} driver
-functions and make sure that they are called when such a device is added or removed.
+functions and make sure that they are called when there is a
+device/driver match.
+\item Find your driver and device in \code{/sys}
 \end{itemize}
 
 \section{Setup}
@@ -132,3 +134,14 @@ your DT changes in your Linux tree:
 \begin{verbatim}
 git commit -sa 
 \end{verbatim}
+
+\section{Exploring /sys}
+
+Take a little time to explore \code{/sys}:
+
+\begin{itemize}
+\item Find the representation of your driver. That's a way
+      of finding the matching devices.
+\item Find the representation of your device, containing its name.
+      You will find a link to the driver too.
+\end{itemize}



More information about the training-materials-updates mailing list