Re: usbfs and MAX_USBFS_BUFFER_SIZE

2007-12-02 Thread Pete Zaitcev
he chain will reject > big control urbs. But you did want it for something, didn't you? Or just idle curiosity? If you're writing microcode, please avoid using control transfers for uploading firmware without breaking it up explicitly. -- Pete - To unsubscribe from this list: send the li

[linux-usb-devel] usbmon: Smooth the core code

2007-08-14 Thread Pete Zaitcev
Two things: - mbus can be NULL (in case of bus removal while reader is reading) - Remove a useless assignment Signed-off-by: Pete Zaitcev <[EMAIL PROTECTED]> diff -urp -X dontdiff linux-2.6.23-rc3-gregkh/drivers/usb/mon/mon_main.c linux-2.6.23-rc3-gregkh-pipe/drivers/usb/mon/mon_

[linux-usb-devel] usbmon: Drop DMA mapping for setup packet

2007-08-14 Thread Pete Zaitcev
Setup packet must be visible in virtual space. There's absolutely no good reason to implement any kind of zero-copy transfer of 8 bytes, and the documentation in usb.h is explicit about it. So, drop DMA remapping. Signed-off-by: Pete Zaitcev <[EMAIL PROTECTED]> diff -urp -X dontdiff l

[linux-usb-devel] usbmon: Update pipe removal to suit my taste

2007-08-14 Thread Pete Zaitcev
This is a set of small updates to Alan's work to make the code more to my liking. Mostly premature optimizations, but also direction of control transfers in the binary interface was always out. Signed-off-by: Pete Zaitcev <[EMAIL PROTECTED]> diff -urp -X dontdiff linux-2.6.23-rc3-gre

[linux-usb-devel] usblp: Cosmetics

2007-08-13 Thread Pete Zaitcev
This is a small bunch of cosmetic fixes: - Timeout is not a write timeout anymore, rename - Condition in poll was confusingly backwards, invert and simplify - The comment log gave a wrong impression of version 0.13, terminate it. Signed-off-by: Pete Zaitcev <[EMAIL PROTECTED]> ---

[linux-usb-devel] usblp: mutex in usblp_check_status

2007-08-13 Thread Pete Zaitcev
Add a mutex to protect the ->statusbuf. Not really an issue, because CUPS is single-threaded when it talks to the printer, but I feel safer this way. This should be deadlock-free, but I kept this as a separate patch in case someone ends running a git bisect. Signed-off-by: Pete Zaitcev <

Re: [linux-usb-devel] [PATCH] [490/2many] MAINTAINERS - USB BLOCK DRIVER (UB ub)

2007-08-13 Thread Pete Zaitcev
ers do not? -- Pete - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of

Re: [linux-usb-devel] [PATCH] USB: Only enable autosuspend by default on certain device classes

2007-08-04 Thread Pete Zaitcev
said that none of his printers work, which sounds bad, and was news to me. But the point is, we are trying to extrapolate from too few cases. I am wondering if Ubuntu has better user reporting, so if Matthew complains, it really means something. -- Pete ---

Re: [linux-usb-devel] [PATCH] USB: Only enable autosuspend by default on certain device classes

2007-08-03 Thread Pete Zaitcev
at the suspend methods for the printer and it seemed possible that they can only work if the device is not open when suspend occurs. I was going to look at that at the first opportunity. So, I'd rather keep at least some kind of capability to suspend printers, even if disa

Re: [linux-usb-devel] [PATCH] USB: Only enable autosuspend by default on certain device classes

2007-08-03 Thread Pete Zaitcev
ork. I'm wondering if this has something to do with a hub or motherboard... How should we test it? Tried plugging elsewhere? -- Pete - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find pro

Re: [linux-usb-devel] usbserial, io_edgeport: Remove CmdUrbs

2007-08-01 Thread Pete Zaitcev
ned out to be a normal, non-EPiC based Edgeport, and so I cannot test after all. I still can make a patch, but cannot be sure I got it right. -- Pete - This SF.net email is sponsored by: Splunk Inc. Still grepping through log fi

Re: [linux-usb-devel] [PATCH] bug with EHCI cpufreq patch on nVidia controllers

2007-07-31 Thread Pete Zaitcev
return qtd; > + } Why use list_for_each_safe when mere list_for_each would do? In fact, some might ask for list_for_each_entry. -- Pete - This SF.net email is sponsored by: Splunk Inc. Still grepping

