<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: IMX 53 CAN0 receive stops when using IPU in i.MX Processors</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/IMX-53-CAN0-receive-stops-when-using-IPU/m-p/269901#M28827</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Do you mean you lose all communication on CAN0 or do you start losing some CAN frames?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What speed is your CAN network. You shouldn't have any trouble on slow (33kHz) CAN buses, but you can expect problems with this software at 500kHz or 1MHz.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What does ifconfig show? Is the interface still "up"?&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Do you have network statistics visible under "/sys/class/net/can0/statistics"? What do they show?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;On our board with two 1MHz CAN buses, we lose CAN messages when we had a lot of Ethernet traffic. This is because the CAN drivers use "NAPI", and don't actually read any data from the absolutely time-critical and unbuffered CAN hardware. Reading the messages from the CAN registers is postponed until a background task. In contrast, the Ethernet driver will happily forward hundreds of packets from within its interrupt routine, locking out everything else (and the CAN interrupts and data-reading task) for many milliseconds.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then there are the "mystery times" when for no apparent reason the Kernel decides to block all tasks (including the NAPI ones) for a few milliseconds. Recompiling the kernel without the default diagnostics that we had helped with this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is compounded by the platform code we have (YMMV) not enabling any interrupt priority setting. Due to the default ordering, Ethernet gets priority over CAN.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I had to change the platform code to enable interrupt priority, AND rewrite the CAN drivers to have them read the data into a ring buffer during the interrupt to have them work reliably.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Tom&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 07 Feb 2014 00:58:12 GMT</pubDate>
    <dc:creator>TomE</dc:creator>
    <dc:date>2014-02-07T00:58:12Z</dc:date>
    <item>
      <title>IMX 53 CAN0 receive stops when using IPU</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/IMX-53-CAN0-receive-stops-when-using-IPU/m-p/269899#M28825</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;We are doing a project that uses both CAN bus and the VPU and IPU for video.&amp;nbsp; Video is coming in from a UVC camera being decode from mjpeg using the VPU and then the IPU is used to do a crop, scale, rotate, colorspace change and display to fb0. When mxc_ipu_lib_task_buf_update is called to display frames we lose communication from CAN0, CAN1 continues to function normally. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Has anyone seen this before or have any idea what could be the cause?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 19 Dec 2013 01:52:57 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/IMX-53-CAN0-receive-stops-when-using-IPU/m-p/269899#M28825</guid>
      <dc:creator>chadgreenebaum</dc:creator>
      <dc:date>2013-12-19T01:52:57Z</dc:date>
    </item>
    <item>
      <title>Re: IMX 53 CAN0 receive stops when using IPU</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/IMX-53-CAN0-receive-stops-when-using-IPU/m-p/269900#M28826</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have never seen this behavior before. Can you share more information about how to reproduce the problem and maybe share code of your application.?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;Alejandro&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Jan 2014 14:31:02 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/IMX-53-CAN0-receive-stops-when-using-IPU/m-p/269900#M28826</guid>
      <dc:creator>alejandrolozan1</dc:creator>
      <dc:date>2014-01-03T14:31:02Z</dc:date>
    </item>
    <item>
      <title>Re: IMX 53 CAN0 receive stops when using IPU</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/IMX-53-CAN0-receive-stops-when-using-IPU/m-p/269901#M28827</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Do you mean you lose all communication on CAN0 or do you start losing some CAN frames?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What speed is your CAN network. You shouldn't have any trouble on slow (33kHz) CAN buses, but you can expect problems with this software at 500kHz or 1MHz.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What does ifconfig show? Is the interface still "up"?&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Do you have network statistics visible under "/sys/class/net/can0/statistics"? What do they show?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;On our board with two 1MHz CAN buses, we lose CAN messages when we had a lot of Ethernet traffic. This is because the CAN drivers use "NAPI", and don't actually read any data from the absolutely time-critical and unbuffered CAN hardware. Reading the messages from the CAN registers is postponed until a background task. In contrast, the Ethernet driver will happily forward hundreds of packets from within its interrupt routine, locking out everything else (and the CAN interrupts and data-reading task) for many milliseconds.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then there are the "mystery times" when for no apparent reason the Kernel decides to block all tasks (including the NAPI ones) for a few milliseconds. Recompiling the kernel without the default diagnostics that we had helped with this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is compounded by the platform code we have (YMMV) not enabling any interrupt priority setting. Due to the default ordering, Ethernet gets priority over CAN.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I had to change the platform code to enable interrupt priority, AND rewrite the CAN drivers to have them read the data into a ring buffer during the interrupt to have them work reliably.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Tom&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 07 Feb 2014 00:58:12 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/IMX-53-CAN0-receive-stops-when-using-IPU/m-p/269901#M28827</guid>
      <dc:creator>TomE</dc:creator>
      <dc:date>2014-02-07T00:58:12Z</dc:date>
    </item>
  </channel>
</rss>

