Use the right ordering of args on mtx_init(). No functional changes
since the args in question was all zero's. Found by: Jimmy Olgeni <olgeni@FreeBSD.org>
This commit is contained in:
parent
ad88cfbeec
commit
166655f4a8
@ -156,7 +156,7 @@ ata_attach(device_t dev)
|
||||
|
||||
/* initialize queue and associated lock */
|
||||
bzero(&ch->queue_mtx, sizeof(struct mtx));
|
||||
mtx_init(&ch->queue_mtx, "ATA queue lock", MTX_DEF, 0);
|
||||
mtx_init(&ch->queue_mtx, "ATA queue lock", NULL, MTX_DEF);
|
||||
TAILQ_INIT(&ch->ata_queue);
|
||||
|
||||
/* do not attach devices if we are in early boot */
|
||||
|
@ -1324,7 +1324,7 @@ ata_promise_chipinit(device_t dev)
|
||||
ctlr->driver = malloc(sizeof(struct ata_promise_sx4),
|
||||
M_TEMP, M_NOWAIT | M_ZERO);
|
||||
hpkt = ctlr->driver;
|
||||
mtx_init(&hpkt->mtx, "ATA promise HPKT lock", MTX_DEF, 0);
|
||||
mtx_init(&hpkt->mtx, "ATA promise HPKT lock", NULL, MTX_DEF);
|
||||
hpkt->busy = hpkt->head = hpkt->tail = 0;
|
||||
|
||||
if ((bus_setup_intr(dev, ctlr->r_irq, ATA_INTR_FLAGS,
|
||||
|
@ -97,7 +97,7 @@ ad_attach(struct ata_device *atadev)
|
||||
adp->sectors = 17;
|
||||
adp->heads = 8;
|
||||
}
|
||||
mtx_init(&adp->queue_mtx, "ATA disk bioqueue lock", MTX_DEF, 0);
|
||||
mtx_init(&adp->queue_mtx, "ATA disk bioqueue lock", NULL, MTX_DEF);
|
||||
bioq_init(&adp->queue);
|
||||
|
||||
lbasize = (u_int32_t)atadev->param->lba_size_1 |
|
||||
|
@ -230,7 +230,7 @@ acd_init_lun(struct ata_device *atadev)
|
||||
if (!(cdp = malloc(sizeof(struct acd_softc), M_ACD, M_NOWAIT | M_ZERO)))
|
||||
return NULL;
|
||||
bioq_init(&cdp->queue);
|
||||
mtx_init(&cdp->queue_mtx, "ATAPI CD bioqueue lock", MTX_DEF, 0);
|
||||
mtx_init(&cdp->queue_mtx, "ATAPI CD bioqueue lock", NULL, MTX_DEF);
|
||||
cdp->device = atadev;
|
||||
cdp->lun = ata_get_lun(&acd_lun_map);
|
||||
cdp->block_size = 2048;
|
||||
|
@ -82,7 +82,7 @@ afd_attach(struct ata_device *atadev)
|
||||
fdp->lun = ata_get_lun(&afd_lun_map);
|
||||
ata_set_name(atadev, "afd", fdp->lun);
|
||||
bioq_init(&fdp->queue);
|
||||
mtx_init(&fdp->queue_mtx, "ATAPI FD bioqueue lock", MTX_DEF, 0);
|
||||
mtx_init(&fdp->queue_mtx, "ATAPI FD bioqueue lock", NULL, MTX_DEF);
|
||||
|
||||
if (afd_sense(fdp)) {
|
||||
free(fdp, M_AFD);
|
||||
|
@ -106,7 +106,7 @@ ast_attach(struct ata_device *atadev)
|
||||
stp->lun = ata_get_lun(&ast_lun_map);
|
||||
ata_set_name(atadev, "ast", stp->lun);
|
||||
bioq_init(&stp->queue);
|
||||
mtx_init(&stp->queue_mtx, "ATAPI TAPE bioqueue lock", MTX_DEF, 0);
|
||||
mtx_init(&stp->queue_mtx, "ATAPI TAPE bioqueue lock", NULL, MTX_DEF);
|
||||
|
||||
if (ast_sense(stp)) {
|
||||
free(stp, M_AST);
|
||||
|
Loading…
x
Reference in New Issue
Block a user