gpu: nvgpu: cleanup uapi header includes

With recent rework in nvgpu most of the <uapi/linux/nvgpu.h> includes
are not needed so remove them

Remove use of NVGPU_DBG_GPU_REG_OP_* in gk20a/gr_gk20a.c and use common
definition instead

Remove use of NVGPU_ALLOC_GPFIFO_FLAGS_REPLAYABLE_FAULTS_ENABLE in
gp10b/fifo_gp10b.c by defining new common flag
NVGPU_GPFIFO_FLAGS_REPLAYABLE_FAULTS_ENABLE and then parsing it in API
nvgpu_gpfifo_user_flags_to_common_flags()

Jira NVGPU-363

Change-Id: I8e653275ea3f443f24be7284d54f2115636aba3f
Signed-off-by: Deepak Nibade <dnibade@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1606108
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
Deepak Nibade
2017-11-27 23:53:48 -08:00
committed by mobile promotions
parent ce06f74d6b
commit 830d3f10ca
16 changed files with 6 additions and 24 deletions

View File

@@ -564,6 +564,9 @@ static u32 nvgpu_gpfifo_user_flags_to_common_flags(u32 user_flags)
if (user_flags & NVGPU_ALLOC_GPFIFO_EX_FLAGS_DETERMINISTIC)
flags |= NVGPU_GPFIFO_FLAGS_SUPPORT_DETERMINISTIC;
if (user_flags & NVGPU_ALLOC_GPFIFO_FLAGS_REPLAYABLE_FAULTS_ENABLE)
flags |= NVGPU_GPFIFO_FLAGS_REPLAYABLE_FAULTS_ENABLE;
return flags;
}

View File

@@ -23,7 +23,6 @@
*/
#include <trace/events/gk20a.h>
#include <uapi/linux/nvgpu.h>
#if defined(CONFIG_DEBUG_FS) || defined(CONFIG_GK20A_CYCLE_STATS)
#include <linux/dma-buf.h>

View File

@@ -48,6 +48,7 @@ struct fifo_profile_gk20a;
/* Flags to be passed to gk20a_channel_alloc_gpfifo() */
#define NVGPU_GPFIFO_FLAGS_SUPPORT_VPR (1 << 0)
#define NVGPU_GPFIFO_FLAGS_SUPPORT_DETERMINISTIC (1 << 1)
#define NVGPU_GPFIFO_FLAGS_REPLAYABLE_FAULTS_ENABLE (1 << 2)
/* Flags to be passed to g->ops.gr.alloc_obj_ctx() */
#define NVGPU_OBJ_CTX_FLAGS_SUPPORT_GFXP (1 << 1)

View File

@@ -22,8 +22,6 @@
* DEALINGS IN THE SOFTWARE.
*/
#include <uapi/linux/nvgpu.h>
#include <nvgpu/kmem.h>
#include <nvgpu/log.h>
#include <nvgpu/vm.h>

View File

@@ -23,7 +23,6 @@
*/
#include <trace/events/gk20a.h>
#include <uapi/linux/nvgpu.h>
#include <nvgpu/mm.h>
#include <nvgpu/dma.h>

View File

@@ -23,7 +23,6 @@
*/
#include <trace/events/gk20a.h>
#include <uapi/linux/nvgpu.h>
#include <nvgpu/dma.h>
#include <nvgpu/kmem.h>
@@ -7892,7 +7891,7 @@ int __gr_gk20a_exec_ctx_ops(struct channel_gk20a *ch,
"ctx op invalid offset: offset=0x%x",
ctx_ops[i].offset);
ctx_ops[i].status =
NVGPU_DBG_GPU_REG_OP_STATUS_INVALID_OFFSET;
REGOP(STATUS_INVALID_OFFSET);
continue;
}
if (!pm_ctx_ready) {

View File

@@ -27,7 +27,6 @@
#include <linux/hrtimer.h>
#include <linux/module.h>
#include <nvgpu/lock.h>
#include <uapi/linux/nvgpu.h>
#include <nvgpu/kmem.h>
#include <nvgpu/semaphore.h>

View File

@@ -20,8 +20,6 @@
* DEALINGS IN THE SOFTWARE.
*/
#include <uapi/linux/nvgpu.h>
#include <nvgpu/kmem.h>
#include <nvgpu/log.h>

View File

@@ -22,8 +22,6 @@
* DEALINGS IN THE SOFTWARE.
*/
#include <uapi/linux/nvgpu.h>
#include <nvgpu/kmem.h>
#include <nvgpu/log.h>
#include <nvgpu/enabled.h>

View File

@@ -22,8 +22,6 @@
* DEALINGS IN THE SOFTWARE.
*/
#include <uapi/linux/nvgpu.h>
#include <nvgpu/dma.h>
#include "gk20a/gk20a.h"

View File

@@ -22,8 +22,6 @@
* DEALINGS IN THE SOFTWARE.
*/
#include <uapi/linux/nvgpu.h>
#include <nvgpu/dma.h>
#include <nvgpu/bug.h>
#include <nvgpu/log2.h>
@@ -141,10 +139,9 @@ int channel_gp10b_setup_ramfc(struct channel_gk20a *c,
pbdma_runlist_timeslice_timescale_3_f() |
pbdma_runlist_timeslice_enable_true_f());
if ( flags & NVGPU_ALLOC_GPFIFO_FLAGS_REPLAYABLE_FAULTS_ENABLE)
if (flags & NVGPU_GPFIFO_FLAGS_REPLAYABLE_FAULTS_ENABLE)
gp10b_set_pdb_fault_replay_flags(c->g, mem);
nvgpu_mem_wr32(g, mem, ram_fc_chid_w(), ram_fc_chid_id_f(c->chid));
if (c->is_privileged_channel) {

View File

@@ -24,7 +24,6 @@
#include <dt-bindings/soc/gm20b-fuse.h>
#include <dt-bindings/soc/gp10b-fuse.h>
#include <uapi/linux/nvgpu.h>
#include <nvgpu/timers.h>
#include <nvgpu/kmem.h>

View File

@@ -22,8 +22,6 @@
* DEALINGS IN THE SOFTWARE.
*/
#include <uapi/linux/nvgpu.h>
#include "gk20a/gk20a.h"
#include "gk20a/dbg_gpu_gk20a.h"
#include "gk20a/regops_gk20a.h"

View File

@@ -22,8 +22,6 @@
* DEALINGS IN THE SOFTWARE.
*/
#include <uapi/linux/nvgpu.h>
#include <nvgpu/log.h>
#include "gk20a/gk20a.h"
#include <nvgpu/hw/gv11b/hw_perf_gv11b.h>

View File

@@ -26,7 +26,6 @@
#include <linux/version.h>
#include <linux/vmalloc.h>
#include <linux/tegra_gpu_t19x.h>
#include <uapi/linux/nvgpu.h>
#include <soc/tegra/fuse.h>

View File

@@ -25,7 +25,6 @@
#include <linux/slab.h>
#include <linux/err.h>
#include <linux/bsearch.h>
#include <uapi/linux/nvgpu.h>
#include "gk20a/gk20a.h"
#include "gk20a/dbg_gpu_gk20a.h"