Bulk in streaming hangs if connected to ASM3142 based host controllers

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
spider01
Level 2
Level 2
First solution authored 5 replies posted 10 sign-ins

Hi,

we face the same issue described here:

https://community.infineon.com/t5/USB-superspeed-peripherals/Bulk-In-data-streaming-hangs-on-CYUSB3K...


The above topic is marked "resolved" but I don't think it is what you can see once you read it.
@Sergey if you read this:
Did you solve the issue in the meantime?

---

I found the post above and we also seem to have the same issue with interoperability of ASM3142 based host controllers of different manufactures (e.g. Logilink v.2 PC0080) and FX3.

1) If using IN transfers with our FX3 based device connected to a ASM3142 based host controller the "IN EP" hangs almost immediately when lange image transfer is started.
We use WinUSB driver and there is no BSOD.
The same problem is seen on different PCs with different of our FX3 based USB devices.

2) The Issue appears on Windows 10 only (never saw it on Linux or Windows 7)

3) Now also checked it with CYUSB3KIT-001 DevKit and Streamer App, SDK 1.3.4:

I can reproduce the errors Sergey has described with the Streamer application together with an ASM3142 based host controller including BSOD especially with large block size: Packets per Xfer 256 and XFers to Queue 64

4) The error is dependent on the ASM3142 Firmware version:

"191209_70_02_40" which seem to become the current version of most of the manufacturers of host controllers, always shows this error.

With a previous version of Asmedia 3142 Firmware "170308_70_02_00" the error does not occur.

This is also true for the check with DevKit and Streamer App!

5) There are no issues with other devices connected to ASM3142 of any firmware version which are not FX3 based.

---

Maybe you are able to reproduce the problem at Infineon by using the current ASM3142 firmware?

Regards
Guenter

0 Likes
1 Solution

Hi AliAsgar,

we have three different test setups:

1. Tests with Cypress cyusb3.sys driver
================================
using unmodified original streamer executable GUI from SDK 1.3.4.
a. +  don't know if Cypress "streamer" uses c. or d.
Packets per Xfer 256 and XFers to Queue 64
Result: system freeze or BSOD, memory dump provided

2. Tests WinUSB driver with WinUSB_ReadPipe, wstreamer application
===========================================================
Still using original FX3 firmware a. and tried both c. and d.
MS-WinUSB driver with my own "WinUSB INF" file for streamer device "04b4:00f1"
"wstreamer application" is a Windows/Linux command line test C++ application developed by myself.
NO BSOD occurred, comparable data rates as in Test 1. but no errors reproducible at all.

3. Tests with our camera product devices, WinUSB_ReadPipe
==================================================
b. + c
FPGA continuously sending image data to FX3.
Two other endpoints for command and response are also used (low rate).
Enumeration was always fine.
"Image Communication stops/hangs" only if  "c. Overlapped IO" is used.
If d. is used no problem occurs. No BSOD.

---

I hope I could clarify the different setups . If you need more information, please let me know.

Best regards
Guenter

 

 

View solution in original post

0 Likes
17 Replies
lock attach
Attachments are accessible only for community members.
AliAsgar
Moderator
Moderator
Moderator
1000 replies posted 250 solutions authored 750 replies posted

Hi Guenter,

We will again try to reproduce the issue at our end.

Meanwhile, could you try to bind FX3 with the attached driver and check if the issue occurs?

Best Regards,
AliAsgar

0 Likes

Hi AliAsgar,

thank you for the driver, I have tested it and the issue still occurs the same way.

Details:

FX3 StreamerExampleDevice 22.12.21,  1.3.0.2

Asmedia Fw: "191209_70_02_40"

Packets per Xfer 256 and XFers to Queue 64

Result: one system Freeze, two BSOD

Best regards

Günter

 

 

 

0 Likes
AliAsgar
Moderator
Moderator
Moderator
1000 replies posted 250 solutions authored 750 replies posted

Hi Gunter,

Could you share with us the BSOD logs, system freeze logs (if any)? It will be really helpful if we could get as much error logs as possible for the above issue.

