summaryrefslogtreecommitdiff
path: root/sys/dev/ata/atapi-cd.c
diff options
context:
space:
mode:
authorSøren Schmidt <sos@FreeBSD.org>2008-04-10 13:05:05 +0000
committerSøren Schmidt <sos@FreeBSD.org>2008-04-10 13:05:05 +0000
commit9f82379c24da01a791b10154df1948893d56c3c0 (patch)
treef3e7a479de8c6c0f0f0f4fe2f5fd2f056d3b80be /sys/dev/ata/atapi-cd.c
parent3cba562fb91da77ecca7d67f368fc87a8f8851d9 (diff)
Notes
Diffstat (limited to 'sys/dev/ata/atapi-cd.c')
-rw-r--r--sys/dev/ata/atapi-cd.c13
1 files changed, 4 insertions, 9 deletions
diff --git a/sys/dev/ata/atapi-cd.c b/sys/dev/ata/atapi-cd.c
index df63fe15dd6b..a64cfeb8c537 100644
--- a/sys/dev/ata/atapi-cd.c
+++ b/sys/dev/ata/atapi-cd.c
@@ -1,5 +1,5 @@
/*-
- * Copyright (c) 1998 - 2007 Søren Schmidt <sos@FreeBSD.org>
+ * Copyright (c) 1998 - 2008 Søren Schmidt <sos@FreeBSD.org>
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -908,10 +908,7 @@ acd_set_ioparm(device_t dev)
struct ata_channel *ch = device_get_softc(device_get_parent(dev));
struct acd_softc *cdp = device_get_ivars(dev);
- if (ch->dma)
- cdp->iomax = min(ch->dma->max_iosize, 65534);
- else
- cdp->iomax = min(DFLTPHYS, 65534);
+ cdp->iomax = min(ch->dma.max_iosize, 65534);
}
static void
@@ -1706,8 +1703,7 @@ acd_describe(device_t dev)
(cdp->cap.media & MST_WRITE_CDRW) ? "CDRW" :
(cdp->cap.media & MST_WRITE_CDR) ? "CDR" :
(cdp->cap.media & MST_READ_DVDROM) ? "DVDROM":"CDROM",
- device_get_unit(ch->dev),
- (atadev->unit == ATA_MASTER) ? "master" : "slave");
+ device_get_unit(ch->dev), ata_unit2str(atadev));
device_printf(dev, "%s", "");
if (cdp->cap.cur_read_speed) {
@@ -1879,8 +1875,7 @@ acd_describe(device_t dev)
printf("with %d CD changer ", cdp->changer_info->slots);
printf("<%.40s/%.8s> at ata%d-%s %s\n",
atadev->param.model, atadev->param.revision,
- device_get_unit(ch->dev),
- (atadev->unit == ATA_MASTER) ? "master" : "slave",
+ device_get_unit(ch->dev), ata_unit2str(atadev),
ata_mode2str(atadev->mode) );
}
}