diff options
author | Alex Waterman <alexw@nvidia.com> | 2017-11-16 15:56:53 -0500 |
---|---|---|
committer | mobile promotions <svcmobile_promotions@nvidia.com> | 2017-11-17 19:17:20 -0500 |
commit | 35ae4194a05d47aa6d79353428f81f2ca47ce90f (patch) | |
tree | 73c7f15348e1f5deb411392f41e339572b797bb4 /include/uapi/linux | |
parent | b42fb7ba26b565f93118fbdd9e17b42ee6144c5e (diff) |
gpu: nvgpu: Add translation for NVGPU MM flags
Add a translation layer to convert from the NVGPU_AS_* flags to
to new set of NVGPU_VM_MAP_* and NVGPU_VM_AREA_ALLOC_* flags.
This allows the common MM code to not depend on the UAPI header
defined for Linux.
In addition to this change a couple of other small changes were
made:
1. Deprecate, print a warning, and ignore usage of the
NVGPU_AS_MAP_BUFFER_FLAGS_MAPPABLE_COMPBITS flag.
2. Move the t19x IO coherence flag from the t19x UAPI header
to the regular UAPI header.
JIRA NVGPU-293
Change-Id: I146402b0e8617294374e63e78f8826c57cd3b291
Signed-off-by: Alex Waterman <alexw@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1599802
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'include/uapi/linux')
-rw-r--r-- | include/uapi/linux/nvgpu-t19x.h | 6 | ||||
-rw-r--r-- | include/uapi/linux/nvgpu.h | 1 |
2 files changed, 1 insertions, 6 deletions
diff --git a/include/uapi/linux/nvgpu-t19x.h b/include/uapi/linux/nvgpu-t19x.h index 27db97c0..7fb7fc48 100644 --- a/include/uapi/linux/nvgpu-t19x.h +++ b/include/uapi/linux/nvgpu-t19x.h | |||
@@ -29,12 +29,6 @@ | |||
29 | #define NVGPU_GPU_IMPL_GV11B 0x0000000B | 29 | #define NVGPU_GPU_IMPL_GV11B 0x0000000B |
30 | #define NVGPU_GPU_IMPL_GV100 0x00000000 | 30 | #define NVGPU_GPU_IMPL_GV100 0x00000000 |
31 | 31 | ||
32 | /* | ||
33 | * this flag is used in struct nvgpu_as_map_buffer_ex_args | ||
34 | * to provide L3 cache allocation hint | ||
35 | */ | ||
36 | #define NVGPU_AS_MAP_BUFFER_FLAGS_L3_ALLOC (1 << 7) | ||
37 | |||
38 | /* subcontexts are available */ | 32 | /* subcontexts are available */ |
39 | #define NVGPU_GPU_FLAGS_SUPPORT_TSG_SUBCONTEXTS (1ULL << 22) | 33 | #define NVGPU_GPU_FLAGS_SUPPORT_TSG_SUBCONTEXTS (1ULL << 22) |
40 | 34 | ||
diff --git a/include/uapi/linux/nvgpu.h b/include/uapi/linux/nvgpu.h index 20a6de29..bf711ef8 100644 --- a/include/uapi/linux/nvgpu.h +++ b/include/uapi/linux/nvgpu.h | |||
@@ -1762,6 +1762,7 @@ struct nvgpu_as_bind_channel_args { | |||
1762 | #define NVGPU_AS_MAP_BUFFER_FLAGS_IO_COHERENT (1 << 4) | 1762 | #define NVGPU_AS_MAP_BUFFER_FLAGS_IO_COHERENT (1 << 4) |
1763 | #define NVGPU_AS_MAP_BUFFER_FLAGS_UNMAPPED_PTE (1 << 5) | 1763 | #define NVGPU_AS_MAP_BUFFER_FLAGS_UNMAPPED_PTE (1 << 5) |
1764 | #define NVGPU_AS_MAP_BUFFER_FLAGS_MAPPABLE_COMPBITS (1 << 6) | 1764 | #define NVGPU_AS_MAP_BUFFER_FLAGS_MAPPABLE_COMPBITS (1 << 6) |
1765 | #define NVGPU_AS_MAP_BUFFER_FLAGS_L3_ALLOC (1 << 7) | ||
1765 | #define NVGPU_AS_MAP_BUFFER_FLAGS_DIRECT_KIND_CTRL (1 << 8) | 1766 | #define NVGPU_AS_MAP_BUFFER_FLAGS_DIRECT_KIND_CTRL (1 << 8) |
1766 | 1767 | ||
1767 | /* | 1768 | /* |