Re: [linux-usb-devel] [PATCH 3/7] USB: add direction bit to urb->transfer_flags

2007-07-30 Thread Pete Zaitcev
ight? There's no good reason for setup_packet not to be mapped, right? -- Pete - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configu

Re: [linux-usb-devel] [PATCH 1/7] USB: add urb->ep

2007-07-30 Thread Pete Zaitcev
break; > } I am afraid that drivers call unlink left and right, even on URBs which were not submitted and thus have ->ep == NULL. But on the other hand, maybe we want to catch them... -- Pete - This SF

Re: [linux-usb-devel] usbserial, io_edgeport: Remove CmdUrbs

2007-07-30 Thread Pete Zaitcev
On Mon, 30 Jul 2007 13:07:02 -0700, Greg KH <[EMAIL PROTECTED]> wrote: > On Mon, Jul 30, 2007 at 12:58:57PM -0700, Pete Zaitcev wrote: > > Oliver converted CmdUrbs into an atomic with commit > > 96c706ed1c46470598d785124b2a7fb233b27dab . > > It seems like a waste

[linux-usb-devel] usbserial, io_edgeport: Remove CmdUrbs

2007-07-30 Thread Pete Zaitcev
Oliver converted CmdUrbs into an atomic with commit 96c706ed1c46470598d785124b2a7fb233b27dab . It seems like a waste to do for a long forgotten debugging aid. Let's just remove it altogether. Signed-off-by: Pete Zaitcev <[EMAIL PROTECTED]> diff --git a/drivers/usb/serial/io_edgeport.

Re: [linux-usb-devel] software unplug

2007-07-30 Thread Pete Zaitcev
cle.c It's a last resort technique which served me well in the past. But usually if it comes to that it's time to seek a new place of employment, because obviously you do not have resources in place to see the project through success. -- Pete ---

Re: [linux-usb-devel] force USB_SPEED_FULL for device

2007-07-27 Thread Pete Zaitcev
ed to USB_SPEED_FULL > doesn't work as the packet does not even get sent by the > subsystem/hcd. How do you know that the packet is not sent? The EPROTO you are getting is what happens when packet IS sent and gets no reply. -- Pete

Re: [linux-usb-devel] [PATCH] mct_u232: Convert to proper speed handling API

2007-07-26 Thread Pete Zaitcev
(serial, port, cflag & CBAUD); > + mct_u232_set_baud_rate(serial, port, tty_get_baud_rate(port->tty)); Thanks for doing this, Alan. I noticed that you were on it and wanted to help but I misunderstood the nature of the change. I thought you wanted to get rid of switch()... Now I s

Re: [linux-usb-devel] usb_control_msg() reads 0 bytes in Linux 2.6.23-rc1

