summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/volt/volt_pmu.c
diff options
context:
space:
mode:
authorSai Nikhil <snikhil@nvidia.com>2018-08-30 04:05:00 -0400
committermobile promotions <svcmobile_promotions@nvidia.com>2018-09-27 02:35:29 -0400
commitd77785800b2ae4c27354500305303c395a18acf4 (patch)
tree1adc96ba310572d8b63dd2284fb801439616a4c1 /drivers/gpu/nvgpu/volt/volt_pmu.c
parent34732a14b22f09d8f9d52f756612178f0313f120 (diff)
gpu: nvgpu: volt: fix MISRA Rule 10.4 Violations
MISRA Rule 10.4 only allows the usage of arithmetic operations on operands of the same essential type category. Adding "U" at the end of the integer literals to have same type of operands when an arithmetic operation is performed. This fixes violation where an arithmetic operation is performed on signed and unsigned int types. JIRA NVGPU-992 Change-Id: Ic9a911beb6d161df950ca85eb4813547603a8743 Signed-off-by: Sai Nikhil <snikhil@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1809751 Reviewed-by: svc-misra-checker <svc-misra-checker@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: Adeel Raza <araza@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/volt/volt_pmu.c')
-rw-r--r--drivers/gpu/nvgpu/volt/volt_pmu.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/nvgpu/volt/volt_pmu.c b/drivers/gpu/nvgpu/volt/volt_pmu.c
index 184aa5d0..2249ae24 100644
--- a/drivers/gpu/nvgpu/volt/volt_pmu.c
+++ b/drivers/gpu/nvgpu/volt/volt_pmu.c
@@ -108,7 +108,7 @@ static u32 volt_pmu_rpc_execute(struct gk20a *g,
108 gk20a_get_gr_idle_timeout(g), 108 gk20a_get_gr_idle_timeout(g),
109 &handler.success, 1); 109 &handler.success, 1);
110 110
111 if (handler.success == 0) { 111 if (handler.success == 0U) {
112 status = -EINVAL; 112 status = -EINVAL;
113 nvgpu_err(g, "rpc call to volt failed"); 113 nvgpu_err(g, "rpc call to volt failed");
114 } 114 }