powerpc/pseries/iommu: Add ddw_list_new_entry() helper
authorLeonardo Bras <leobras.c@gmail.com>
Tue, 17 Aug 2021 06:39:22 +0000 (03:39 -0300)
committerMichael Ellerman <mpe@ellerman.id.au>
Thu, 26 Aug 2021 14:56:54 +0000 (00:56 +1000)
commit92a23219299cedde52e3298788484f4875d5ce0f
tree494c17bf5b3d1f367af19d8ef5e0d2f29e4757f6
parent4ff8677a0b192a58d998d1d34fc5168203041a24
powerpc/pseries/iommu: Add ddw_list_new_entry() helper

There are two functions creating direct_window_list entries in a
similar way, so create a ddw_list_new_entry() to avoid duplicity and
simplify those functions.

Signed-off-by: Leonardo Bras <leobras.c@gmail.com>
Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru>
Reviewed-by: Frederic Barrat <fbarrat@linux.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20210817063929.38701-5-leobras.c@gmail.com
arch/powerpc/platforms/pseries/iommu.c