From owner-freebsd-hackers Thu May 24 15:51:11 2001 Delivered-To: freebsd-hackers@freebsd.org Received: from messiah.megadeb.org (cpe.atm0-0-0-218131.arcnxx5.customer.tele.dk [62.242.79.117]) by hub.freebsd.org (Postfix) with ESMTP id 3A41437B423 for ; Thu, 24 May 2001 15:51:07 -0700 (PDT) (envelope-from messiah@runbox.com) Received: (from messiah@localhost) by messiah.megadeb.org (8.11.3/8.11.3) id f4OMqTv07673 for freebsd-hackers@freebsd.org; Fri, 25 May 2001 00:52:29 +0200 (CEST) (envelope-from messiah) Date: Fri, 25 May 2001 00:52:28 +0200 From: Munish Chopra To: freebsd-hackers@freebsd.org Subject: Re: Fix for ATAPI CDRW problem: MODE_SELECT_BIG - ILLEGAL REQUEST asc=1a Message-ID: <20010525005228.D7219@messiah.megadeb.org> Mail-Followup-To: freebsd-hackers@freebsd.org References: <200105242223.f4OMNSm16593@starvation.hungry.com> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <200105242223.f4OMNSm16593@starvation.hungry.com>; from bpk@Hungry.COM on Thu, May 24, 2001 at 03:23:28PM -0700 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, May 24, 2001 at 03:23:28PM -0700, bpk@Hungry.COM wrote: > > I recently acquired a new Yamaha 2100E ATAPI CDRW drive, and encountered > this error during the fixation stage with burncd on a FreeBSD 4.3 release > system: > > burncd: ioctl(CDRIOCCLOSEDISK): Input/output error > > and the kernel complains: > > acd0: MODE_SELECT_BIG - ILLEGAL REQUEST asc=1a ascq=00 error=00 > > After perusing the ATA/ATAPI-5 and MMC-3 specifications I realized that the > asc=1a error (PARAMETER LENGTH LIST ERROR) was telling me that the CDRW > drive wasn't happy with the length of the CLOSE DISK mode page that was > being sent to it. > > In atapi-cd.c the acd_close_disk() function is sending the write_param > mode page structure in the CLOSE DISK command to the drive. > > Upon examination of struct write_param in atapi-cd.h I noticed sure enough > the last four bytes of the page were commented out: > /* > u_int8_t vendor_specific_byte0; > u_int8_t vendor_specific_byte1; > u_int8_t vendor_specific_byte2; > u_int8_t vendor_specific_byte3; > */ > > I uncommented these lines, recompiled/rebooted, and tried burncd again. > This time it failed right away on the CDRIOCOPENDISK ioctl, with the kernel > error being something about an invalid parameter. > > So I reverted struct write_param back to the original commented version. > But I copied write_param to a new struct called full_write_param and > uncommented the last 4 bytes. I then changed acd_close_disk() to use the > full_write_param struct rather than the original write_param struct. > > Recompiled/rebooted. > > The result: success! I'm not sure how things work here on -hackers yet, but I know Søren (sos@freebsd.dk) is handling the burncd stuff. You might want to send him a copy of that patch. -- -Munish To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message