summaryrefslogtreecommitdiff
path: root/Documentation/printk-formats.txt
AgeCommit message (Collapse)Author
2013-04-30Merge branch 'for-linus' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial Pull fixup for trivial branch from Jiri Kosina: "Unfortunately I made a mistake when merging into for-linus branch, and omitted one pre-requisity patch for a few other patches (which have been Acked by the appropriate maintainers) in the series. Mea culpa maxima, sorry for that." The trivial branch added %pSR usage before actually teaching vsnprintf() about the 'R' part of %pSR. The 'R' causes the symbol translation to do a "__builtin_extract_return_addr()" before symbol lookup. That said, on most architectures __builtin_extract_return_addr() isn't likely to do anything special, so it probably is not normally noticeable. * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial: vsprintf: Add extension %pSR - print_symbol replacement
2013-04-30vsprintf: Add extension %pSR - print_symbol replacementJoe Perches
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>
2013-03-08Randy has movedRandy Dunlap
Update email address and CREDITS info. xenotime.net is defunct. Signed-off-by: Randy Dunlap <rdunlap@infradead.org> Cc: Harry Wei <harryxiyou@gmail.com> Cc: Keiichi KII <k-keiichi@bx.jp.nec.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2013-02-21lib/vsprintf.c: add %pa format specifier for phys_addr_t typesStepan Moskovchenko
Add the %pa format specifier for printing a phys_addr_t type and its derivative types (such as resource_size_t), since the physical address size on some platforms can vary based on build options, regardless of the native integer type. Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org> Cc: Rob Landley <rob@landley.net> Cc: George Spelvin <linux@horizon.com> Cc: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Cc: Stephen Boyd <sboyd@codeaurora.org> Cc: Andrei Emeltchenko <andrei.emeltchenko@intel.com> Cc: Ingo Molnar <mingo@elte.hu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2012-10-06lib/vsprintf: update documentation to cover all of %p[Mm][FR]Andy Shevchenko
Acked-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2012-07-30vsprintf: add support of '%*ph[CDN]'Andy Shevchenko
There are many places in the kernel where the drivers print small buffers as a hex string. This patch adds a support of the variable width buffer to print it as a hex string with a delimiter. The idea came from Pavel Roskin here: http://www.digipedia.pl/usenet/thread/18835/17449/ Sample output of pr_info("buf[%d:%d] %*phC\n", from, len, len, &buf[from]); could be look like this: [ 0.726130] buf[51:8] e8:16:b6:ef:e3:74:45:6e [ 0.750736] buf[59:15] 31:81:b8:3f:35:49:06:ae:df:32:06:05:4a:af:55 [ 0.757602] buf[17:5] ac:16:d5:2c:ef Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Cc: Joe Perches <joe@perches.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2012-07-30vsprintf: add %pMR for Bluetooth MAC addressAndrei Emeltchenko
Bluetooth uses mostly LE byte order which is reversed for visual interpretation. Currently in Bluetooth in use unsafe batostr function. This is a slightly modified version of Joe's patch (sent Sat, Dec 4, 2010). Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com> Cc: Joe Perches <joe@perches.com> Cc: Marcel Holtmann <marcel@holtmann.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2011-06-15Documentation: update printk-formats.txtAndrew Murray
This patch updates the incomplete documentation concerning the printk extended format specifiers. Signed-off-by: Andrew Murray <amurray@mpc-data.co.uk> Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-11-12DOC: add printk-formats.txtRandy Dunlap
Add printk-formats.txt so that we don't have to keep fixing the same things over and over again. <wishful thinking> Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com> Cc: Alexey Dobriyan <adobriyan@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>