* [PATCH v4] iommu: remove redundant parameter check in tegra_smmu_debugfs_init()
@ 2023-07-13 7:28 Minjie Du
2023-07-14 2:31 ` Baolu Lu
2023-07-14 2:57 ` Baolu Lu
0 siblings, 2 replies; 5+ messages in thread
From: Minjie Du @ 2023-07-13 7:28 UTC (permalink / raw)
To: Thierry Reding, Krishna Reddy, Joerg Roedel, Will Deacon,
Robin Murphy, Jonathan Hunter, open list:TEGRA IOMMU DRIVERS,
open list:IOMMU SUBSYSTEM, open list
Cc: opensource.kernel, Minjie Du, Thierry Reding
debugfs_create_file() will return early if smmu->debugfs is an error
pointer, so an extra error check is not needed.
Signed-off-by: Minjie Du <duminjie@vivo.com>
Acked-by: Thierry Reding <treding@nvidia.com>
---
drivers/iommu/tegra-smmu.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/iommu/tegra-smmu.c b/drivers/iommu/tegra-smmu.c
index 1cbf063cc..2137040b7 100644
--- a/drivers/iommu/tegra-smmu.c
+++ b/drivers/iommu/tegra-smmu.c
@@ -1056,8 +1056,6 @@ DEFINE_SHOW_ATTRIBUTE(tegra_smmu_clients);
static void tegra_smmu_debugfs_init(struct tegra_smmu *smmu)
{
smmu->debugfs = debugfs_create_dir("smmu", NULL);
- if (!smmu->debugfs)
- return;
debugfs_create_file("swgroups", S_IRUGO, smmu->debugfs, smmu,
&tegra_smmu_swgroups_fops);
--
2.39.0
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH v4] iommu: remove redundant parameter check in tegra_smmu_debugfs_init()
2023-07-13 7:28 [PATCH v4] iommu: remove redundant parameter check in tegra_smmu_debugfs_init() Minjie Du
@ 2023-07-14 2:31 ` Baolu Lu
[not found] ` <SG2PR06MB5288E9FC9B6EA21E20BB011EAE34A@SG2PR06MB5288.apcprd06.prod.outlook.com>
2023-07-14 2:57 ` Baolu Lu
1 sibling, 1 reply; 5+ messages in thread
From: Baolu Lu @ 2023-07-14 2:31 UTC (permalink / raw)
To: Minjie Du, Thierry Reding, Krishna Reddy, Joerg Roedel,
Will Deacon, Robin Murphy, Jonathan Hunter,
open list:TEGRA IOMMU DRIVERS, open list:IOMMU SUBSYSTEM,
open list
Cc: baolu.lu, opensource.kernel, Thierry Reding
On 2023/7/13 15:28, Minjie Du wrote:
> debugfs_create_file() will return early if smmu->debugfs is an error
> pointer, so an extra error check is not needed.
>
> Signed-off-by: Minjie Du <duminjie@vivo.com>
> Acked-by: Thierry Reding <treding@nvidia.com>
> ---
> drivers/iommu/tegra-smmu.c | 2 --
> 1 file changed, 2 deletions(-)
Next time when you send a new version of a patch, please don't forget to
add the change log after the tear line. This way, people can know how
the patch evolved into this way.
Best regards,
baolu
>
> diff --git a/drivers/iommu/tegra-smmu.c b/drivers/iommu/tegra-smmu.c
> index 1cbf063cc..2137040b7 100644
> --- a/drivers/iommu/tegra-smmu.c
> +++ b/drivers/iommu/tegra-smmu.c
> @@ -1056,8 +1056,6 @@ DEFINE_SHOW_ATTRIBUTE(tegra_smmu_clients);
> static void tegra_smmu_debugfs_init(struct tegra_smmu *smmu)
> {
> smmu->debugfs = debugfs_create_dir("smmu", NULL);
> - if (!smmu->debugfs)
> - return;
>
> debugfs_create_file("swgroups", S_IRUGO, smmu->debugfs, smmu,
> &tegra_smmu_swgroups_fops);
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: 回复: [PATCH v4] iommu: remove redundant parameter check in tegra_smmu_debugfs_init()
[not found] ` <SG2PR06MB5288E9FC9B6EA21E20BB011EAE34A@SG2PR06MB5288.apcprd06.prod.outlook.com>
@ 2023-07-14 2:50 ` Baolu Lu
0 siblings, 0 replies; 5+ messages in thread
From: Baolu Lu @ 2023-07-14 2:50 UTC (permalink / raw)
To: 杜敏杰, Thierry Reding, Krishna Reddy,
Joerg Roedel, Will Deacon, Robin Murphy, Jonathan Hunter,
open list:TEGRA IOMMU DRIVERS, open list:IOMMU SUBSYSTEM,
open list
Cc: baolu.lu, opensource.kernel, Thierry Reding
On 2023/7/14 10:38, 杜敏杰 wrote:
> Hi baolu!
>
> Thanks for your suggestion!
>
> You say:
>> Next time when you send a new version of a patch, please don't forget to add the change log after the tear line. This way, people can know how the patch evolved into this way.
> Do I need to submit a new patch?
Oh no. Just a kind remind. :-)
Best regards,
baolu
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v4] iommu: remove redundant parameter check in tegra_smmu_debugfs_init()
2023-07-13 7:28 [PATCH v4] iommu: remove redundant parameter check in tegra_smmu_debugfs_init() Minjie Du
2023-07-14 2:31 ` Baolu Lu
@ 2023-07-14 2:57 ` Baolu Lu
[not found] ` <SG2PR06MB5288ED578DB3CE7DA2B25AB5AE34A@SG2PR06MB5288.apcprd06.prod.outlook.com>
1 sibling, 1 reply; 5+ messages in thread
From: Baolu Lu @ 2023-07-14 2:57 UTC (permalink / raw)
To: Minjie Du, Thierry Reding, Krishna Reddy, Joerg Roedel,
Will Deacon, Robin Murphy, Jonathan Hunter,
open list:TEGRA IOMMU DRIVERS, open list:IOMMU SUBSYSTEM,
open list
Cc: baolu.lu, opensource.kernel, Thierry Reding
On 2023/7/13 15:28, Minjie Du wrote:
> debugfs_create_file() will return early if smmu->debugfs is an error
> pointer, so an extra error check is not needed.
>
> Signed-off-by: Minjie Du<duminjie@vivo.com>
> Acked-by: Thierry Reding<treding@nvidia.com>
Greg keeps reminding that no error branch for debugfs, so
Reviewed-by: Lu Baolu <baolu.lu@linux.intel.com>
Best regards,
baolu
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: 回复: [PATCH v4] iommu: remove redundant parameter check in tegra_smmu_debugfs_init()
[not found] ` <SG2PR06MB5288ED578DB3CE7DA2B25AB5AE34A@SG2PR06MB5288.apcprd06.prod.outlook.com>
@ 2023-07-14 8:41 ` Thierry Reding
0 siblings, 0 replies; 5+ messages in thread
From: Thierry Reding @ 2023-07-14 8:41 UTC (permalink / raw)
To: 杜敏杰
Cc: Baolu Lu, Krishna Reddy, Joerg Roedel, Will Deacon, Robin Murphy,
Jonathan Hunter, open list:TEGRA IOMMU DRIVERS,
open list:IOMMU SUBSYSTEM, open list, opensource.kernel,
Thierry Reding
[-- Attachment #1: Type: text/plain, Size: 1874 bytes --]
On Fri, Jul 14, 2023 at 03:21:47AM +0000, 杜敏杰 wrote:
> Hi Baolu!
>
> It seems that 'smmu->debugfs' check is still needed.
> Then I will modify the patch.
> Thanks!
>
> regards,
> Minjie
Don't top-post, please. See Documentation/process/2.Process.rst and
Documentation/process/submitting-patches.rst.
Also, how did you come to the above conclusion? Baolu said that Greg
keeps reminding people that we shouldn't do error handling for debugfs
and gave a Reviewed-by:, so why the 180?
Thierry
> -----邮件原件-----
> 发件人: Baolu Lu <baolu.lu@linux.intel.com>
> 发送时间: 2023年7月14日 10:58
> 收件人: 杜敏杰 <duminjie@vivo.com>; Thierry Reding <thierry.reding@gmail.com>; Krishna Reddy <vdumpa@nvidia.com>; Joerg Roedel <joro@8bytes.org>; Will Deacon <will@kernel.org>; Robin Murphy <robin.murphy@arm.com>; Jonathan Hunter <jonathanh@nvidia.com>; open list:TEGRA IOMMU DRIVERS <linux-tegra@vger.kernel.org>; open list:IOMMU SUBSYSTEM <iommu@lists.linux.dev>; open list <linux-kernel@vger.kernel.org>
> 抄送: baolu.lu@linux.intel.com; opensource.kernel <opensource.kernel@vivo.com>; Thierry Reding <treding@nvidia.com>
> 主题: Re: [PATCH v4] iommu: remove redundant parameter check in tegra_smmu_debugfs_init()
>
> [Some people who received this message don't often get email from baolu.lu@linux.intel.com. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]
>
> On 2023/7/13 15:28, Minjie Du wrote:
> > debugfs_create_file() will return early if smmu->debugfs is an error
> > pointer, so an extra error check is not needed.
> >
> > Signed-off-by: Minjie Du<duminjie@vivo.com>
> > Acked-by: Thierry Reding<treding@nvidia.com>
>
> Greg keeps reminding that no error branch for debugfs, so
>
> Reviewed-by: Lu Baolu <baolu.lu@linux.intel.com>
>
> Best regards,
> baolu
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2023-07-14 8:41 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-07-13 7:28 [PATCH v4] iommu: remove redundant parameter check in tegra_smmu_debugfs_init() Minjie Du
2023-07-14 2:31 ` Baolu Lu
[not found] ` <SG2PR06MB5288E9FC9B6EA21E20BB011EAE34A@SG2PR06MB5288.apcprd06.prod.outlook.com>
2023-07-14 2:50 ` 回复: " Baolu Lu
2023-07-14 2:57 ` Baolu Lu
[not found] ` <SG2PR06MB5288ED578DB3CE7DA2B25AB5AE34A@SG2PR06MB5288.apcprd06.prod.outlook.com>
2023-07-14 8:41 ` 回复: " Thierry Reding
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).