[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <3908561D78D1C84285E8C5FCA982C28F39FD386A@ORSMSX114.amr.corp.intel.com>
Date: Fri, 5 Feb 2016 22:24:05 +0000
From: "Luck, Tony" <tony.luck@...el.com>
To: "Luck, Tony" <tony.luck@...el.com>, Borislav Petkov <bp@...en8.de>
CC: Ingo Molnar <mingo@...nel.org>, "H. Peter Anvin" <hpa@...or.com>,
"Thomas Gleixner" <tglx@...utronix.de>,
Andy Lutomirski <luto@...capital.net>,
"Peter Zijlstra" <peterz@...radead.org>,
Steven Rostedt <rostedt@...dmis.org>,
"Brian Gerst" <brgerst@...il.com>,
lkml <linux-kernel@...r.kernel.org>
Subject: RE: [PATCH -v2] x86: Add an archinfo dumper module
+ show_reg_bits(m, "CR4", cr4_format, cr4);
Can %pXX formats use more than one argument? If so, we might be able to move
all my code to lib/vsprintf.c and just write:
seq_printf(m, "CR4: %pBITS: 0x%lx\n", cr4_format, cr4, cr4);
If they can't, we could bundle the format and value into a structure:
struct printbits {
char *fmt;
u64 val;
};
{
struct printbits p;
p.fmt = cr4_format;
p.val = __read_cr4();
seq_printf(m, "CR4: %pBITS: 0x%lx\n", &p, p.val);
}
-Tony
Powered by blists - more mailing lists