vsprintf: Add support for userspace strings

From: Richard Weinberger
Date: Sun May 10 2015 - 15:42:30 EST


While debugging issues I often add (trace_)printks to strategic positions.
Dealing with user provided string is complicated as an extra buffer a
copy_from_user() is needed.
This adds a new format string to allow direct printing of such strings.

My initial plan was to use %pU but 'U' is already taken, therefore
I used the next letter which comes in mind when one thinks of userpace,
'L'.
The %pL format string works exactly like %s.

[PATCH 1/2] Fix printk() on ERR_PTR()
[PATCH 2/2] vsprintf: Add support for userspace strings
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/