2007-07-25 Thread Pete Zaitcev
On Wed, 25 Jul 2007 08:30:40 +0200, Wolfgang Mües <[EMAIL PROTECTED]> wrote: > Pete, > > On Dienstag, 24. Juli 2007, Pete Zaitcev wrote: > > Please keep in mind that all this discussion about short reads has > > nothing to do with your real problem (e.g. the device whi

Re: [linux-usb-devel] Bug in EHCI split-interrupt handling

2007-07-25 Thread Pete Zaitcev
qh->hw_token and uses it for length calculation against qtd->length. -- Pete - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and confi

Re: [linux-usb-devel] usb_control_msg() reads 0 bytes in Linux 2.6.23-rc1

2007-07-24 Thread Pete Zaitcev
s a little awkward. Your new solution is fine, I think. I was concerned that I missed something so obvious. I rescanned the patch-2.6.23-rc1 looking for ->status being used _outside_ of a callback and didn't see anything el

Re: [linux-usb-devel] Bug in EHCI split-interrupt handling

2007-07-24 Thread Pete Zaitcev
on where to > go searching through the driver code for a solution? I'm going to double-check that usbmon is not deceiving you. It sure looks totally bogus. Maybe I mixed up fields in a union somewhere. -- Pete - This S

Re: [linux-usb-devel] usb_control_msg() reads 0 bytes in Linux 2.6.23-rc1

2007-07-24 Thread Pete Zaitcev
int retval; > - int status = urb->status; > > - init_completion(&done); > - urb->context = &done; > + init_completion(&ctx.done); > + urb->context = &ctx; > urb->actual_length

Re: [linux-usb-devel] usb_control_msg() reads 0 bytes in Linux 2.6.23-rc1

2007-07-24 Thread Pete Zaitcev
for maximum packet size, and then receive the actual number of bytes, or even a zero. Please keep in mind that all this discussion about short reads has nothing to do with your real problem (e.g. the device which used to reply with a stall stopped to do so, or it continues to reply with a

Re: [linux-usb-devel] usb_control_msg() reads 0 bytes in Linux 2.6.23-rc1

2007-07-24 Thread Pete Zaitcev
;t ask Pavel to run usbmon because I was concerned for EHCI. But yes, it's normally the first thing to be done because it gives us some baseline. -- Pete - This SF.net email is sponsored by: Splunk Inc. Still grepping thr

Re: [linux-usb-devel] usb_control_msg() reads 0 bytes in Linux 2.6.23-rc1

2007-07-24 Thread Pete Zaitcev
stupid. > > The patch for the kernel: > http://80211libre.org/at76/at76_usb.patch I don't see anything suspicious in the patch. -- Pete - This SF.net email is sponsored by: Splunk Inc. Still grepping through l

[linux-usb-devel] usblp: Make use of URB_FREE_BUFFER

2007-07-23 Thread Pete Zaitcev
Employ the new API URB_FREE_BUFFER that we've got. There was talk of a combined constructor for this case, but apparently it's not happening, so just set the flag explicitly for now. Signed-off-by: Pete Zaitcev <[EMAIL PROTECTED]> --- linux-2.6.23-rc1-nip/drivers/usb/class/usbl

[linux-usb-devel] usblp: Implement the ENOSPC convention

2007-07-23 Thread Pete Zaitcev
is. It has several components; those which invoke LPABORT work, but some of them need the ioctl added. This is completely compatible, you can mix old CUPS and new kernels or vice versa. Signed-off-by: Pete Zaitcev <[EMAIL PROTECTED]> --- a/drivers/usb/class/usblp.c +++ b/drivers/usb/class/usblp.

Re: [linux-usb-devel] urb->status cleanup (was: [GIT PATCH] more USB patches for 2.6.22)

2007-07-22 Thread Pete Zaitcev
s in the tree. That said, we can help Alan and Co. if something gets overlooked. If gigaset or ub stop break, you and I will fix them up. The goal is to get rid of drivers referencing urb->status. It's going to be passed as an argument. -- Pete -

Re: [linux-usb-devel] Kingsun KS-959 USB IrDA dongle - release candidate for submission (try 1)

2007-07-21 Thread Pete Zaitcev
y definition. So, I see no opportunity to invoke unlink_urb _here_ as you said. -- Pete - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and confi

Re: [linux-usb-devel] Kingsun KS-959 USB IrDA dongle - release?candidate for submission (try 1)

2007-07-21 Thread Pete Zaitcev
ctures since it's not 32 bits aligned, so I think this attribute > is correct. Oliver is correct, everything is perfectly aligned and the attribute is unnecessary. However the question is moot, since the bit fields vary in order. Bit fields must not be used, and shifts and masks must be u

Re: [linux-usb-devel] [patch 09/17] usb: split usb_new_device for clarity and refactoring

2007-07-18 Thread Pete Zaitcev
> > [...] It would help a lot if you trimmed your replies properly. -- Pete - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limit

Re: [linux-usb-devel] [PATCH] iuu_phoenix new driver proposal for review and comments

2007-07-18 Thread Pete Zaitcev
appens as long as SLAB debugging is not enabled. If you want alignment to 256, either grab pages or realign by hand like ymfpci did. -- Pete - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version

Re: [linux-usb-devel] usb_control_msg question

2007-07-17 Thread Pete Zaitcev
#x27;s not a delay. > Any ideas? Btw, yes I've realized the rcvctrlpipe problem. Thanks. Make sure you aren't doing DMA to stack. The ded0a8c0 does not seem like an x86 address to me. You might be on an ARM or something. -- Pete ---

Re: [linux-usb-devel] usb_control_msg question

2007-07-17 Thread Pete Zaitcev
MEOUT); Are you sure you want to use input pipe with SET_IDLE? > I've been able to do all of this using libusb in user space > but have no success within a kernel module. Compare usbmon traces for two cases, the difference should be evident. -- Pete --

Re: [linux-usb-devel] [PATCH 118/149] USB: usblp: add dynamic URBs, fix races

2007-07-12 Thread Pete Zaitcev
y about that. -- Pete --- Begin Forwarded Message --- From: Pete Zaitcev <[EMAIL PROTECTED]> To: [EMAIL PROTECTED] Cc: [email protected], [EMAIL PROTECTED] Subject: usblp: "Big cleanup" breaks O_NONBLOCK Date: Tue, 10 Jul 2007 20:09:58 -0700 I found the firs

[linux-usb-devel] usblp: "Big cleanup" breaks O_NONBLOCK

2007-07-10 Thread Pete Zaitcev
hat the transfer has succeeded even if URB was merely queued. It is the same behaviour as with the old version. Signed-off-by: Pete Zaitcev <[EMAIL PROTECTED]> --- linux-2.6.22-gregkh/drivers/usb/class/usblp.c 2007-07-10 19:40:48.0 -0700 +++ linux-2.6.22-gregkh-eagain/drivers/usb/class

Re: [linux-usb-devel] how to detect SD card under linux

2007-07-09 Thread Pete Zaitcev
for you even if you tried to open a slice. However, you cannot do it on dynamic /dev because udev hasn't created the slice nodes, and it won't do it until partitions are scanned. Embedded devices usually just run static /dev for that purpose. Heck, some even use ub with static /dev. The

Re: [linux-usb-devel] urb status EOVERFLOW

2007-07-04 Thread Pete Zaitcev
legal for HID devices to bunch reports together. -- Pete - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it no

Re: [linux-usb-devel] [RFC] URBs and buffer management

2007-07-02 Thread Pete Zaitcev
t you write is true in a way, in case of swiotlb. The swiotlb reserves a real chunk of memory (still cached though). That memory remains unavailable to normal users regardless of the number and size of I/Os currently active in the system. -- Pete --

Re: [linux-usb-devel] usb_fill_bulk_urb() broken for USB1.1?

2007-06-26 Thread Pete Zaitcev
2.6.16.18, it works for > > both USB2.0 and 1.1. This looks like an attempt to submit a bulk URB to an interrupt endpoint, with garbage interval or something of that nature. I think it would be the best to talk to the driver author directly. -- Pete

Re: [linux-usb-devel] [PATCH] Add usb_setup_{control, bulk, int}_urb helpers

2007-06-25 Thread Pete Zaitcev
int address instead of the pipe, because the pipe type is known to each wrapper, right? BTW, you sure like empty lines... -- Pete - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 e

Re: [linux-usb-devel] patch usb-add-urb_free_buffer-flag-and-the-logic-behind-it.patch added to gregkh-2.6 tree

2007-06-25 Thread Pete Zaitcev
right away. Marcel, please let me know if I'm doing it wrong. -- Pete --- a/drivers/usb/class/usblp.c +++ b/drivers/usb/class/usblp.c @@ -330,9 +330,6 @@ static void usblp_bulk_write(struct urb *urb) wake_up(&usblp->wwait); spin_unlock(&usblp->lock);

Re: [linux-usb-devel] Fedora 7 USB problems

2007-06-22 Thread Pete Zaitcev
nd see how that goes. If it fails, disable the autosuspend. Although, what to do if it crashes the device? We'd need to forward this knowledge to the newly reconnected device somehow, maybe with some kind of a dynamic blacklist... -- Pete

Re: [linux-usb-devel] usblp: add dynamic URBs, fix races

2007-06-22 Thread Pete Zaitcev
not -ERESTARTSYS ? > > > > Hmm. Yes, the syscall is restartable at this point. I guess I inherited > > it from the old driver, where the loop was unified, so it didn't try > > to distinguish the cases when something was written or nothing was written, > > and retu

Re: [linux-usb-devel] usblp: add dynamic URBs, fix races

2007-06-22 Thread Pete Zaitcev
en just as it always did (e.g. a quick loop-around and a EIO). > > + if (mutex_lock_interruptible(&usblp->wmut)) { > > + rv = -EINTR; > > Why not -ERESTARTSYS ? Hmm. Yes, the syscall is restartable at this point. I guess I inherited it from the old driver, where

Re: [linux-usb-devel] HID device communication problem with kernel 2.4

2007-06-21 Thread Pete Zaitcev
missing wake_up(), but I don't know. Please let me know if you uncover something new and/or come with a patch. -- Pete - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2

[linux-usb-devel] USB: Take over usblp

2007-06-21 Thread Pete Zaitcev
Vojtech agreed to pass usblp over to me, so if you find bugs don't bug him. Signed-off-by: Pete Zaitcev <[EMAIL PROTECTED]> Signed-off-by: Vojtech Pavlik <[EMAIL PROTECTED]> --- a/MAINTAINERS +++ b/MAINTAINERS @@ -3702,12 +3702,12 @@ L: [email protected]

[linux-usb-devel] usblp: add dynamic URBs, fix races

2007-06-21 Thread Pete Zaitcev
ht to have them interleaved). Also gone are issues with interrupts using barriers dangerously. This patch makes use of Oliver's anchor, and so it must trail the anchor patch on the way to Linus. Signed-off-by: Pete Zaitcev <[EMAIL PROTECTED]> --- linux-2.6.22-rc5-gregkh-usblp/drivers/

[linux-usb-devel] Fingerprint reader (was: Error -71 on device descriptor read/all)

2007-06-20 Thread Pete Zaitcev
Blacklist the hub by VID:PID (0b97:7762)? But where, in hub.c? -- Pete - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just

Re: [linux-usb-devel] Error -71 on device descriptor read/all

2007-06-20 Thread Pete Zaitcev
actual problem ("my printer does not work") instead of reporting the message ("on noes, it's -71!"). Now you see how usbmon is central to the overarching plan for world domination. -- Pete - This SF.net

Re: [linux-usb-devel] Question about usb sg handling

2007-06-19 Thread Pete Zaitcev
more bytes in struct urb ;-) I think your irony falls flat. Why do you think I haven't submitted a patch to add it yet? Of course there's always a tradeoff and linear URBs served us well so far. I am merely stating the reaso

