local_log_level = rte_log_get_level(dpaa2_logtype_bus);
if (global_log_level == RTE_LOG_DEBUG ||
local_log_level == RTE_LOG_DEBUG) {
- DPAA2_BUS_DEBUG("List of devices scanned on bus:");
+ DPAA2_BUS_LOG(DEBUG, "List of devices scanned on bus:");
TAILQ_FOREACH(dev, &rte_fslmc_bus.device_list, next) {
- DPAA2_BUS_DEBUG("%s", dev->device.name);
+ DPAA2_BUS_LOG(DEBUG, "\t\t%s", dev->device.name);
}
}
}
return -ENOMEM;
}
+ dev->device.bus = &rte_fslmc_bus.bus;
+
/* Parse the device name and ID */
t_ptr = strtok(dup_dev_name, ".");
if (!t_ptr) {
dev->device.devargs->policy ==
RTE_DEV_WHITELISTED)) {
ret = drv->probe(drv, dev);
- if (ret)
+ if (ret) {
DPAA2_BUS_ERR("Unable to probe");
+ } else {
+ dev->driver = drv;
+ dev->device.driver = &drv->driver;
+ }
}
break;
}
RTE_REGISTER_BUS(FSLMC_BUS_NAME, rte_fslmc_bus.bus);
-RTE_INIT(fslmc_init_log);
-static void
-fslmc_init_log(void)
+RTE_INIT(fslmc_init_log)
{
/* Bus level logs */
dpaa2_logtype_bus = rte_log_register("bus.fslmc");