<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/drivers/net/can/usb, branch v6.3.2</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v6.3.2</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v6.3.2'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2023-02-16T19:59:48+00:00</updated>
<entry>
<title>can: esd_usb: Improve readability on decoding ESD_EV_CAN_ERROR_EXT messages</title>
<updated>2023-02-16T19:59:48+00:00</updated>
<author>
<name>Frank Jungclaus</name>
<email>frank.jungclaus@esd.eu</email>
</author>
<published>2023-02-16T19:04:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=07c3f9224713c1b5f82c4583a456a6abc28f9d73'/>
<id>urn:sha1:07c3f9224713c1b5f82c4583a456a6abc28f9d73</id>
<content type='text'>
As suggested by Marc introduce a union plus a struct ev_can_err_ext
for easier decoding of an ESD_EV_CAN_ERROR_EXT event message (which
simply is a rx_msg with some dedicated data).

Suggested-by: Marc Kleine-Budde &lt;mkl@pengutronix.de&gt;
Link: https://lore.kernel.org/linux-can/20220621071152.ggyhrr5sbzvwpkpx@pengutronix.de/
Signed-off-by: Frank Jungclaus &lt;frank.jungclaus@esd.eu&gt;
Link: https://lore.kernel.org/all/20230216190450.3901254-4-frank.jungclaus@esd.eu
Signed-off-by: Marc Kleine-Budde &lt;mkl@pengutronix.de&gt;
</content>
</entry>
<entry>
<title>can: esd_usb: Make use of can_change_state() and relocate checking skb for NULL</title>
<updated>2023-02-16T19:59:48+00:00</updated>
<author>
<name>Frank Jungclaus</name>
<email>frank.jungclaus@esd.eu</email>
</author>
<published>2023-02-16T19:04:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=9684b000a86299b5968fef8ffbf1484def37452a'/>
<id>urn:sha1:9684b000a86299b5968fef8ffbf1484def37452a</id>
<content type='text'>
Start a rework initiated by Vincents remarks "You should not report
the greatest of txerr and rxerr but the one which actually increased."
[1] and "As far as I understand, those flags should be set only when
the threshold is reached" [2] .

Therefore make use of can_change_state() to (among others) set the
flags CAN_ERR_CRTL_[RT]X_WARNING and CAN_ERR_CRTL_[RT]X_PASSIVE,
maintain CAN statistic counters for error_warning, error_passive and
bus_off.

Relocate testing alloc_can_err_skb() for NULL to the end of
esd_usb_rx_event(), to have things like can_bus_off(),
can_change_state() working even in out of memory conditions.

Fixes: 96d8e90382dc ("can: Add driver for esd CAN-USB/2 device")
Signed-off-by: Frank Jungclaus &lt;frank.jungclaus@esd.eu&gt;
Link: [1] https://lore.kernel.org/all/CAMZ6RqKGBWe15aMkf8-QLf-cOQg99GQBebSm+1wEzTqHgvmNuw@mail.gmail.com/
Link: [2] https://lore.kernel.org/all/CAMZ6Rq+QBO1yTX_o6GV0yhdBj-RzZSRGWDZBS0fs7zbSTy4hmA@mail.gmail.com/
Link: https://lore.kernel.org/all/20230216190450.3901254-3-frank.jungclaus@esd.eu
Signed-off-by: Marc Kleine-Budde &lt;mkl@pengutronix.de&gt;
</content>
</entry>
<entry>
<title>can: esd_usb: Move mislocated storage of SJA1000_ECC_SEG bits in case of a bus error</title>
<updated>2023-02-16T19:59:47+00:00</updated>
<author>
<name>Frank Jungclaus</name>
<email>frank.jungclaus@esd.eu</email>
</author>
<published>2023-02-16T19:04:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=118469f88180438ef43dee93d71f77c00e7b425d'/>
<id>urn:sha1:118469f88180438ef43dee93d71f77c00e7b425d</id>
<content type='text'>
Move the supply for cf-&gt;data[3] (bit stream position of CAN error), in
case of a bus- or protocol-error, outside of the "switch (ecc &amp;
SJA1000_ECC_MASK){}"-statement, because this bit stream position is
independent of the error type.