[linux-usb-devel] Fedora 7 USB problems

2007-06-15 Thread Pete Zaitcev
fashion... V.strange. -- Pete - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourcefo

Re: [linux-usb-devel] [PATCH] USB: introduce urb->core_status field

2007-06-09 Thread Pete Zaitcev
a hook, we can pass status to it as an argument, if that helps. I don't expect any trouble from the usbmon's direction. -- Pete - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE v

Re: [linux-usb-devel] [PATCH] USB IAD Support (kernel2.6.21.3)

2007-06-09 Thread Pete Zaitcev
ce Association Descriptors in this > + * configuration. */ > + struct usb_interface_assoc_descriptor *intf_assoc[USB_MAXIADS]; What is this for? How do you want to use this? -- Pete - This SF.net email is sponsored by DB2 E

Re: [linux-usb-devel] The anchor patch critique

2007-06-09 Thread Pete Zaitcev
e. Your hunch that we'll win anything in driver code is not any better substantiated than my hunch that URBs are too big and cause memory pressure in unfortunate moments (otherwise, why does usb-storage continue to lock up with write throttling issues, but ub works in same tests). So, another reas

Re: [linux-usb-devel] [PATCH] USB: introduce urb->core_status field

2007-06-08 Thread Pete Zaitcev
say "Ewww one more field to already-bloated URB" but if we follow through on making status an argument, no problem. -- Pete - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2

