trace_uprobe: support reference counter in fd-based uprobe

This patch enables uprobes with reference counter in fd-based uprobe.
Highest 32 bits of perf_event_attr.config is used to stored offset
of the reference count (semaphore).

Format information in /sys/bus/event_source/devices/uprobe/format/ is
updated to reflect this new feature.

Link: http://lkml.kernel.org/r/[email protected]

Cc: Oleg Nesterov <[email protected]>
Acked-by: Peter Zijlstra (Intel) <[email protected]>
Reviewed-and-tested-by: Ravi Bangoria <[email protected]>
Signed-off-by: Song Liu <[email protected]>
Signed-off-by: Steven Rostedt (VMware) <[email protected]>
(cherry picked from commit a6ca88b241d5e929e6e60b12ad8cd288f0ffa256)
Signed-off-by: Roy Yang <[email protected]>

BUG=b:126232850
TEST=Build, manual
SOURCE=UPSTREAM(a6ca88b241d5e929e6e60b12ad8cd288f0ffa256)

Change-Id: I8f189d0b28e9c6f32703180bc35b4155630e5c79
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/lakitu-kernel/+/2045032
Commit-Queue: Roy Yang <[email protected]>
Tested-by: Roy Yang <[email protected]>
Reviewed-by: Vaibhav Rustagi <[email protected]>
5 files changed