Skip to content

Commit 7482a65

Browse files
KatrinJotursulin
authored andcommitted
drm/i915/gem: add missing else
Add missing else in set_proto_ctx_param() to fix coverity issue. Addresses-Coverity: ("Unused value") Fixes: d4433c7 ("drm/i915/gem: Use the proto-context to handle create parameters (v5)") Suggested-by: Tvrtko Ursulin <[email protected]> Signed-off-by: katrinzhou <[email protected]> [tursulin: fixup alignment] Signed-off-by: Tvrtko Ursulin <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
1 parent 14d6a08 commit 7482a65

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

drivers/gpu/drm/i915/gem/i915_gem_context.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -933,8 +933,9 @@ static int set_proto_ctx_param(struct drm_i915_file_private *fpriv,
933933
case I915_CONTEXT_PARAM_PERSISTENCE:
934934
if (args->size)
935935
ret = -EINVAL;
936-
ret = proto_context_set_persistence(fpriv->dev_priv, pc,
937-
args->value);
936+
else
937+
ret = proto_context_set_persistence(fpriv->dev_priv, pc,
938+
args->value);
938939
break;
939940

940941
case I915_CONTEXT_PARAM_PROTECTED_CONTENT:

0 commit comments

Comments
 (0)