Re: Need docs on USB driver development

2008-02-11 Thread Dmitry Marakasov
* Dmitry Marakasov ([EMAIL PROTECTED]) wrote:

> work through neither uhid nor ugen drivers (though I'm gonna do
> some more digging here). So I've decided to go level lower and write
Upd: I was able to make it work through ugen. By the chance I've plugged
the device into another slot, and it worked.

So the curious thing is that it works like that:
addr 1: UHCI root hub, Intel
 addr 3: AVerMedia USB Radio, AVerMedia Technologies

(can write commands to /dev/ugen0.2)

But not like that:
addr 1: OHCI root hub, NEC
 addr 2: AVerMedia USB Radio, AVerMedia Technologies

(writing to /dev/ugen0.2 fails with EIO)

-- 
Dmitry A. Marakasov| jabber: [EMAIL PROTECTED]
[EMAIL PROTECTED]   | http://www.amdmi3.ru
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Need docs on USB driver development

2008-02-11 Thread Dmitry Marakasov
Hi!

I want to write driver for "AVerMedia Technologies" "AVerMedia USB
Radio" FM tuner. Though it's HID device, I was not able to make it
work through neither uhid nor ugen drivers (though I'm gonna do
some more digging here). So I've decided to go level lower and write
kernel driver for the device (for fun & new knowledge as well).
I've taken ufm driver as a basis and now I have a driver that
successfully attaches to a device, creates device node and reports
some info, but I'm a but stuch with actually communicating with
device. Neither arch handbook, nor developers handbook, usbd_*
manpage and usb headers have any verbose information.

Thus, I would be grateful for documentation on FreeBSD USB driver
development.

If you're curious, my current work is based on
http://av-usbradio.sourceforge.net/index.php?show=reverse.
Currently I try to send that 16 initialize bytes into the device. I set
up pipe via usbd_open_pipe, then xfer via usbd_alloc_xfer and try to do
usbd_bulk_transfer, but it fails with USBD_IOERROR and sometimes I end
with my system unresponsible to keystrokes (though I can switch between
consoles).

Also advices regarding driver testing environemnt would be useful (fsck
takes too much time). I can think of qemu which AFAIR supports USB
devices and booting from NFS partition.

-- 
Dmitry A. Marakasov| jabber: [EMAIL PROTECTED]
[EMAIL PROTECTED]   | http://www.amdmi3.ru
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re[2]: usb/85067: [uscanner] Cannot attach ScanJet 4300C to usb device

2008-02-11 Thread Ivan
The problem is fixed in 6.3-STABLE. ScanJet got attached as uscanner0 without 
any problems. But scanimage (SANE) currently needs it to be a generic 
usb-device (ugen) and ugen fails with the same problem as uscanner did it 
before. So, plese apply the same fix to ugen, as it was done for uscanner. And 
the world will be happy :)


-Original Message-
From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED], [EMAIL PROTECTED], freebsd-usb@FreeBSD.org
Date: Tue, 29 Jan 2008 10:06:53 GMT
Subject: Re: usb/85067: [uscanner] Cannot attach ScanJet 4300C to usb device

> 
> Synopsis: [uscanner] Cannot attach ScanJet 4300C to usb device
> 
> State-Changed-From-To: open->suspended
> State-Changed-By: linimon
> State-Changed-When: Tue Jan 29 10:06:34 UTC 2008
> State-Changed-Why: 
> Mark suspended awaiting patches.
> 
> http://www.freebsd.org/cgi/query-pr.cgi?pr=85067
> ___
> freebsd-usb@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-usb
> To unsubscribe, send any mail to "[EMAIL PROTECTED]"
> 
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Current problem reports assigned to freebsd-usb@FreeBSD.org

2008-02-11 Thread FreeBSD bugmaster
Current FreeBSD problem reports
Critical problems

S Tracker  Resp.  Description

o usb/84750usb[hang] 6-BETA2 reboot/shutdown with root_fs on externa
o usb/91629usbusbd_abort_pipe() may result in infinite loop

2 problems total.

Serious problems

S Tracker  Resp.  Description

