diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/mxc/gpu-viv/hal/os/linux/kernel/gc_hal_kernel_driver.c | 2 | ||||
-rw-r--r-- | drivers/mxc/gpu-viv/hal/os/linux/kernel/platform/freescale/gc_hal_kernel_platform_imx6.c | 12 |
2 files changed, 13 insertions, 1 deletions
diff --git a/drivers/mxc/gpu-viv/hal/os/linux/kernel/gc_hal_kernel_driver.c b/drivers/mxc/gpu-viv/hal/os/linux/kernel/gc_hal_kernel_driver.c index 05474e78553d..b96e26068ef6 100644 --- a/drivers/mxc/gpu-viv/hal/os/linux/kernel/gc_hal_kernel_driver.c +++ b/drivers/mxc/gpu-viv/hal/os/linux/kernel/gc_hal_kernel_driver.c @@ -915,7 +915,7 @@ static int gpu_probe(struct pci_dev *pdev, const struct pci_device_id *ent) memcpy(moduleParam.registerBases, registerBases, gcmSIZEOF(gctUINT) * gcvCORE_COUNT); memcpy(moduleParam.registerSizes, registerSizes, gcmSIZEOF(gctUINT) * gcvCORE_COUNT); memcpy(moduleParam.chipIDs, chipIDs, gcmSIZEOF(gctUINT) * gcvCORE_COUNT); - moduleParam.compression = (compression == -1) ? gcvCOMPRESSION_OPTION_DEFAULT : (gceCOMPRESSION_OPTION)compression; + moduleParam.compression = compression; platform->device = pdev; #if USE_LINUX_PCIE if (pci_enable_device(pdev)) { diff --git a/drivers/mxc/gpu-viv/hal/os/linux/kernel/platform/freescale/gc_hal_kernel_platform_imx6.c b/drivers/mxc/gpu-viv/hal/os/linux/kernel/platform/freescale/gc_hal_kernel_platform_imx6.c index 9869fc1e4ba3..b9b7633e90d6 100644 --- a/drivers/mxc/gpu-viv/hal/os/linux/kernel/platform/freescale/gc_hal_kernel_platform_imx6.c +++ b/drivers/mxc/gpu-viv/hal/os/linux/kernel/platform/freescale/gc_hal_kernel_platform_imx6.c @@ -857,6 +857,18 @@ static int patch_param(struct platform_device *pdev, #endif patch_param_imx6(pdev, args); +#if LINUX_VERSION_CODE >= KERNEL_VERSION(3,5,0) + if(args->compression == -1) + { + const u32 *property; + args->compression = gcvCOMPRESSION_OPTION_DEFAULT; + property = of_get_property(pdev->dev.of_node, "depth-compression", NULL); + if (property && *property == 0) + { + args->compression &= ~gcvCOMPRESSION_OPTION_DEPTH; + } + } +#endif res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "phys_baseaddr"); if (res && !args->baseAddress && !args->physSize) { |