perf probe: Ensure offset provided is not greater than function length
perf probe: Ensure offset provided is not greater than function length

The perf probe command allows kprobe to be inserted at any offset from a
function start, which results in adding kprobes to unintended location.

Example: perf probe do_fork+10000 is allowed even though size of do_fork
is ~904.

This patch will ensure probe addition fails when the offset specified is
greater than size of the function.

Acked-by: Masami Hiramatsu <60fcdccfd958d359debfe6e6e7417cd7f1aaa9e3@hitachi.com>
Cc: Ananth N Mavinakayanahalli <7dc108d19a2513f6455353af182b9e4d3b794ec9@in.ibm.com>
Cc: Srikar Dronamraju <1f69195f6d934d4caf5816234bde319316df237e@linux.vnet.ibm.com>
Cc: Steven Rostedt <43232e92d70cc7aa53504ad0397085ee47bad87f@goodmis.org>
Cc: Andrew Morton <5c1e68b099950c134891f0b6e179498a8ebe9cf9@linux-foundation.org>
Cc: Jason Baron <af9bd1db766a43cb09b647251c97dbddcd2e59dc@redhat.com>
Cc: Masami Hiramatsu <60fcdccfd958d359debfe6e6e7417cd7f1aaa9e3@hitachi.com>
Link: 7b79f505a3ddae1bc88b332350625cd5c24d76e8@linux.vnet.ibm.com
Signed-off-by: Prashanth Nageshappa <6a61c43b7476ff565122832d0742acbf483e358a@linux.vnet.ibm.com>
Signed-off-by: Arnaldo Carvalho de Melo <293abb6b76d7791c0732cc517d38c4b5c734b87f@redhat.com>

TeamVee-Kanas/android_kernel_samsung_kanas,TeamVee-Kanas/android_kernel_samsung_kanas,KristFoundation/Programs,KristFoundation/Programs,TeamVee-Kanas/android_kernel_samsung_kanas,KristFoundation/Programs,TeamVee-Kanas/android_kernel_samsung_kanas,KristFoundation/Programs,TeamVee-Kanas/android_kernel_samsung_kanas,KristFoundation/Programs,KristFoundation/Programs