mirror of
git://nv-tegra.nvidia.com/linux-nvgpu.git
synced 2025-12-24 02:22:34 +03:00
gpu: nvgpu: fix MISRA 5.7 nvgpu.common.unit
MISRA rule 5.7 forbids from re-using tag or identifier names multiple times. Multiple definitions of a tag or identifier may create developer confusion. Currently, enum nvgpu_unit definition is used in gk20a.h as type of function arguments without including unit.h header file. MISRA scanner considered this as two different definitions for the enum. Including correct header file resolves this issue. Jira NVGPU-3307 Change-Id: I824888084632e8897c7c0edcc2b05adfea4a6aff Signed-off-by: Vedashree Vidwans <vvidwans@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2122465 Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
committed by
mobile promotions
parent
8a7770dbe5
commit
12af06ae32
@@ -91,7 +91,6 @@ struct nvgpu_gpfifo_entry;
|
|||||||
struct vm_gk20a_mapping_batch;
|
struct vm_gk20a_mapping_batch;
|
||||||
struct pmu_pg_stats_data;
|
struct pmu_pg_stats_data;
|
||||||
|
|
||||||
enum nvgpu_unit;
|
|
||||||
enum nvgpu_flush_op;
|
enum nvgpu_flush_op;
|
||||||
enum gk20a_mem_rw_flag;
|
enum gk20a_mem_rw_flag;
|
||||||
enum nvgpu_nvlink_minion_dlcmd;
|
enum nvgpu_nvlink_minion_dlcmd;
|
||||||
@@ -120,6 +119,7 @@ enum ctxsw_addr_type;
|
|||||||
#include <nvgpu/worker.h>
|
#include <nvgpu/worker.h>
|
||||||
#include <nvgpu/semaphore.h>
|
#include <nvgpu/semaphore.h>
|
||||||
#include <nvgpu/fifo.h>
|
#include <nvgpu/fifo.h>
|
||||||
|
#include <nvgpu/unit.h>
|
||||||
|
|
||||||
#include "hal/clk/clk_gk20a.h"
|
#include "hal/clk/clk_gk20a.h"
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user