RE: 8.0-RC3 USB lock up on mounting two partitions from one USB drive

2009-11-17 Thread Guojun Jin
Did newfs on those partition and made things worsen -- restore completely fails:
(I had experienced another similar problem on an IDE, which works well for 6.4 
and 7.2, but 8.0.)
This dirve works fine under FreeBSD 6.4.

Is something new in 8.0 making disk partition schema changed?

g_vfs_done():da0s3d[READ(offset=98304, length=16384)]error = 6
g_vfs_done():da0s3d[WRITE(offset=192806912, length=16384)]error = 6
fopen: Device not configured
cannot create save file ./restoresymtable for symbol table
abort? [yn] (da0:umass-sim0:0:0:0): Synchronize cache failed, status == 0xa, scs
i status == 0x0
(da0:umass-sim0:0:0:0): removing device entry
ugen1.2:  at usbus1
umass0:  on usbus1
umass0:  SCSI over Bulk-Only; quirks = 0x
umass0:0:0:-1: Attached to scbus0
da0 at umass-sim0 bus 0 target 0 lun 0
da0:  Fixed Direct Access SCSI-0 device
da0: 40.000MB/s transfers
da0: 114473MB (234441648 512 byte sectors: 255H 63S/T 14593C)
Device da0s3d went missing before all of the data could be written to it; expect
 data loss.

99  23:19   sysinstall
   100  23:20   newfs /dev/da0s3d
   101  23:20   newfs /dev/da0s3e
   102  23:21   mount /dev/da0s3d /mnt
   103  23:21   cd /mnt
   104  23:21   dump -0f - /home | restore -rf -
   105  23:27   history 15



-Original Message-
From: Guojun Jin
Sent: Tue 11/17/2009 11:05 PM
To: freebsd-sta...@freebsd.org
Cc: questi...@freebsd.org; freebsd-usb@freebsd.org
Subject: 8.0-RC3 USB lock up on mounting two partitions from one USB drive
 
When mounting two partitions from a USB dirve, it can cause the drive access 
lock up for a long time.
Details:

Terminal 1 --
term1# mount /dev/da0s3d  /mnt
term1# cd /mnt ; rm -fr *

when rm starts, go to terminal 2 and do:

term2# mount /dev/da0s3e /dist ### this will hanging for a long time and USB 
hard drive activity light is off.
After more than 1-2 minutes, mount returns, and the drive activity light is 
blinking, thus removing is going on.

term2# ls /dist   ### this will cause dUSB dirve hanging again -- no avtivity.
Similarly, ls will finish in a couple of miniutes or longer, the rm command 
continues; but for a while, the drive
activity will stop again.

Reboot machine, repeat the above steps, and result will be the same. Reboot 
machine again, and just mount one
partition, then doing "rm -rf *" without involve the second partition, rm will 
finish quickly.

Has anyone obseved this behave on 8.0-RC?

-Jin














___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: usb printer rejects incoming data [SOLVED]

2009-11-17 Thread Alex Troussov
On Tue, Nov 17, 2009 at 09:16:03AM +0100, Hans Petter Selasky wrote:
> > Recently I upgraded to the latest RELENG_8 and rebuilt world.
> > Now I'm having strange problems with my USB printer (Samsung CLP 315).
> > Digging into it these last days, I found that it seems to refuse
> > incoming data via USB port.
> >
> > >sudo cat tiger.qpdl > /dev/usb/4.3.0
> >
> > cat: stdout: Input/output error
> >
> > I'm sure this file tiger.qpdl contains the data needed, I created it
> > from /usr/local/share/ghostscript/8.64/examples/tiger.eps using gs +
> > foo2qpdl and tested on another PC.
> 
> .0 is the control endpoint. You won't get any data through there :-)
> 
> See:
> 
> usbconfig -u 4 -a 3 dump_curr_config_desc
> 
> for the correct OUT endpoint.

OK, here is what it gives:

>sudo usbconfig -u 4 -a 3 dump_curr_config_desc
ugen4.3:  at usbus4, cfg=0
md=HOST spd=HIGH (480Mbps) pwr=ON

 Configuration index 0

bLength = 0x0009 
bDescriptorType = 0x0002 
wTotalLength = 0x0020 
bNumInterfaces = 0x0001 
bConfigurationValue = 0x0001 
iConfiguration = 0x  
bmAttributes = 0x00c0 
bMaxPower = 0x0001 

