Skip to content
Commit 00f8c6dc authored by Namhyung Kim's avatar Namhyung Kim Committed by Greg Kroah-Hartman
Browse files

perf/core: Add a new read format to get a number of lost samples



[ Upstream commit 119a784c ]

Sometimes we want to know an accurate number of samples even if it's
lost.  Currenlty PERF_RECORD_LOST is generated for a ring-buffer which
might be shared with other events.  So it's hard to know per-event
lost count.

Add event->lost_samples field and PERF_FORMAT_LOST to retrieve it from
userspace.

Original-patch-by: default avatarJiri Olsa <jolsa@redhat.com>
Signed-off-by: default avatarNamhyung Kim <namhyung@kernel.org>
Signed-off-by: default avatarPeter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lkml.kernel.org/r/20220616180623.1358843-1-namhyung@kernel.org


Stable-dep-of: 382c27f4 ("perf: Fix perf_event_validate_size()")
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent 4aed5240
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment