<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/lib/vsprintf.c, branch v2.6.28</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v2.6.28</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v2.6.28'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2008-10-20T16:12:32Z</updated>
<entry>
<title>Implement %pR to print struct resource content</title>
<updated>2008-10-20T16:12:32Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2008-10-20T04:07:34Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=332d2e7834986a9326ec3fa6a91641daef81746c'/>
<id>urn:sha1:332d2e7834986a9326ec3fa6a91641daef81746c</id>
<content type='text'>
Add a %pR option to the kernel vsnprintf that prints the range of
addresses inside a struct resource passed by pointer.

Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Signed-off-by: Benjamin Herrenschmidt &lt;benh@kernel.crashing.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>lib: remove defining macros for strict_strto??</title>
<updated>2008-10-16T21:58:08Z</updated>
<author>
<name>Harvey Harrison</name>
<email>harvey.harrison@gmail.com</email>
</author>
<published>2008-10-16T20:40:35Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=9d85db2244d71fa4f2f9747a090c1920f07a8b4b'/>
<id>urn:sha1:9d85db2244d71fa4f2f9747a090c1920f07a8b4b</id>
<content type='text'>
Open-code them rather than using defining macros.  The function bodies are now
next to their kerneldoc comments as a bonus.

Add casts to the signed cases as they call into the unsigned versions.

Avoids the sparse warnings:
lib/vsprintf.c:249:1: warning: incorrect type in argument 3 (different signedness)
lib/vsprintf.c:249:1:    expected unsigned long *res
lib/vsprintf.c:249:1:    got long *res
lib/vsprintf.c:249:1: warning: incorrect type in argument 3 (different signedness)
lib/vsprintf.c:249:1:    expected unsigned long *res
lib/vsprintf.c:249:1:    got long *res
lib/vsprintf.c:251:1: warning: incorrect type in argument 3 (different signedness)
lib/vsprintf.c:251:1:    expected unsigned long long *res
lib/vsprintf.c:251:1:    got long long *res
lib/vsprintf.c:251:1: warning: incorrect type in argument 3 (different signedness)
lib/vsprintf.c:251:1:    expected unsigned long long *res
lib/vsprintf.c:251:1:    got long long *res

Signed-off-by: Harvey Harrison &lt;harvey.harrison@gmail.com&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>lib: trivial whitespace tidy</title>
<updated>2008-10-16T21:58:07Z</updated>
<author>
<name>Harvey Harrison</name>
<email>harvey.harrison@gmail.com</email>
</author>
<published>2008-10-16T20:40:35Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=22d27051b4b2a2650c54fa3f08c2c271c6234a2f'/>
<id>urn:sha1:22d27051b4b2a2650c54fa3f08c2c271c6234a2f</id>
<content type='text'>
Remove extra lines before the EXPORT_SYMBOL()s

Signed-off-by: Harvey Harrison &lt;harvey.harrison@gmail.com&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>lib: pull base-guessing logic to helper function</title>
<updated>2008-10-16T21:58:07Z</updated>
<author>
<name>Harvey Harrison</name>
<email>harvey.harrison@gmail.com</email>
</author>
<published>2008-10-16T20:40:34Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=aa46a63efc896f0a6d54e7614e750788793582e5'/>
<id>urn:sha1:aa46a63efc896f0a6d54e7614e750788793582e5</id>
<content type='text'>
The default base is 10 unless there is a leading zero, in which
case the base will be guessed as 8.

The base will only be guesed as 16 when the string starts with '0x'
the third character is a valid hex digit.

Signed-off-by: Harvey Harrison &lt;harvey.harrison@gmail.com&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>Add kerneldoc documentation for new printk format extensions</title>
<updated>2008-10-16T18:21:32Z</updated>
<author>
<name>Andi Kleen</name>
<email>andi@firstfloor.org</email>
</author>
<published>2008-10-16T05:02:02Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=20036fdcaf05fac0a84ed81a56906493a7d822e2'/>
<id>urn:sha1:20036fdcaf05fac0a84ed81a56906493a7d822e2</id>
<content type='text'>
Add documentation in kerneldoc for new printk format extensions

This patch documents the new %pS/%pF options in printk in kernel doc.

Hope I didn't miss any other extension.

