Re: [PATCH v2] tracing: Add test for user space strings when filtering on string pointers
From: Steven Rostedt
Date: Thu Jan 13 2022 - 16:51:22 EST
On Thu, 13 Jan 2022 22:28:01 +0100
Sven Schnelle <svens@xxxxxxxxxxxxx> wrote:
>
> Hmm, i don't see how. On s390, TASK_SIZE is -PAGE_SIZE, which means
> 0xfffffffffffff000 so i think the if() condition below is always true.
Yes, I did that to just use the kernel version and not the user space one.
This is just a workaround for now.
>
> Too bad that the __user attribute is stripped during a normal compile.
> But couldn't we add the information whether a pointer belongs to user
> or kernel space in the trace event definition? For syscall tracing it's
> easy, because pointer types in SYSCALL_DEFINE() and friends are always
> userspace pointers?
We could add something later. As it is currently the merge window, and this
is a real bug, I'm going to just leave it as is, and we can work to fix the
other archs later. I need to get a pull request ready by tomorrow.
-- Steve