lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Thu, 2 May 2024 19:53:57 +0300
From: Georgi Djakov <djakov@...nel.org>
To: Will Deacon <will@...nel.org>, Georgi Djakov <quic_c_gdjako@...cinc.com>
Cc: robin.murphy@....com, joro@...tes.org, iommu@...ts.linux.dev,
 robh+dt@...nel.org, krzysztof.kozlowski+dt@...aro.org, conor+dt@...nel.org,
 devicetree@...r.kernel.org, andersson@...nel.org, konrad.dybcio@...aro.org,
 robdclark@...il.com, linux-arm-kernel@...ts.infradead.org,
 linux-kernel@...r.kernel.org, linux-arm-msm@...r.kernel.org,
 quic_cgoldswo@...cinc.com, quic_sukadev@...cinc.com, quic_pdaly@...cinc.com,
 quic_sudaraja@...cinc.com
Subject: Re: [PATCH v8 2/7] iommu/arm-smmu-qcom-debug: Add support for TBUs

Hi Will,

On 1.05.24 17:34, Will Deacon wrote:
> Hi Georgi,
> 
> On Wed, Apr 17, 2024 at 06:37:26AM -0700, Georgi Djakov wrote:
>> diff --git a/drivers/iommu/arm/arm-smmu/arm-smmu-qcom-debug.c b/drivers/iommu/arm/arm-smmu/arm-smmu-qcom-debug.c
>> index bb89d49adf8d..eff7ca94ec8d 100644
>> --- a/drivers/iommu/arm/arm-smmu/arm-smmu-qcom-debug.c
>> +++ b/drivers/iommu/arm/arm-smmu/arm-smmu-qcom-debug.c
> 
> ...
> 
>> +static const struct of_device_id qcom_tbu_of_match[] = {
>> +	{ .compatible = "qcom,sc7280-tbu" },
>> +	{ .compatible = "qcom,sdm845-tbu" },
>> +	{ }
>> +};
>> +
>> +static struct platform_driver qcom_tbu_driver = {
>> +	.driver = {
>> +		.name           = "qcom_tbu",
>> +		.of_match_table = qcom_tbu_of_match,
>> +	},
>> +	.probe = qcom_tbu_probe,
>> +};
>> +builtin_platform_driver(qcom_tbu_driver);
> 
> I just noticed that this breaks a modular build of the arm-smmu driver
> because we now have two init functions for the module:
> 
>    ld.lld: error: duplicate symbol: init_module
>    >>> defined at arm-smmu.c
>    >>>            drivers/iommu/arm/arm-smmu/arm-smmu.o:(init_module)
>    >>> defined at arm-smmu-qcom-debug.c
>    >>>            drivers/iommu/arm/arm-smmu/arm-smmu-qcom-debug.o:(.init.text+0x4)
> 
> I think you should initialise the TBU debug feature by calling into it
> manually from qcom_smmu_impl_init().
> 
> Please can you send a patch to fix that? For now, I'll bodge it so that
> the qcom debug stuff doesn't build as a module (see below).

Š¢hanks for sorting that out and apologies for missing it. We are at rc6 now and
i am afraid that i won't be able to validate my patch until next week (Easter
holidays here). I'll definitely send the rework when I get back.

BR,
Georgi

> 
> Cheers,
> 
> Will
> 
> --->8
> 
> diff --git a/drivers/iommu/Kconfig b/drivers/iommu/Kconfig
> index 032bfd681307..66325210c8c9 100644
> --- a/drivers/iommu/Kconfig
> +++ b/drivers/iommu/Kconfig
> @@ -376,7 +376,7 @@ config ARM_SMMU_QCOM
> 
>   config ARM_SMMU_QCOM_DEBUG
>          bool "ARM SMMU QCOM implementation defined debug support"
> -       depends on ARM_SMMU_QCOM
> +       depends on ARM_SMMU_QCOM=y
>          help
>            Support for implementation specific debug features in ARM SMMU
>            hardware found in QTI platforms. This include support for
> 


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