Re: [linux-usb-devel] usb: free DMA mappings if enqueue fails

2007-06-08 Thread Pete Zaitcev
On Fri, 8 Jun 2007 13:47:54 -0700, Greg KH <[EMAIL PROTECTED]> wrote: > Thanks, do you think this should go in before 2.6.22 is released? Considering that we had this bug for 5 years, 2 months won't make a huge difference. It's not worth any extra eff

[linux-usb-devel] usb: free DMA mappings if enqueue fails

2007-06-08 Thread Pete Zaitcev
fixing as well. Signed-off-by: Pete Zaitcev <[EMAIL PROTECTED]> --- a/drivers/usb/core/hcd.c +++ b/drivers/usb/core/hcd.c @@ -901,17 +901,32 @@ EXPORT_SYMBOL (usb_calc_bus_time); /*-*/ -static void urb_unlink (struct ur

Re: [linux-usb-devel] usb: free DMA if enqueue fails

2007-06-08 Thread Pete Zaitcev
idn't know how to correct it. -- Pete - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now.

Re: [linux-usb-devel] usb: free DMA if enqueue fails

2007-06-08 Thread Pete Zaitcev
ion under which it can fail? The patch was completely compliant with the format, as much as I can see. All the discussion was below the tripple dash. -- Pete - This SF.net email is sponsored by DB2 Express Download DB2 Express C

Re: [linux-usb-devel] blank filenames in /sys/modules, kernel 2.6.21

2007-06-08 Thread Pete Zaitcev
On Fri, 8 Jun 2007 11:32:32 -0700, Greg KH <[EMAIL PROTECTED]> wrote: > > and from drivers/usb/core/usb.c: > > > > /* format to disable USB on kernel command line is: nousb */ > > __module_param_call("", nousb, param_set_bool, param_get_bool, &n

Re: [linux-usb-devel] [RFC] URBs and buffer management

2007-06-06 Thread Pete Zaitcev
it with old API like they do now. The skbuffs are set up this way and it seems to work. -- Pete - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of y

[linux-usb-devel] The anchor patch critique

2007-06-05 Thread Pete Zaitcev
nd a compare, and at worst we'll get a false negative. However, modern compilers optimize so much that I don't trust anything anymore. -- Pete - This SF.net email is sponsored by DB2 Express Download DB2 E

Re: [linux-usb-devel] [RFC] URBs and buffer management

2007-06-05 Thread Pete Zaitcev
ction that take > care of DMA is a good thing. Just as I suspected. You know, if you used kmalloc instead, usb_setup_bulk_urb would be useful for my update of usblp.c. -- Pete - This SF.net email is sponsored by DB2 Ex

Re: [linux-usb-devel] [RFC] URBs and buffer management

2007-06-05 Thread Pete Zaitcev
sb_buffer_alloc due to confusion. I'm actually wondering now if your driver is one of the latter... -- Pete - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and ta

Re: [linux-usb-devel] [RFC] URBs and buffer management

2007-06-05 Thread Pete Zaitcev
is assertion makes no sense to me. URBs are not "freed" or "put" by magic by the core when your completion handler returns, thank heavens! Your own completion handler calls usb_free_urb, when the status is known. So, if you need to

Re: [linux-usb-devel] [Bugme-new] [Bug 8310] New: USB device names are not sanitized for UTF-8

2007-06-04 Thread Pete Zaitcev
when we read them in? I remember that issue. I thought that we wanted some kind of escape syntax... Like what HTML uses with &#; perhaps. This would allow to edit xorg.conf on systems which are not UTF-8 clean. But perhaps it's a non-goal. How big is the code to convert (we

Re: [linux-usb-devel] reincarnation of /dev/ttyUSB0 as /dev/ttyUSB1

2007-06-03 Thread Pete Zaitcev
ROTECTED] ~]$ cat /etc/udev/rules.d/70-gps.rules KERNEL=="ttyACM*", SYSFS{idVendor}=="0b20" SYSFS{idProduct}=="0406", SYMLINK+="gps0" [EMAIL PROTECTED] ~]$ -- Pete - This SF.net email is

