Re: [linux-usb-devel] CDC-ACM driver: data duplication due to throttling

2007-02-06 Thread Oliver Neukum
Am Montag, 5. Februar 2007 22:26 schrieb Joris van Rantwijk: One more thing to bother you with ;-) Since acm-throttle_lock is only used to protect the simple flag byte acm-throttle, it is somewhat more efficient and convenient to use an atomic_t instead of a spinlock. Do you feel like

[linux-usb-devel] [PATCH] usb-storage: add Teac HD-35PU devices to unusual_devs.h

2007-02-06 Thread Thomas Bächler
Add Teac HD-35PU devices to unusual_devs.h to fix I/O errors resulting from wrong residue values returned by the device. Signed-off-by: Thomas Baechler [EMAIL PROTECTED] diff -uprN a/drivers/usb/storage/unusual_devs.h b/drivers/usb/storage/unusual_devs.h --- a/drivers/usb/storage/unusual_devs.h

Re: [linux-usb-devel] CDC-ACM driver: data duplication due to throttling

2007-02-06 Thread Joris van Rantwijk
On 5 feb 2007, at 23:07, Alan wrote: atomic_t on many platforms isn't that efficient and there are more cases where the atomic bit operations are fast. How about using test_bit/set_bit/clear_bit/etc I don't know. The thing is, I want something different from atomicity. In itself, atomically

Re: [linux-usb-devel] CDC-ACM driver: data duplication due to throttling

2007-02-06 Thread Oliver Neukum
Am Dienstag, 6. Februar 2007 10:38 schrieb Joris van Rantwijk: On 5 feb 2007, at 23:07, Alan wrote: atomic_t on many platforms isn't that efficient and there are more cases where the atomic bit operations are fast. How about using test_bit/set_bit/clear_bit/etc I don't know. The thing

Re: [linux-usb-devel] CDC-ACM driver: data duplication due to throttling

2007-02-06 Thread Oleg Verych
From: Oliver Neukum Newsgroups: gmane.linux.usb.devel Subject: Re: CDC-ACM driver: data duplication due to throttling Date: Tue, 6 Feb 2007 11:38:09 +0100 Hallo. To: [] Am Dienstag, 6. Februar 2007 10:38 schrieb Joris van Rantwijk: On 5 feb 2007, at 23:07, Alan wrote: atomic_t on many

Re: [linux-usb-devel] CDC-ACM driver: data duplication due to throttling

2007-02-06 Thread Joris van Rantwijk
On 6 feb 2007, at 11:38, Oliver Neukum wrote: What I really want is ordered access and volatility. I want exactly the kind of semantics that Java defines for volatile variables. A spinlock will surely do that. For the time being I'll push your first three patches forward and we can discuss

[linux-usb-devel] volatile useless in system programming (Re: CDC-ACM driver: data duplication due to throttling)

2007-02-06 Thread Oleg Verych
On Tue, Feb 06, 2007 at 12:31:14PM +0100, Joris van Rantwijk wrote: [] (In short, I really like Java.) Then you mustn't do system level programming ;) Do you happen to know what the exact semantics of 'volatile' are in C? I'd love to know. See subject and lkml archives. Thanks, Joris.

Re: [linux-usb-devel] CDC-ACM driver: data duplication due to throttling

2007-02-06 Thread Joris van Rantwijk
On 6 feb 2007, at 13:18, Oliver Neukum wrote: And 'volatile' in C have nothing to do with hardware: SMP, caches or whatever there may be. The problem that we're trying to solve has not much to do with hardware. I'd like to solve it at a pure logical level: by using some interface that

Re: [linux-usb-devel] CDC-ACM driver: data duplication due to throttling

2007-02-06 Thread Oleg Verych
On Tue, Feb 06, 2007 at 01:18:13PM +0100, Oliver Neukum wrote: Am Dienstag, 6. Februar 2007 12:31 schrieb Joris van Rantwijk: A spinlock should certainly be sufficient. I think spinlocks have a memory barrier built-in, otherwise they would be pretty useless. They do, as do all locks. Hm.

[linux-usb-devel] hid powersave by autosuspend #2