Fixes: 96d8e90382dc ("can: Add driver for esd CAN-USB/2 device")
Signed-off-by: Frank Jungclaus &lt;frank.jungclaus@esd.eu&gt;
Link: https://lore.kernel.org/all/20230216190450.3901254-2-frank.jungclaus@esd.eu
Signed-off-by: Marc Kleine-Budde &lt;mkl@pengutronix.de&gt;
</content>
</entry>
<entry>
<title>can: peak_usb: Reorder include directives alphabetically</title>
<updated>2023-02-02T16:39:29+00:00</updated>
<author>
<name>Lukas Magel</name>
<email>lukas.magel@posteo.net</email>
</author>
<published>2023-01-16T20:09:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=73019de17732ec2edde007930407912e491a1c0f'/>
<id>urn:sha1:73019de17732ec2edde007930407912e491a1c0f</id>
<content type='text'>
The include directives in all source files are reordered alphabetically
according to the names of the header files.

Signed-off-by: Lukas Magel &lt;lukas.magel@posteo.net&gt;
Link: https://lore.kernel.org/all/20230116200932.157769-9-lukas.magel@posteo.net
[mkl: move header changes from Patch 3 here]
Signed-off-by: Marc Kleine-Budde &lt;mkl@pengutronix.de&gt;
</content>
</entry>
<entry>
<title>can: peak_usb: align CAN channel ID format in log with sysfs attribute</title>
<updated>2023-02-02T16:39:27+00:00</updated>
<author>
<name>Lukas Magel</name>
<email>lukas.magel@posteo.net</email>
</author>
<published>2023-01-16T20:09:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=09ce908e50c9ee43732015c36c32b18efe7b9ab6'/>
<id>urn:sha1:09ce908e50c9ee43732015c36c32b18efe7b9ab6</id>
<content type='text'>
Previously, the CAN channel ID was printed to the kernel log in decimal
upon connecting a new PEAK device. This behavior is inconsistent with
the hexadecimal format of the CAN channel ID sysfs attribute. This patch
updates the log message to output the id in hexadecimal.

Signed-off-by: Lukas Magel &lt;lukas.magel@posteo.net&gt;
Link: https://lore.kernel.org/all/20230116200932.157769-8-lukas.magel@posteo.net
Signed-off-by: Marc Kleine-Budde &lt;mkl@pengutronix.de&gt;
</content>
</entry>
<entry>
<title>can: peak_usb: export PCAN CAN channel ID as sysfs device attribute</title>
<updated>2023-02-02T16:39:25+00:00</updated>
<author>
<name>Lukas Magel</name>
<email>lukas.magel@posteo.net</email>
</author>
<published>2023-01-16T20:09:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=6d02f6daeb44c0099ace2e3597d56420eecfaeb2'/>
<id>urn:sha1:6d02f6daeb44c0099ace2e3597d56420eecfaeb2</id>
<content type='text'>
This patch exports the CAN channel ID as a sysfs attribute. The CAN
channel ID is a user-configurable u8/u32 identifier that can be set
individually for each CAN interface of a PEAK USB device.

Exporting the channel ID as a sysfs attribute allows users to easily read
the ID and to write udev rules that can match against the ID. This is
especially useful for PEAK USB devices that do not export a serial
number at SUB level.

Signed-off-by: Stephane Grosjean &lt;s.grosjean@peak-system.com&gt;
Signed-off-by: Lukas Magel &lt;lukas.magel@posteo.net&gt;
Link: https://lore.kernel.org/all/20230116200932.157769-7-lukas.magel@posteo.net
Signed-off-by: Marc Kleine-Budde &lt;mkl@pengutronix.de&gt;
</content>
</entry>
<entry>
<title>can: peak_usb: add ethtool interface to user-configurable CAN channel identifier</title>
<updated>2023-02-02T16:39:23+00:00</updated>
<author>
<name>Stephane Grosjean</name>
<email>s.grosjean@peak-system.com</email>
</author>
<published>2023-01-16T20:09:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=36d007c6fc7962cb70ff4b1496d1e24f8b1c1300'/>
<id>urn:sha1:36d007c6fc7962cb70ff4b1496d1e24f8b1c1300</id>
<content type='text'>
This patch introduces 3 new functions implementing support for ethtool
access to the CAN channel ID of all USB CAN network interfaces managed by
the driver. With this patch, it is possible to read/write the CAN
channel ID from/to the EEPROM via the ethtool interface.

