mfi(4): Avoid some code duplication.
authorSascha Wildner <saw@online.de>
Fri, 6 Jan 2012 18:06:48 +0000 (19:06 +0100)
committerSascha Wildner <saw@online.de>
Fri, 6 Jan 2012 18:06:48 +0000 (19:06 +0100)
sys/dev/raid/mfi/mfi.c

index 5f5be44..543460b 100644 (file)
@@ -1014,15 +1014,12 @@ mfi_free(struct mfi_softc *sc)
                sysctl_ctx_free(&sc->mfi_sysctl_ctx);
 
 #if 0 /* XXX swildner: not sure if we need something like mtx_initialized() */
-
-       if (mtx_initialized(&sc->mfi_io_lock)) {
-               lockuninit(&sc->mfi_io_lock);
-               sx_destroy(&sc->mfi_config_lock);
-       }
+       if (mtx_initialized(&sc->mfi_io_lock))
 #endif
-
+       {
        lockuninit(&sc->mfi_io_lock);
        lockuninit(&sc->mfi_config_lock);
+       }
 
        return;
 }