Lines Matching defs:sc
74 struct gpioled_softc *sc;
76 sc = (struct gpioled_softc *)priv;
77 GPIOLED_LOCK(sc);
78 if (GPIOBUS_PIN_SETFLAGS(sc->sc_busdev, sc->sc_dev, GPIOLED_PIN,
80 GPIOBUS_PIN_SET(sc->sc_busdev, sc->sc_dev, GPIOLED_PIN,
83 GPIOLED_UNLOCK(sc);
97 struct gpioled_softc *sc;
101 sc = device_get_softc(dev);
102 sc->sc_dev = dev;
103 sc->sc_busdev = device_get_parent(dev);
104 GPIOLED_LOCK_INIT(sc);
114 sc->sc_leddev = led_create_state(gpioled_control, sc, name ? name :
123 struct gpioled_softc *sc;
125 sc = device_get_softc(dev);
126 if (sc->sc_leddev) {
127 led_destroy(sc->sc_leddev);
128 sc->sc_leddev = NULL;
130 GPIOLED_LOCK_DESTROY(sc);