drm/i915/perf: replace BUG_ON() with WARN_ON()

Avoid BUG_ON(). Replace with WARN_ON() and early return.

Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20220830093411.1511040-4-jani.nikula@intel.com
This commit is contained in:
Jani Nikula
2022-08-30 12:34:10 +03:00
parent 8482af4bd2
commit 6f10c4d623
+2 -1
View File
@@ -1376,7 +1376,8 @@ static void i915_oa_stream_destroy(struct i915_perf_stream *stream)
{
struct i915_perf *perf = stream->perf;
BUG_ON(stream != perf->exclusive_stream);
if (WARN_ON(stream != perf->exclusive_stream))
return;
/*
* Unset exclusive_stream first, it will be checked while disabling