From owner-freebsd-bugs Tue Aug 6 9:50: 8 2002 Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 55DD237B400 for ; Tue, 6 Aug 2002 09:50:04 -0700 (PDT) Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1755743E3B for ; Tue, 6 Aug 2002 09:50:04 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.12.4/8.12.4) with ESMTP id g76Go3JU074172 for ; Tue, 6 Aug 2002 09:50:03 -0700 (PDT) (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.12.4/8.12.4/Submit) id g76Go3fQ074171; Tue, 6 Aug 2002 09:50:03 -0700 (PDT) Date: Tue, 6 Aug 2002 09:50:03 -0700 (PDT) Message-Id: <200208061650.g76Go3fQ074171@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org Cc: From: Ian Dowse Subject: Re: kern/41382: ATAPI TAPE hung in atrpq Reply-To: Ian Dowse Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org The following reply was made to PR kern/41382; it has been noted by GNATS. From: Ian Dowse To: Sean Cc: FreeBSD-gnats-submit@FreeBSD.org Subject: Re: kern/41382: ATAPI TAPE hung in atrpq Date: Tue, 06 Aug 2002 17:47:48 +0100 In message <20020806155754.92708A6A2C@visi.gothic.net.au>, Sean writes: > Seagte STT20000A (IDE Travan 5 tape drive) - using dump to write out > a partition, dump hangs in 'atprq' (according to top) on > closing the tape device. The following patch is reported to fix this problem. Can you try it to see if it helps? Ian Index: atapi-all.c =================================================================== RCS file: /home/iedowse/CVS/src/sys/dev/ata/atapi-all.c,v retrieving revision 1.46.2.14 diff -u -r1.46.2.14 atapi-all.c --- atapi-all.c 14 Jul 2002 12:35:28 -0000 1.46.2.14 +++ atapi-all.c 14 Jul 2002 23:39:00 -0000 @@ -186,6 +186,7 @@ request->flags = flags; request->timeout = timeout * hz; request->ccbsize = atadev->param->packet_size ? 16 : 12; + request->error = EINPROGRESS; bcopy(ccb, request->ccb, request->ccbsize); if (callback) { request->callback = callback; @@ -215,7 +216,8 @@ } /* wait for request to complete */ - tsleep((caddr_t)request, PRIBIO, "atprq", 0); + if (request->error == EINPROGRESS) + tsleep((caddr_t)request, PRIBIO, "atprq", 0); splx(s); error = request->error; if (error) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message