<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/drivers/net/can/usb, branch linux-3.13.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-3.13.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-3.13.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2014-03-07T06:06:23Z</updated>
<entry>
<title>can: kvaser_usb: check number of channels returned by HW</title>
<updated>2014-03-07T06:06:23Z</updated>
<author>
<name>Olivier Sobrie</name>
</author>
<published>2014-02-11T10:01:23Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a122e1f4c504578e1379d2808ce8a6f7e71a96db'/>
<id>urn:sha1:a122e1f4c504578e1379d2808ce8a6f7e71a96db</id>
<content type='text'>
commit 862474f8b46f6c1e600d4934e40ba40646c696ec upstream.

It is needed to check the number of channels returned by the HW because it
cannot be greater than MAX_NET_DEVICES otherwise it will crash.

Signed-off-by: Olivier Sobrie &lt;olivier@sobrie.be&gt;
Signed-off-by: Marc Kleine-Budde &lt;mkl@pengutronix.de&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>can: peak_usb: fix mem leak in pcan_usb_pro_init()</title>
<updated>2013-12-17T10:19:33Z</updated>
<author>
<name>Marc Kleine-Budde</name>
</author>
<published>2013-12-14T13:36:25Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=20fb4eb96fb0350d28fc4d7cbfd5506711079592'/>
<id>urn:sha1:20fb4eb96fb0350d28fc4d7cbfd5506711079592</id>
<content type='text'>
This patch fixes a memory leak in pcan_usb_pro_init(). In patch

    f14e224 net: can: peak_usb: Do not do dma on the stack

the struct pcan_usb_pro_fwinfo *fi and struct pcan_usb_pro_blinfo *bi were
converted from stack to dynamic allocation va kmalloc(). However the
corresponding kfree() was not introduced.

This patch adds the missing kfree().

Cc: linux-stable &lt;stable@vger.kernel.org&gt; # v3.10
Reported-by: Stephane Grosjean &lt;s.grosjean@peak-system.com&gt;
Signed-off-by: Marc Kleine-Budde &lt;mkl@pengutronix.de&gt;
</content>
</entry>
<entry>
<title>can: ems_usb: fix urb leaks on failure paths</title>
<updated>2013-12-17T10:19:11Z</updated>
<author>
<name>Alexey Khoroshilov</name>
</author>
<published>2013-12-06T23:10:35Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a1c31f1d057130cc63e72a09189410d169db7ecf'/>
<id>urn:sha1:a1c31f1d057130cc63e72a09189410d169db7ecf</id>
<content type='text'>
There are a couple failure paths where urb leaks.
Is spare code within ems_usb_start_xmit(),
usb_free_urb() should be used to deallocate urb instead of usb_unanchor_urb().
In ems_usb_start() there is no usb_free_urb() if usb_submit_urb() fails.

Found by Linux Driver Verification project (linuxtesting.org).

Signed-off-by: Alexey Khoroshilov &lt;khoroshilov@ispras.ru&gt;
Acked-by: Sebastian Haas &lt;dev@sebastianhaas.info&gt;
Signed-off-by: Marc Kleine-Budde &lt;mkl@pengutronix.de&gt;
</content>
</entry>
<entry>
<title>can: kvaser_usb: fix usb endpoints detection</title>
<updated>2013-10-31T19:20:23Z</updated>
<author>
<name>Olivier Sobrie</name>
</author>
<published>2013-10-27T21:07:53Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=896e23bd04ea50a146dffd342e2f96180f0812a5'/>
<id>urn:sha1:896e23bd04ea50a146dffd342e2f96180f0812a5</id>
<content type='text'>
Some devices, like the Kvaser Memorator Professional, have several bulk in
endpoints. Only the first one found must be used by the driver. The same holds
for the bulk out endpoint. The official Kvaser driver (leaf) was used as
reference for this patch.

Cc: linux-stable &lt;stable@vger.kernel.org&gt;
Signed-off-by: Olivier Sobrie &lt;olivier@sobrie.be&gt;
Signed-off-by: Marc Kleine-Budde &lt;mkl@pengutronix.de&gt;
</content>
</entry>
<entry>
<title>can: pcan_usb_core: fix memory leak on failure paths in peak_usb_start()</title>
<updated>2013-09-20T18:58:21Z</updated>
<author>
<name>Alexey Khoroshilov</name>
</author>
<published>2013-09-04T21:46:09Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=f37d6e701f2a3a04e66690397340a6417f6e053f'/>
<id>urn:sha1:f37d6e701f2a3a04e66690397340a6417f6e053f</id>
<content type='text'>
Tx and rx urbs are not deallocated if something goes wrong in peak_usb_start().
The patch fixes error handling to deallocate all the resources.

Found by Linux Driver Verification project (linuxtesting.org).

