[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <b07d3b02-bf96-fd73-8333-a1104da9ae47@web.de>
Date: Sun, 19 Apr 2020 15:10:33 +0200
From: Markus Elfring <Markus.Elfring@....de>
To: Tang Bin <tangbin@...s.chinamobile.com>,
iommu@...ts.linux-foundation.org, linux-arm-msm@...r.kernel.org,
Andy Gross <agross@...nel.org>,
Bjorn Andersson <bjorn.andersson@...aro.org>,
Jörg Rödel <joro@...tes.org>,
Rob Clark <robdclark@...il.com>
Cc: linux-kernel@...r.kernel.org, kernel-janitors@...r.kernel.org,
Dejin Zheng <zhengdejin5@...il.com>
Subject: Re: [PATCH v2] iommu/qcom: Fix local_base status check
> …
>> +++ b/drivers/iommu/qcom_iommu.c
>> @@ -813,8 +813,11 @@ static int qcom_iommu_device_probe(struct platform_device *pdev)
>> qcom_iommu->dev = dev;
>>
>> res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
…
>> qcom_iommu->local_base = devm_ioremap_resource(dev, res);
…
> Please take another look at a corresponding usage example.
I would like to point another possibility out for desirable software evolution.
How do you think about to call a “known” wrapper function instead?
devm_platform_get_and_ioremap_resource
https://elixir.bootlin.com/linux/v5.7-rc1/source/drivers/base/platform.c#L66
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/log/drivers/base/platform.c
Regards,
Markus
Powered by blists - more mailing lists