Re: [PATCH 03/15] x86/split_lock: Handle #AC exception for split lock in kernel mode
From: Luck, Tony
Date: Tue May 15 2018 - 13:41:30 EST
On Tue, May 15, 2018 at 08:51:24AM -0700, Dave Hansen wrote:
> > + pr_info_ratelimited("Alignment check for split lock at %lx\n", address);
>
> This is a potential KASLR bypass, I believe. We shouldn't be printing
> raw kernel addresses.
>
> We have some nice printk's for page faults that give you kernel symbols.
> Could you copy one of those?
It's not really all that useful to print the address of the split lock
itself. It's probably in something that was kmalloc()'d. Users will
probably want to see the address of the instruction so they know which
function to go and debug. Print that with %pF
-Tony