FTrace on MPC8xx

Stefan Roese ml at stefan-roese.de
Fri Apr 15 17:22:42 EST 2011


Hi Joakim,

On Thursday 14 April 2011 21:21:23 Joakim Tjernlund wrote:
> > hmm, I guess 8xx really maps kernel RO as RO :) Try
> > 
> > changing in pte-8xx.h:
> >  - #define _PAGE_KERNEL_RO   (_PAGE_SHARED)
> >  + #define _PAGE_KERNEL_RO   (_PAGE_RW |_PAGE_SHARED)
> 
> hmm, I wonder if not this is the problem(in pte-common.h)
> #if defined(CONFIG_KGDB) || defined(CONFIG_XMON) ||
> defined(CONFIG_BDI_SWITCH) ||\ defined(CONFIG_KPROBES)
> #define PAGE_KERNEL_TEXT	PAGE_KERNEL_X
> #else
> #define PAGE_KERNEL_TEXT	PAGE_KERNEL_ROX
> #endif
> 
> What is PAGE_KERNEL_TEXT for you?
> I think it must be PAGE_KERNEL_X, otherwise kernel text will be readonly.

Yes, that's it! Its PAGE_KERNEL_ROX right now. We need to add CONFIG_FTRACE or 
at least CONFIG_DYNAMIC_FTRACE to the #if statement above.

Do you want to send a patch (since you detected the real problem)? Or should I 
do this?

Thanks.

Best regards,
Stefan


More information about the Linuxppc-dev mailing list