Date: Wed, 18 Mar 2009 16:30:32 +0900 From: Weongyo Jeong <weongyo.jeong@gmail.com> To: Hans Petter Selasky <hselasky@c2i.net> Cc: Sam Leffler <sam@freebsd.org>, freebsd-usb@freebsd.org, Andrew Thompson <thompsa@freebsd.org> Subject: q: USB_SET_TIMEOUT in ugen. Message-ID: <20090318073032.GA12632@weongyo.cdnetworks.kr>
next in thread | raw e-mail | index | archive | help
Hello, During porting uath(4) to usb2 I found the following code failed to run: data = open("/dev/usb/0.2.2", O_WRONLY, 0); timeout = UATH_DATA_TIMEOUT; if (ioctl(data, USB_SET_TIMEOUT, &timeout) < 0) err(-1, "%s: USB_SET_TIMEOUT(%u)", datadev, UATH_DATA_TIMEOUT); and the error was: uathload: /dev/usb/0.2.2: USB_SET_TIMEOUT(1000): Invalid argument It looks it's ok with calling ioctl(msg, USB_SET_TIMEOUT, ..) to /dev/usb/0.2.1 And the behaviour of program isn't likely with usb1 that it worked well in usb1. After writing some data into msg and data pipe there was no any response using read(2). The problem source can be found at:. http://perforce.freebsd.org/depotTreeBrowser.cgi?FSPC=//depot/user/weongyo/wireless/src/usr.sbin/uathload&HIDEDEL=NO Are there something I missed in here? regards, Weongyo Jeong
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20090318073032.GA12632>