<feed xmlns='http://www.w3.org/2005/Atom'>
<title>litmus-rt-ext-res.git/drivers/usb/usbip, branch EXT-RES</title>
<subtitle>LITMUS^RT with extended reservations for Forbidden Zones paper @ RTAS'20</subtitle>
<link rel='alternate' type='text/html' href='http://rtsrv.cs.unc.edu/cgit/cgit.cgi/litmus-rt-ext-res.git/'/>
<entry>
<title>usbip: vudc: fix: Clear already_seen flag also for ep0</title>
<updated>2017-01-06T09:40:11+00:00</updated>
<author>
<name>Krzysztof Opasiak</name>
<email>k.opasiak@samsung.com</email>
</author>
<published>2016-12-01T18:14:37+00:00</published>
<link rel='alternate' type='text/html' href='http://rtsrv.cs.unc.edu/cgit/cgit.cgi/litmus-rt-ext-res.git/commit/?id=77bd73ce21fafe2ca80fe09b6e9dbebf93fd4cd6'/>
<id>77bd73ce21fafe2ca80fe09b6e9dbebf93fd4cd6</id>
<content type='text'>
commit 3e448e13a662fb20145916636127995cbf37eb83 upstream.

ep_list inside gadget structure doesn't contain ep0.
It is stored separately in ep0 field.

This causes an urb hang if gadget driver decides to
delay setup handling. On host side this is visible as
timeout error when setting configuration.

This bug can be reproduced using for example any gadget
with mass storage function.

Fixes: abdb29574322 ("usbip: vudc: Add vudc_transfer")
Signed-off-by: Krzysztof Opasiak &lt;k.opasiak@samsung.com&gt;
Acked-by: Shuah Khan &lt;shuahkh@osg.samsung.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

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

ep_list inside gadget structure doesn't contain ep0.
It is stored separately in ep0 field.

This causes an urb hang if gadget driver decides to
delay setup handling. On host side this is visible as
timeout error when setting configuration.

This bug can be reproduced using for example any gadget
with mass storage function.

Fixes: abdb29574322 ("usbip: vudc: Add vudc_transfer")
Signed-off-by: Krzysztof Opasiak &lt;k.opasiak@samsung.com&gt;
Acked-by: Shuah Khan &lt;shuahkh@osg.samsung.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>usb: Kconfig: using select for USB_COMMON dependency</title>
<updated>2016-09-27T10:20:17+00:00</updated>
<author>
<name>Peter Chen</name>
<email>peter.chen@nxp.com</email>
</author>
<published>2016-09-14T01:49:30+00:00</published>
<link rel='alternate' type='text/html' href='http://rtsrv.cs.unc.edu/cgit/cgit.cgi/litmus-rt-ext-res.git/commit/?id=cb9c1cfc86926d0e86d19c8e34f6c23458cd3478'/>
<id>cb9c1cfc86926d0e86d19c8e34f6c23458cd3478</id>
<content type='text'>
According to (badf6d47f8a9 "usb: common: rework CONFIG_USB_COMMON logic")
we should select USB_COMMON at Kconfig when usb common stuffs are needed,
but some of Kconfig enties have not followed it, update them.

Cc: Felipe Balbi &lt;balbi@kernel.org&gt;
Cc: Heikki Krogerus &lt;heikki.krogerus@linux.intel.com&gt;
Signed-off-by: Peter Chen &lt;peter.chen@nxp.com&gt;
Acked-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
According to (badf6d47f8a9 "usb: common: rework CONFIG_USB_COMMON logic")
we should select USB_COMMON at Kconfig when usb common stuffs are needed,
but some of Kconfig enties have not followed it, update them.

Cc: Felipe Balbi &lt;balbi@kernel.org&gt;
Cc: Heikki Krogerus &lt;heikki.krogerus@linux.intel.com&gt;
Signed-off-by: Peter Chen &lt;peter.chen@nxp.com&gt;
Acked-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>usb: usbip: vudc: fix left shift overflow</title>
<updated>2016-08-30T20:28:52+00:00</updated>
<author>
<name>Nicolas Iooss</name>
<email>nicolas.iooss_linux@m4x.org</email>
</author>
<published>2016-08-23T15:13:29+00:00</published>
<link rel='alternate' type='text/html' href='http://rtsrv.cs.unc.edu/cgit/cgit.cgi/litmus-rt-ext-res.git/commit/?id=238b7bd91b16d5a08326f858db42229b212e53d8'/>
<id>238b7bd91b16d5a08326f858db42229b212e53d8</id>
<content type='text'>
In v_recv_cmd_submit(), urb_p-&gt;urb-&gt;pipe has the type unsigned int
(which is 32-bit long on x86_64) but 11&lt;&lt;30 results in a 34-bit integer.
Therefore the 2 leading bits are truncated and

    urb_p-&gt;urb-&gt;pipe &amp;= ~(11 &lt;&lt; 30);

