*/
static int __devinit fsl_of_rio_rpn_probe(struct platform_device *dev)
{
- int rc;
printk(KERN_INFO "Setting up RapidIO peer-to-peer network %s\n",
dev->dev.of_node->full_name);
- rc = fsl_rio_setup(dev);
- if (rc)
- goto out;
-
- /* Enumerate all registered ports */
- rc = rio_init_mports();
-out:
- return rc;
+ return fsl_rio_setup(dev);
};
static const struct of_device_id fsl_of_rio_rpn_ids[] = {
rio_unregister_driver(&rionet_driver);
}
-module_init(rionet_init);
+late_initcall(rionet_init);
module_exit(rionet_exit);
return 0;
}
-device_initcall(rio_init);
-
int __devinit rio_init_mports(void)
{
int rc = 0;
rio_disc_mport(port);
}
+ rio_init();
+
out:
return rc;
}
+device_initcall_sync(rio_init_mports);
+
void rio_register_mport(struct rio_mport *port)
{
list_add_tail(&port->node, &rio_mports);
};
/* Architecture and hardware-specific functions */
-extern int rio_init_mports(void);
extern void rio_register_mport(struct rio_mport *);
extern int rio_open_inb_mbox(struct rio_mport *, void *, int, int);
extern void rio_close_inb_mbox(struct rio_mport *, int);