From 27c97f766064c33d3a0cb80d7ceaa82de6682058 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dag-Erling=20Sm=C3=B8rgrav?= Date: Wed, 24 Oct 2001 18:24:09 +0000 Subject: [PATCH] Don't enable write cacheing on devices that don't support tagged queuing unless hw.ata.wc is set. Approved by: sos MFC after: 1 week --- sys/dev/ata/ata-disk.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/ata/ata-disk.c b/sys/dev/ata/ata-disk.c index d9f662f305ab..e7117158602f 100644 --- a/sys/dev/ata/ata-disk.c +++ b/sys/dev/ata/ata-disk.c @@ -158,7 +158,7 @@ ad_attach(struct ata_softc *scp, int device) ata_printf(scp, device, "enabling readahead cache failed\n"); /* enable write cacheing if allowed and not default on device */ - if (ata_wc || ata_tags) { + if (ata_wc || (ata_tags && ad_tagsupported(adp))) { if (ata_command(adp->controller, adp->unit, ATA_C_SETFEATURES, 0, 0, ATA_C_F_ENAB_WCACHE, ATA_WAIT_INTR)) ata_printf(scp, device, "enabling write cache failed\n");