Lines Matching refs:dev
5 __FBSDID("$FreeBSD: releng/11.0/sys/dev/scd/scd_isa.c 274679 2014-11-18 22:02:37Z jhb $");
25 #include <dev/scd/scdreg.h>
26 #include <dev/scd/scdvar.h>
36 scd_isa_probe (device_t dev)
42 if (isa_get_vendorid(dev))
46 if (bus_get_resource_start(dev, SYS_RES_IOPORT, 0) == 0)
49 sc = device_get_softc(dev);
50 sc->dev = dev;
53 error = scd_alloc_resources(dev);
59 device_printf(dev, "Probe failed.\n");
63 device_set_desc(dev, sc->data.name);
66 scd_release_resources(dev);
71 scd_isa_attach (device_t dev)
76 sc = device_get_softc(dev);
79 sc->dev = dev;
82 error = scd_alloc_resources(dev);
88 device_printf(dev, "Re-Probe failed.\n");
94 device_printf(dev, "Attach failed.\n");
100 scd_release_resources(dev);
105 scd_isa_detach (device_t dev)
110 sc = device_get_softc(dev);
115 scd_release_resources(dev);
121 scd_alloc_resources (device_t dev)
126 sc = device_get_softc(dev);
131 sc->port = bus_alloc_resource_any(dev, sc->port_type,
134 device_printf(dev, "Unable to allocate PORT resource.\n");
145 scd_release_resources (device_t dev)
149 sc = device_get_softc(dev);
152 bus_release_resource(dev, sc->port_type, sc->port_rid, sc->port);