diff options
Diffstat (limited to 'sys/pci/if_pcn.c')
-rw-r--r-- | sys/pci/if_pcn.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/pci/if_pcn.c b/sys/pci/if_pcn.c index aa9549e..c5139ef 100644 --- a/sys/pci/if_pcn.c +++ b/sys/pci/if_pcn.c @@ -496,6 +496,10 @@ static int pcn_attach(dev) sc = device_get_softc(dev); unit = device_get_unit(dev); + /* Initialize our mutex. */ + mtx_init(&sc->pcn_mtx, device_get_nameunit(dev), MTX_DEF); + PCN_LOCK(sc); + /* * Handle power management nonsense. */ @@ -582,10 +586,6 @@ static int pcn_attach(dev) goto fail; } - /* Initialize our mutex. */ - mtx_init(&sc->pcn_mtx, device_get_nameunit(dev), MTX_DEF); - PCN_LOCK(sc); - /* Reset the adapter. */ pcn_reset(sc); |