svn commit: r325023 - stable/11/sys/dev/sdhci
Ian Lepore
ian at FreeBSD.org
Thu Oct 26 22:19:30 UTC 2017
Author: ian
Date: Thu Oct 26 22:19:28 2017
New Revision: 325023
URL: https://svnweb.freebsd.org/changeset/base/325023
Log:
MFC r314914:
Release all previously allocated resources.
Modified:
stable/11/sys/dev/sdhci/sdhci_fdt_gpio.c
Directory Properties:
stable/11/ (props changed)
Modified: stable/11/sys/dev/sdhci/sdhci_fdt_gpio.c
==============================================================================
--- stable/11/sys/dev/sdhci/sdhci_fdt_gpio.c Thu Oct 26 20:55:33 2017 (r325022)
+++ stable/11/sys/dev/sdhci/sdhci_fdt_gpio.c Thu Oct 26 22:19:28 2017 (r325023)
@@ -220,9 +220,14 @@ sdhci_fdt_gpio_teardown(struct sdhci_fdt_gpio *gpio)
if (gpio == NULL)
return;
- if (gpio->cd_ihandler != NULL) {
+ if (gpio->cd_ihandler != NULL)
bus_teardown_intr(gpio->dev, gpio->cd_ires, gpio->cd_ihandler);
- }
+ if (gpio->wp_pin != NULL)
+ gpio_pin_release(gpio->wp_pin);
+ if (gpio->cd_pin != NULL)
+ gpio_pin_release(gpio->cd_pin);
+ if (gpio->cd_ires != NULL)
+ bus_release_resource(gpio->dev, SYS_RES_IRQ, 0, gpio->cd_ires);
free(gpio, M_DEVBUF);
}
More information about the svn-src-all
mailing list