Best Regards,
AliAsgar

0 Likes

Hi AliAsgar,

sure, since the MEMORY dump is too big to attach you can find it here:

https://my.hidrive.com/lnk/TeSgUCCk

Name: MEMORY_fx3_asm_3142_190209_70_02_40.zip

Best regards

Günter

 

0 Likes

Hi AliAsgar,

did you already try to reproduce the issue at your side?

I have some news:

I have implemented a "wstreamer" application which uses Microsoft WinUSB instead of the Cypress kernel driver. I still used the original Cypress USBBulkSourceSink.img Firmware.

I tried "WinUsb_ReadPipe" (IN) reads with and without overlapped I/O, different block sizes and long term over night tests also on different machines.

I got about 400-440 MByte/sec throughput (IN) but I could not reproduce any error here. So I'am not sure whether the BSOD of above is maybe a different problem than the one with our devices (we also use WinUSB).

Then I further analyzed the "streaming hang" regarding our devices.

I found out that -  if I deactivate the "Operlapped I/O" feature - the issue is does not occur anymore.

So  the preconditions for the hang to occur are:

- Windows 10

- WinUsb_ReadPipe with Overlapped I/O 

- Asmedia HostController with FW "191209_*" or later

- FX3 Slave Fifo implementation

No events were triggered in USBEventCB or LPMRcqCB callbacks if the hang occurs.

What could make the difference between USBBulkSourceSink and SlaveFifo/GPIF2 here?

Do you have any ideas where to look at and how to proceed?

Best regards

Guenter

 

 

0 Likes
AliAsgar
Moderator
Moderator
Moderator
1000 replies posted 250 solutions authored 750 replies posted

Hi Guenter,

We are procuring an Asmedia 3142 host controller right now. We will update you once we are able to get the controller and test on it.

I have a few confusions regarding the tests. Could you let me know what exact issues (preferable, with a snippet) were seen for the below test cases:

1. Cypress cyusb3.sys driver, streamer application,
    a. BulkSrcSink firmware
    b. SlaveFifoSync firmware.
    c. Overlapped IO
   d. Non overlapped IO

2. WinUSB driver with WinUSB_ReadPipe, wstreamer application,
    a. BulkSrcSink firmware
    b. SlaveFifoSync firmware  
    c. Overlapped IO
   d. Non overlapped IO

In your original question I see "We use WinUSB driver and there is no BSOD". Could you let me know what host application were used for this driver.

I assume there is an FPGA continuously sending data to FX3 for the slaveFifoSync firmware.

"No events were triggered in USBEventCB or LPMRcqCB callbacks if the hang occurs." In the given case, is enumeration happening fine?

Best Regards,
AliAsgar

0 Likes

Hi AliAsgar,

we have three different test setups:

1. Tests with Cypress cyusb3.sys driver
================================
using unmodified original streamer executable GUI from SDK 1.3.4.
a. +  don't know if Cypress "streamer" uses c. or d.
Packets per Xfer 256 and XFers to Queue 64
Result: system freeze or BSOD, memory dump provided

2. Tests WinUSB driver with WinUSB_ReadPipe, wstreamer application
===========================================================
Still using original FX3 firmware a. and tried both c. and d.
MS-WinUSB driver with my own "WinUSB INF" file for streamer device "04b4:00f1"
"wstreamer application" is a Windows/Linux command line test C++ application developed by myself.
NO BSOD occurred, comparable data rates as in Test 1. but no errors reproducible at all.

3. Tests with our camera product devices, WinUSB_ReadPipe
==================================================
b. + c
FPGA continuously sending image data to FX3.
Two other endpoints for command and response are also used (low rate).
Enumeration was always fine.
"Image Communication stops/hangs" only if  "c. Overlapped IO" is used.
If d. is used no problem occurs. No BSOD.

---

I hope I could clarify the different setups . If you need more information, please let me know.

Best regards
Guenter

 

 

0 Likes
AliAsgar
Moderator
Moderator
Moderator
1000 replies posted 250 solutions authored 750 replies posted