has the same meaning as

    urb_p-&gt;urb-&gt;pipe &amp;= ~(3 &lt;&lt; 30);

This second statement seems to be how the code was intended to be
written, as PIPE_ constants have values between 0 and 3.

The overflow has been detected with a clang warning:

    drivers/usb/usbip/vudc_rx.c:145:27: warning: signed shift result
    (0x2C0000000) requires 35 bits to represent, but 'int' only has 32
    bits [-Wshift-overflow]
            urb_p-&gt;urb-&gt;pipe &amp;= ~(11 &lt;&lt; 30);
                                  ~~ ^  ~~

Fixes: 79c02cb1fd5c ("usbip: vudc: Add vudc_rx")
Signed-off-by: Nicolas Iooss &lt;nicolas.iooss_linux@m4x.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In v_recv_cmd_submit(), urb_p-&gt;urb-&gt;pipe has the type unsigned int
(which is 32-bit long on x86_64) but 11&lt;&lt;30 results in a 34-bit integer.
Therefore the 2 leading bits are truncated and

    urb_p-&gt;urb-&gt;pipe &amp;= ~(11 &lt;&lt; 30);

has the same meaning as

    urb_p-&gt;urb-&gt;pipe &amp;= ~(3 &lt;&lt; 30);

This second statement seems to be how the code was intended to be
written, as PIPE_ constants have values between 0 and 3.

The overflow has been detected with a clang warning:

    drivers/usb/usbip/vudc_rx.c:145:27: warning: signed shift result
    (0x2C0000000) requires 35 bits to represent, but 'int' only has 32
    bits [-Wshift-overflow]
            urb_p-&gt;urb-&gt;pipe &amp;= ~(11 &lt;&lt; 30);
                                  ~~ ^  ~~

Fixes: 79c02cb1fd5c ("usbip: vudc: Add vudc_rx")
Signed-off-by: Nicolas Iooss &lt;nicolas.iooss_linux@m4x.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>usbip: vudc: Fix apparent cut-n-paste error</title>
<updated>2016-08-30T17:06:43+00:00</updated>
<author>
<name>Dave Jones</name>
<email>davej@codemonkey.org.uk</email>
</author>
<published>2016-05-31T15:25:09+00:00</published>
<link rel='alternate' type='text/html' href='http://rtsrv.cs.unc.edu/cgit/cgit.cgi/litmus-rt-ext-res.git/commit/?id=1328f7b928e3fc41e019903a56d7253b04d7e4de'/>
<id>1328f7b928e3fc41e019903a56d7253b04d7e4de</id>
<content type='text'>
Coverity picked up that this looks like a cut-n-paste from an almost
identical sequence below that didn't get its variable renamed.

Signed-off-by: Dave Jones &lt;davej@codemonkey.org.uk&gt;
Reviewed-by: Krzysztof Opasiak &lt;k.opasiak@samsung.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Coverity picked up that this looks like a cut-n-paste from an almost
identical sequence below that didn't get its variable renamed.

Signed-off-by: Dave Jones &lt;davej@codemonkey.org.uk&gt;
Reviewed-by: Krzysztof Opasiak &lt;k.opasiak@samsung.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>usbip: vhci_hcd: fix return value check in add_platform_device()</title>
<updated>2016-08-15T14:25:59+00:00</updated>
<author>
<name>Wei Yongjun</name>
<email>weiyj.lk@gmail.com</email>
</author>
<published>2016-08-12T11:22:22+00:00</published>
<link rel='alternate' type='text/html' href='http://rtsrv.cs.unc.edu/cgit/cgit.cgi/litmus-rt-ext-res.git/commit/?id=6e958051cb0742dd54bb61528c130bd6eaecae0d'/>
<id>6e958051cb0742dd54bb61528c130bd6eaecae0d</id>
<content type='text'>
In case of error, the function platform_device_register_simple() returns
ERR_PTR() and never returns NULL. The NULL test in the return value
check should be replaced with IS_ERR().

Signed-off-by: Wei Yongjun &lt;weiyj.lk@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In case of error, the function platform_device_register_simple() returns
ERR_PTR() and never returns NULL. The NULL test in the return value
check should be replaced with IS_ERR().

