-static int __devinit sunlance_sbus_probe(struct of_device *dev, const struct of_device_id *match)
-{
- struct sbus_dev *sdev = to_sbus_device(&dev->dev);
- int err;
-
- if (sdev->parent) {
- struct of_device *parent = &sdev->parent->ofdev;
-
- if (!strcmp(parent->node->name, "ledma")) {
- struct sbus_dma *ledma = find_ledma(to_sbus_device(&parent->dev));
-
- err = sparc_lance_probe_one(sdev, ledma, NULL);
- } else if (!strcmp(parent->node->name, "lebuffer")) {
- err = sparc_lance_probe_one(sdev, NULL, to_sbus_device(&parent->dev));
- } else
- err = sparc_lance_probe_one(sdev, NULL, NULL);
- } else
- err = sparc_lance_probe_one(sdev, NULL, NULL);
-
- return err;
-}
-
-static int __devexit sunlance_sbus_remove(struct of_device *dev)
-{
- struct lance_private *lp = dev_get_drvdata(&dev->dev);
- struct net_device *net_dev = lp->dev;
-
- unregister_netdevice(net_dev);
-
- lance_free_hwresources(lp);
-
- free_netdev(net_dev);
-
- dev_set_drvdata(&dev->dev, NULL);
-
- return 0;
-}
-
-static struct of_device_id sunlance_sbus_match[] = {
- {
- .name = "le",
- },
- {},
-};
-
-MODULE_DEVICE_TABLE(of, sunlance_sbus_match);
-
-static struct of_platform_driver sunlance_sbus_driver = {
- .name = "sunlance",
- .match_table = sunlance_sbus_match,
- .probe = sunlance_sbus_probe,
- .remove = __devexit_p(sunlance_sbus_remove),
-};
-
-