Hi Shreyansh, On Tue, Oct 09, 2018 at 04:55:44PM +0530, Shreyansh Jain wrote: > In case RTE_LIBRTE_DPAA2_USE_PHYS_IOVA is enabled, only supported > class is RTE_IOVA_PA. > > Fixes: f7768afac101 ("bus/fslmc: support dynamic IOVA") > Cc: hemant.agra...@nxp.com > > Signed-off-by: Shreyansh Jain <shreyansh.j...@nxp.com> > --- > drivers/bus/fslmc/fslmc_bus.c | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/drivers/bus/fslmc/fslmc_bus.c b/drivers/bus/fslmc/fslmc_bus.c > index bfe81e236..a4f9a9eee 100644 > --- a/drivers/bus/fslmc/fslmc_bus.c > +++ b/drivers/bus/fslmc/fslmc_bus.c > @@ -491,6 +491,10 @@ rte_dpaa2_get_iommu_class(void) > bool is_vfio_noiommu_enabled = 1; > bool has_iova_va; > > +#ifdef RTE_LIBRTE_DPAA2_USE_PHYS_IOVA > + return RTE_IOVA_PA; > +#endif > +
As, RTE_LIBRTE_DPAA2_USE_PHYS_IOVA is set to true by default[1] and fslmc bus being always registered[2] irrespective of the underlying platform, the IOVA class will be always returned as PA. This will break multiple platforms as some work only when IOVA as VA. I think you need to verify if the underlying platform is really FLMC similar to DPAA[3] [1] ->[master]ltp-pvn[dpdk] $ grep -nir "RTE_LIBRTE_DPAA2_USE_PHYS_IOVA" config/ config/meson.build:86:dpdk_conf.set('RTE_LIBRTE_DPAA2_USE_PHYS_IOVA', true) config/common_base:218:CONFIG_RTE_LIBRTE_DPAA2_USE_PHYS_IOVA=y [2] config/common_linuxapp:45:CONFIG_RTE_LIBRTE_FSLMC_BUS=y [3] static enum rte_iova_mode rte_dpaa_get_iommu_class(void) { if ((access(DPAA_DEV_PATH1, F_OK) != 0) && (access(DPAA_DEV_PATH2, F_OK) != 0)) { return RTE_IOVA_DC; } return RTE_IOVA_PA; } > if (TAILQ_EMPTY(&rte_fslmc_bus.device_list)) > return RTE_IOVA_DC; > > -- > 2.17.1 > Thanks, Pavan.