Messages in this thread | | | Date | Fri, 27 May 2011 12:57:14 -0300 | From | Arnaldo Carvalho de Melo <> | Subject | Re: [tip:perf/urgent] perf symbols: Handle /proc/sys/kernel/kptr_restrict |
| |
Em Fri, May 27, 2011 at 08:46:42AM -0700, Linus Torvalds escreveu: > On Fri, May 27, 2011 at 1:35 AM, Ingo Molnar <mingo@elte.hu> wrote: > > > > I think the biggest problem is that it is yelling at us even when i'm > > root - and root can access all the pointer values just fine: > > Instead of looking at the kptr_restrict file, please just look at the > addresses in the kallsyms file, and if they are all zero, you know > that it's not a usable kallsyms file (and you can pretty much assume > that it's due to kptr_restrict). > > So I think the whole symbol__read_kptr_restrict() thing is just > pointless. Don't do it.
I thought about that, ended up using the file not to rely on the values on kallsyms, too much future proofing, I guess.
BTW, the problem reported by Ingo above (yelling even for root) is not a bug, he ran 'perf record' as non root with kptr_restrict set and then ran 'perf report' as root.
- Arnaldo
| |