mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-03 09:00:21 +00:00
Initialize the callout structure earlier in attach before calling any
routines that can fail since ciss_free() always tries to stop and drain the callout.
This commit is contained in:
parent
b19b0de471
commit
aa1385cd7b
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=207335
@ -417,6 +417,7 @@ ciss_attach(device_t dev)
|
||||
sc = device_get_softc(dev);
|
||||
sc->ciss_dev = dev;
|
||||
mtx_init(&sc->ciss_mtx, "cissmtx", NULL, MTX_DEF);
|
||||
callout_init_mtx(&sc->ciss_periodic, &sc->ciss_mtx, 0);
|
||||
|
||||
/*
|
||||
* Do PCI-specific init.
|
||||
@ -429,7 +430,6 @@ ciss_attach(device_t dev)
|
||||
*/
|
||||
ciss_initq_free(sc);
|
||||
ciss_initq_notify(sc);
|
||||
callout_init_mtx(&sc->ciss_periodic, &sc->ciss_mtx, 0);
|
||||
|
||||
/*
|
||||
* Initalize device sysctls.
|
||||
|
Loading…
Reference in New Issue
Block a user