diff options
author | Alex Waterman <alexw@nvidia.com> | 2016-07-21 16:46:44 -0400 |
---|---|---|
committer | Alex Waterman <alexw@nvidia.com> | 2016-07-22 14:24:12 -0400 |
commit | 7a2e30267bdb9ab2ff15a1e9d7e57bb7ea9bd3a3 (patch) | |
tree | 4175aa989b8d15ced3e672e14d989a44688bc3ad /drivers/gpu/nvgpu/gk20a/buddy_allocator_priv.h | |
parent | b2a86525278423b60797bb25b3bd89aeefba77d4 (diff) |
gpu: nvgpu: Use consistent definition for PTE size
In the buddy allocator the BALLOC_PTE_SIZE_* macros are inconsistent
with the gmmu_page_size_* enum. This patch makes the buddy allocator
use the gmmu_page_size_* fields and now has only BALLOC_PTE_SIZE_ANY
for when the allocator does not care about PTE size.
Change-Id: Idbe727b8208e1ace2b947d67f698c471782d5587
Signed-off-by: Alex Waterman <alexw@nvidia.com>
Reviewed-on: http://git-master/r/1185136
Reviewed-by: Konsta Holtta <kholtta@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Yu-Huan Hsu <yhsu@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a/buddy_allocator_priv.h')
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/buddy_allocator_priv.h | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/buddy_allocator_priv.h b/drivers/gpu/nvgpu/gk20a/buddy_allocator_priv.h index 55de9bc9..1a6aed48 100644 --- a/drivers/gpu/nvgpu/gk20a/buddy_allocator_priv.h +++ b/drivers/gpu/nvgpu/gk20a/buddy_allocator_priv.h | |||
@@ -46,11 +46,10 @@ struct gk20a_buddy { | |||
46 | 46 | ||
47 | /* | 47 | /* |
48 | * Size of the PDE this buddy is using. This allows for grouping like | 48 | * Size of the PDE this buddy is using. This allows for grouping like |
49 | * sized allocations into the same PDE. | 49 | * sized allocations into the same PDE. This uses the gmmu_pgsz_gk20a |
50 | * enum except for the BALLOC_PTE_SIZE_ANY specifier. | ||
50 | */ | 51 | */ |
51 | #define BALLOC_PTE_SIZE_ANY 0x0 | 52 | #define BALLOC_PTE_SIZE_ANY -1 |
52 | #define BALLOC_PTE_SIZE_SMALL 0x1 | ||
53 | #define BALLOC_PTE_SIZE_BIG 0x2 | ||
54 | int pte_size; | 53 | int pte_size; |
55 | }; | 54 | }; |
56 | 55 | ||