diff options
author | Srirangan <smadhavan@nvidia.com> | 2018-08-01 03:32:14 -0400 |
---|---|---|
committer | mobile promotions <svcmobile_promotions@nvidia.com> | 2018-08-02 16:56:31 -0400 |
commit | 63e6e8ee3ee9ce01b1f7d4c0014bb589df105d71 (patch) | |
tree | f4db057c93973a9ad4afa15d1c6e5e1f2440c241 /drivers/gpu/nvgpu/common/pmu/pmu_fw.c | |
parent | e6c135ecb70e8b966fc036587301c979ae70e869 (diff) |
gpu: nvgpu: common: Fix MISRA 15.6 violations
This fixes errors due to single statement loop bodies
without braces, which is part of Rule 15.6 of MISRA.
This patch covers in gpu/nvgpu/common/
JIRA NVGPU-989
Change-Id: Ic6a98a1cd04e4524dabf650e2f6e73c6b5a1db9d
Signed-off-by: Srirangan <smadhavan@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1786207
Reviewed-by: svc-misra-checker <svc-misra-checker@nvidia.com>
Reviewed-by: Adeel Raza <araza@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Alex Waterman <alexw@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/common/pmu/pmu_fw.c')
-rw-r--r-- | drivers/gpu/nvgpu/common/pmu/pmu_fw.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/drivers/gpu/nvgpu/common/pmu/pmu_fw.c b/drivers/gpu/nvgpu/common/pmu/pmu_fw.c index 53eae49a..fc328401 100644 --- a/drivers/gpu/nvgpu/common/pmu/pmu_fw.c +++ b/drivers/gpu/nvgpu/common/pmu/pmu_fw.c | |||
@@ -881,8 +881,9 @@ static void get_pmu_init_msg_pmu_queue_params_v4( | |||
881 | queue->index = init->queue_index[tmp_id]; | 881 | queue->index = init->queue_index[tmp_id]; |
882 | queue->size = init->queue_size[tmp_id]; | 882 | queue->size = init->queue_size[tmp_id]; |
883 | if (tmp_id != 0) { | 883 | if (tmp_id != 0) { |
884 | for (i = 0 ; i < tmp_id; i++) | 884 | for (i = 0 ; i < tmp_id; i++) { |
885 | current_ptr += init->queue_size[i]; | 885 | current_ptr += init->queue_size[i]; |
886 | } | ||
886 | } | 887 | } |
887 | queue->offset = init->queue_offset + current_ptr; | 888 | queue->offset = init->queue_offset + current_ptr; |
888 | } | 889 | } |
@@ -908,8 +909,9 @@ static void get_pmu_init_msg_pmu_queue_params_v5( | |||
908 | queue->index = init->queue_index[tmp_id]; | 909 | queue->index = init->queue_index[tmp_id]; |
909 | queue->size = init->queue_size[tmp_id]; | 910 | queue->size = init->queue_size[tmp_id]; |
910 | if (tmp_id != 0) { | 911 | if (tmp_id != 0) { |
911 | for (i = 0 ; i < tmp_id; i++) | 912 | for (i = 0 ; i < tmp_id; i++) { |
912 | current_ptr += init->queue_size[i]; | 913 | current_ptr += init->queue_size[i]; |
914 | } | ||
913 | } | 915 | } |
914 | queue->offset = init->queue_offset + current_ptr; | 916 | queue->offset = init->queue_offset + current_ptr; |
915 | } | 917 | } |
@@ -935,8 +937,9 @@ static void get_pmu_init_msg_pmu_queue_params_v3( | |||
935 | queue->index = init->queue_index[tmp_id]; | 937 | queue->index = init->queue_index[tmp_id]; |
936 | queue->size = init->queue_size[tmp_id]; | 938 | queue->size = init->queue_size[tmp_id]; |
937 | if (tmp_id != 0) { | 939 | if (tmp_id != 0) { |
938 | for (i = 0 ; i < tmp_id; i++) | 940 | for (i = 0 ; i < tmp_id; i++) { |
939 | current_ptr += init->queue_size[i]; | 941 | current_ptr += init->queue_size[i]; |
942 | } | ||
940 | } | 943 | } |
941 | queue->offset = init->queue_offset + current_ptr; | 944 | queue->offset = init->queue_offset + current_ptr; |
942 | } | 945 | } |