2007-02-06 Thread Oliver Neukum
Hi, this fixes the issue with output in the hid driver. I can now get keyboards to sleep. It is still not perfect, but an important step. Comments? Regards Oliver PS: against vanilla 2.6.20 --- linux-2.6.20/include/linux/hid.h2007-02-06 14:14:56.0 +0100

Re: [linux-usb-devel] CDC-ACM driver: data duplication due to throttling

2007-02-06 Thread Oliver Neukum
Am Dienstag, 6. Februar 2007 14:34 schrieb Oleg Verych: On Tue, Feb 06, 2007 at 01:18:13PM +0100, Oliver Neukum wrote: Am Dienstag, 6. Februar 2007 12:31 schrieb Joris van Rantwijk: A spinlock should certainly be sufficient. I think spinlocks have a memory barrier built-in, otherwise

[linux-usb-devel] example with io ordering (Re: CDC-ACM driver: data duplication due to throttling)

2007-02-06 Thread Oleg Verych
On Tue, Feb 06, 2007 at 02:32:44PM +0100, Oliver Neukum wrote: Am Dienstag, 6. Februar 2007 14:34 schrieb Oleg Verych: On Tue, Feb 06, 2007 at 01:18:13PM +0100, Oliver Neukum wrote: Am Dienstag, 6. Februar 2007 12:31 schrieb Joris van Rantwijk: A spinlock should certainly be sufficient.

Re: [linux-usb-devel] example with io ordering (Re: CDC-ACM driver: data duplication due to throttling)

2007-02-06 Thread Alan Stern
On Tue, 6 Feb 2007, Oleg Verych wrote: On Tue, Feb 06, 2007 at 02:32:44PM +0100, Oliver Neukum wrote: Am Dienstag, 6. Februar 2007 14:34 schrieb Oleg Verych: On Tue, Feb 06, 2007 at 01:18:13PM +0100, Oliver Neukum wrote: Am Dienstag, 6. Februar 2007 12:31 schrieb Joris van Rantwijk:

[linux-usb-devel] Fresh rise expect.

2007-02-06 Thread Mauro Herbert
LOM LOGISTICS INC (Other OTC: LOMJ at PK) Last: $1.75 Momemtum: Buy very strong. This one will rise like lastone. Look at news from the company. - Using Tomcat but need to do more? Need to support web

Re: [linux-usb-devel] hid powersave by autosuspend #2

2007-02-06 Thread Jiri Kosina
On Tue, 6 Feb 2007, Oliver Neukum wrote: this fixes the issue with output in the hid driver. I can now get keyboards to sleep. It is still not perfect, but an important step. Comments? Hi Oliver, I am going to look at it more thoroughly soon, just a quick note - when I plug in the USB

[linux-usb-devel] [Patch] cp2101: remove unnecessary kcalloc

2007-02-06 Thread Ben Gardner
The CP210x currently does a kcalloc() to create a temporary buffer that has a maximum size of 16 bytes. This patch uses the stack for the buffer. This patch also simplifies the math used to calculate the number of u32's needed to contain the byte array. Signed-off-by: Ben Gardner [EMAIL

Re: [linux-usb-devel] hid powersave by autosuspend #2

2007-02-06 Thread Alan Stern
On Tue, 6 Feb 2007, Oliver Neukum wrote: Hi, this fixes the issue with output in the hid driver. I can now get keyboards to sleep. It is still not perfect, but an important step. Comments? Regards Oliver PS: against vanilla 2.6.20 I'd really prefer to see

Re: [linux-usb-devel] [Patch] cp2101: remove unnecessary kcalloc

2007-02-06 Thread Alan Stern
On Tue, 6 Feb 2007, Ben Gardner wrote: The CP210x currently does a kcalloc() to create a temporary buffer that has a maximum size of 16 bytes. This patch uses the stack for the buffer. This part of the patch is incorrect. The buffer must be allocated using kmalloc or equivalent because some

Re: [linux-usb-devel] hid powersave by autosuspend #2

