[dpdk-dev] [PATCH] eal: forcing IOVA as PA in ppc
Burakov, Anatoly
anatoly.burakov at intel.com
Wed Jul 31 11:10:24 CEST 2019
On 31-Jul-19 4:35 AM, Takeshi Yoshimura wrote:
> Commit b76fafb174d2 ("eal: fix IOVA mode selection as VA for PCI
> drivers") breaks ppc apps with no IOVA configs (or RTE_IOVA_DC)
> because of the inconsistency of user's request and the result of
> device capability for IOVA mode. I updated the code to force IOVA as
> PA in ppc as before because current ppc driver does not support VA
> mode.
>
> Theoretically, ppc can support VA mode, but I suspect that ppc with
> VA mode may have performance issues to create a big DMA window
> (VA often uses higher addresses than PA). So, I didn't change the
> code to check device capability in ppc.
>
> Signed-off-by: Takeshi Yoshimura <tyos at jp.ibm.com>
> ---
> lib/librte_eal/linux/eal/eal.c | 6 ++++++
> 1 file changed, 6 insertions(+)
>
> diff --git a/lib/librte_eal/linux/eal/eal.c b/lib/librte_eal/linux/eal/eal.c
> index 946222ccd..db2dec922 100644
> --- a/lib/librte_eal/linux/eal/eal.c
> +++ b/lib/librte_eal/linux/eal/eal.c
> @@ -1121,6 +1121,12 @@ rte_eal_init(int argc, char **argv)
> RTE_LOG(DEBUG, EAL, "KNI can not work since physical addresses are unavailable\n");
> }
> }
> +#endif
> +#ifdef RTE_ARCH_PPC_64
> + if (iova_mode == RTE_IOVA_VA) {
> + iova_mode = RTE_IOVA_PA;
> + RTE_LOG(WARNING, EAL, "Forcing IOVA as 'PA' because PPC uses PA mode.\n");
> + }
> #endif
I would have preferred a space between #endif and a new #ifdef, but
otherwise
Acked-by: Anatoly Burakov <anatoly.burakov at intel.com>
--
Thanks,
Anatoly
More information about the dev
mailing list