diff options
author | Alex Waterman <alexw@nvidia.com> | 2017-04-10 17:03:16 -0400 |
---|---|---|
committer | mobile promotions <svcmobile_promotions@nvidia.com> | 2017-04-25 17:26:00 -0400 |
commit | 5714f5eaaf4715c9989e5c2bf732cdb9136b0fbe (patch) | |
tree | 65164fc80979817ae2a65ba20a0c9f1c8781f668 /drivers/gpu/nvgpu/include | |
parent | 126c735d3015f515bde9f26d10b4e34d6e194e36 (diff) |
gpu: nvgpu: Remove bools from nvgpu_mem
Replace a couple of boolean fields in nvgpu_mem with bits in a
bitmap introduced in an earlier patch.
JIRA NVGPU-12
JIRA NVGPU-30
Change-Id: Iffc31bd629cab9a37e5a4fd13377eb9090353410
Signed-off-by: Alex Waterman <alexw@nvidia.com>
Reviewed-on: http://git-master/r/1464079
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-by: svccoveritychecker <svccoveritychecker@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/include')
-rw-r--r-- | drivers/gpu/nvgpu/include/nvgpu/nvgpu_mem.h | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/drivers/gpu/nvgpu/include/nvgpu/nvgpu_mem.h b/drivers/gpu/nvgpu/include/nvgpu/nvgpu_mem.h index 397e9ab1..b01fbec5 100644 --- a/drivers/gpu/nvgpu/include/nvgpu/nvgpu_mem.h +++ b/drivers/gpu/nvgpu/include/nvgpu/nvgpu_mem.h | |||
@@ -53,6 +53,21 @@ struct nvgpu_mem { | |||
53 | * the struct is just a copy of another nvgpu_mem struct. | 53 | * the struct is just a copy of another nvgpu_mem struct. |
54 | */ | 54 | */ |
55 | #define NVGPU_MEM_FLAG_SHADOW_COPY (1 << 0) | 55 | #define NVGPU_MEM_FLAG_SHADOW_COPY (1 << 0) |
56 | |||
57 | /* | ||
58 | * Specify that the GVA mapping is a fixed mapping - that is the caller | ||
59 | * chose the GPU VA, not the GMMU mapping function. Only relevant for | ||
60 | * VIDMEM. | ||
61 | */ | ||
62 | #define NVGPU_MEM_FLAG_FIXED (1 << 1) | ||
63 | |||
64 | /* | ||
65 | * Set for user generated VIDMEM allocations. This triggers a special | ||
66 | * cleanup path that clears the vidmem on free. Given that the VIDMEM is | ||
67 | * zeroed on boot this means that all user vidmem allocations are | ||
68 | * therefor zeroed (to prevent leaking information in VIDMEM buffers). | ||
69 | */ | ||
70 | #define NVGPU_MEM_FLAG_USER_MEM (1 << 2) | ||
56 | unsigned long mem_flags; | 71 | unsigned long mem_flags; |
57 | 72 | ||
58 | /* | 73 | /* |
@@ -63,8 +78,6 @@ struct nvgpu_mem { | |||
63 | /* | 78 | /* |
64 | * Fields only populated for vidmem allocations. | 79 | * Fields only populated for vidmem allocations. |
65 | */ | 80 | */ |
66 | bool fixed; | ||
67 | bool user_mem; | ||
68 | struct nvgpu_allocator *allocator; | 81 | struct nvgpu_allocator *allocator; |
69 | struct nvgpu_list_node clear_list_entry; | 82 | struct nvgpu_list_node clear_list_entry; |
70 | 83 | ||