* Query for status of timestamping for XCAN driver and possible project
@ 2021-10-20 11:17 Pavel Pisa
2021-10-20 11:34 ` Marc Kleine-Budde
0 siblings, 1 reply; 2+ messages in thread
From: Pavel Pisa @ 2021-10-20 11:17 UTC (permalink / raw)
To: Marc Kleine-Budde, Oliver Hartkopp, linux-can
Cc: Matej Vasilevski, Michal Simek, Martin Jeřábek
Hello Oliver and Marc,
our student, Matej Vasilevski, has chosen to continue
on CAN latency tester which we done for Oliver years
ago.
We want to continue on the CAN-BENCH project started
by Martin Jerabek
https://gitlab.fel.cvut.cz/canbus/zynq/zynq-can-sja1000-top/-/wikis/home
https://gitlab.fel.cvut.cz/canbus/zynq/zynq-can-sja1000-top/-/wikis/uploads/56b4d27d8f81ae390fc98bdce803398f/F3-BP-2016-Jerabek-Martin-Jerabek-thesis-2016.pd
We want to use XCAN on Xilinx Zynq 7010 with timestamping
in the first iteration, then switch to our CTU CAN FD core
and add timestamping to its driver.
Is there some more recent attempt to add timestamping
to XCAN driver than that original work of Martin Jerabek?
Is there some suggestion which driver is the right
example to implement timestamping now?
Our intention is to implement feature in state ready
for mainlining and we hope that with your feedback
we succeed this time.
Best wishes,
Pavel Pisa
phone: +420 603531357
e-mail: pisa@cmp.felk.cvut.cz
Department of Control Engineering FEE CVUT
Karlovo namesti 13, 121 35, Prague 2
university: http://dce.fel.cvut.cz/
personal: http://cmp.felk.cvut.cz/~pisa
projects: https://www.openhub.net/accounts/ppisa
CAN related:http://canbus.pages.fel.cvut.cz/
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Query for status of timestamping for XCAN driver and possible project
2021-10-20 11:17 Query for status of timestamping for XCAN driver and possible project Pavel Pisa
@ 2021-10-20 11:34 ` Marc Kleine-Budde
0 siblings, 0 replies; 2+ messages in thread
From: Marc Kleine-Budde @ 2021-10-20 11:34 UTC (permalink / raw)
To: Pavel Pisa
Cc: Oliver Hartkopp, linux-can, Matej Vasilevski, Michal Simek,
Martin Jeřábek
[-- Attachment #1: Type: text/plain, Size: 2104 bytes --]
On 20.10.2021 13:17:50, Pavel Pisa wrote:
> Hello Oliver and Marc,
>
> our student, Matej Vasilevski, has chosen to continue
> on CAN latency tester which we done for Oliver years
> ago.
>
> We want to continue on the CAN-BENCH project started
> by Martin Jerabek
>
> https://gitlab.fel.cvut.cz/canbus/zynq/zynq-can-sja1000-top/-/wikis/home
>
> https://gitlab.fel.cvut.cz/canbus/zynq/zynq-can-sja1000-top/-/wikis/uploads/56b4d27d8f81ae390fc98bdce803398f/F3-BP-2016-Jerabek-Martin-Jerabek-thesis-2016.pd
>
> We want to use XCAN on Xilinx Zynq 7010 with timestamping
> in the first iteration, then switch to our CTU CAN FD core
> and add timestamping to its driver.
>
> Is there some more recent attempt to add timestamping
> to XCAN driver than that original work of Martin Jerabek?
>
> Is there some suggestion which driver is the right
> example to implement timestamping now?
I recently added HW timestamp support to the mcp251xfd driver. It makes
use of the timecounter + cyclecounter helpers. These take care of wrap
arounds and conversion of the timer value to nanoseconds.
https://elixir.bootlin.com/linux/v5.14/source/drivers/net/can/spi/mcp251xfd/mcp251xfd-timestamp.c
A worker is setup to regularly read the free running time stamp register
to deal with the wrap around. You probably don't need this, if you have
a 64 bit timestamp register.
If your hardware directly provides 64 bit timestamp in ns or µs, you
don't even need the timecounter/cyclecounter.
To set the HW timestamp on the skb, it's
| mcp251xfd_skb_set_timestamp()
with timestamp provided by the CAN core that's done on RX and
TX-completion.
> Our intention is to implement feature in state ready
> for mainlining and we hope that with your feedback
> we succeed this time.
regards,
Marc
--
Pengutronix e.K. | Marc Kleine-Budde |
Embedded Linux | https://www.pengutronix.de |
Vertretung West/Dortmund | Phone: +49-231-2826-924 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2021-10-20 11:49 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-10-20 11:17 Query for status of timestamping for XCAN driver and possible project Pavel Pisa
2021-10-20 11:34 ` Marc Kleine-Budde
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox