Hello,

it took a while, but finally I tried to fix the problem with the two methods you told me. Here's the results:

As reported before, doing

echo 'Sony:DSC - F505:0x80400' >/proc/scsi/device_info

works fine for both, 2.6.8 and 2.6.9 kernels, BUT only if the kernel option
CONFIG_USB_STORAGE_RW_DETECT is not set! If this option is set, mounting the camera fails with the same errors described before.
Furthermore there's a problem with the "haldaemon" that's started by default on Fedora Core 3 systems. If the deamon is running when I plug in the camera, the system freezes completely. There's nothing I could do but to reboot the machine.


I couldn't apply the kernel patch directly, because the versions of the files in the 2.6.9 kernel seem to be different from the ones that you used to create the patch.
So I edited the files manually, and it worked fine! Nevertheless I had the same problems that I had with the echo version: "CONFIG_USB_STORAGE_RW_DETECT" has to be switched of and the "haldaemon" must not be running!


Thanks again!
Greetings,
Dietrich



On Wed, 10 Nov 2004, Alan Stern wrote:

Okay, this problem has come up before.  If you like, you should be able to
fix it by doing

        echo 'Sony:DSC - F505:0x80400' >/proc/scsi/device_info

as root, at some time when the scsi_mod module is loaded but your device
hasn't been plugged in yet.  Alternatively, the patch below (for 2.6.9)
should provide an easier way to accomplish the same thing.  Let me know
how it works out.

Alan Stern



===== drivers/usb/storage/scsiglue.c 1.87 vs edited =====
--- 1.87/drivers/usb/storage/scsiglue.c 2004-11-01 13:59:21 -05:00
+++ edited/drivers/usb/storage/scsiglue.c       2004-11-10 14:39:53 -05:00
@@ -143,6 +143,11 @@
                sdev->use_10_for_ms = 1;
        }

+       /* Some devices choke when they receive a PREVENT-ALLOW MEDIUM
+        * REMOVAL command, so suppress those commands. */
+       if (us->flags & US_FL_NOT_LOCKABLE)
+               sdev->lockable = 0;
+
        /* this is to satisfy the compiler, tho I don't think the
         * return code is ever checked anywhere. */
        return 0;
===== drivers/usb/storage/usb.h 1.64 vs edited =====
--- 1.64/drivers/usb/storage/usb.h      2004-10-20 12:38:15 -04:00
+++ edited/drivers/usb/storage/usb.h    2004-11-10 14:28:10 -05:00
@@ -73,6 +73,7 @@
#define US_FL_SCM_MULT_TARG   0x00000020 /* supports multiple targets       */
#define US_FL_FIX_INQUIRY     0x00000040 /* INQUIRY response needs faking   */
#define US_FL_FIX_CAPACITY    0x00000080 /* READ CAPACITY response too big  */
+#define US_FL_NOT_LOCKABLE    0x00000200 /* PREVENT/ALLOW not supported        
    */

/* Dynamic flag definitions: used in set_bit() etc. */
#define US_FLIDX_URB_ACTIVE     18  /* 0x00040000  current_urb is in use  */
===== drivers/usb/storage/unusual_devs.h 1.161 vs edited =====
--- 1.161/drivers/usb/storage/unusual_devs.h    2004-10-20 12:38:15 -04:00
+++ edited/drivers/usb/storage/unusual_devs.h   2004-11-10 14:35:01 -05:00
@@ -180,6 +180,13 @@
                "CD-R/RW Drive",
                US_SC_8070, US_PR_CB, NULL, 0),

+/* Reported by Adriaan Penning <[EMAIL PROTECTED]> */
+UNUSUAL_DEV(  0x04da, 0x2372, 0x0000, 0x9999,
+               "Panasonic",
+               "DMC-LCx Camera",
+               US_SC_DEVICE, US_PR_DEVICE, NULL,
+               US_FL_FIX_CAPACITY | US_FL_NOT_LOCKABLE ),
+
/* Most of the following entries were developed with the help of
 * Shuttle/SCM directly.
 */
@@ -265,12 +272,11 @@
                US_SC_8070, US_PR_BULK, NULL,
                US_FL_FIX_INQUIRY ),

-/* This entry is needed because the device reports Sub=ff */
UNUSUAL_DEV(  0x054c, 0x0010, 0x0106, 0x0450,
                "Sony",
                "DSC-S30/S70/S75/505V/F505/F707/F717/P8",
                US_SC_SCSI, US_PR_DEVICE, NULL,
-               US_FL_SINGLE_LUN | US_FL_MODE_XLATE ),
+               US_FL_SINGLE_LUN | US_FL_NOT_LOCKABLE ),

/* This entry is needed because the device reports Sub=ff */
UNUSUAL_DEV(  0x054c, 0x0010, 0x0500, 0x0500,





-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. http://productguide.itmanagersjournal.com/
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-users

Reply via email to