2007-02-06 Thread Oliver Neukum
Am Dienstag, 6. Februar 2007 16:15 schrieb Jiri Kosina: On Tue, 6 Feb 2007, Oliver Neukum wrote: this fixes the issue with output in the hid driver. I can now get keyboards to sleep. It is still not perfect, but an important step. Comments? Hi Oliver, I am going to look at it more

Re: [linux-usb-devel] hid powersave by autosuspend #2

2007-02-06 Thread Oliver Neukum
Am Dienstag, 6. Februar 2007 16:54 schrieb Alan Stern: On Tue, 6 Feb 2007, Oliver Neukum wrote: Hi, this fixes the issue with output in the hid driver. I can now get keyboards to sleep. It is still not perfect, but an important step. Comments? Regards Oliver

Re: [linux-usb-devel] hid powersave by autosuspend #2

2007-02-06 Thread Alan Stern
On Tue, 6 Feb 2007, Oliver Neukum wrote: With this infrastructure in place, all you have to do is set_bit(USB_DF_DEVICE_BUSY, hid_to_usb_dev(hid)-dflags); whenever an event occurs. No messing around with extra timers. If you make USB_AUTOSUSPEND_DELAY a per interface variable,

Re: [linux-usb-devel] [Patch] cp2101: remove unnecessary kcalloc

2007-02-06 Thread Ben Gardner
Ah. That makes sense. Thanks for the feedback. Ben On 2/6/07, Alan Stern [EMAIL PROTECTED] wrote: On Tue, 6 Feb 2007, Ben Gardner wrote: The CP210x currently does a kcalloc() to create a temporary buffer that has a maximum size of 16 bytes. This patch uses the stack for the buffer.

Re: [linux-usb-devel] [Patch] cp2101: remove unnecessary kcalloc

2007-02-06 Thread David Brownell
On Tuesday 06 February 2007 7:57 am, Alan Stern wrote: On Tue, 6 Feb 2007, Ben Gardner wrote: The CP210x currently does a kcalloc() to create a temporary buffer that has a maximum size of 16 bytes. This patch uses the stack for the buffer. This part of the patch is incorrect. The

Re: [linux-usb-devel] Problem with usbtest

2007-02-06 Thread David Brownell
On Monday 05 February 2007 10:34 pm, Guenther Sohler wrote: What is the purpose of usbtest http://www.linux-usb.org/usbtest and how can I avoid loading it for my FX2 device ? Don't configure it for your kernel ... it's only for use by developers doing USB testing. Simple. What is the

Re: [linux-usb-devel] [Linux-usb-users] ehci_hcd with slower FSB than normal (fwd)

2007-02-06 Thread David Brownell
On Monday 05 February 2007 11:27 am, Alan Stern wrote: -- Forwarded message -- Date: Sun, 04 Feb 2007 14:20:52 -0500 From: [EMAIL PROTECTED] To: linux-usb-users@lists.sourceforge.net Subject: [Linux-usb-users] ehci_hcd with slower FSB than normal I have a pc that I use as

[linux-usb-devel] Howto debug failure to use remote wakup?

2007-02-06 Thread Frédéric RISS
Hi, Is there any way to debug the remote wakeup functionality of usb devices? I'm trying to wake my MacMini up using the built-in IR Receiver. This device is seen as an raw HID device. Remote wakeup is working fine with other devices on this box. I can get the box out of sleep using a Microsoft

Re: [linux-usb-devel] PATCH: usb: descriptor structures have to be packed

2007-02-06 Thread Inaky Perez-Gonzalez
On Friday 02 February 2007 19:05, you wrote: On Fri, 2 Feb 2007 17:32:24 -0800, Inaky Perez-Gonzalez [EMAIL PROTECTED] wrote: usb: descriptor structures have to be packed Many of the Wireless USB decriptors added to usb_ch9.h don't have the __attribute__((packed)) tag, and thus, they

Re: [linux-usb-devel] PATCH: usb: descriptor structures have to be packed

2007-02-06 Thread David Brownell
On Friday 02 February 2007 7:05 pm, Pete Zaitcev wrote: On Fri, 2 Feb 2007 17:32:24 -0800, Inaky Perez-Gonzalez [EMAIL PROTECTED] wrote: usb: descriptor structures have to be packed Many of the Wireless USB decriptors added to usb_ch9.h don't have the __attribute__((packed)) tag, and

