]> git.baikalelectronics.ru Git - kernel.git/commit
vsprintf: Add extension %pSR - print_symbol replacement
authorJoe Perches <joe@perches.com>
Wed, 12 Dec 2012 18:18:50 +0000 (10:18 -0800)
committerJiri Kosina <jkosina@suse.cz>
Tue, 30 Apr 2013 20:31:16 +0000 (22:31 +0200)
commit44d0b01260b20bc529a931e127d0515170784c00
tree2acb72d0e39aee019cf8aecc917685b120e506a3
parent4e286ff5e532fdfc0150a2421faa6cfb855a93d9
vsprintf: Add extension %pSR - print_symbol replacement

print_symbol takes a long and converts it to a function
name and offset.  %pS does something similar, but doesn't
translate the address via __builtin_extract_return_addr.
%pSR does the translation.

This will enable replacing multiple calls like
printk(...);
printk_symbol(addr);
printk("\n");
with a single non-interleavable in dmesg
printk("... %pSR\n", (void *)addr);

Update documentation too.

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Documentation/printk-formats.txt
lib/vsprintf.c