mirror of
git://nv-tegra.nvidia.com/linux-nv-oot.git
synced 2025-12-25 10:42:21 +03:00
prod: Add support for legacy and next-gen prod via config
Instead of using the Linux kernel version, use the configs coming from core kernel to find out whether legacy or next-gen prod configuration method is used. This will help on porting changes on any kernel and configuring via core kernel configs. Bug 3389584 Change-Id: I19c242c573dd63c7dbecbf87d4ba807857dcf4fb Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3013911 Reviewed-by: Krishna Yarlagadda <kyarlagadda@nvidia.com> GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
This commit is contained in:
committed by
mobile promotions
parent
3d64e97531
commit
1dd2ef3473
@@ -12,7 +12,7 @@
|
||||
#define CAN_MSG_FLUSH_TIMEOUT 100
|
||||
static void mttcan_start(struct net_device *dev);
|
||||
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 16, 0)
|
||||
#if defined(CONFIG_TEGRA_PROD_NEXT_GEN)
|
||||
#define MTTCAN_PROD_FIELD(name, rindex, roffset, fname) \
|
||||
{ \
|
||||
.field_name = name, \
|
||||
@@ -1877,7 +1877,7 @@ static int mttcan_probe(struct platform_device *pdev)
|
||||
if (ret)
|
||||
goto exit_free_device;
|
||||
|
||||
#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 16, 0)
|
||||
#if !defined(CONFIG_TEGRA_PROD_NEXT_GEN)
|
||||
priv->ttcan->prod_list = devm_tegra_prod_get(&pdev->dev);
|
||||
#else
|
||||
priv->ttcan->prod_list = devm_tegra_prod_get_list(&pdev->dev, &mttcan_prod_dev_info);
|
||||
|
||||
Reference in New Issue
Block a user