From owner-freebsd-bugs@FreeBSD.ORG Sun Feb 18 10:50:06 2007 Return-Path: X-Original-To: freebsd-bugs@hub.freebsd.org Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id C8B7916A401 for ; Sun, 18 Feb 2007 10:50:06 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [69.147.83.40]) by mx1.freebsd.org (Postfix) with ESMTP id A10B513C467 for ; Sun, 18 Feb 2007 10:50:06 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.4/8.13.4) with ESMTP id l1IAo6Tp015732 for ; Sun, 18 Feb 2007 10:50:06 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.4/8.13.4/Submit) id l1IAo64E015729; Sun, 18 Feb 2007 10:50:06 GMT (envelope-from gnats) Resent-Date: Sun, 18 Feb 2007 10:50:06 GMT Resent-Message-Id: <200702181050.l1IAo64E015729@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Martin Birgmeier Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 285A016A400 for ; Sun, 18 Feb 2007 10:43:53 +0000 (UTC) (envelope-from martin@email.aon.at) Received: from email.aon.at (nat-warsl417-02.aon.at [195.3.96.120]) by mx1.freebsd.org (Postfix) with ESMTP id 84E6113C46B for ; Sun, 18 Feb 2007 10:43:52 +0000 (UTC) (envelope-from martin@email.aon.at) Received: (qmail 15780 invoked from network); 18 Feb 2007 10:17:10 -0000 Received: from unknown (HELO email.aon.at) ([172.18.5.230]) (envelope-sender ) by fallback01.highway.telekom.at (qmail-ldap-1.03) with SMTP for ; 18 Feb 2007 10:17:10 -0000 Received: (qmail 3810 invoked from network); 18 Feb 2007 10:17:05 -0000 Received: from m1458p030.adsl.highway.telekom.at (HELO gandalf.xyzzy) ([80.121.54.62]) (envelope-sender ) by smarthub77.highway.telekom.at (qmail-ldap-1.03) with SMTP for ; 18 Feb 2007 10:17:05 -0000 Received: from gandalf.xyzzy (localhost.xyzzy [127.0.0.1]) by gandalf.xyzzy (8.13.8/8.13.8) with ESMTP id l1IAH5cR003935 for ; Sun, 18 Feb 2007 11:17:05 +0100 (CET) (envelope-from martin@gandalf.xyzzy) Received: (from martin@localhost) by gandalf.xyzzy (8.13.8/8.13.8/Submit) id l1IAH4w1003934; Sun, 18 Feb 2007 11:17:04 +0100 (CET) (envelope-from martin) Message-Id: <200702181017.l1IAH4w1003934@gandalf.xyzzy> Date: Sun, 18 Feb 2007 11:17:04 +0100 (CET) From: Martin Birgmeier To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Cc: Subject: kern/109270: [burncd] [atapi] [ata] [patch] patch for burncd blank & fixate X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Martin Birgmeier List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 18 Feb 2007 10:50:07 -0000 >Number: 109270 >Category: kern >Synopsis: [burncd] [atapi] [ata] [patch] patch for burncd blank & fixate >Confidential: no >Severity: serious >Priority: medium >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Sun Feb 18 10:50:05 GMT 2007 >Closed-Date: >Last-Modified: >Originator: Martin Birgmeier >Release: FreeBSD 6.2-RELEASE i386 >Organization: MBi at home >Environment: System: FreeBSD gandalf.xyzzy 6.2-RELEASE FreeBSD 6.2-RELEASE #1: Fri Feb 16 22:33:38 CET 2007 root@gandalf.xyzzy:/d/14.1/OBJ/FreeBSD/RELENG_6_2_0_RELEASE/src/sys/XYZZY i386 >Description: burncd blank & burncd ... fixate hang at the blanking/fixate stage >How-To-Repeat: see description >Fix: The problem seems to stem from an incorrect reading of the MMC ATAPI specification - the patch in atapi-cd.c shows what is wrong. For me this gets it working for the first time since ages (RELENG_5 probably). In RELENG_4 this was working (the code was not in there). The ata.h patch is just a miscellaneous fix, the constants affected are not used anywhere in the current code. I assume that this patch closes kern/79255, kern/95344, bin/98082, bin/98502, and probably bin/63319. It also closes kern/104270, which contains a too simple-minded patch. Sorry, the e-mail address is invalid - too much spam. Respond by adding to the PR. *** sys/dev/ata/atapi-cd.c.ORIG Sat Sep 2 19:01:32 2006 --- sys/dev/ata/atapi-cd.c Fri Feb 16 21:34:12 2007 *************** *** 1234,1240 **** request->flags = ATA_R_ATAPI | ATA_R_READ; request->timeout = 30; ata_queue_request(request); ! if (!request->error && request->u.atapi.sense.error & ATA_SENSE_VALID) *finished = ((request->u.atapi.sense.specific2 | (request->u.atapi.sense.specific1 << 8)) * 100) / 65535; else --- 1234,1240 ---- request->flags = ATA_R_ATAPI | ATA_R_READ; request->timeout = 30; ata_queue_request(request); ! if (!request->error && request->u.atapi.sense.specific & ATA_SENSE_SPEC_VALID) *finished = ((request->u.atapi.sense.specific2 | (request->u.atapi.sense.specific1 << 8)) * 100) / 65535; else *** sys/sys/ata.h.ORIG Tue Apr 4 18:07:41 2006 --- sys/sys/ata.h Fri Feb 16 21:33:33 2007 *************** *** 373,381 **** #define ATA_SENSE_VOLUME_OVERFLOW 0x0d /* volume overflow */ #define ATA_SENSE_MISCOMPARE 0x0e /* data dont match the medium */ #define ATA_SENSE_RESERVED 0x0f ! #define ATA_SENSE_ILI 0x20; ! #define ATA_SENSE_EOM 0x40; ! #define ATA_SENSE_FILEMARK 0x80; u_int32_t cmd_info; /* cmd information */ u_int8_t sense_length; /* additional sense len (n-7) */ --- 373,381 ---- #define ATA_SENSE_VOLUME_OVERFLOW 0x0d /* volume overflow */ #define ATA_SENSE_MISCOMPARE 0x0e /* data dont match the medium */ #define ATA_SENSE_RESERVED 0x0f ! #define ATA_SENSE_ILI 0x20 ! #define ATA_SENSE_EOM 0x40 ! #define ATA_SENSE_FILEMARK 0x80 u_int32_t cmd_info; /* cmd information */ u_int8_t sense_length; /* additional sense len (n-7) */ >Release-Note: >Audit-Trail: >Unformatted: