From 377e1e8f36c45821f0cf7797fb2f8f20e75b466e Mon Sep 17 00:00:00 2001 From: Divya Singhatwaria Date: Mon, 27 May 2019 14:57:11 +0530 Subject: [PATCH] gpu: nvgpu: Fix MISRA 16.1 violation in BIOS unit - Rule 16.1 states that all switch statements shall be well-formed - "default" case was missing in a switch statement Fix this MISRA violation in this CL. JIRA NVGPU-3546 Change-Id: Iadfbf91c335c564a169263e19d484205f4b35e23 Signed-off-by: Divya Singhatwaria Reviewed-on: https://git-master.nvidia.com/r/2126477 Reviewed-by: svc-mobile-coverity Reviewed-by: svc-mobile-misra Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit Reviewed-by: Deepak Nibade Reviewed-by: mobile promotions Tested-by: mobile promotions --- drivers/gpu/nvgpu/common/vbios/bios.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/nvgpu/common/vbios/bios.c b/drivers/gpu/nvgpu/common/vbios/bios.c index 06a4b6ef7..abd0cdbaf 100644 --- a/drivers/gpu/nvgpu/common/vbios/bios.c +++ b/drivers/gpu/nvgpu/common/vbios/bios.c @@ -142,8 +142,11 @@ struct bit_token *nvgpu_bios_get_bit_token(struct gk20a *g, u8 token_id) case NVGPU_BIOS_VIRT_TOKEN: token = g->bios->virt_token; break; - } + default: + token = NULL; + break; + } return token; }