<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-toradex.git/drivers/usb/misc/usbtest.c, branch v2.6.34.8</title>
<subtitle>Linux kernel for Apalis and Colibri modules</subtitle>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/'/>
<entry>
<title>USB: usbtest: avoid to free coherent buffer in atomic context</title>
<updated>2010-08-13T20:27:28+00:00</updated>
<author>
<name>Ming Lei</name>
<email>tom.leiming@gmail.com</email>
</author>
<published>2010-08-02T14:09:01+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=150efe00d1991696b4e1ef48e44403b7fd018d95'/>
<id>150efe00d1991696b4e1ef48e44403b7fd018d95</id>
<content type='text'>
commit e10e1bec8e6654de4591ef45ddd6a6d1e5b2591c upstream.

This patch fixes the warning below:
[30753.755998] ------------[ cut here ]------------
[30753.755998] WARNING: at /home/tom/git/linux-2.6/linux-2.6-next/arch/x86/include/asm/dma-mapping.h:155 hcd_buffer_free+0xb1/0xd4 [usbcore]()
[30753.755998] Hardware name: 6475EK2
[30753.755998] Modules linked in: uvcvideo ehci_hcd usbtest cdc_ether usbnet vfat fat usb_storage nfsd lockd nfs_acl auth_rpcgss exportfs mii tun videodev v4l1_compat v4l2_compat_ioctl32 fuse bridge stp llc sunrpc ipv6 cpufreq_ondemand acpi_cpufreq freq_table mperf kvm_intel kvm arc4 ecb ath5k usbhid mac80211 snd_hda_codec_conexant ch341 usbserial ath cfg80211 thinkpad_acpi snd_hda_intel pcspkr wmi hwmon yenta_socket iTCO_wdt iTCO_vendor_support i2c_i801 e1000e snd_hda_codec snd_hwdep snd_pcm snd_timer snd soundcore snd_page_alloc pata_acpi uhci_hcd ohci_hcd usbcore i915 drm_kms_helper drm i2c_algo_bit i2c_core video output [last unloaded: uvcvideo]
[30753.755998] Pid: 0, comm: swapper Tainted: G        W   2.6.35-rc6-gkh-wl+ #49
[30753.755998] Call Trace:
[30753.755998]  &lt;IRQ&gt;  [&lt;ffffffff8104478a&gt;] warn_slowpath_common+0x80/0x98
[30753.755998]  [&lt;ffffffff810447b7&gt;] warn_slowpath_null+0x15/0x17
[30753.755998]  [&lt;ffffffffa00ce02d&gt;] hcd_buffer_free+0xb1/0xd4 [usbcore]
[30753.755998]  [&lt;ffffffffa00c1345&gt;] usb_free_coherent+0x1c/0x1e [usbcore]
[30753.755998]  [&lt;ffffffffa00b13e4&gt;] simple_free_urb+0x23/0x2f [usbtest]
[30753.755998]  [&lt;ffffffffa00b210b&gt;] iso_callback+0xbb/0x10f [usbtest]
[30753.755998]  [&lt;ffffffffa00c7390&gt;] usb_hcd_giveback_urb+0x8c/0xc0 [usbcore]
[30753.755998]  [&lt;ffffffffa0449b35&gt;] ehci_urb_done+0x84/0x95 [ehci_hcd]
[30753.755998]  [&lt;ffffffffa044b5a5&gt;] ehci_work+0x41a/0x7dd [ehci_hcd]
[30753.755998]  [&lt;ffffffffa044e298&gt;] ehci_irq+0x33b/0x370 [ehci_hcd]
[30753.755998]  [&lt;ffffffff8100fb05&gt;] ? sched_clock+0x9/0xd
[30753.755998]  [&lt;ffffffff8105e641&gt;] ? sched_clock_local+0x1c/0x82
[30753.755998]  [&lt;ffffffff8105e76a&gt;] ? sched_clock_cpu+0xc3/0xce
[30753.755998]  [&lt;ffffffff81067c7e&gt;] ? trace_hardirqs_off+0xd/0xf
[30753.755998]  [&lt;ffffffff8105e7b8&gt;] ? cpu_clock+0x43/0x5e
[30753.755998]  [&lt;ffffffffa00c6999&gt;] usb_hcd_irq+0x45/0xa1 [usbcore]
[30753.755998]  [&lt;ffffffff81092e02&gt;] handle_IRQ_event+0x20/0xa5
[30753.755998]  [&lt;ffffffff81094cea&gt;] handle_fasteoi_irq+0x92/0xd2
[30753.755998]  [&lt;ffffffff8100c0ed&gt;] handle_irq+0x1f/0x2a
[30753.755998]  [&lt;ffffffff8100b75d&gt;] do_IRQ+0x57/0xbe
[30753.755998]  [&lt;ffffffff8136a693&gt;] ret_from_intr+0x0/0x16
[30753.755998]  &lt;EOI&gt;  [&lt;ffffffff81223baa&gt;] ? acpi_idle_enter_bm+0x231/0x269
[30753.755998]  [&lt;ffffffff81223ba3&gt;] ? acpi_idle_enter_bm+0x22a/0x269
[30753.755998]  [&lt;ffffffff812c4b6b&gt;] cpuidle_idle_call+0x99/0xce
[30753.755998]  [&lt;ffffffff81008dd5&gt;] cpu_idle+0x61/0xaa
[30753.755998]  [&lt;ffffffff8136374b&gt;] start_secondary+0x1c2/0x1c6
[30753.755998] ---[ end trace 904cfaf7ab4cb1a2 ]---

