summaryrefslogtreecommitdiffstats
path: root/Documentation/printk-formats.txt
diff options
context:
space:
mode:
authorHelge Deller <deller@gmx.de>2017-08-23 21:52:05 +0200
committerHelge Deller <deller@gmx.de>2017-08-24 18:49:52 +0200
commitfd46cd55fbc5a8e8c180ee04a30cda26c84569d2 (patch)
tree6048f617297f2689e5d21584c0e1cf0a5b3ed1c5 /Documentation/printk-formats.txt
parentd81f734462d439291531266c4004ab97e9a033cc (diff)
downloadop-kernel-dev-fd46cd55fbc5a8e8c180ee04a30cda26c84569d2.zip
op-kernel-dev-fd46cd55fbc5a8e8c180ee04a30cda26c84569d2.tar.gz
printk-formats.txt: Add examples for %pF and %pS usage
Signed-off-by: Helge Deller <deller@gmx.de> Signed-off-by: Petr Mladek <pmladek@suse.com> Reviewed-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com> Acked-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Diffstat (limited to 'Documentation/printk-formats.txt')
-rw-r--r--Documentation/printk-formats.txt10
1 files changed, 10 insertions, 0 deletions
diff --git a/Documentation/printk-formats.txt b/Documentation/printk-formats.txt
index 074670b..361789d 100644
--- a/Documentation/printk-formats.txt
+++ b/Documentation/printk-formats.txt
@@ -75,6 +75,16 @@ used when printing stack backtraces. The specifier takes into
consideration the effect of compiler optimisations which may occur
when tail-call``s are used and marked with the noreturn GCC attribute.
+Examples::
+
+ printk("Going to call: %pF\n", gettimeofday);
+ printk("Going to call: %pF\n", p->func);
+ printk("%s: called from %pS\n", __func__, (void *)_RET_IP_);
+ printk("%s: called from %pS\n", __func__,
+ (void *)__builtin_return_address(0));
+ printk("Faulted at %pS\n", (void *)regs->ip);
+ printk(" %s%pB\n", (reliable ? "" : "? "), (void *)*stack);
+
Kernel Pointers
===============
OpenPOWER on IntegriCloud