summaryrefslogtreecommitdiff
path: root/sys/dev/usb
diff options
context:
space:
mode:
authorbouyer <bouyer@NetBSD.org>2013-04-03 17:15:07 +0000
committerbouyer <bouyer@NetBSD.org>2013-04-03 17:15:07 +0000
commita3b0601a795b28251903bb1ef097485b8ff704fa (patch)
tree1357974b60f4397f0987772adb00192f5ca2dec5 /sys/dev/usb
parent92709f7e863ccc7bdc700a3cd94fa372825d8855 (diff)
Fix kernel dump on ahci controller, by making sure we won't sleep
while dumping: - introduce ata_delay() which either use delay() or kpause() depending on flags. use it in sata_reset_interface() and some ahci functions - kill ATA_NOSLEEP, it was tested but never set. use ATA_POLL instead. - reduce delay while polling in ahci, to speed up the dump Should fix PR kern/41095
Diffstat (limited to 'sys/dev/usb')
-rw-r--r--sys/dev/usb/umass_isdata.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/dev/usb/umass_isdata.c b/sys/dev/usb/umass_isdata.c
index e582e16d03a..42b008c555d 100644
--- a/sys/dev/usb/umass_isdata.c
+++ b/sys/dev/usb/umass_isdata.c
@@ -1,4 +1,4 @@
-/* $NetBSD: umass_isdata.c,v 1.27 2012/07/31 15:50:37 bouyer Exp $ */
+/* $NetBSD: umass_isdata.c,v 1.28 2013/04/03 17:15:07 bouyer Exp $ */
/*
* TODO:
@@ -37,7 +37,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: umass_isdata.c,v 1.27 2012/07/31 15:50:37 bouyer Exp $");
+__KERNEL_RCSID(0, "$NetBSD: umass_isdata.c,v 1.28 2013/04/03 17:15:07 bouyer Exp $");
#ifdef _KERNEL_OPT
#include "opt_umass.h"
@@ -288,8 +288,8 @@ uisdata_bio1(struct ata_drive_datas *drv, struct ata_bio *ata_bio)
DPRINTF(("%s\n", __func__));
/* XXX */
- if (ata_bio->flags & ATA_NOSLEEP) {
- printf("%s: ATA_NOSLEEP not supported\n", __func__);
+ if (ata_bio->flags & ATA_POLL) {
+ printf("%s: ATA_POLL not supported\n", __func__);
ata_bio->error = TIMEOUT;
ata_bio->flags |= ATA_ITSDONE;
return (ATACMD_COMPLETE);