projects
/
linux-block.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f38338c
)
iommu/renesas: Fix unused-function warning
author
Arnd Bergmann
<arnd@arndb.de>
Fri, 8 May 2020 22:02:16 +0000
(
00:02
+0200)
committer
Joerg Roedel
<jroedel@suse.de>
Wed, 13 May 2020 08:46:56 +0000
(10:46 +0200)
gcc warns because the only reference to ipmmu_find_group
is inside of an #ifdef:
drivers/iommu/ipmmu-vmsa.c:878:28: error: 'ipmmu_find_group' defined but not used [-Werror=unused-function]
Change the #ifdef to an equivalent IS_ENABLED().
Fixes:
6580c8a78424
("iommu/renesas: Convert to probe/release_device() call-backs")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Reviewed-by: Simon Horman <horms@verge.net.au>
Link:
https://lore.kernel.org/r/20200508220224.688985-1-arnd@arndb.de
Signed-off-by: Joerg Roedel <jroedel@suse.de>
drivers/iommu/ipmmu-vmsa.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/iommu/ipmmu-vmsa.c
b/drivers/iommu/ipmmu-vmsa.c
index fb7e702dee2375c09605d48337c3f1170c158c72..4c2972f3153b52bfb48e7d76b64274f394aaccec 100644
(file)
--- a/
drivers/iommu/ipmmu-vmsa.c
+++ b/
drivers/iommu/ipmmu-vmsa.c
@@
-903,11
+903,8
@@
static const struct iommu_ops ipmmu_ops = {
.probe_device = ipmmu_probe_device,
.release_device = ipmmu_release_device,
.probe_finalize = ipmmu_probe_finalize,
-#if defined(CONFIG_ARM) && !defined(CONFIG_IOMMU_DMA)
- .device_group = generic_device_group,
-#else
- .device_group = ipmmu_find_group,
-#endif
+ .device_group = IS_ENABLED(CONFIG_ARM) && !IS_ENABLED(CONFIG_IOMMU_DMA)
+ ? generic_device_group : ipmmu_find_group,
.pgsize_bitmap = SZ_1G | SZ_2M | SZ_4K,
.of_xlate = ipmmu_of_xlate,
};