Пример #1
0
static int
uart_pci_detach(device_t dev)
{
	struct uart_softc *sc;

	sc = device_get_softc(dev);

	if (sc->sc_irid != 0)
		pci_release_msi(dev);

	return (uart_bus_detach(dev));
}
Пример #2
0
static int
tegra_uart_detach(device_t dev)
{
	struct tegra_softc *sc;

	sc = device_get_softc(dev);
	if (sc->clk != NULL) {
		clk_release(sc->clk);
	}

	return (uart_bus_detach(dev));
}
Пример #3
0
static int
jz4780_uart_detach(device_t dev)
{
    struct jz4780_uart_softc *sc;
    int rv;

    rv = uart_bus_detach(dev);
    if (rv != 0)
        return (rv);

    sc = device_get_softc(dev);
    if (sc->clk_mod != NULL) {
        clk_release(sc->clk_mod);
    }
    if (sc->clk_baud != NULL) {
        clk_release(sc->clk_baud);
    }
    return (0);
}