Signed-off-by: Ming Lei &lt;tom.leiming@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
commit e10e1bec8e6654de4591ef45ddd6a6d1e5b2591c upstream.

This patch fixes the warning below:
[30753.755998] ------------[ cut here ]------------
[30753.755998] WARNING: at /home/tom/git/linux-2.6/linux-2.6-next/arch/x86/include/asm/dma-mapping.h:155 hcd_buffer_free+0xb1/0xd4 [usbcore]()
[30753.755998] Hardware name: 6475EK2
[30753.755998] Modules linked in: uvcvideo ehci_hcd usbtest cdc_ether usbnet vfat fat usb_storage nfsd lockd nfs_acl auth_rpcgss exportfs mii tun videodev v4l1_compat v4l2_compat_ioctl32 fuse bridge stp llc sunrpc ipv6 cpufreq_ondemand acpi_cpufreq freq_table mperf kvm_intel kvm arc4 ecb ath5k usbhid mac80211 snd_hda_codec_conexant ch341 usbserial ath cfg80211 thinkpad_acpi snd_hda_intel pcspkr wmi hwmon yenta_socket iTCO_wdt iTCO_vendor_support i2c_i801 e1000e snd_hda_codec snd_hwdep snd_pcm snd_timer snd soundcore snd_page_alloc pata_acpi uhci_hcd ohci_hcd usbcore i915 drm_kms_helper drm i2c_algo_bit i2c_core video output [last unloaded: uvcvideo]
[30753.755998] Pid: 0, comm: swapper Tainted: G        W   2.6.35-rc6-gkh-wl+ #49
[30753.755998] Call Trace:
[30753.755998]  &lt;IRQ&gt;  [&lt;ffffffff8104478a&gt;] warn_slowpath_common+0x80/0x98
[30753.755998]  [&lt;ffffffff810447b7&gt;] warn_slowpath_null+0x15/0x17
[30753.755998]  [&lt;ffffffffa00ce02d&gt;] hcd_buffer_free+0xb1/0xd4 [usbcore]
[30753.755998]  [&lt;ffffffffa00c1345&gt;] usb_free_coherent+0x1c/0x1e [usbcore]
[30753.755998]  [&lt;ffffffffa00b13e4&gt;] simple_free_urb+0x23/0x2f [usbtest]
[30753.755998]  [&lt;ffffffffa00b210b&gt;] iso_callback+0xbb/0x10f [usbtest]
[30753.755998]  [&lt;ffffffffa00c7390&gt;] usb_hcd_giveback_urb+0x8c/0xc0 [usbcore]
[30753.755998]  [&lt;ffffffffa0449b35&gt;] ehci_urb_done+0x84/0x95 [ehci_hcd]
[30753.755998]  [&lt;ffffffffa044b5a5&gt;] ehci_work+0x41a/0x7dd [ehci_hcd]
[30753.755998]  [&lt;ffffffffa044e298&gt;] ehci_irq+0x33b/0x370 [ehci_hcd]
[30753.755998]  [&lt;ffffffff8100fb05&gt;] ? sched_clock+0x9/0xd
[30753.755998]  [&lt;ffffffff8105e641&gt;] ? sched_clock_local+0x1c/0x82
[30753.755998]  [&lt;ffffffff8105e76a&gt;] ? sched_clock_cpu+0xc3/0xce
[30753.755998]  [&lt;ffffffff81067c7e&gt;] ? trace_hardirqs_off+0xd/0xf
[30753.755998]  [&lt;ffffffff8105e7b8&gt;] ? cpu_clock+0x43/0x5e
[30753.755998]  [&lt;ffffffffa00c6999&gt;] usb_hcd_irq+0x45/0xa1 [usbcore]
[30753.755998]  [&lt;ffffffff81092e02&gt;] handle_IRQ_event+0x20/0xa5
[30753.755998]  [&lt;ffffffff81094cea&gt;] handle_fasteoi_irq+0x92/0xd2
[30753.755998]  [&lt;ffffffff8100c0ed&gt;] handle_irq+0x1f/0x2a
[30753.755998]  [&lt;ffffffff8100b75d&gt;] do_IRQ+0x57/0xbe
[30753.755998]  [&lt;ffffffff8136a693&gt;] ret_from_intr+0x0/0x16
[30753.755998]  &lt;EOI&gt;  [&lt;ffffffff81223baa&gt;] ? acpi_idle_enter_bm+0x231/0x269
[30753.755998]  [&lt;ffffffff81223ba3&gt;] ? acpi_idle_enter_bm+0x22a/0x269
[30753.755998]  [&lt;ffffffff812c4b6b&gt;] cpuidle_idle_call+0x99/0xce
[30753.755998]  [&lt;ffffffff81008dd5&gt;] cpu_idle+0x61/0xaa
[30753.755998]  [&lt;ffffffff8136374b&gt;] start_secondary+0x1c2/0x1c6
[30753.755998] ---[ end trace 904cfaf7ab4cb1a2 ]---

