summaryrefslogtreecommitdiff
path: root/drivers/gpu
diff options
context:
space:
mode:
authorColin Ian King <colin.king@canonical.com>2020-06-10 12:58:04 +0100
committerThomas Zimmermann <tzimmermann@suse.de>2020-06-11 09:05:31 +0200
commit291ddeb621e4a9f1ced8302a777fbd7fbda058c6 (patch)
treeab9132e3a6a63df4f5fc9c45abf66bd51bd5da41 /drivers/gpu
parent54e1e06bcf1cf6e7ac3f86daa5f7454add24b494 (diff)
drm/ast: fix missing break in switch statement for format->cpp[0] case 4
Currently the switch statement for format->cpp[0] value 4 assigns color_index which is never read again and then falls through to the default case and returns. This looks like a missing break statement bug. Fix this by adding a break statement. Addresses-Coverity: ("Unused value") Fixes: 259d14a76a27 ("drm/ast: Split ast_set_vbios_mode_info()") Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Tested-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de> Link: https://patchwork.freedesktop.org/patch/msgid/20200610115804.1132338-1-colin.king@canonical.com
Diffstat (limited to 'drivers/gpu')
-rw-r--r--drivers/gpu/drm/ast/ast_mode.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gpu/drm/ast/ast_mode.c b/drivers/gpu/drm/ast/ast_mode.c
index 7d39b858c9f1..3a3a511670c9 100644
--- a/drivers/gpu/drm/ast/ast_mode.c
+++ b/drivers/gpu/drm/ast/ast_mode.c
@@ -226,6 +226,7 @@ static void ast_set_vbios_color_reg(struct ast_private *ast,
case 3:
case 4:
color_index = TrueCModeIndex;
+ break;
default:
return;
}