[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-devel] [PATCH v2 0/7] Printk symbol specifier



This series implements %ps and %pS, in the same way as Linux.

Changes from v1:
  The first patch has grown to three.  The breakdown is now:

The first two patches refactor string() and pointer() respectivly out of
vsnprintf().  This is just code motion in preparation for the subsequent
patch.

The third patch is the main implementation of %ps and %pS.  With the
refactoring from the first patch, the recursive call to scnprintf in v1 can be
removed.

One inconsistency with the behaviour of print_symbol() is that in the case
that a symbol cant be found, the pointer is printed as per %p, rather than
"???" as before.

Documentation is now provided in docs/misc/printk-formats.txt

The fourth and fifth patches replace all uses of print_symbol() with %ps/%pS,
for x86 and arm respectively.  Most replacements are straight replacements,
but I have taken the opportunity to slightly cleanup the stack tracing code.
When two CPUs are racing at printing a stack, they contend on the console
spinlock, resulting in interleaving across end of the partial strings.  Now,
each full line of the stack trace is printed from a single printk(), so the
interleaving will occur at the line boundaries rather than mid-line
boundaries.

The sixth patch removes print_symbol() and friends, now that the functionality
has been completely replaced.

The seventh patch is not intended for committing, but for people wishing to
test and verify some of the boundary conditions.

Signed-off-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
CC: Keir Fraser <keir@xxxxxxx>
CC: Jan Beulich <JBeulich@xxxxxxxx>
CC: Ian Campbell <ian.campbell@xxxxxxxxxx>
CC: Stefano Stabellini <stefano.stabellini@xxxxxxxxxx>
CC: Tim Deegan <tim@xxxxxxx>

-- 
1.7.10.4


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.