Deleted Added
full compact
34c34
< __FBSDID("$FreeBSD: head/sys/mips/atheros/ar71xx_gpio.c 277968 2015-01-31 12:17:07Z loos $");
---
> __FBSDID("$FreeBSD: head/sys/mips/atheros/ar71xx_gpio.c 277996 2015-01-31 19:32:14Z loos $");
54a55
> #include <dev/gpio/gpiobusvar.h>
81a83
> static device_t ar71xx_gpio_get_bus(device_t);
137a140,149
> static device_t
> ar71xx_gpio_get_bus(device_t dev)
> {
> struct ar71xx_gpio_softc *sc;
>
> sc = device_get_softc(dev);
>
> return (sc->busdev);
> }
>
436,437c448,452
< device_add_child(dev, "gpioc", -1);
< device_add_child(dev, "gpiobus", -1);
---
> sc->busdev = gpiobus_attach_bus(dev);
> if (sc->busdev == NULL) {
> ar71xx_gpio_detach(dev);
> return (ENXIO);
> }
439c454
< return (bus_generic_attach(dev));
---
> return (0);
449c464
< bus_generic_detach(dev);
---
> gpiobus_detach_bus(dev);
470a486
> DEVMETHOD(gpio_get_bus, ar71xx_gpio_get_bus),