gpu: nvgpu: move common.unit into common.mc

nvgpu.common.unit was just an enum used for passing to nvgpu.common.mc
APIs. So, move the enum into mc.h, and replace the include of unit.h
with mc.h where appropriate. And update the yaml arch.

JIRA NVGPU-4144

Change-Id: I210ea4d3b49cd494e43add1b52f3fbcdb020a1e3
Signed-off-by: Philip Elcan <pelcan@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/2216106
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
Philip Elcan
2019-10-11 16:43:07 -04:00
committed by Alex Waterman
parent 417e44fb74
commit 06fd513e1e
22 changed files with 24 additions and 66 deletions

View File

@@ -194,11 +194,6 @@ sim:
include/nvgpu/hw_sim_pci.h,
include/nvgpu/sim.h ]
unit:
safe: yes
owner: Terje B
sources: [ include/nvgpu/unit.h ]
utils:
safe: yes
owner: Terje B

View File

@@ -31,7 +31,6 @@
#include <nvgpu/io.h>
#include <nvgpu/utils.h>
#include <nvgpu/channel.h>
#include <nvgpu/unit.h>
#include <nvgpu/gk20a.h>
#include <nvgpu/nvgpu_init.h>
#include <nvgpu/debugger.h>

View File

@@ -23,7 +23,6 @@
#include <nvgpu/gk20a.h>
#include <nvgpu/io.h>
#include <nvgpu/bug.h>
#include <nvgpu/unit.h>
#include <nvgpu/errno.h>
#include <nvgpu/static_analysis.h>
#include <nvgpu/gr/gr.h>
@@ -42,6 +41,7 @@
#include <nvgpu/gr/fecs_trace.h>
#include <nvgpu/power_features/cg.h>
#include <nvgpu/power_features/pg.h>
#include <nvgpu/mc.h>
#include "gr_priv.h"

View File

@@ -35,7 +35,6 @@
#include <nvgpu/utils.h>
#include <nvgpu/gk20a.h>
#include <nvgpu/channel.h>
#include <nvgpu/unit.h>
#include <nvgpu/cyclestats_snapshot.h>
/* check client for pointed perfmon ownership */

View File

@@ -38,8 +38,8 @@
#include <nvgpu/utils.h>
#include <nvgpu/timers.h>
#include <nvgpu/gk20a.h>
#include <nvgpu/unit.h>
#include <nvgpu/firmware.h>
#include <nvgpu/mc.h>
#include "fb_gv100.h"

View File

@@ -26,8 +26,8 @@
#include <nvgpu/io.h>
#include <nvgpu/fifo.h>
#include <nvgpu/gk20a.h>
#include <nvgpu/unit.h>
#include <nvgpu/power_features/cg.h>
#include <nvgpu/mc.h>
#include "hal/fifo/fifo_gk20a.h"

View File

@@ -26,7 +26,6 @@
#include <nvgpu/io.h>
#include <nvgpu/fifo.h>
#include <nvgpu/gk20a.h>
#include <nvgpu/unit.h>
#include <nvgpu/power_features/cg.h>
#include "hal/fifo/fifo_gk20a.h"

View File

@@ -27,9 +27,9 @@
#include <nvgpu/io.h>
#include <nvgpu/fifo.h>
#include <nvgpu/gk20a.h>
#include <nvgpu/unit.h>
#include <nvgpu/power_features/cg.h>
#include <nvgpu/static_analysis.h>
#include <nvgpu/mc.h>
#include <nvgpu/hw/gv11b/hw_fifo_gv11b.h>

View File

@@ -31,7 +31,6 @@
#include <nvgpu/runlist.h>
#include <nvgpu/gk20a.h>
#include <nvgpu/channel.h>
#include <nvgpu/unit.h>
#include <nvgpu/nvgpu_err.h>
#include <nvgpu/pbdma_status.h>
#include <nvgpu/engine_status.h>

View File

@@ -24,7 +24,6 @@
#include <nvgpu/timers.h>
#include <nvgpu/atomic.h>
#include <nvgpu/unit.h>
#include <nvgpu/io.h>
#include <nvgpu/mc.h>
#include <nvgpu/ltc.h>

View File

@@ -24,7 +24,6 @@
#include <nvgpu/timers.h>
#include <nvgpu/atomic.h>
#include <nvgpu/unit.h>
#include <nvgpu/io.h>
#include <nvgpu/mc.h>
#include <nvgpu/ltc.h>

View File

@@ -32,7 +32,6 @@
#include "mc_gp10b.h"
#include <nvgpu/atomic.h>
#include <nvgpu/unit.h>
#include <nvgpu/hw/gp10b/hw_mc_gp10b.h>

View File

