diff options
author | Terje Bergstrom <tbergstrom@nvidia.com> | 2017-06-22 15:55:17 -0400 |
---|---|---|
committer | mobile promotions <svcmobile_promotions@nvidia.com> | 2017-06-30 21:34:59 -0400 |
commit | 001c7c3185d9b087f89f48a41bee27d2d06721f6 (patch) | |
tree | c869be82279688a5dbe5d1145da09ca2323aef92 /drivers/gpu/nvgpu/common/as.c | |
parent | 82c0c96290602b1baf296133c7f55ae1848e433a (diff) |
gpu: nvgpu: Per chip default big page size
Make default big page size query a HAL op instead of per-platform
constant. This allows querying for default big page size without
accessing Linux specific gk20a_platform structure.
JIRA NVGPU-38
Change-Id: Ibfbd1319764fdae5fdb06700fb64d23f6f3dd01a
Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: https://git-master/r/1507928
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Diffstat (limited to 'drivers/gpu/nvgpu/common/as.c')
-rw-r--r-- | drivers/gpu/nvgpu/common/as.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/gpu/nvgpu/common/as.c b/drivers/gpu/nvgpu/common/as.c index 99d18195..0ff5bc6c 100644 --- a/drivers/gpu/nvgpu/common/as.c +++ b/drivers/gpu/nvgpu/common/as.c | |||
@@ -49,8 +49,7 @@ static int gk20a_vm_alloc_share(struct gk20a_as_share *as_share, | |||
49 | gk20a_dbg_fn(""); | 49 | gk20a_dbg_fn(""); |
50 | 50 | ||
51 | if (big_page_size == 0) { | 51 | if (big_page_size == 0) { |
52 | big_page_size = | 52 | big_page_size = g->ops.mm.get_default_big_page_size(); |
53 | gk20a_get_platform(g->dev)->default_big_page_size; | ||
54 | } else { | 53 | } else { |
55 | if (!is_power_of_2(big_page_size)) | 54 | if (!is_power_of_2(big_page_size)) |
56 | return -EINVAL; | 55 | return -EINVAL; |