Hi Guenter,

I am in the final process of procuring an Asmedia ASM3142 PC for testing to reproduce the issue.

However, I notice that the BSODs and the issues are occurring only when using the asynchronous (overlapped IO) mode and not synchronous mode.

Could you try programing FX3 with BulkSrcSink firmware and do a BULK IN transfer with bytes to transfer = 3276800 in the Control Center? If it fails, try rebooting and transferring again.

Control center uses a synchronous mode of data transfer. If the BSOD issue is not seen with the above test, we can confirm that the issue is due to overlapped IOs itself.

Best Regards,
AliAsgar

0 Likes

Hi AliAsgar,

I have  tested the Streamer Applictaion + "Cypress FX3 USB StreamerExample Device" already and get BSOD (see my post above "1. Tests with Cypress cyusb3.sys driver".
So if  - as you write - "Control center uses a synchronous mode of data transfer" overlapped IO mode cannot be the reason for BSOD in this case.

As I wrote above "3. Tests with our camera product devices, WinUSB_ReadPipe" If using overlapped IO mode with "WinUSB_ReadPipe" leads to a "hung end point" and a BSOD never was the issue here.

Best regards
Guenter

 

 

 

 

0 Likes
AliAsgar
Moderator
Moderator
Moderator
1000 replies posted 250 solutions authored 750 replies posted

Hi Guenter,

>> Streamer and Control Center are two different host application provided by Infineon. Streamer uses asynchronous (overlapped IO) mode of operation and Control center uses synchronous (non-overlapped IO) mode of operation.

Have you performed the Control Center test as I mentioned above?

>> Sorry for the miscommunication, I meant BSOD or any other issues resulting due to high transfer rate.

Best Regards,
AliAsgar

0 Likes

Hi AliAsgar,

thank you for the explanation, now I understand what you mean (sorry, at that moment I was not aware that data  transfer is possible with Control Center itself).

I executed BULK-IN with Control Center with "Bytes to transfer = 3276800"  more than 50 times and there was no issue.

After the tests I tried the "Streamer" executable again and got BSOD after a few minutes.

Best regards
Guenter

0 Likes
AliAsgar
Moderator
Moderator
Moderator
1000 replies posted 250 solutions authored 750 replies posted

Hi Guenter,

I am able to reproduce the issue at my end.

I will try out some tests and let you know the updates.

Best Regards,
AliAsgar

0 Likes

Hi AliAsgar,

it was good to hear that you can reproduce the problem at your side now.

Any updates?

Best regards
Guenter

 

0 Likes

Hi AliAsgar,

after a long time has passed now is there any progress on your side?

Still hoping for good news from you.

Best regards
Guenter

0 Likes
AliAsgar
Moderator
Moderator
Moderator
1000 replies posted 250 solutions authored 750 replies posted

Hi Guenter,

I am trying to discuss this issue internally with the team. As the issue is related to our driver, it may take some time for the debug to take place.

However, do you mind clarifying, 

1. Will the older host controller firmware work for you?

2. If a new host application is created with WinUSB and is working fine, is a asynchronous IO mode (overlapped) host application needed for CyUSB driver. If yes, why?

These are some questions asked by the internal team.

Best Regards,
AliAsgar

0 Likes

Hi AliAsgar,

1. Yes, this is our current workaround. The older host controller firmware is working fine, however host controllers flashed with older firmware do not work with the latest intel chipset anymore i.e. the controllers are no longer recognized by those mainboards. So this workaround will only work for limited time.

2. Only with asynchronous I/O we can achieve the full performance of our devices.

Furthermore I am not sure whether the issue is only related to your driver since the FX3 endpoint "hangs" when using asynchronous I/O occurs with the WinUSB driver.

Best regards
Guenter

0 Likes
AliAsgar
Moderator
Moderator
Moderator
1000 replies posted 250 solutions authored 750 replies posted

Hi Guenter,

Would it be possible for you to share with us a hardware USB trace (LeCroy/ellisys) of when the issue is seen?

Best Regards,
AliAsgar

0 Likes