@@ -32,7 +32,6 @@
#include "mc_gp10b.h"
#include <nvgpu/atomic.h>
#include <nvgpu/unit.h>
#include <nvgpu/hw/gp10b/hw_mc_gp10b.h>

View File

@@ -26,7 +26,6 @@
#include <nvgpu/io.h>
#include <nvgpu/mc.h>
#include <nvgpu/gk20a.h>
#include <nvgpu/unit.h>
#include <nvgpu/bug.h>
#include <nvgpu/engines.h>

View File

@@ -23,8 +23,8 @@
#include <nvgpu/io.h>
#include <nvgpu/mm.h>
#include <nvgpu/bug.h>
#include <nvgpu/unit.h>
#include <nvgpu/gk20a.h>
#include <nvgpu/mc.h>
#include "perf_gm20b.h"

View File

@@ -23,8 +23,8 @@
#include <nvgpu/io.h>
#include <nvgpu/mm.h>
#include <nvgpu/bug.h>
#include <nvgpu/unit.h>
#include <nvgpu/gk20a.h>
#include <nvgpu/mc.h>
#include "perf_gv11b.h"

View File

@@ -24,12 +24,12 @@
#include <nvgpu/gk20a.h>
#include <nvgpu/pmu.h>
#include <nvgpu/falcon.h>
#include <nvgpu/unit.h>
#include <nvgpu/firmware.h>
#include <nvgpu/pmu/mutex.h>
#include <nvgpu/pmu/fw.h>
#include <nvgpu/pmu/debug.h>
#include <nvgpu/pmu/pmu_pg.h>
#include <nvgpu/mc.h>
#include <nvgpu/hw/gk20a/hw_pwr_gk20a.h>

View File

@@ -28,7 +28,6 @@
#include <nvgpu/runlist.h>
#include <nvgpu/gk20a.h>
#include <nvgpu/channel.h>
#include <nvgpu/unit.h>
#include <nvgpu/types.h>
#include <nvgpu/engine_status.h>
#include <nvgpu/engines.h>

View File

@@ -104,6 +104,7 @@ struct pmu_pg_stats_data;
enum nvgpu_flush_op;
enum gk20a_mem_rw_flag;
enum nvgpu_nvlink_minion_dlcmd;
enum nvgpu_unit;
#include <nvgpu/lock.h>
#include <nvgpu/thread.h>
@@ -129,7 +130,6 @@ enum nvgpu_nvlink_minion_dlcmd;
#include <nvgpu/bios.h>
#include <nvgpu/semaphore.h>
#include <nvgpu/fifo.h>
#include <nvgpu/unit.h>
#include <nvgpu/gops_gr.h>
#include <nvgpu/gops_fifo.h>

View File

@@ -1,5 +1,5 @@
/*
* Copyright (c) 2018, NVIDIA CORPORATION. All rights reserved.
* Copyright (c) 2018-2019, NVIDIA CORPORATION. All rights reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
@@ -27,6 +27,21 @@
struct gk20a;
/**
* Enumeration of all units intended to be used by any HAL that requires
* unit as parameter.
*
* Units are added to the enumeration as needed, so it is not complete.
*/
enum nvgpu_unit {
NVGPU_UNIT_FIFO,
NVGPU_UNIT_PERFMON,
NVGPU_UNIT_GRAPH,
NVGPU_UNIT_BLG,
NVGPU_UNIT_PWR,
NVGPU_UNIT_NVDEC,
};
#define NVGPU_MC_INTR_STALLING 0U
#define NVGPU_MC_INTR_NONSTALLING 1U

View File

@@ -1,41 +0,0 @@
/*
* Copyright (c) 2017-2018, NVIDIA CORPORATION. All rights reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
* and/or sell copies of the Software, and to permit persons to whom the
* Software is furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
* THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
* DEALINGS IN THE SOFTWARE.
*/
#ifndef NVGPU_UNIT_H
#define NVGPU_UNIT_H
/*
* Enumeration of all units intended to be used by any HAL that requires
* unit as parameter.
*
* Units are added to the enumeration as needed, so it is not complete.
*/
enum nvgpu_unit {
NVGPU_UNIT_FIFO,
NVGPU_UNIT_PERFMON,
NVGPU_UNIT_GRAPH,
NVGPU_UNIT_BLG,
NVGPU_UNIT_PWR,
NVGPU_UNIT_NVDEC,
};
#endif /* NVGPU_UNIT_H */

View File

@@ -20,7 +20,6 @@
#include <nvgpu/nvgpu_init.h>
#include <nvgpu/atomic.h>
#include <nvgpu/unit.h>
#include "os_linux.h"
irqreturn_t nvgpu_intr_stall(struct gk20a *g)