Re: Ftrace broken on parisc

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 1/29/2014 3:44 PM, Helge Deller wrote:
Hi Guy,

On 01/29/2014 08:59 PM, Guy Martin wrote:
It seems that the ftrace subsystem has not been maintained for a few
years.
Yes.
So far I have the diff at the bottom that attempts to fix it bug there
is still an issue while linking :
I'm not sure I tested 64bit at that time.

arch/parisc/kernel/built-in.o: In function `return_to_handler':
(.text+0xb2a8): undefined reference to `ftrace_return_to_handler'
hppa64-linux-ld: arch/parisc/kernel/built-in.o(.text+0xllx): cannot
reach (null)
arch/parisc/kernel/built-in.o: In function `return_to_handler':
(.text+0xb2a8): relocation truncated to fit: R_PARISC_PCREL17F against
undefined symbol `ftrace_return_to_handler'
make: *** [vmlinux] Error 1

I'm not sure how this can be fixed, the problems comes from the
assembly in entry.S, it uses a 'b' to jump to ftrace_return_to_handler.
I guess 'be' needs to be used but not sure how that'd works with the
linker.
Can you try
BL ftrace_return_to_handler, %r0
(I'm not good in hppa assembly - as you can see if you take a look at this assembly code section :-)).

BL might not reach on PA 1.1. The PA 2.0 b,l instruction is only "long" when the link
register is %rp and it is used for the return_trampoline.

I would say replace "b" with the following as it will always reach target:
        load32  ftrace_return_to_handler, %r20
        bv      %r0(%r20)

%r1 is another register alternative.

Dave

--
John David Anglin    dave.anglin@xxxxxxxx

--
To unsubscribe from this list: send the line "unsubscribe linux-parisc" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux SoC]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux