changeset 4078:63cca4b3778c

6315147 cdrw fails audio extraction with method unknown error
author rameshc
date Fri, 20 Apr 2007 05:39:31 -0700
parents 0b7e19932b34
children 4c31c5bc2389
files usr/src/cmd/cdrw/device.c
diffstat 1 files changed, 8 insertions(+), 12 deletions(-) [+]
line wrap: on
line diff
--- a/usr/src/cmd/cdrw/device.c	Thu Apr 19 21:55:12 2007 -0700
+++ b/usr/src/cmd/cdrw/device.c	Fri Apr 20 05:39:31 2007 -0700
@@ -2,9 +2,8 @@
  * CDDL HEADER START
  *
  * The contents of this file are subject to the terms of the
- * Common Development and Distribution License, Version 1.0 only
- * (the "License").  You may not use this file except in compliance
- * with the License.
+ * Common Development and Distribution License (the "License").
+ * You may not use this file except in compliance with the License.
  *
  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  * or http://www.opensolaris.org/os/licensing.
@@ -20,7 +19,7 @@
  * CDDL HEADER END
  */
 /*
- * Copyright 2006 Sun Microsystems, Inc.  All rights reserved.
+ * Copyright 2007 Sun Microsystems, Inc.  All rights reserved.
  * Use is subject to license terms.
  */
 
@@ -198,12 +197,6 @@
 	if (is_old_sun_drive(dev)) {
 		dev->d_read_audio = toshiba_read_audio;
 		dev->d_speed_ctrl = toshiba_speed_ctrl;
-	} else if (use_cd_speed)  {
-		/*
-		 * Work around for Lite-on FW bug in which rt_speed_ctrl
-		 * doesn't work correctly.
-		 */
-		dev->d_speed_ctrl = cd_speed_ctrl;
 	} else {
 		/*
 		 * If the CD Read Feature is supported, READ CD will work
@@ -222,10 +215,13 @@
 		}
 		/*
 		 * If the Real Time Streaming Feature is supported then
-		 * Real-time streaming commands can be used for speed control.
+		 * Real-time streaming commands can be used for speed control
+		 * (except when we want to use cd_speed_ctrl explicitly which
+		 * is specified by setting use_cd_speed to 1).
 		 * Otherwise try SET CD SPEED.
 		 */
-		if (ftr_supported(fd, MMC_FTR_RT_STREAM) == 1) {
+		if ((ftr_supported(fd, MMC_FTR_RT_STREAM) == 1) &&
+		    !use_cd_speed) {
 			dev->d_speed_ctrl = rt_streaming_ctrl;
 			if (debug)
 				(void) printf("using rt speed ctrl\n");