On Tue, 2013-09-17 at 19:32 +0200, Harald Schmalzbauer wrote:
> Bezüglich Ian Lepore's Nachricht vom 17.09.2013 18:16 (localtime):
> > On Tue, 2013-09-17 at 17:38 +0200, Harald Schmalzbauer wrote:
> >> ...
> >>> Try this patch and see what happens:
> >>>
> >>> ==================================================================
> >>> --- umcs.c    (revision 255492)
> >>> +++ umcs.c    (local)
> >>> @@ -230,6 +230,7 @@
> >>>          .bufsize = 0,        /* use wMaxPacketSize */
> >>>          .callback = &umcs7840_intr_callback,
> >>>          .if_index = 0,
> >>> +        .interval = 20, /* ms */
> >>>      },
> >>>  };
> >>>
> >>>
> >>> BTW: I see that the umcs driver shouldn't do synchronous control
> >>> transfers from the USB interrupt transfer callback. This should be
> >>> postponed into some worker thread, for example the USB explore thread.
> >>> See USB audio driver for an example.
> >>>
> >>> --HPS
> >> I tried your patch and it works as expected: IRQs decreased to ~64/s
> >> when idle/disconnected.
> >>
> >> One interesting thing I never measured before:
> >> Console connection with 115k2 via umcs and 'while ( 2>1 ) echo "---..."
> >> end' results in 8000 irqs/s :-( But that's also true for the prolific
> >> (uplcom). The latter just goes down to 0.0 irqs/s when idle.
> >>
> >> Doing the same with uart0 results in 1444irqs/s.
> >> Is it by design/unavoidable that transfering the same via USB multiplies
> >> by factor 5-6?
> >>
> >> Thanks,
> >>
> >> -Harry
> >>
> > I don't know about that chipset, but with the FTDI chips it does xfers
> > in 64 byte chunks and high speed bulk data results in an astronomical
> > number of interrupts (and if you go fast enough, lost data).  I have
> 
> According to ASIX product brief, MCS7840 has 512 byte buffer. Pretty
> much for an UART I think, which should make 115k2 baud connections  with
> less than 30 transfers/s work, or am I missing something?

That's the internal buffer, it still does usb transfers in smaller
chunks.  Some ftdi chips have 4k onboard buffers but do 64-byte usb
transfers.

-- Ian


_______________________________________________
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"

Reply via email to