Signed-off-by: Wei Yongjun &lt;weiyj.lk@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>usb: usbip: stub_rx: don't print error when allocating urb fails</title>
<updated>2016-08-15T13:54:27+00:00</updated>
<author>
<name>Wolfram Sang</name>
<email>wsa-dev@sang-engineering.com</email>
</author>
<published>2016-08-11T21:14:48+00:00</published>
<link rel='alternate' type='text/html' href='http://rtsrv.cs.unc.edu/cgit/cgit.cgi/litmus-rt-ext-res.git/commit/?id=7190c178e65b111379faa7c3b453b7e54f078872'/>
<id>7190c178e65b111379faa7c3b453b7e54f078872</id>
<content type='text'>
kmalloc will print enough information in case of failure.

Signed-off-by: Wolfram Sang &lt;wsa-dev@sang-engineering.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
kmalloc will print enough information in case of failure.

Signed-off-by: Wolfram Sang &lt;wsa-dev@sang-engineering.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>usbip: vhci extension: modifications to vhci driver</title>
<updated>2016-08-09T14:21:05+00:00</updated>
<author>
<name>Nobuo Iwata</name>
<email>nobuo.iwata@fujixerox.co.jp</email>
</author>
<published>2016-06-13T02:33:40+00:00</published>
<link rel='alternate' type='text/html' href='http://rtsrv.cs.unc.edu/cgit/cgit.cgi/litmus-rt-ext-res.git/commit/?id=0775a9cbc694e8c7276688be3bbd2f386167ab54'/>
<id>0775a9cbc694e8c7276688be3bbd2f386167ab54</id>
<content type='text'>
Modification to Kconfig, vhci_hc.c, vhci.h and vhci_sysfs.c.

1. kernel config

Followings are added.

USBIP_VHCI_HC_PORTS: Number of ports per USB/IP virtual host
controller. The default is 8 - same as current VHCI_NPORTS.
USBIP_VHCI_NR_HCS: Number of USB/IP virtual host controllers. The
default is 1. This paratmeter is replaced with USBIP_VHCI_INIT_HCS and
USBIP_VHCI_MAX_HCS included in succeeding dynamic extension patch.

2. the_controller to controllers

the_controller is changed to vhci_pdevs: array of struct
platform_device.

3. vhci_sysfs.c

Sysfs structure is changed as following.

BEFORE:
    /sys/devices/platform
        +-- vhci
            +-- status
            +-- attach
            +-- detach
            +-- usbip_debug

AFTER: example for CONFIG_USBIP_NR_HCS=4
    /sys/devices/platform
        +-- vhci
        |   +-- nports
        |   +-- status
        |   +-- status.1
        |   +-- status.2
        |   +-- status.3
        |   +-- attach
        |   +-- detach
        |   +-- usbip_debug
        +-- vhci.1
        +-- vhci.2
        +-- vhci.3

vhci[.N] is shown for each host controller kobj. vhch.1, vhci.2, ...
are shown only when CONFIG_USBIP_NR_HCS is more than 1. Only 'vhci'
(without number) has user space interfaces. 'nports' is newly added to
give ports-per-controller and number of controlles. Before that, number
of ports is acquired by reading status lines. Status is divided for
each controller to avoid page size (4KB) limitation.

Old userspace tool binaries work with the first status within the first
controller.

Inconsistency between status header and content is fixed.
4th and 5th column are
header:          "dev bus"
content(unused): "000 000"
content(used):   "%08x", devid
Only 1st and 2nd column are used by program. In old version, sscanf()
in parse_status expect no bus column. And bus_id string is shown in the
last column. Then bus in the header is removed and unused content is
replaced with 8 zeros. The sscanf() expects more than 5 columns and new
has 6 columns so there's no compatibility issue in this change.

Signed-off-by: Nobuo Iwata &lt;nobuo.iwata@fujixerox.co.jp&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Modification to Kconfig, vhci_hc.c, vhci.h and vhci_sysfs.c.

1. kernel config

Followings are added.

USBIP_VHCI_HC_PORTS: Number of ports per USB/IP virtual host
controller. The default is 8 - same as current VHCI_NPORTS.
USBIP_VHCI_NR_HCS: Number of USB/IP virtual host controllers. The
default is 1. This paratmeter is replaced with USBIP_VHCI_INIT_HCS and
USBIP_VHCI_MAX_HCS included in succeeding dynamic extension patch.

2. the_controller to controllers

the_controller is changed to vhci_pdevs: array of struct
platform_device.

3. vhci_sysfs.c

Sysfs structure is changed as following.

BEFORE:
    /sys/devices/platform
        +-- vhci
            +-- status
            +-- attach
            +-- detach
            +-- usbip_debug