Signed-off-by: Alexey Khoroshilov &lt;khoroshilov@ispras.ru&gt;
Acked-by: Stephane Grosjean &lt;s.grosjean@peak-system.com&gt;
Signed-off-by: Marc Kleine-Budde &lt;mkl@pengutronix.de&gt;
</content>
</entry>
<entry>
<title>can: pcan_usb: fix wrong memcpy() bytes length</title>
<updated>2013-08-12T04:51:49Z</updated>
<author>
<name>Stephane Grosjean</name>
</author>
<published>2013-08-09T09:44:06Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=3c322a56b01695df15c70bfdc2d02e0ccd80654e'/>
<id>urn:sha1:3c322a56b01695df15c70bfdc2d02e0ccd80654e</id>
<content type='text'>
Fix possibly wrong memcpy() bytes length since some CAN records received from
PCAN-USB could define a DLC field in range [9..15].
In that case, the real DLC value MUST be used to move forward the record pointer
but, only 8 bytes max. MUST be copied into the data field of the struct
can_frame object of the skb given to the network core.

Cc: linux-stable &lt;stable@vger.kernel.org&gt;
Signed-off-by: Stephane Grosjean &lt;s.grosjean@peak-system.com&gt;
Signed-off-by: Marc Kleine-Budde &lt;mkl@pengutronix.de&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>can: usb_8dev: fix urb leak on failure path in usb_8dev_start()</title>
<updated>2013-07-19T12:55:14Z</updated>
<author>
<name>Alexey Khoroshilov</name>
</author>
<published>2013-07-17T21:20:33Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=7671986839f9207f8d76e8ef92b2d3f263a794cc'/>
<id>urn:sha1:7671986839f9207f8d76e8ef92b2d3f263a794cc</id>
<content type='text'>
If usb_8dev_start() fails to submit urb,
it unanchors the urb but forgets to free it.

Found by Linux Driver Verification project (linuxtesting.org).

Signed-off-by: Alexey Khoroshilov &lt;khoroshilov@ispras.ru&gt;
Signed-off-by: Marc Kleine-Budde &lt;mkl@pengutronix.de&gt;
</content>
</entry>
<entry>
<title>net: can: esd_usb2: check index of array before accessing</title>
<updated>2013-07-19T12:55:13Z</updated>
<author>
<name>Maximilian Schneider</name>
</author>
<published>2013-07-02T23:43:29Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=233a26e85f9a72bcd0cdb7a95d1d5abcd052369f'/>
<id>urn:sha1:233a26e85f9a72bcd0cdb7a95d1d5abcd052369f</id>
<content type='text'>
The esd_usb2_read_bulk_callback() function is parsing the data that comes from
the USB CAN adapter. One datum is used as an index to access the dev-&gt;nets[]
array. This patch adds the missing bounds checking.

Acked-by: Matthias Fuchs &lt;matthias.fuchs@esd.eu&gt;
Signed-off-by: Maximilian Schneider &lt;max@schneidersoft.net&gt;
Signed-off-by: Marc Kleine-Budde &lt;mkl@pengutronix.de&gt;
</content>
</entry>
<entry>
<title>can: usb_8dev: unregister netdev before free()ing</title>
<updated>2013-06-19T06:56:10Z</updated>
<author>
<name>Marc Kleine-Budde</name>
</author>
<published>2013-06-18T12:33:58Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=4afe2156eb639e563d6ef0c2706b66ea400348b2'/>
<id>urn:sha1:4afe2156eb639e563d6ef0c2706b66ea400348b2</id>
<content type='text'>
The usb_8dev hardware has problems on some xhci USB hosts. The driver fails to
read the firmware revision in the probe function. This leads to the following
Oops:

    [ 3356.635912] kernel BUG at net/core/dev.c:5701!

The driver tries to free the netdev, which has already been registered, without
unregistering it.

This patch fixes the problem by unregistering the netdev in the error path.

Reported-by: Michael Olbrich &lt;m.olbrich@pengutronix.de&gt;
Reviewed-by: Bernd Krumboeck &lt;krumboeck@universalnet.at&gt;
Signed-off-by: Marc Kleine-Budde &lt;mkl@pengutronix.de&gt;
</content>
</entry>
<entry>
<title>net: can: peak_usb: Do not do dma on the stack</title>
<updated>2013-06-03T12:05:32Z</updated>
<author>
<name>Marc Kleine-Budde</name>
</author>
<published>2013-05-16T09:36:40Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=f14e22435a27ef183bbfa78f77ad86644c0b354c'/>
<id>urn:sha1:f14e22435a27ef183bbfa78f77ad86644c0b354c</id>
<content type='text'>
smatch reports the following warnings:
drivers/net/can/usb/peak_usb/pcan_usb_pro.c:514 pcan_usb_pro_drv_loaded() error: doing dma on the stack (buffer)
drivers/net/can/usb/peak_usb/pcan_usb_pro.c:878 pcan_usb_pro_init() error: doing dma on the stack (&amp;fi)
drivers/net/can/usb/peak_usb/pcan_usb_pro.c:889 pcan_usb_pro_init() error: doing dma on the stack (&amp;bi)

See "Documentation/DMA-API-HOWTO.txt" section "What memory is DMA'able?"

Cc: Stephane Grosjean &lt;s.grosjean@peak-system.com&gt;
Signed-off-by: Marc Kleine-Budde &lt;mkl@pengutronix.de&gt;
</content>
</entry>
</feed>