Signed-off-by: Andi Kleen &lt;ak@linux.intel.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>lib: Correct printk %pF to work on all architectures</title>
<updated>2008-09-09T18:51:15Z</updated>
<author>
<name>James Bottomley</name>
<email>James.Bottomley@HansenPartnership.com</email>
</author>
<published>2008-09-04T01:43:36Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=deac93df26b20cf8438339b5935b5f5643bc30c9'/>
<id>urn:sha1:deac93df26b20cf8438339b5935b5f5643bc30c9</id>
<content type='text'>
It was introduced by "vsprintf: add support for '%pS' and '%pF' pointer
formats" in commit 0fe1ef24f7bd0020f29ffe287dfdb9ead33ca0b2.  However,
the current way its coded doesn't work on parisc64.  For two reasons: 1)
parisc isn't in the #ifdef and 2) parisc has a different format for
function descriptors

Make dereference_function_descriptor() more accommodating by allowing
architecture overrides.  I put the three overrides (for parisc64, ppc64
and ia64) in arch/kernel/module.c because that's where the kernel
internal linker which knows how to deal with function descriptors sits.

Signed-off-by: James Bottomley &lt;James.Bottomley@HansenPartnership.com&gt;
Acked-by: Benjamin Herrenschmidt &lt;benh@kernel.crashing.org&gt;
Acked-by: Tony Luck &lt;tony.luck@intel.com&gt;
Acked-by: Kyle McMartin &lt;kyle@mcmartin.ca&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>lib/vsprintf.c: wrong conversion function used</title>
<updated>2008-08-12T23:07:29Z</updated>
<author>
<name>Yi Yang</name>
<email>yi.y.yang@intel.com</email>
</author>
<published>2008-08-12T22:08:58Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=29a6d39bf3a890ad1d29e66baa9f4bc8d9334f3a'/>
<id>urn:sha1:29a6d39bf3a890ad1d29e66baa9f4bc8d9334f3a</id>
<content type='text'>
Fix wrong conversion function used by strict_strtou*

Signed-off-by: Yi Yang &lt;yi.y.yang@intel.com&gt;
Reported-by: Swen Schillig &lt;swen@vnet.ibm.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>vsprintf: add support for '%pS' and '%pF' pointer formats</title>
<updated>2008-07-06T23:55:51Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2008-07-06T23:43:12Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=0fe1ef24f7bd0020f29ffe287dfdb9ead33ca0b2'/>
<id>urn:sha1:0fe1ef24f7bd0020f29ffe287dfdb9ead33ca0b2</id>
<content type='text'>
They print out a pointer in symbolic format, if possible (ie using
symbolic KALLSYMS information).  The '%pS' format is for regular direct
pointers (which can point to data or code and that you find on the stack
during backtraces etc), while '%pF' is for C function pointer types.

On most architectures, the two mean exactly the same thing, but some
architectures use an indirect pointer for C function pointers, where the
function pointer points to a function descriptor (which in turn contains
the actual pointer to the code).  The '%pF' code automatically does the
appropriate function descriptor dereference on such architectures.

Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>vsprintf: add infrastructure support for extended '%p' specifiers</title>
<updated>2008-07-06T23:24:57Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2008-07-06T23:24:57Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=4d8a743cdd2690c0bc8d1b8cbd02cffb1ead849f'/>
<id>urn:sha1:4d8a743cdd2690c0bc8d1b8cbd02cffb1ead849f</id>
<content type='text'>
This expands the kernel '%p' handling with an arbitrary alphanumberic
specifier extension string immediately following the '%p'.  Right now
it's just being ignored, but the next commit will start adding some
specific pointer type extensions.

NOTE! The reason the extension is appended to the '%p' is to allow
minimal gcc type checking: gcc will still see the '%p' and will check
that the argument passed in is indeed a pointer, and yet will not
complain about the extended information that gcc doesn't understand
about (on the other hand, it also won't actually check that the pointer
type and the extension are compatible).

Alphanumeric characters were chosen because there is no sane existing
use for a string format with a hex pointer representation immediately
followed by alphanumerics (which is what such a format string would have
traditionally resulted in).

Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>vsprintf: split out '%p' handling logic</title>
<updated>2008-07-06T23:16:15Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2008-07-06T23:16:15Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=78a8bf69b32980879975f7e31d30386c50bfe851'/>
<id>urn:sha1:78a8bf69b32980879975f7e31d30386c50bfe851</id>
<content type='text'>
The actual code is the same, just split out into a helper function.
This makes it easier to read, and allows for simple future extension
of %p handling.

Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
</feed>
