Messages in this thread | | | Subject | Re: [PATCH] lib/vsprintf: add %pT[C012] format specifier | From | Joe Perches <> | Date | Sat, 28 Dec 2013 11:53:25 -0800 |
| |
On Sat, 2013-12-28 at 20:25 +0100, Geert Uytterhoeven wrote: > On Sat, Dec 28, 2013 at 8:25 PM, Andrew Morton > <akpm@linux-foundation.org> wrote: > >> Is any of the "\x" (backslash + character) unused and thus available? > > > > I guess control characters would work. > > > > #define PRINTK_COMM "\001" > > Not that one, cfr. include/linux/kern_levels.h ;-)
yup.
> > #define PRINTK_PID "\002" > > #define PRINTK_TASK_ID "\003" /* "comm:pid" */ > > > > printk(PRINTK_TASK_ID ": hair on fire\n"); > > > > It's certainly compact. I doubt if there's any existing code which > > deliberately prints control chars? > > But the rest looks OK to me.
Tell me again, what's wrong with using p or current?
printk("%pt", current);
| |