mirror of
git://nv-tegra.nvidia.com/linux-nv-oot.git
synced 2025-12-23 17:55:05 +03:00
video: tegra: host: probe engines based on SKUs
- Xavier has different SKUs based on which different engines are enabled or disabled based on fuse setttings. - This patch probes engines only if they are actually enabled in SKU by reading SKU INFO. - This makes sure that we dont access engines if they are enabled inadvertently in DT Bug 200428527 JIRA VFND-5075 Change-Id: I4d3a4c84452237fdab0426980282cd9c39cc2a28 Signed-off-by: Deepak Bhosale <dbhosale@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1784306 Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Damian Halas <dhalas@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: Mikko Perttunen <mperttunen@nvidia.com> Reviewed-by: Nirav Patel <nipatel@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
committed by
Laxman Dewangan
parent
2ed4adb936
commit
e44a671c9b
@@ -26,6 +26,7 @@
|
||||
#include <linux/dma-attrs.h>
|
||||
#include <linux/dma-mapping.h>
|
||||
#include <linux/uaccess.h>
|
||||
#include <soc/tegra/fuse.h>
|
||||
|
||||
#include "dev.h"
|
||||
#include "bus_client.h"
|
||||
@@ -722,6 +723,13 @@ static int nvdla_probe(struct platform_device *pdev)
|
||||
goto err_get_pdata;
|
||||
}
|
||||
|
||||
if (tegra_get_chipid() == TEGRA_CHIPID_TEGRA19 &&
|
||||
tegra_get_sku_id() == 0x9E) {
|
||||
dev_err(dev, "NVDLA IP is disabled in SKU\n");
|
||||
err = -ENODEV;
|
||||
goto err_no_ip;
|
||||
}
|
||||
|
||||
dma_set_mask(dev, DMA_BIT_MASK(40));
|
||||
|
||||
nvdla_dev = devm_kzalloc(dev, sizeof(*nvdla_dev), GFP_KERNEL);
|
||||
@@ -789,6 +797,7 @@ err_module_init:
|
||||
err_get_resources:
|
||||
devm_kfree(dev, nvdla_dev);
|
||||
err_alloc_nvdla:
|
||||
err_no_ip:
|
||||
err_get_pdata:
|
||||
|
||||
return err;
|
||||
|
||||
Reference in New Issue
Block a user