Interface 0
  bLength = 0x0009 
  bDescriptorType = 0x0004 
  bInterfaceNumber = 0x 
  bAlternateSetting = 0x 
  bNumEndpoints = 0x0002 
  bInterfaceClass = 0x0007 
  bInterfaceSubClass = 0x0001 
  bInterfaceProtocol = 0x0002 
  iInterface = 0x  

 Endpoint 0
bLength = 0x0007 
bDescriptorType = 0x0005 
bEndpointAddress = 0x0002 
bmAttributes = 0x0002 
wMaxPacketSize = 0x0200 
bInterval = 0x000a 
bRefresh = 0x 
bSynchAddress = 0x 

 Endpoint 1
bLength = 0x0007 
bDescriptorType = 0x0005 
bEndpointAddress = 0x0081 
bmAttributes = 0x0002 
wMaxPacketSize = 0x0200 
bInterval = 0x000a 
bRefresh = 0x 
bSynchAddress = 0x

I don't know where to look for the right endpoint here...

But I tried every endpoint - /dev/usb/4.3.0, /dev/usb/4.3.1 and
/dev/usb/4.3.2 - and the last one worked.
So, the problem is solved for me.

Just for my curiosity, where can I read more about USB endpoints?

WBR, Alex
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: usb printer rejects incoming data

2009-11-17 Thread Hans Petter Selasky
On Tuesday 17 November 2009 00:07:41 Alex Troussov wrote:
> Hello all,
>
> Recently I upgraded to the latest RELENG_8 and rebuilt world.
> Now I'm having strange problems with my USB printer (Samsung CLP 315).
> Digging into it these last days, I found that it seems to refuse
> incoming data via USB port.
> I'm using foo2qpdl filter and it generates a standard QPDL stream for that
> printer, the problem occurs when I try to feed that data to the printer.
>
> Here is some details about my environment:
> >uname -a
>
> FreeBSD ..net 8.0-PRERELEASE FreeBSD 8.0-PRERELEASE #26: Sun
> Nov 15 15:44:11 CET 2009 r...@..net:/usr/obj/usr/src/sys/ERLEY 
> i386
>
> >sudo usbconfig
>
> ugen0.1:  at usbus0, cfg=0 md=HOST spd=FULL (12Mbps)
> pwr=ON ugen1.1:  at usbus1, cfg=0 md=HOST spd=FULL
> (12Mbps) pwr=ON ugen2.1:  at usbus2, cfg=0 md=HOST
> spd=FULL (12Mbps) pwr=ON ugen3.1:  at usbus3, cfg=0
> md=HOST spd=FULL (12Mbps) pwr=ON ugen4.1:  at usbus4,
> cfg=0 md=HOST spd=HIGH (480Mbps) pwr=ON ugen4.2: <802.11 bg WLAN Ralink> at
> usbus4, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=ON ugen0.2: 
> at usbus0, cfg=0 md=HOST spd=FULL (12Mbps) pwr=ON ugen4.3:  Samsung Electronics Co., Ltd.> at usbus4, cfg=0 md=HOST spd=HIGH (480Mbps)
> pwr=ON ugen1.2:  at usbus1, cfg=0 md=HOST spd=LOW
> (1.5Mbps) pwr=ON
>
> >sudo ls -l /dev/u* | grep 4.3
>
> lrw-rw-rw-  1 daemon  daemon   9 16 ноя 14:07 /dev/ugen4.3@ ->
> usb/4.3.0 crw-rw-rw-  1 daemon  daemon  0, 140 16 ноя 14:07 4.3.0
> crw-rw-rw-  1 daemon  daemon  0, 142 16 ноя 14:07 4.3.1
> crw-rw-rw-  1 daemon  daemon  0, 143 16 ноя 14:07 4.3.2
>
> >sudo cat tiger.qpdl > /dev/usb/4.3.0
>
> cat: stdout: Input/output error
>
> I'm sure this file tiger.qpdl contains the data needed, I created it
> from /usr/local/share/ghostscript/8.64/examples/tiger.eps using gs +
> foo2qpdl and tested on another PC.

Hi,

.0 is the control endpoint. You won't get any data through there :-)

See:

usbconfig -u 4 -a 3 dump_curr_config_desc

for the correct OUT endpoint.

--HPS
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"