drm/i915/perf: Consider OA buffer boundary when zeroing out reports
authorUmesh Nerlige Ramappa <umesh.nerlige.ramappa@intel.com>
Fri, 16 Jun 2023 17:34:02 +0000 (10:34 -0700)
committerAshutosh Dixit <ashutosh.dixit@intel.com>
Fri, 7 Jul 2023 22:15:45 +0000 (15:15 -0700)
commit40b1588a750240cbe8a83117aa785d778749a77c
tree65f7c4397311549d51c3cc2de06c808118cff31a
parenta8c94b3964c59408f531ce819f13f0209695db7f
drm/i915/perf: Consider OA buffer boundary when zeroing out reports

For reports that are not powers of 2, reports at the end of the OA
buffer may get split across the buffer boundary. When zeroing out such
reports, take the split into consideration.

v2: Use OA_BUFFER_SIZE (Ashutosh)

Fixes: 09a36015d9a0 ("drm/i915/perf: Clear out entire reports after reading if not power of 2 size")
Signed-off-by: Umesh Nerlige Ramappa <umesh.nerlige.ramappa@intel.com>
Reviewed-by: Ashutosh Dixit <ashutosh.dixit@intel.com>
Signed-off-by: Ashutosh Dixit <ashutosh.dixit@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20230616173402.699776-1-umesh.nerlige.ramappa@intel.com
drivers/gpu/drm/i915/i915_perf.c