Signed-off-by: Ming Lei &lt;tom.leiming@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>USB misc: make USB device id constant</title>
<updated>2010-03-02T22:54:17+00:00</updated>
<author>
<name>Németh Márton</name>
<email>nm127@freemail.hu</email>
</author>
<published>2010-01-10T14:34:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=33b9e16243fd69493be3ddda7be73226c8be586a'/>
<id>33b9e16243fd69493be3ddda7be73226c8be586a</id>
<content type='text'>
The id_table field of the struct usb_device_id is constant in &lt;linux/usb.h&gt;
so it is worth to make the initialization data also constant.

The semantic match that finds this kind of pattern is as follows:
(http://coccinelle.lip6.fr/)

// &lt;smpl&gt;
@r@
disable decl_init,const_decl_init;
identifier I1, I2, x;
@@
	struct I1 {
	  ...
	  const struct I2 *x;
	  ...
	};
@s@
identifier r.I1, y;
identifier r.x, E;
@@
	struct I1 y = {
	  .x = E,
	};
@c@
identifier r.I2;
identifier s.E;
@@
	const struct I2 E[] = ... ;
@depends on !c@
identifier r.I2;
identifier s.E;
@@
+	const
	struct I2 E[] = ...;
// &lt;/smpl&gt;

Signed-off-by: Németh Márton &lt;nm127@freemail.hu&gt;
Cc: Julia Lawall &lt;julia@diku.dk&gt;
Cc: cocci@diku.dk
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;


</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The id_table field of the struct usb_device_id is constant in &lt;linux/usb.h&gt;
so it is worth to make the initialization data also constant.

The semantic match that finds this kind of pattern is as follows:
(http://coccinelle.lip6.fr/)

// &lt;smpl&gt;
@r@
disable decl_init,const_decl_init;
identifier I1, I2, x;
@@
	struct I1 {
	  ...
	  const struct I2 *x;
	  ...
	};
@s@
identifier r.I1, y;
identifier r.x, E;
@@
	struct I1 y = {
	  .x = E,
	};
@c@
identifier r.I2;
identifier s.E;
@@
	const struct I2 E[] = ... ;
@depends on !c@
identifier r.I2;
identifier s.E;
@@
+	const
	struct I2 E[] = ...;
// &lt;/smpl&gt;

Signed-off-by: Németh Márton &lt;nm127@freemail.hu&gt;
Cc: Julia Lawall &lt;julia@diku.dk&gt;
Cc: cocci@diku.dk
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;


</pre>
</div>
</content>
</entry>
<entry>
<title>USB: convert to the runtime PM framework</title>
<updated>2010-03-02T22:54:12+00:00</updated>
<author>
<name>Alan Stern</name>
<email>stern@rowland.harvard.edu</email>
</author>
<published>2010-01-08T17:57:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=9bbdf1e0afe771ca7650f9f476769310bee9d8f3'/>
<id>9bbdf1e0afe771ca7650f9f476769310bee9d8f3</id>
<content type='text'>
This patch (as1329) converts the USB stack over to the PM core's
runtime PM framework.  This involves numerous changes throughout
usbcore, especially to hub.c and driver.c.  Perhaps the most notable
change is that CONFIG_USB_SUSPEND now depends on CONFIG_PM_RUNTIME
instead of CONFIG_PM.

Several fields in the usb_device and usb_interface structures are no
longer needed.  Some code which used to depend on CONFIG_USB_PM now
depends on CONFIG_USB_SUSPEND (requiring some rearrangement of header
files).

The only visible change in behavior should be that following a system
sleep (resume from RAM or resume from hibernation), autosuspended USB
devices will be resumed just like everything else.  They won't remain
suspended.  But if they aren't in use then they will naturally
autosuspend again in a few seconds.

Signed-off-by: Alan Stern &lt;stern@rowland.harvard.edu&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch (as1329) converts the USB stack over to the PM core's
runtime PM framework.  This involves numerous changes throughout
usbcore, especially to hub.c and driver.c.  Perhaps the most notable
change is that CONFIG_USB_SUSPEND now depends on CONFIG_PM_RUNTIME
instead of CONFIG_PM.

Several fields in the usb_device and usb_interface structures are no
longer needed.  Some code which used to depend on CONFIG_USB_PM now
depends on CONFIG_USB_SUSPEND (requiring some rearrangement of header
files).

The only visible change in behavior should be that following a system
sleep (resume from RAM or resume from hibernation), autosuspended USB
devices will be resumed just like everything else.  They won't remain
suspended.  But if they aren't in use then they will naturally
autosuspend again in a few seconds.

Signed-off-by: Alan Stern &lt;stern@rowland.harvard.edu&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>usbtest: make module param pattern writeable</title>
<updated>2009-12-11T19:55:22+00:00</updated>
<author>
<name>Vikram Pandita</name>
<email>vikram.pandita@ti.com</email>
</author>
<published>2009-11-10T03:24:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=7f4e985448e82fe4a1cc0ae4fcecaf7e0301c07b'/>
<id>7f4e985448e82fe4a1cc0ae4fcecaf7e0301c07b</id>
<content type='text'>
Allow module_param to be writeable. This allows us to change
the parameter if usbtest is built-in in the kernel.

Signed-off-by: Vikram Pandita &lt;vikram.pandita@ti.com&gt;
Signed-off-by: Anand Gadiyar &lt;gadiyar@ti.com&gt;
Cc: David Brownell &lt;david-b@pacbell.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Allow module_param to be writeable. This allows us to change
the parameter if usbtest is built-in in the kernel.

Signed-off-by: Vikram Pandita &lt;vikram.pandita@ti.com&gt;
Signed-off-by: Anand Gadiyar &lt;gadiyar@ti.com&gt;
Cc: David Brownell &lt;david-b@pacbell.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>USB: usbtest fix endless loop in unlink tests.</title>
<updated>2009-06-16T04:44:48+00:00</updated>
<author>
<name>Martin Fuzzey</name>
<email>mfuzzey@gmail.com</email>
</author>
<published>2009-06-04T21:20:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=3b6c023f831e3179c42bbcff189c73628cd5ea4c'/>
<id>3b6c023f831e3179c42bbcff189c73628cd5ea4c</id>
<content type='text'>
In tests 11 and 12 if the URB completes with an error status (eg babble)
the asynchrous unlink entered an endless loop trying to unlink
a non resubmitted URB.

Signed-off-by: Martin Fuzzey &lt;mfuzzey@gmail.com&gt;
Acked-by: David Brownell &lt;david-b@pacbell.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In tests 11 and 12 if the URB completes with an error status (eg babble)
the asynchrous unlink entered an endless loop trying to unlink
a non resubmitted URB.

Signed-off-by: Martin Fuzzey &lt;mfuzzey@gmail.com&gt;
Acked-by: David Brownell &lt;david-b@pacbell.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>USB: clean up redundant tests on unsigned</title>
<updated>2009-01-07T17:59:49+00:00</updated>
<author>
<name>roel kluin</name>
<email>roel.kluin@gmail.com</email>
</author>
<published>2008-10-21T04:47:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=e64a5219296fff11a0da0322b43012265cd3b327'/>
<id>e64a5219296fff11a0da0322b43012265cd3b327</id>
<content type='text'>
temp, bytes and param-&gt;{length,sglen,vary} are unsigned so
these tests do nothing.

Signed-off-by: Roel Kluin &lt;roel.kluin@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
temp, bytes and param-&gt;{length,sglen,vary} are unsigned so
these tests do nothing.

Signed-off-by: Roel Kluin &lt;roel.kluin@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>USB: usbtest.c: length, sglen and vary are unsigned, so cannot be negative</title>
<updated>2008-10-22T17:05:28+00:00</updated>
<author>
<name>roel kluin</name>
<email>roel.kluin@gmail.com</email>
</author>
<published>2008-10-21T04:36:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=8aafdf6a1528b0672a0527be473d9be5a12289d3'/>
<id>8aafdf6a1528b0672a0527be473d9be5a12289d3</id>
<content type='text'>
length, sglen and vary are unsigned, so cannot be negative

see
vi drivers/usb/misc/usbtest.c +18
struct usbtest_param {
...
        unsigned                iterations;
        unsigned                length;
        unsigned                vary;
        unsigned                sglen;
...
};

Signed-off-by: Roel Kluin &lt;roel.kluin@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
length, sglen and vary are unsigned, so cannot be negative

see
vi drivers/usb/misc/usbtest.c +18
struct usbtest_param {
...
        unsigned                iterations;
        unsigned                length;
        unsigned                vary;
        unsigned                sglen;
...
};

Signed-off-by: Roel Kluin &lt;roel.kluin@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>Rename WARN() to WARNING() to clear the namespace</title>
<updated>2008-07-25T17:53:29+00:00</updated>
<author>
<name>Arjan van de Ven</name>
<email>arjan@linux.intel.com</email>
</author>
<published>2008-07-25T08:45:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=b6c63937001889af6fe431aaba97e59d04e028e7'/>
<id>b6c63937001889af6fe431aaba97e59d04e028e7</id>
<content type='text'>
We want to use WARN() as a variant of WARN_ON(), however a few drivers are
using WARN() internally.  This patch renames these to WARNING() to avoid the
namespace clash.  A few cases were defining but not using the thing, for those
cases I just deleted the definition.

Signed-off-by: Arjan van de Ven &lt;arjan@linux.intel.com&gt;
Acked-by: Greg KH &lt;greg@kroah.com&gt;
Cc: Karsten Keil &lt;kkeil@suse.de&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We want to use WARN() as a variant of WARN_ON(), however a few drivers are
using WARN() internally.  This patch renames these to WARNING() to avoid the
namespace clash.  A few cases were defining but not using the thing, for those
cases I just deleted the definition.

Signed-off-by: Arjan van de Ven &lt;arjan@linux.intel.com&gt;
Acked-by: Greg KH &lt;greg@kroah.com&gt;
Cc: Karsten Keil &lt;kkeil@suse.de&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>usbtest: comment on why this code "expects" negative and positive errnos</title>
<updated>2008-05-14T17:00:29+00:00</updated>
<author>
<name>Marcin Slusarz</name>
<email>marcin.slusarz@gmail.com</email>
</author>
<published>2008-05-12T18:17:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=6def755320a214ae149ad6bc69eb8c1d7887e678'/>
<id>6def755320a214ae149ad6bc69eb8c1d7887e678</id>
<content type='text'>
On Mon, May 12, 2008 at 01:02:22AM -0700, David Brownell wrote:
&gt; On Sunday 11 May 2008, Marcin Slusarz wrote:
&gt; &gt; 
&gt; &gt; test_ctrl_queue expects (?) positive and negative errnos.
&gt; &gt; what is going on here?
&gt; 
&gt; The sign is just a way to flag something:
&gt; 
&gt;                 /* some faults are allowed, not required */
&gt; 
&gt; The negative ones are required.  Positive codes are optional,
&gt; in the sense that, depending on how the peripheral happens
&gt; to be implemented, they won't necessarily be triggered.
&gt; 
&gt; For example, the test to fetch a device qualifier desriptor
&gt; must succeed if the device is running at high speed.  So that
&gt; test is marked as negative.  But when it's full speed, it
&gt; could legitimately fail; marked as positive.  And so on for
&gt; other tests.
&gt; 
&gt; Look at how the codes are *interpreted* to see it work.

Lets document it.

Based on comment from David Brownell &lt;david-b@pacbell.net&gt;.

Signed-off-by: Marcin Slusarz &lt;marcin.slusarz@gmail.com&gt;
Cc: David Brownell &lt;david-b@pacbell.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
On Mon, May 12, 2008 at 01:02:22AM -0700, David Brownell wrote:
&gt; On Sunday 11 May 2008, Marcin Slusarz wrote:
&gt; &gt; 
&gt; &gt; test_ctrl_queue expects (?) positive and negative errnos.
&gt; &gt; what is going on here?
&gt; 
&gt; The sign is just a way to flag something:
&gt; 
&gt;                 /* some faults are allowed, not required */
&gt; 
&gt; The negative ones are required.  Positive codes are optional,
&gt; in the sense that, depending on how the peripheral happens
&gt; to be implemented, they won't necessarily be triggered.
&gt; 
&gt; For example, the test to fetch a device qualifier desriptor
&gt; must succeed if the device is running at high speed.  So that
&gt; test is marked as negative.  But when it's full speed, it
&gt; could legitimately fail; marked as positive.  And so on for
&gt; other tests.
&gt; 
&gt; Look at how the codes are *interpreted* to see it work.

Lets document it.

Based on comment from David Brownell &lt;david-b@pacbell.net&gt;.

Signed-off-by: Marcin Slusarz &lt;marcin.slusarz@gmail.com&gt;
Cc: David Brownell &lt;david-b@pacbell.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>USB: usbtest displays diagnostics again</title>
<updated>2008-05-02T17:25:52+00:00</updated>
<author>
<name>David Brownell</name>
<email>david-b@pacbell.net</email>
</author>
<published>2008-04-26T01:51:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=28ffd79c31a7bed6f610511a4d104d1255cd1d95'/>
<id>28ffd79c31a7bed6f610511a4d104d1255cd1d95</id>
<content type='text'>
Minor cleanup to the "usbtest" driver, mostly to resolve a regression:
all the important diagnostics were at KERN_DEBUG, so that when the
"#define DEBUG" was removed from the top of that file it stopped
providing diagnostics.  Fix by using KERN_ERROR.  Also:

 - Stop using the legacy dbg() calls
 - Simplify the internal debug macros
 - Correct some test descriptions:
	* Test #10 subcase 7 should *always* stall
	* Test #10 subcase 8 *may* stall
 - Diagnostic about control queue test failures is more informative
 - Fix some whitespace "bugs"

And add a warning about the rude interaction between usbfs ioctl()
and khubd during device disconnect ... don't unplug a device under
test, that will wedge.

Signed-off-by: David Brownell &lt;dbrownell@users.sourceforge.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Minor cleanup to the "usbtest" driver, mostly to resolve a regression:
all the important diagnostics were at KERN_DEBUG, so that when the
"#define DEBUG" was removed from the top of that file it stopped
providing diagnostics.  Fix by using KERN_ERROR.  Also:

 - Stop using the legacy dbg() calls
 - Simplify the internal debug macros
 - Correct some test descriptions:
	* Test #10 subcase 7 should *always* stall
	* Test #10 subcase 8 *may* stall
 - Diagnostic about control queue test failures is more informative
 - Fix some whitespace "bugs"

And add a warning about the rude interaction between usbfs ioctl()
and khubd during device disconnect ... don't unplug a device under
test, that will wedge.

Signed-off-by: David Brownell &lt;dbrownell@users.sourceforge.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</pre>
</div>
</content>
</entry>
</feed>
