git.droids-corp.org
/
dpdk.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
vfio: export some internal functions
[dpdk.git]
/
drivers
/
bus
/
dpaa
/
dpaa_bus.c
diff --git
a/drivers/bus/dpaa/dpaa_bus.c
b/drivers/bus/dpaa/dpaa_bus.c
index
290b967
..
ffc90a7
100644
(file)
--- a/
drivers/bus/dpaa/dpaa_bus.c
+++ b/
drivers/bus/dpaa/dpaa_bus.c
@@
-19,7
+19,6
@@
#include <rte_interrupts.h>
#include <rte_log.h>
#include <rte_debug.h>
#include <rte_interrupts.h>
#include <rte_log.h>
#include <rte_debug.h>
-#include <rte_pci.h>
#include <rte_atomic.h>
#include <rte_branch_prediction.h>
#include <rte_memory.h>
#include <rte_atomic.h>
#include <rte_branch_prediction.h>
#include <rte_memory.h>
@@
-235,7
+234,7
@@
int rte_dpaa_portal_init(void *arg)
BUS_INIT_FUNC_TRACE();
BUS_INIT_FUNC_TRACE();
- if ((
uint64
_t)arg == 1 || cpu == LCORE_ID_ANY)
+ if ((
size
_t)arg == 1 || cpu == LCORE_ID_ANY)
cpu = rte_get_master_lcore();
/* if the core id is not supported */
else
cpu = rte_get_master_lcore();
/* if the core id is not supported */
else
@@
-309,9
+308,15
@@
rte_dpaa_portal_fq_init(void *arg, struct qman_fq *fq)
/* Affine above created portal with channel*/
u32 sdqcr;
struct qman_portal *qp;
/* Affine above created portal with channel*/
u32 sdqcr;
struct qman_portal *qp;
+ int ret;
- if (unlikely(!RTE_PER_LCORE(dpaa_io)))
- rte_dpaa_portal_init(arg);
+ if (unlikely(!RTE_PER_LCORE(dpaa_io))) {
+ ret = rte_dpaa_portal_init(arg);
+ if (ret < 0) {
+ DPAA_BUS_LOG(ERR, "portal initialization failure");
+ return ret;
+ }
+ }
/* Initialise qman specific portals */
qp = fsl_qman_portal_create();
/* Initialise qman specific portals */
qp = fsl_qman_portal_create();
@@
-541,6
+546,10
@@
rte_dpaa_find_device(const struct rte_device *start, rte_dev_cmp_t cmp,
static enum rte_iova_mode
rte_dpaa_get_iommu_class(void)
{
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;
}
return RTE_IOVA_PA;
}