bus/fslmc: support scanning and probing of QDMA devices

'dpdmai' devices detected on fsl-mc bus are represented by DPAA2 QDMA
devices in DPDK.

Signed-off-by: Nipun Gupta <nipun.gupta@nxp.com>
Acked-by: Shreyansh Jain <shreyansh.jain@nxp.com>
This commit is contained in:
Nipun Gupta 2018-05-03 21:36:05 +05:30 committed by Thomas Monjalon
parent 23e8fcb018
commit 51db78c2d5
3 changed files with 5 additions and 0 deletions

View File

@ -164,6 +164,8 @@ scan_one_fslmc_device(char *dev_name)
dev->dev_type = DPAA2_CI; dev->dev_type = DPAA2_CI;
else if (!strncmp("dpmcp", t_ptr, 5)) else if (!strncmp("dpmcp", t_ptr, 5))
dev->dev_type = DPAA2_MPORTAL; dev->dev_type = DPAA2_MPORTAL;
else if (!strncmp("dpdmai", t_ptr, 6))
dev->dev_type = DPAA2_QDMA;
else else
dev->dev_type = DPAA2_UNKNOWN; dev->dev_type = DPAA2_UNKNOWN;

View File

@ -661,6 +661,7 @@ fslmc_vfio_process_group(void)
switch (dev->dev_type) { switch (dev->dev_type) {
case DPAA2_ETH: case DPAA2_ETH:
case DPAA2_CRYPTO: case DPAA2_CRYPTO:
case DPAA2_QDMA:
ret = fslmc_process_iodevices(dev); ret = fslmc_process_iodevices(dev);
if (ret) { if (ret) {
DPAA2_BUS_DEBUG("Dev (%s) init failed", DPAA2_BUS_DEBUG("Dev (%s) init failed",

View File

@ -61,6 +61,7 @@ enum rte_dpaa2_dev_type {
DPAA2_IO, /**< DPIO type device */ DPAA2_IO, /**< DPIO type device */
DPAA2_CI, /**< DPCI type device */ DPAA2_CI, /**< DPCI type device */
DPAA2_MPORTAL, /**< DPMCP type device */ DPAA2_MPORTAL, /**< DPMCP type device */
DPAA2_QDMA, /**< DPDMAI type device */
/* Unknown device placeholder */ /* Unknown device placeholder */
DPAA2_UNKNOWN, DPAA2_UNKNOWN,
DPAA2_DEVTYPE_MAX, DPAA2_DEVTYPE_MAX,
@ -91,6 +92,7 @@ struct rte_dpaa2_device {
union { union {
struct rte_eth_dev *eth_dev; /**< ethernet device */ struct rte_eth_dev *eth_dev; /**< ethernet device */
struct rte_cryptodev *cryptodev; /**< Crypto Device */ struct rte_cryptodev *cryptodev; /**< Crypto Device */
struct rte_rawdev *rawdev; /**< Raw Device */
}; };
enum rte_dpaa2_dev_type dev_type; /**< Device Type */ enum rte_dpaa2_dev_type dev_type; /**< Device Type */
uint16_t object_id; /**< DPAA2 Object ID */ uint16_t object_id; /**< DPAA2 Object ID */