Re: [linux-usb-devel] PATCH: usb: descriptor structures have to be packed

2007-02-06 Thread David Brownell
On Tuesday 06 February 2007 1:08 pm, Inaky Perez-Gonzalez wrote: On Friday 02 February 2007 19:05, you wrote: The code should have used sizes such as USB_DT_CONFIG_SIZE instead of sizeof(). I have a problem with that, and is maintenance. Is not that I don't like DT_CONFIG_SIZE at all

Re: [linux-usb-devel] Howto debug failure to use remote wakup?

2007-02-06 Thread Frédéric Riss
Le mardi 06 février 2007 à 13:43 -0800, David Brownell a écrit : Remote wakeup is working fine with other devices on this box. ... But this doesn't work when I try it on the IR receiver although it exposes the remote wakeup capability. Do you know for a fact that it has _working_

[linux-usb-devel] drivers/usb/serial/mos7720.c: inconsequent NULL checking

2007-02-06 Thread Adrian Bunk
The Coverity checker noted the following inconsequent NULL checking in drivers/usb/serial/mos7720.c: -- snip -- ... static void mos7720_close(struct usb_serial_port *port, struct file *filp) { ... /* While closing port, shutdown all bulk read, write * * and interrupt read

Re: [linux-usb-devel] PATCH: usb: descriptor structures have to be packed

2007-02-06 Thread Pete Zaitcev
On Tue, 6 Feb 2007 13:08:19 -0800, Inaky Perez-Gonzalez [EMAIL PROTECTED] wrote: [btw, I truly have little idea about which are those specific costs, out of professional curiosity, got any pointers?]

Re: [linux-usb-devel] PATCH: usb: descriptor structures have to be packed

2007-02-06 Thread David Brownell
On Tuesday 06 February 2007 2:48 pm, Pete Zaitcev wrote: On Tue, 6 Feb 2007 13:08:19 -0800, Inaky Perez-Gonzalez [EMAIL PROTECTED] wrote: [btw, I truly have little idea about which are those specific costs, out of professional curiosity, got any pointers?]

[linux-usb-devel] 不会被扔掉的传单

2007-02-06 Thread 藏雅斋
全国首创 不会被抛弃的传单,效益永久的广告 企业为了宣传产品,或为了提高企业在本地的知名度,往往印制精美的传单向大众发放。拿到传单者,只有少数会看看,大多数会选择扔掉。广告效果很不理想。 我们可为企业提供一个好的方案:将收藏品融入广告传单中,使广告传单具有收藏价值和增值功能,人们肯定不会再扔掉。什么时候欣赏藏品时都能看到广告,效果不言而喻。使您的企业传单变成一份永久广告!

Re: [linux-usb-devel] PATCH: usb: descriptor structures have to be packed

2007-02-06 Thread Oleg Verych
From: David Brownell Newsgroups: gmane.linux.usb.devel Subject: Re: PATCH: usb: descriptor structures have to be packed Date: Tue, 6 Feb 2007 16:02:27 -0800 Hallo. On Tuesday 06 February 2007 2:48 pm, Pete Zaitcev wrote: On Tue, 6 Feb 2007 13:08:19 -0800, Inaky Perez-Gonzalez [EMAIL

Re: [linux-usb-devel] PATCH: usb: descriptor structures have to be packed

2007-02-06 Thread David Brownell
On Tuesday 06 February 2007 5:58 pm, Oleg Verych wrote: Would you clarify non aligned access issue on well known platforms (*x86-*). I see on gcc's output, that they are not carry much about it: X86 has hardware logic to handle misaligned access directly. Which is why GCC output doesn't pay

[linux-usb-devel] USB host controller testing in linux

2007-02-06 Thread Deepak Katagade
Hi All, We have written usb host controller driver for our arm board which does not have any pci interface.We are trying to test the this usb host controller with the usb test driver provided in the linux kernel.We tried to test the host controller with an mass storage device but it is giving