[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v2] xen/iommu: smmu: Silence clang in arm_smmu_device_dt_probe()
Hi Stefano,
On 06/04/2021 23:02, Stefano Stabellini wrote:
On Fri, 2 Apr 2021, Julien Grall wrote:
From: Julien Grall <jgrall@xxxxxxxxxx>
Clang 11 will throw the following error:
smmu.c:2284:18: error: cast to smaller integer type 'enum
arm_smmu_arch_version' from 'const void *' [-Werror,-Wvoid-pointer-to-enum-cast]
smmu->version = (enum arm_smmu_arch_version)of_id->data;
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
The error can be prevented by initially casting to (uintptr_t) and then
enum.
Signed-off-by: Julien Grall <jgrall@xxxxxxxxxx>
Acked-by: Stefano Stabellini <sstabellini@xxxxxxxxxx>
Thanks! I have committed the patch.
Cheers,
--
Julien Grall
|