Re: [linux-usb-devel] usb: free DMA if enqueue fails

2007-06-01 Thread Pete Zaitcev
Release DMA resources if submission fails in the HCD. Signed-Off-By: Pete Zaitcev <[EMAIL PROTECTED]> --- > Amazing indeed. Just for the record, I didn't find it just by looking. IBM filed a bug RH#236922 after they ran out of IOMMU. Our (older) uhci-hcd was rejecting bulk re

[linux-usb-devel] usb: free DMA if enqueue fails

2007-05-31 Thread Pete Zaitcev
Release DMA resources if submission fails in the HCD. Signed-Off-By: Pete Zaitcev <[EMAIL PROTECTED]> --- This seems too obvious. Yet I went back to kernel 2.2.19 and we always had this bug (well, in 2.2 we didn't because we used virt_to_bus). I'm amazed that such things can l

Re: [linux-usb-devel] [PATCH] drivers/block/ub.c: use list_for_each_entry()

2007-05-30 Thread Pete Zaitcev
!= (head); >pos = n, n = list_entry(n->member.next, typeof(*n), member)) > > then what am I to think? You won't catch me writing this kind of crap, so the question is moot. Seriously, a comma operator? Admit it, you just expanded a marcro from list.h by

Re: [linux-usb-devel] [PATCH] drivers/block/ub.c: use list_for_each_entry()

2007-05-30 Thread Pete Zaitcev
not find a better way to blow up your own argument than to mention list_for_each_entry_safe(), which is anything but. Matthias' use of list_for_each_entry() actually IS safe, which is why I am not NAKing it. Andrew has

Re: [linux-usb-devel] [PATCH] drivers/block/ub.c: use list_for_each_entry()

