[bootlin/training-materials updates] master: kernel-dma: Save the struct device to simplify the code (f3944ba9)
Miquel Raynal
miquel.raynal at bootlin.com
Thu Jul 27 19:59:53 CEST 2023
Repository : https://github.com/bootlin/training-materials
On branch : master
Link : https://github.com/bootlin/training-materials/commit/f3944ba9f618d7e2767ffe72e211f44a95794d2d
>---------------------------------------------------------------
commit f3944ba9f618d7e2767ffe72e211f44a95794d2d
Author: Miquel Raynal <miquel.raynal at bootlin.com>
Date: Thu Jul 27 19:57:20 2023 +0200
kernel-dma: Save the struct device to simplify the code
Signed-off-by: Miquel Raynal <miquel.raynal at bootlin.com>
>---------------------------------------------------------------
f3944ba9f618d7e2767ffe72e211f44a95794d2d
labs/kernel-serial-dma/kernel-serial-dma.tex | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/labs/kernel-serial-dma/kernel-serial-dma.tex b/labs/kernel-serial-dma/kernel-serial-dma.tex
index 6b7515db..42bce2ae 100644
--- a/labs/kernel-serial-dma/kernel-serial-dma.tex
+++ b/labs/kernel-serial-dma/kernel-serial-dma.tex
@@ -26,7 +26,11 @@ buffer named \code{tx_buf} of the same size as \code{rx_buf} in our
As we will also need the \code{resource} structure with the MMIO physical
addresses from outside of the \code{->probe()}, it might be relevant to save
the \code{resource} pointer used to derive the \code{miscdev} name into the
-\code{serial_dev} structure as well.
+\code{serial_dev} structure.
+
+Finally, the device-model \code{struct device *} contained in the
+platform device will soon be very useful as well, so we can save it in
+our \code{struct serial_dev *} object.
Before going further, re-compile and test your driver.
More information about the training-materials-updates
mailing list