gpu: nvgpu: skip secure_alloc for pre-silicon

Skip secure memory alloc for all pre-silicon platforms.
If vpr support is added in future for any of pre-slicon
platforms, then modify check for sec_alloc as per requirement.

Jira NVGPU-5521

Change-Id: I15bebe8719436c689abfbbf5422722ea750800ec
Signed-off-by: Seshendra Gadagottu <sgadagottu@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2367627
Reviewed-by: automaticguardword <automaticguardword@nvidia.com>
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Alex Waterman <alexw@nvidia.com>
Reviewed-by: Seema Khowala <seemaj@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
GVS: Gerrit_Virtual_Submit
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
Seshendra Gadagottu
2020-06-26 20:37:16 -07:00
committed by Alex Waterman
parent 78118bb1c6
commit 80fec3f699

View File

@@ -659,8 +659,11 @@ int gk20a_tegra_init_secure_alloc(struct gk20a_platform *platform)
struct secure_page_buffer *secure_buffer = &platform->secure_buffer;
dma_addr_t iova;
if (nvgpu_is_enabled(g, NVGPU_IS_FMODEL))
/* VPR is not supported on pre-silicon platforms - Jira NVGPU-5302 */
if (!tegra_platform_is_silicon()) {
nvgpu_log_info(g, "VPR is not supported on pre-si platform");
return 0;
}
#if PAGE_SIZE > 4096
platform->secure_buffer_size += SZ_64K;