[bootlin/training-materials updates] master: kernel: serial: Fix a build warning (c87c070b)

Miquel Raynal miquel.raynal at bootlin.com
Fri May 7 12:01:42 CEST 2021

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


commit c87c070b21b3708609cfa327baf67b58985336ad
Author: Miquel Raynal <miquel.raynal at bootlin.com>
Date:   Fri May 7 11:55:34 2021 +0200

    kernel: serial: Fix a build warning
    This has been solved in the labs already.
    Signed-off-by: Miquel Raynal <miquel.raynal at bootlin.com>


 labs/kernel-serial-output/kernel-serial-output.tex | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/labs/kernel-serial-output/kernel-serial-output.tex b/labs/kernel-serial-output/kernel-serial-output.tex
index f14f838b..dbe7e62c 100644
--- a/labs/kernel-serial-output/kernel-serial-output.tex
+++ b/labs/kernel-serial-output/kernel-serial-output.tex
@@ -63,8 +63,7 @@ for each found device:
 \item To get an automatically assigned minor number.
 \item To specify a name for the device file in {\em devtmpfs}. We
-  propose to use {\tt devm\_kasprintf(\&pdev->dev, GFP\_KERNEL,
-  "serial-\%x", platform\_get\_resource(pdev, IORESOURCE\_MEM, 0)->start)}.
+  "serial-\%llx", platform\_get\_resource(pdev, IORESOURCE\_MEM, 0)->start)}.
   \kfunc{devm_kasprintf} allocates a buffer and runs \kfunc{kasprintf}
   to fill its contents. \kfunc{platform_get_resource} is used to
   retrieve the device physical address from the device tree.

More information about the training-materials-updates mailing list