The CAN channel ID is a user-configurable device identifier that can be
set individually for each CAN interface of a PEAK USB device. Depending on
the device, the identifier has a length of 8 or 32 bit. The identifier
is stored in the non-volatile memory of the device.

The identifier of a CAN interface can be read/written as an 8 or 32 bit
byte string in native (little-endian) byte order, where the length depends
on the device type.

Signed-off-by: Stephane Grosjean &lt;s.grosjean@peak-system.com&gt;
Signed-off-by: Lukas Magel &lt;lukas.magel@posteo.net&gt;
Link: https://lore.kernel.org/all/20230116200932.157769-6-lukas.magel@posteo.net
Signed-off-by: Marc Kleine-Budde &lt;mkl@pengutronix.de&gt;
</content>
</entry>
<entry>
<title>can: peak_usb: replace unregister_netdev() with unregister_candev()</title>
<updated>2023-02-02T16:39:20+00:00</updated>
<author>
<name>Stephane Grosjean</name>
<email>s.grosjean@peak-system.com</email>
</author>
<published>2023-01-16T20:09:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=e1bd882252439dae49c40cfe80997cde5955939f'/>
<id>urn:sha1:e1bd882252439dae49c40cfe80997cde5955939f</id>
<content type='text'>
This patch changes the call to unregister_netdev() in
peak_usb_disconnect() with unregister_candev().

Signed-off-by: Stephane Grosjean &lt;s.grosjean@peak-system.com&gt;
Signed-off-by: Lukas Magel &lt;lukas.magel@posteo.net&gt;
Link: https://lore.kernel.org/all/20230116200932.157769-5-lukas.magel@posteo.net
Signed-off-by: Marc Kleine-Budde &lt;mkl@pengutronix.de&gt;
</content>
</entry>
<entry>
<title>can: peak_usb: allow flashing of the CAN channel ID</title>
<updated>2023-02-02T16:39:18+00:00</updated>
<author>
<name>Stephane Grosjean</name>
<email>s.grosjean@peak-system.com</email>
</author>
<published>2023-01-16T20:09:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=e7a7b3d22503d79ccd0c2536080ed3f7b10a23f6'/>
<id>urn:sha1:e7a7b3d22503d79ccd0c2536080ed3f7b10a23f6</id>
<content type='text'>
This patch adds callbacks that allow the user to set a new self-defined
CAN channel ID to all USB - CAN/CANFD interfaces of PEAK-System managed by
this driver, namely:
- PCAN-USB
- PCAN-USB FD
- PCAN-USB Pro FD
- PCAN-USB X6
- PCAN-Chip USB
- PCAN-USB Pro

The callback functions write the CAN channel ID to the non-volatile
memory of the devices.

Signed-off-by: Stephane Grosjean &lt;s.grosjean@peak-system.com&gt;
Signed-off-by: Lukas Magel &lt;lukas.magel@posteo.net&gt;
Link: https://lore.kernel.org/all/20230116200932.157769-4-lukas.magel@posteo.net
Signed-off-by: Marc Kleine-Budde &lt;mkl@pengutronix.de&gt;
</content>
</entry>
<entry>
<title>can: peak_usb: add callback to read CAN channel ID of PEAK CAN-FD devices</title>
<updated>2023-02-02T16:39:16+00:00</updated>
<author>
<name>Stephane Grosjean</name>
<email>s.grosjean@peak-system.com</email>
</author>
<published>2023-01-16T20:09:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=517ad5e6761feca12f0fc78e7c6304560da853f4'/>
<id>urn:sha1:517ad5e6761feca12f0fc78e7c6304560da853f4</id>
<content type='text'>
This patch adds a new function that allows to read the CAN channel ID
from the non volatile memory of the USB CAN-FD PEAK devices. The CAN
channel ID is a user-configurable u8/u32 identifier value that can be set
individually for each PEAK CAN interface.

Signed-off-by: Stephane Grosjean &lt;s.grosjean@peak-system.com&gt;
Signed-off-by: Lukas Magel &lt;lukas.magel@posteo.net&gt;
Link: https://lore.kernel.org/all/20230116200932.157769-3-lukas.magel@posteo.net
Signed-off-by: Marc Kleine-Budde &lt;mkl@pengutronix.de&gt;
</content>
</entry>
</feed>
