mps(4): Add forgotten D_MPSAFE to dev_ops and use callout_init_mp().
authorSascha Wildner <saw@online.de>
Sat, 2 Aug 2014 10:57:36 +0000 (12:57 +0200)
committerSascha Wildner <saw@online.de>
Sat, 2 Aug 2014 10:57:36 +0000 (12:57 +0200)
sys/dev/raid/mps/mps.c
sys/dev/raid/mps/mps_user.c

index 6344ff0..7260fb0 100644 (file)
@@ -864,7 +864,7 @@ mps_alloc_requests(struct mps_softc *sc)
                cm->cm_desc.Default.SMID = i;
                cm->cm_sc = sc;
                TAILQ_INIT(&cm->cm_chain_list);
-               callout_init(&cm->cm_callout);
+               callout_init_mp(&cm->cm_callout);
 
                /* XXX Is a failure here a critical problem? */
                if (bus_dmamap_create(sc->buffer_dmat, 0, &cm->cm_dmamap) == 0)
@@ -1037,7 +1037,7 @@ mps_attach(struct mps_softc *sc)
        mps_dprint(sc, MPS_TRACE, "%s\n", __func__);
 
        lockinit(&sc->mps_lock, "MPT2SAS lock", 0, LK_CANRECURSE);
-       callout_init(&sc->periodic);
+       callout_init_mp(&sc->periodic);
        TAILQ_INIT(&sc->event_list);
 
        if ((error = mps_transition_ready(sc)) != 0) {
index 32354bc..8501f19 100644 (file)
@@ -106,7 +106,7 @@ static d_close_t    mps_close;
 static d_ioctl_t       mps_ioctl_devsw;
 
 static struct dev_ops mps_ops = {
-       { "mps", 0, 0 },
+       { "mps", 0, D_MPSAFE },
        .d_open =       mps_open,
        .d_close =      mps_close,
        .d_ioctl =      mps_ioctl_devsw,