usb flashkey disk copy error
John-Mark Gurney
gurney_j at efn.org
Sat Sep 13 00:32:19 PDT 2003
Barney Wolff wrote this message on Fri, Sep 12, 2003 at 15:52 -0400:
> Patch below had some problems. Needed #ifdef USB_DEBUG around the
> ref to ohcidebug to compile, and either BROKEN_OHCI added to the
> list of valid options or (as I did) kludged to 1. Worse, trying
> to mount_msdosfs my camera caused an instant panic: "Length went
> negative: -4096". If that's not enough info, I imagine I can
> recreate the panic.
Yeh, I ran across this when testing on a system. But you can
ignore this patch. With this patch applied the USB device would
stop working even after I fixed the #ifdef and -4096 problems.. (btw,
I never "intended" for the patch to compile w/o USB_DEBUG, but since
the modules don't inherit the kernel config's make files, it breaks)..
> Just to restate my particular problem, I get the wrong data on read
> of an existing file from the memory stick on the camera. I have
> not dared to try writing to it since reads don't work.
Ok, I have a system that I'm going to be looking at tomorrow that
has a similar issue. Could you file an add in to kern/54982 that
includes the dmesg output of your usb messages (ohci/uhci/umass/etc.)
I tried using my 128meg CF in the same reader/machine that was having
problems reading, and it worked. So it looks like reads are broken
for only some devices, not all. :(
> On Sun, Sep 07, 2003 at 01:39:08PM -0700, John-Mark Gurney wrote:
> > Barney Wolff wrote this message on Sun, Sep 07, 2003 at 15:48 -0400:
> > > I can't do more detailed diagnosis right now, but could in a few days.
> >
> > When you get a chance (or anyone else who has this problem), try the
> > attached patch, and add options BROKEN_OHCI to your kernel config file.
> > Please set hw.usb.ohci.debug=1, and send me the dmesg output of the
> > writes. (When you copy the data to the media.)
> >
> > Hmmm. I just thought of something. Now is the data corrupt still correupt
> > on another system? What I mean is did the data get written properly, but
> > just isn't being read back from the media correctly. Unless you are
> > coping a file larger than memory size, the cmp just pulls it from memory,
> > not from the media. The umount/mount forces a flush of the cache, and so
> > attempts to read from the media.
--
John-Mark Gurney Voice: +1 415 225 5579
"All that I will do, has been done, All that I have, has not."
More information about the freebsd-current
mailing list