git: 2af2ec524957 - main - jh7110_gpio: remove unneeded cleanup

Mitchell Horne <[email protected]>
Newsgroups gmane.os.freebsd.devel.cvs.src
Message-ID <6a888306.1c745.751cb983__11456.2364340358$1787331355$gmane$org@gitrepo.freebsd.org>
The branch main has been updated by mhorne:

URL: https://cgit.FreeBSD.org/src/commit/?id=2af2ec524957754ff356daea5fa7ee4990c1c3ea

commit 2af2ec524957754ff356daea5fa7ee4990c1c3ea
Author:     Mitchell Horne <[email protected]>
AuthorDate: 2025-08-10 17:16:11 +0000
Commit:     Mitchell Horne <[email protected]>
CommitDate: 2026-08-21 16:55:24 +0000

    jh7110_gpio: remove unneeded cleanup
    
    Any failure within bus_alloc_resources() will call bus_release_resources();
    thus the call is redundant here.
    
    MFC after:      3 days
    Sponsored by:   The FreeBSD Foundation
---
 sys/riscv/starfive/jh7110_gpio.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/sys/riscv/starfive/jh7110_gpio.c b/sys/riscv/starfive/jh7110_gpio.c
index 96b2cef43a4c..93de49e79ace 100644
--- a/sys/riscv/starfive/jh7110_gpio.c
+++ b/sys/riscv/starfive/jh7110_gpio.c
@@ -295,7 +295,6 @@ jh7110_gpio_attach(device_t dev)
 
 	if (bus_alloc_resources(dev, jh7110_gpio_spec, &sc->res) != 0) {
 		device_printf(dev, "Could not allocate resources\n");
-		bus_release_resources(dev, jh7110_gpio_spec, &sc->res);
 		mtx_destroy(&sc->mtx);
 		return (ENXIO);
 	}
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.