diff options
-rw-r--r-- | sys/geom/eli/g_eli.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/sys/geom/eli/g_eli.c b/sys/geom/eli/g_eli.c index d4b85cd..0e5b531 100644 --- a/sys/geom/eli/g_eli.c +++ b/sys/geom/eli/g_eli.c @@ -324,6 +324,13 @@ g_eli_worker(void *arg) wr = arg; sc = wr->w_softc; +#ifdef SMP + /* Before sched_bind() to a CPU, wait for all CPUs to go on-line. */ + if (sc->sc_crypto == G_ELI_CRYPTO_SW && g_eli_threads == 0) { + while (!smp_started) + tsleep(wr, 0, "geli:smp", hz / 4); + } +#endif mtx_lock_spin(&sched_lock); sched_prio(curthread, PRIBIO); if (sc->sc_crypto == G_ELI_CRYPTO_SW && g_eli_threads == 0) |