2007-05-30 Thread Pete Zaitcev
working knowledge of them. Iterators are particularly nasty that way. I'm thinking about dropping all of these list_for_each_with_murky_argument_requirements_and_odd_side_effects() and use plain for(;;), as a courtesy to someone who has to read the code years down the road. -- Pete

Re: [linux-usb-devel] [PATCH] drivers/block/ub.c: use list_for_each_entry()

2007-05-30 Thread Pete Zaitcev
ch straddles the border of acceptable. The pointless obfuscation is balanced against the removal of explicit type in list_entry() and thus a possible mismatched struct. I'm not acking nor naking this. -- Pete - This SF.net e

[linux-usb-devel] usblp: Don't let suspend to kill ->used

2007-05-24 Thread Pete Zaitcev
Suspend destroys refcounting for open/release. Signed-off-by: Pete Zaitcev <[EMAIL PROTECTED]> --- This whole driver needs a good beating, I swear. diff --git a/drivers/usb/class/usblp.c b/drivers/usb/class/usblp.c index fc2624d..2c74880 100644 --- a/drivers/usb/class/usblp.c +++ b/drive

Re: [linux-usb-devel] Is usb_buffer_alloc a generic URB buffer allocator ? (was Split Bulk Transfers)

2007-05-22 Thread Pete Zaitcev
ed and lame, other people love it. If someone (Laurent?) rolls out a buffer allocator which builds upon vmalloc, I guess I'll have to look for specific flaws in that. It's not something completely impossible, but we'l

[linux-usb-devel] usblp: Use correct DMA address in case of probe error

2007-05-21 Thread Pete Zaitcev
Looks like the error path had a copy-paste error. The normal exit path uses correct URB already. Signed-off-by: Pete Zaitcev <[EMAIL PROTECTED]> --- a/drivers/usb/class/usblp.c +++ b/drivers/usb/class/usblp.c @@ -1004,7 +1004,7 @@ abort: usblp->writeb

Re: [linux-usb-devel] [PATCH 2.6.21] Work around for PPC440EPX USBH_23 errrata

2007-05-20 Thread Pete Zaitcev
. There, we solved the issue by having a compilation unit (pci-quirks.c) which textually belongs to the driver, yet is built into kernel. What I proposed is more like how the handoff quirk worked before. But if you know an sane alternative, I'll be happy (ok, Mar

Re: [linux-usb-devel] [PATCH 2.6.21] Work around for PPC440EPX USBH_23 errrata

2007-05-20 Thread Pete Zaitcev
ore part. Fill the word when ohci probes, let ehci use it. Then, see above. The patch was linewrapped, the coding style was horrible, but it was all secondary to the overall architecture. Once you get rid of inter-module interaction, we can look at small things. They are easy. Best wishes, -- Pete -

Re: [linux-usb-devel] New USB stack on FreeBSD w/Linux emulation layer coming

2007-05-19 Thread Pete Zaitcev
one, which has > always been kind of dubious and acts unmaintained). And that routine > doesn't do a local_irq_save. Absolutely right, I'm being an idiot here. I think I looked at root hub code in the rush to the FreedomHEC preparations. We do not have local_irq_save in th

Re: [linux-usb-devel] New USB stack on FreeBSD w/Linux emulation layer coming

2007-05-17 Thread Pete Zaitcev
rm allows it, this is done by masking a specific IRQ. If that is impossible, interrupts are masked in the CPU (maybe only partially, e.g. on SPARC). However it is done though, the local_irq_save that we do adds nothing that I can see. -- Pete

Re: [linux-usb-devel] New USB stack on FreeBSD w/Linux emulation layer coming

2007-05-17 Thread Pete Zaitcev
;s interrupt handling, and we'll only need to make it explicit if any HCDs start using softirq when calling the giveback routine). I'm poking your memory in case there's actually a good reason for it which I forgot. Yours, -- Pete ---

Re: [linux-usb-devel] New USB stack on FreeBSD w/Linux emulation layer coming

2007-05-17 Thread Pete Zaitcev
rnel hacker) receive at least some benefit. If I turned Hans away right off the bat, his cohorts would still do the same thing, only without talking to us. That would be a net loss for Linux. -- Pete - This SF.net email is spons

Re: [linux-usb-devel] New USB stack on FreeBSD w/Linux emulation layer coming

2007-05-16 Thread Pete Zaitcev
> of "usb_submit_urb()" after that the device has detached! It must be > something terribly wrong in the Linux USB stack if the callbacks are alive > after that you have detached a USB device. I'm so blogging this. -- Pete -