AFTER: example for CONFIG_USBIP_NR_HCS=4
    /sys/devices/platform
        +-- vhci
        |   +-- nports
        |   +-- status
        |   +-- status.1
        |   +-- status.2
        |   +-- status.3
        |   +-- attach
        |   +-- detach
        |   +-- usbip_debug
        +-- vhci.1
        +-- vhci.2
        +-- vhci.3

vhci[.N] is shown for each host controller kobj. vhch.1, vhci.2, ...
are shown only when CONFIG_USBIP_NR_HCS is more than 1. Only 'vhci'
(without number) has user space interfaces. 'nports' is newly added to
give ports-per-controller and number of controlles. Before that, number
of ports is acquired by reading status lines. Status is divided for
each controller to avoid page size (4KB) limitation.

Old userspace tool binaries work with the first status within the first
controller.

Inconsistency between status header and content is fixed.
4th and 5th column are
header:          "dev bus"
content(unused): "000 000"
content(used):   "%08x", devid
Only 1st and 2nd column are used by program. In old version, sscanf()
in parse_status expect no bus column. And bus_id string is shown in the
last column. Then bus in the header is removed and unused content is
replaced with 8 zeros. The sscanf() expects more than 5 columns and new
has 6 columns so there's no compatibility issue in this change.

Signed-off-by: Nobuo Iwata &lt;nobuo.iwata@fujixerox.co.jp&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge 4.7-rc4 into usb-next</title>
<updated>2016-06-20T14:40:51+00:00</updated>
<author>
<name>Greg Kroah-Hartman</name>
<email>gregkh@linuxfoundation.org</email>
</author>
<published>2016-06-20T14:40:51+00:00</published>
<link rel='alternate' type='text/html' href='http://rtsrv.cs.unc.edu/cgit/cgit.cgi/litmus-rt-ext-res.git/commit/?id=bc71c2df45e5a861818b5ee173702883df07471a'/>
<id>bc71c2df45e5a861818b5ee173702883df07471a</id>
<content type='text'>
We need the 4.7-rc4 fixes in here as well.

Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We need the 4.7-rc4 fixes in here as well.

Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>usbip: rate limit get_frame_number message</title>
<updated>2016-06-18T01:00:46+00:00</updated>
<author>
<name>Greg Kroah-Hartman</name>
<email>gregkh@linuxfoundation.org</email>
</author>
<published>2016-06-14T20:41:07+00:00</published>
<link rel='alternate' type='text/html' href='http://rtsrv.cs.unc.edu/cgit/cgit.cgi/litmus-rt-ext-res.git/commit/?id=083d5ad1a924e79ecf92be37cce9f1efa5c1d240'/>
<id>083d5ad1a924e79ecf92be37cce9f1efa5c1d240</id>
<content type='text'>
It's annoying to constantly see the same "Not yet implemented" message
over and over with nothing able to be done about it, so rate limit it
for now to keep user's logs "clean".

Reported-by: Lars Täuber &lt;lars.taeuber@web.de&gt;
Tested-by: Lars Täuber &lt;lars.taeuber@web.de&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It's annoying to constantly see the same "Not yet implemented" message
over and over with nothing able to be done about it, so rate limit it
for now to keep user's logs "clean".

Reported-by: Lars Täuber &lt;lars.taeuber@web.de&gt;
Tested-by: Lars Täuber &lt;lars.taeuber@web.de&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>usb: usbip: remove null check</title>
<updated>2016-06-08T05:18:39+00:00</updated>
<author>
<name>Sudip Mukherjee</name>
<email>sudipm.mukherjee@gmail.com</email>
</author>
<published>2016-06-06T21:23:32+00:00</published>
<link rel='alternate' type='text/html' href='http://rtsrv.cs.unc.edu/cgit/cgit.cgi/litmus-rt-ext-res.git/commit/?id=7c348f1cfb6d8c6911fcb6d13b4c267a8bc93856'/>
<id>7c348f1cfb6d8c6911fcb6d13b4c267a8bc93856</id>
<content type='text'>
The only caller of get_gadget_descs() has already dereferenced udc
before calling this function, so udc can not be NULL at this point of
the code and hence no use of checking it.

Signed-off-by: Sudip Mukherjee &lt;sudip.mukherjee@codethink.co.uk&gt;
Reviewed-by: Krzysztof Opasiak &lt;k.opasiak@samsung.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The only caller of get_gadget_descs() has already dereferenced udc
before calling this function, so udc can not be NULL at this point of
the code and hence no use of checking it.

Signed-off-by: Sudip Mukherjee &lt;sudip.mukherjee@codethink.co.uk&gt;
Reviewed-by: Krzysztof Opasiak &lt;k.opasiak@samsung.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
</feed>
