* [PATCH] iommu/io-pgtalbe-arm: Remove "iopte_type(pte, l)" extra parameter "l"
@ 2020-12-07 8:14 Kunkun Jiang
2020-12-07 10:24 ` Will Deacon
0 siblings, 1 reply; 3+ messages in thread
From: Kunkun Jiang @ 2020-12-07 8:14 UTC (permalink / raw)
To: Will Deacon, Robin Murphy, Joerg Roedel,
moderated list:ARM SMMU DRIVERS, open list:IOMMU DRIVERS,
open list
Cc: wanghaibin.wang, Keqian Zhu, Kunkun Jiang
Knowing from the code, the macro "iopte_type(pte, l)" doesn't use the
parameter "l" (level). So we'd better to remove it.
Fixes: e1d3c0fd701df(iommu: add ARM LPAE page table allocator)
Signed-off-by: Kunkun Jiang <jiangkunkun@huawei.com>
---
drivers/iommu/io-pgtable-arm.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/iommu/io-pgtable-arm.c b/drivers/iommu/io-pgtable-arm.c
index a7a9bc08dcd1..925ae2b713d6 100644
--- a/drivers/iommu/io-pgtable-arm.c
+++ b/drivers/iommu/io-pgtable-arm.c
@@ -130,7 +130,7 @@
/* IOPTE accessors */
#define iopte_deref(pte,d) __va(iopte_to_paddr(pte, d))
-#define iopte_type(pte,l) \
+#define iopte_type(pte) \
(((pte) >> ARM_LPAE_PTE_TYPE_SHIFT) & ARM_LPAE_PTE_TYPE_MASK)
#define iopte_prot(pte) ((pte) & ARM_LPAE_PTE_ATTR_MASK)
--
2.19.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] iommu/io-pgtalbe-arm: Remove "iopte_type(pte, l)" extra parameter "l"
2020-12-07 8:14 [PATCH] iommu/io-pgtalbe-arm: Remove "iopte_type(pte, l)" extra parameter "l" Kunkun Jiang
@ 2020-12-07 10:24 ` Will Deacon
2020-12-07 12:09 ` Kunkun Jiang
0 siblings, 1 reply; 3+ messages in thread
From: Will Deacon @ 2020-12-07 10:24 UTC (permalink / raw)
To: Kunkun Jiang
Cc: Robin Murphy, Joerg Roedel, moderated list:ARM SMMU DRIVERS,
open list:IOMMU DRIVERS, open list, wanghaibin.wang, Keqian Zhu
On Mon, Dec 07, 2020 at 04:14:04PM +0800, Kunkun Jiang wrote:
> Knowing from the code, the macro "iopte_type(pte, l)" doesn't use the
> parameter "l" (level). So we'd better to remove it.
>
> Fixes: e1d3c0fd701df(iommu: add ARM LPAE page table allocator)
> Signed-off-by: Kunkun Jiang <jiangkunkun@huawei.com>
> ---
> drivers/iommu/io-pgtable-arm.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/iommu/io-pgtable-arm.c b/drivers/iommu/io-pgtable-arm.c
> index a7a9bc08dcd1..925ae2b713d6 100644
> --- a/drivers/iommu/io-pgtable-arm.c
> +++ b/drivers/iommu/io-pgtable-arm.c
> @@ -130,7 +130,7 @@
> /* IOPTE accessors */
> #define iopte_deref(pte,d) __va(iopte_to_paddr(pte, d))
>
> -#define iopte_type(pte,l) \
> +#define iopte_type(pte) \
> (((pte) >> ARM_LPAE_PTE_TYPE_SHIFT) & ARM_LPAE_PTE_TYPE_MASK)
Shouldn't we update all the users of the macro too?
Will
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] iommu/io-pgtalbe-arm: Remove "iopte_type(pte, l)" extra parameter "l"
2020-12-07 10:24 ` Will Deacon
@ 2020-12-07 12:09 ` Kunkun Jiang
0 siblings, 0 replies; 3+ messages in thread
From: Kunkun Jiang @ 2020-12-07 12:09 UTC (permalink / raw)
To: Will Deacon
Cc: Robin Murphy, Joerg Roedel, moderated list:ARM SMMU DRIVERS,
open list:IOMMU DRIVERS, open list, wanghaibin.wang, Keqian Zhu
Hi Will,
On 2020/12/7 18:24, Will Deacon wrote:
> On Mon, Dec 07, 2020 at 04:14:04PM +0800, Kunkun Jiang wrote:
>> Knowing from the code, the macro "iopte_type(pte, l)" doesn't use the
>> parameter "l" (level). So we'd better to remove it.
>>
>> Fixes: e1d3c0fd701df(iommu: add ARM LPAE page table allocator)
>> Signed-off-by: Kunkun Jiang <jiangkunkun@huawei.com>
>> ---
>> drivers/iommu/io-pgtable-arm.c | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/iommu/io-pgtable-arm.c b/drivers/iommu/io-pgtable-arm.c
>> index a7a9bc08dcd1..925ae2b713d6 100644
>> --- a/drivers/iommu/io-pgtable-arm.c
>> +++ b/drivers/iommu/io-pgtable-arm.c
>> @@ -130,7 +130,7 @@
>> /* IOPTE accessors */
>> #define iopte_deref(pte,d) __va(iopte_to_paddr(pte, d))
>>
>> -#define iopte_type(pte,l) \
>> +#define iopte_type(pte) \
>> (((pte) >> ARM_LPAE_PTE_TYPE_SHIFT) & ARM_LPAE_PTE_TYPE_MASK)
> Shouldn't we update all the users of the macro too?
>
> Will
> .
Sorry for my carelessness. :(
I have resent it.
Thanks,
Kunkun Jiang
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-12-07 12:11 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-07 8:14 [PATCH] iommu/io-pgtalbe-arm: Remove "iopte_type(pte, l)" extra parameter "l" Kunkun Jiang
2020-12-07 10:24 ` Will Deacon
2020-12-07 12:09 ` Kunkun Jiang
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).