Re: [linux-usb-devel] New USB stack on FreeBSD w/Linux emulation layer coming

2007-05-16 Thread Pete Zaitcev
submission, it is reported on the context which is submitting. Thus, you cannot hold any locks across the submission which the callback is likely to take. It's a real pain on SMP and with a multithreaded system. -- Pete - T

Re: [linux-usb-devel] New USB stack on FreeBSD w/Linux emulation layer coming

2007-05-16 Thread Pete Zaitcev
ties by default and only use them when > >memory pressure invokes these URBs > > > > This is something which, I think, only Greg Kroah can decide on doing > > or not doing. > > I am not in favor of such a large change. Yeah... I mentioned in m

Re: [linux-usb-devel] New USB stack on FreeBSD w/Linux emulation layer coming

2007-05-16 Thread Pete Zaitcev
, but it cannot wait for a writeout. If it cannot be satisfied without writing dirty data, it will fail. -- Pete - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and t

Re: [linux-usb-devel] New USB stack on FreeBSD w/Linux emulation layer coming

2007-05-16 Thread Pete Zaitcev
pported on Linux. Heck it works better than the equivalent on x86_64, because there's no address range limitation. The key is to set IOMMU at transfer time. Solaris defers DMA setup as well (for what they call "streaming transfers"). -- Pete --

Re: [linux-usb-devel] New USB stack on FreeBSD w/Linux emulation layer coming

2007-05-16 Thread Pete Zaitcev
scsi_eh_0, and usb-storage helper. I am thinking about taking the ub concept and integrating it into usb-storage as some kind of "threadless" option. If only I could get rid of the SCSI error handling... -- Pete -

Re: [linux-usb-devel] New USB stack on FreeBSD w/Linux emulation layer coming

2007-05-16 Thread Pete Zaitcev
r, less complex, less buggy, used commonly, and another far more complex, only used by usb-storage. Personally, I don't see it flying. -- Pete - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the F

Re: [linux-usb-devel] autosuspend for hid

2007-05-16 Thread Pete Zaitcev
quick glance. -- Pete - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/

Re: [linux-usb-devel] [PATCH]usblp read race

2007-05-14 Thread Pete Zaitcev
e old driver did here, sorry. But oddly enough, it only returned ENOMEM for writes, but not reads. I changed this to match the legacy. -- Pete - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE ver

Re: [linux-usb-devel] [PATCH]usblp read race

2007-05-14 Thread Pete Zaitcev
e in drivers/char/lp.c - Greg-style dynamic URBs -- Pete P.S. I'm thinking if I should take usblp for maintenance from Vojtech since I am reworking it anyway. P.P.S. Does anyone remember what hash signs in front of copyright statements mean? diff --git a/drivers/usb/class/usblp.c b/driver

Re: [linux-usb-devel] [PATCH 14/16] USB: Add usbfs ioctl to get the frame number

2007-05-14 Thread Pete Zaitcev
got its name) to fetch the current SOF and then call gettimeofday? Rest assured that the jitter you get from scheduling is going to be there for any in-kernel implementation as well. -- Pete - This SF.net email is sponsored b

Re: [linux-usb-devel] [PATCH] Make appletouch shut up when it has nothing to say

2007-05-13 Thread Pete Zaitcev
want to make sure that a scheduled work won't be run when the module is gone. More often, a device removal is the issue, but as I take it, such is not possible for a built-in device :-) . In most cases, all it takes is a strategically placed flu

Re: [linux-usb-devel] [PATCH] Make appletouch shut up when it has nothing to say

2007-05-13 Thread Pete Zaitcev
more unconditionally regardless of hardware present seems like stepping over the line to me. Overall this seems like a good patch to me, only needs to be less intrusive for owners of other hardware. -- Pete - This SF.net email is

Re: [linux-usb-devel] [PATCH 14/16] USB: Add usbfs ioctl to get the frame number

2007-05-12 Thread Pete Zaitcev
a host to keep wider counters than are needed. -- Pete - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to

Re: [linux-usb-devel] [PATCH 14/16] USB: Add usbfs ioctl to get the frame number

2007-05-12 Thread Pete Zaitcev
wn timestamp is not good enough, because the device does not know it. Actually, I think that a clever design would set an interrupt-out transfer with software initiated timestamp, which would not depend on HC implementing SOF number as a monotonously increasing counte

  1   2   3   4   5   6   7   8   9   10   >