o usb/46176usb[umass] [panic] umass causes kernel panic if device re
o i386/46371   usbUSB controller cannot be initialized on IBM Netfinity 
o bin/57255usbusbd and multi-function devices
o usb/63621usb[umass] [panic] USB MemoryStick Reader stalls/crashes 
o usb/69006usb[usbdevs] [patch] Apple Cinema Display hangs USB ports
o usb/71155usb[ulpt] misbehaving usb-printer hangs processes, causes
o usb/73307usb[panic] Kernel panics on USB disconnect
o usb/74771usb[umass] [hang] mounting write-protected umass device a
o usb/75705usb[umass] [panic] da0 attach / Optio S4 (with backtrace)
o usb/75797usb[pcm] 5.3-STABLE(2005 1/4) detect USB headset, But can
o usb/76395usb[uhci] USB printer does not work, usbdevs says "addr 0
o usb/77184usb[umass] [panic] kernel panic on USB device disconnect,
o usb/77294usb[ulpcom] [panic] ucom + ulpcom panic
o usb/79269usb[ohci] USB ohci da0 plug/unplug causes crashes and loc
o usb/79287usb[uhci] [hang] UHCI hang after interrupt transfer
o usb/79524usb[ulpt] printing to Minolta PagePro 1[23]xxW via USB fa
a usb/79656usb[ehci] RHSC interrupts lost
o usb/79722usb[ehci] wrong alignments in ehci.h
o usb/80040usb[hang] Use of sound mixer causes system freeze with ua
o usb/80361usb[umass] [patch] mounting of Dell usb-stick fails
o usb/80829usb[modules] [panic] possible panic when loading USB-modu
o usb/80862usb[patch] USB locking issues: missing some Giant calls
o usb/82350usb[ucom] [panic] null pointer dereference in USB stack
o usb/82520usb[udbp] [reboot] Reboot when USL101 connected
s usb/82569usb[umass] [panic] USB mass storage plug/unplug causes sy
o usb/82660usb[echi] [panic] EHCI: I/O stuck in state 'physrd'/panic
o usb/83563usb[umamss] [panic] Page Fault while detaching Mpman Usb 
o usb/83677usb[usb] [request] usb controller often not detected (Sun
o usb/83756usb[ums] [patch] Microsoft Intellimouse Explorer 4.0A doe
o usb/83977usb[ucom] [panic] ucom1: open bulk out error (addr 2): IN
o usb/84326usb[umass] Panic trying to connect SCSI tape drive via US
s usb/84336usb[usb] [reboot] instant system reboot when unmounting a
o usb/86767usb[umass] [patch] bogus "slice starts beyond end of the 
o usb/88743usb[hang] USB makes kernel hang at boot (regression in 6.
o usb/88966usb[modules] kldunload ucom.ko returns "Device busy" erro
s usb/89003usb[request] LaCie Firewire drive not properly supported 
o usb/89954usb[umass] [panic] USB Disk driver race condition?
o usb/90700usb[umass] [panic] Kernel panic on connect/mount/use umas
o usb/91238usb[umass] USB tape unit fails to write a second tape fil
o usb/91283usb[boot] booting very slow with usb devices connection (
o usb/91538usb[ulpt] [patch] Unable to print to EPSON CX3500
o usb/91906usb[ehci] [hang] FreeBSD hangs while booting with USB leg
o usb/92052usb[unlpt] usbd causes defunct process with busy file-han
o usb/92083usb[ural] [panic] panic using WPA on ural NIC in 6.0-RELE
o usb/92142usb[uhub] SET_ADDR_FAILED and SHORT_XFER errors from usb 
o usb/92171usb[panic] panic unplugging Vodafone Mobile Connect (UMTS
o usb/93155usb[ulpt] /dev/ulpt0: device busy, USB printer does not w
o usb/93408usb[mouse] hw.acpi.cpu.cx_lowest=C3 on AMD Turion causes 
o usb/93640usb[echi] [irq] device ehci causes interrupt storm on thi
o usb/93828usb[ochi] [panic] ohci causes panic on boot (HP Pavillion
o usb/94166usb[umass] [boot] btx halted with a flashcard plugged
o usb/94384usb[panic] kernel panic with usb2 hardware
o usb/94717usb[ulpt] Reading from /dev/ulpt can break work of a UHCI
o usb/94813usb[umass] mounting write-protected umass device freezes 
o usb/94897usb[panic] Kernel Panic when cleanly unmounting USB disk
s usb/95348usb[kbd] USB keyboard unplug causes noise on screen
o usb/95562usb[umass] Write Stress in USB Mass drive causes "vinvalb
s usb/95636usb[umass] [boot] 5 minute delay at boot when usin