This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linux/DRA750: Test eye diagram on usb3.0

Part Number: DRA750


Tool/software: Linux

Hi all,

we are using DRA7xx_GLSDK_7.04.00.03 to develop our custom board.

We need to measure the eye diagram.
Refer to processors.wiki.ti.com/.../USB_General_Guide_Linux_v3.8
Is "test_packet" for generating the eye diagram?
Is this function support USB3.0?

I use these command trying to send test packet,

but get nothing on Keysight DSAV134A:

root@dra7xx-evm:~# mount -t debugfs dubugfs /mnt
root@dra7xx-evm:~# echo "test_packet" > /mnt/48890000.usb/testmode
root@dra7xx-evm:~# cat /mnt/48890000.usb/regdump
GSBUSCFG0 = 0x0000000e
GSBUSCFG1 = 0x00000f00
GTXTHRCFG = 0x00000000
GRXTHRCFG = 0x00000000
GCTL = 0x25801000
GEVTEN = 0x00000000
GSTS = 0x3e800002
GSNPSID = 0x5533202a
GGPIO = 0x00000000
GUID = 0x00000000
GUCTL = 0x00008010
GBUSERRADDR0 = 0x00000000
GBUSERRADDR1 = 0x00000000
GPRTBIMAP0 = 0x00000000
GPRTBIMAP1 = 0x00000000
GHWPARAMS0 = 0x202040ca
GHWPARAMS1 = 0x01c0c93b
GHWPARAMS2 = 0x00000000
GHWPARAMS3 = 0x1042008d
GHWPARAMS4 = 0x48822004
GHWPARAMS5 = 0x04202088
GHWPARAMS6 = 0x0b000c20
GHWPARAMS7 = 0x03080780
GDBGFIFOSPACE = 0x00820000
GDBGLTSSM = 0x01514c42
GPRTBIMAP_HS0 = 0x00000000
GPRTBIMAP_HS1 = 0x00000000
GPRTBIMAP_FS0 = 0x00000000
GPRTBIMAP_FS1 = 0x00000000
GUSB2PHYCFG(0) = 0x00002500
GUSB2PHYCFG(1) = 0x00000000
GUSB2PHYCFG(2) = 0x00000000
GUSB2PHYCFG(3) = 0x00000000
GUSB2PHYCFG(4) = 0x00000000
GUSB2PHYCFG(5) = 0x00000000
GUSB2PHYCFG(6) = 0x00000000
GUSB2PHYCFG(7) = 0x00000000
GUSB2PHYCFG(8) = 0x00000000
GUSB2PHYCFG(9) = 0x00000000
GUSB2PHYCFG(10) = 0x00000000
GUSB2PHYCFG(11) = 0x00000000
GUSB2PHYCFG(12) = 0x00000000
GUSB2PHYCFG(13) = 0x00000000
GUSB2PHYCFG(14) = 0x00000000
GUSB2PHYCFG(15) = 0x00000000
GUSB2I2CCTL(0) = 0x00000000
GUSB2I2CCTL(1) = 0x00000000
GUSB2I2CCTL(2) = 0x00000000
GUSB2I2CCTL(3) = 0x00000000
GUSB2I2CCTL(4) = 0x00000000
GUSB2I2CCTL(5) = 0x00000000
GUSB2I2CCTL(6) = 0x00000000
GUSB2I2CCTL(7) = 0x00000000
GUSB2I2CCTL(8) = 0x00000000
GUSB2I2CCTL(9) = 0x00000000
GUSB2I2CCTL(10) = 0x00000000
GUSB2I2CCTL(11) = 0x00000000
GUSB2I2CCTL(12) = 0x00000000
GUSB2I2CCTL(13) = 0x00000000
GUSB2I2CCTL(14) = 0x00000000
GUSB2I2CCTL(15) = 0x00000000
GUSB2PHYACC(0) = 0x00000000
GUSB2PHYACC(1) = 0x00000000
GUSB2PHYACC(2) = 0x00000000
GUSB2PHYACC(3) = 0x00000000
GUSB2PHYACC(4) = 0x00000000
GUSB2PHYACC(5) = 0x00000000
GUSB2PHYACC(6) = 0x00000000
GUSB2PHYACC(7) = 0x00000000
GUSB2PHYACC(8) = 0x00000000
GUSB2PHYACC(9) = 0x00000000
GUSB2PHYACC(10) = 0x00000000
GUSB2PHYACC(11) = 0x00000000
GUSB2PHYACC(12) = 0x00000000
GUSB2PHYACC(13) = 0x00000000
GUSB2PHYACC(14) = 0x00000000
GUSB2PHYACC(15) = 0x00000000
GUSB3PIPECTL(0) = 0x00040002
GUSB3PIPECTL(1) = 0x00000000
GUSB3PIPECTL(2) = 0x00000000
GUSB3PIPECTL(3) = 0x00000000
GUSB3PIPECTL(4) = 0x00000000
GUSB3PIPECTL(5) = 0x00000000
GUSB3PIPECTL(6) = 0x00000000
GUSB3PIPECTL(7) = 0x00000000
GUSB3PIPECTL(8) = 0x00000000
GUSB3PIPECTL(9) = 0x00000000
GUSB3PIPECTL(10) = 0x00000000
GUSB3PIPECTL(11) = 0x00000000
GUSB3PIPECTL(12) = 0x00000000
GUSB3PIPECTL(13) = 0x00000000
GUSB3PIPECTL(14) = 0x00000000
GUSB3PIPECTL(15) = 0x00000000
GTXFIFOSIZ(0) = 0x00000082
GTXFIFOSIZ(1) = 0x00820103
GTXFIFOSIZ(2) = 0x01850205
GTXFIFOSIZ(3) = 0x038a0000
GTXFIFOSIZ(4) = 0x038a0000
GTXFIFOSIZ(5) = 0x038a0000
GTXFIFOSIZ(6) = 0x038a0000
GTXFIFOSIZ(7) = 0x038a0000
GTXFIFOSIZ(8) = 0x038a0000
GTXFIFOSIZ(9) = 0x038a0000
GTXFIFOSIZ(10) = 0x038a0000
GTXFIFOSIZ(11) = 0x038a0000
GTXFIFOSIZ(12) = 0x038a0000
GTXFIFOSIZ(13) = 0x038a0000
GTXFIFOSIZ(14) = 0x038a0000
GTXFIFOSIZ(15) = 0x038a0000
GTXFIFOSIZ(16) = 0x00000000
GTXFIFOSIZ(17) = 0x00000000
GTXFIFOSIZ(18) = 0x00000000
GTXFIFOSIZ(19) = 0x00000000
GTXFIFOSIZ(20) = 0x00000000
GTXFIFOSIZ(21) = 0x00000000
GTXFIFOSIZ(22) = 0x00000000
GTXFIFOSIZ(23) = 0x00000000
GTXFIFOSIZ(24) = 0x00000000
GTXFIFOSIZ(25) = 0x00000000
GTXFIFOSIZ(26) = 0x00000000
GTXFIFOSIZ(27) = 0x00000000
GTXFIFOSIZ(28) = 0x00000000
GTXFIFOSIZ(29) = 0x00000000
GTXFIFOSIZ(30) = 0x00000000
GTXFIFOSIZ(31) = 0x00000000
GRXFIFOSIZ(0) = 0x071e0084
GRXFIFOSIZ(1) = 0x07a20104
GRXFIFOSIZ(2) = 0x08a60180
GRXFIFOSIZ(3) = 0x00000000
GRXFIFOSIZ(4) = 0x00000000
GRXFIFOSIZ(5) = 0x00000000
GRXFIFOSIZ(6) = 0x00000000
GRXFIFOSIZ(7) = 0x00000000
GRXFIFOSIZ(8) = 0x00000000
GRXFIFOSIZ(9) = 0x00000000
GRXFIFOSIZ(10) = 0x00000000
GRXFIFOSIZ(11) = 0x00000000
GRXFIFOSIZ(12) = 0x00000000
GRXFIFOSIZ(13) = 0x00000000
GRXFIFOSIZ(14) = 0x00000000
GRXFIFOSIZ(15) = 0x00000000
GRXFIFOSIZ(16) = 0x00000000
GRXFIFOSIZ(17) = 0x00000000
GRXFIFOSIZ(18) = 0x00000000
GRXFIFOSIZ(19) = 0x00000000
GRXFIFOSIZ(20) = 0x00000000
GRXFIFOSIZ(21) = 0x00000000
GRXFIFOSIZ(22) = 0x00000000
GRXFIFOSIZ(23) = 0x00000000
GRXFIFOSIZ(24) = 0x00000000
GRXFIFOSIZ(25) = 0x00000000
GRXFIFOSIZ(26) = 0x00000000
GRXFIFOSIZ(27) = 0x00000000
GRXFIFOSIZ(28) = 0x00000000
GRXFIFOSIZ(29) = 0x00000000
GRXFIFOSIZ(30) = 0x00000000
GRXFIFOSIZ(31) = 0x00000000
GEVNTADRLO(0) = 0x00000000
GEVNTADRHI(0) = 0x00000000
GEVNTSIZ(0) = 0x00000000
GEVNTCOUNT(0) = 0x00000000
GHWPARAMS8 = 0x0000071e
DCFG = 0x00080800
DCTL = 0x00000008
DEVTEN = 0x00000000
DSTS = 0x00d35cd1
DGCMDPAR = 0x00000000
DGCMD = 0x00000000
DALEPENA = 0x00000000
DEPCMDPAR2(0) = 0x00000000
DEPCMDPAR2(1) = 0x00000000
DEPCMDPAR2(2) = 0xab885000
DEPCMDPAR2(3) = 0x00000000
DEPCMDPAR2(4) = 0xab889000
DEPCMDPAR2(5) = 0x00000000
DEPCMDPAR2(6) = 0x00000000
DEPCMDPAR2(7) = 0x00000000
DEPCMDPAR2(8) = 0x00000000
DEPCMDPAR2(9) = 0x00000000
DEPCMDPAR2(10) = 0x00000000
DEPCMDPAR2(11) = 0x00000000
DEPCMDPAR2(12) = 0x00000000
DEPCMDPAR2(13) = 0x00000000
DEPCMDPAR2(14) = 0x00000000
DEPCMDPAR2(15) = 0x00000000
DEPCMDPAR2(16) = 0x00000000
DEPCMDPAR2(17) = 0x00000000
DEPCMDPAR2(18) = 0x00000000
DEPCMDPAR2(19) = 0x00000000
DEPCMDPAR2(20) = 0x00000000
DEPCMDPAR2(21) = 0x00000000
DEPCMDPAR2(22) = 0x00000000
DEPCMDPAR2(23) = 0x00000000
DEPCMDPAR2(24) = 0x00000000
DEPCMDPAR2(25) = 0x00000000
DEPCMDPAR2(26) = 0x00000000
DEPCMDPAR2(27) = 0x00000000
DEPCMDPAR2(28) = 0x00000000
DEPCMDPAR2(29) = 0x00000000
DEPCMDPAR2(30) = 0x00000000
DEPCMDPAR2(31) = 0x00000000
DEPCMDPAR1(0) = 0x00000002
DEPCMDPAR1(1) = 0x00000000
DEPCMDPAR1(2) = 0x00000000
DEPCMDPAR1(3) = 0x00000000
DEPCMDPAR1(4) = 0x00000000
DEPCMDPAR1(5) = 0x00000000
DEPCMDPAR1(6) = 0x00000000
DEPCMDPAR1(7) = 0x00000000
DEPCMDPAR1(8) = 0x00000000
DEPCMDPAR1(9) = 0x00000000
DEPCMDPAR1(10) = 0x00000000
DEPCMDPAR1(11) = 0x00000000
DEPCMDPAR1(12) = 0x00000000
DEPCMDPAR1(13) = 0x00000000
DEPCMDPAR1(14) = 0x00000000
DEPCMDPAR1(15) = 0x00000000
DEPCMDPAR1(16) = 0x00000000
DEPCMDPAR1(17) = 0x00000000
DEPCMDPAR1(18) = 0x00000000
DEPCMDPAR1(19) = 0x00000000
DEPCMDPAR1(20) = 0x00000000
DEPCMDPAR1(21) = 0x00000000
DEPCMDPAR1(22) = 0x00000000
DEPCMDPAR1(23) = 0x00000000
DEPCMDPAR1(24) = 0x00000000
DEPCMDPAR1(25) = 0x00000000
DEPCMDPAR1(26) = 0x00000000
DEPCMDPAR1(27) = 0x00000000
DEPCMDPAR1(28) = 0x00000000
DEPCMDPAR1(29) = 0x00000000
DEPCMDPAR1(30) = 0x00000000
DEPCMDPAR1(31) = 0x00000000
DEPCMDPAR0(0) = 0xab886001
DEPCMDPAR0(1) = 0x00000000
DEPCMDPAR0(2) = 0x00000040
DEPCMDPAR0(3) = 0x00000000
DEPCMDPAR0(4) = 0xab888000
DEPCMDPAR0(5) = 0x00000000
DEPCMDPAR0(6) = 0x00000000
DEPCMDPAR0(7) = 0x00000000
DEPCMDPAR0(8) = 0x00000000
DEPCMDPAR0(9) = 0x00000000
DEPCMDPAR0(10) = 0x00000000
DEPCMDPAR0(11) = 0x00000000
DEPCMDPAR0(12) = 0x00000000
DEPCMDPAR0(13) = 0x00000000
DEPCMDPAR0(14) = 0x00000000
DEPCMDPAR0(15) = 0x00000000
DEPCMDPAR0(16) = 0x00000000
DEPCMDPAR0(17) = 0x00000000
DEPCMDPAR0(18) = 0x00000000
DEPCMDPAR0(19) = 0x00000000
DEPCMDPAR0(20) = 0x00000000
DEPCMDPAR0(21) = 0x00000000
DEPCMDPAR0(22) = 0x00000000
DEPCMDPAR0(23) = 0x00000000
DEPCMDPAR0(24) = 0x00000000
DEPCMDPAR0(25) = 0x00000000
DEPCMDPAR0(26) = 0x00000000
DEPCMDPAR0(27) = 0x00000000
DEPCMDPAR0(28) = 0x00000000
DEPCMDPAR0(29) = 0x00000000
DEPCMDPAR0(30) = 0x00000000
DEPCMDPAR0(31) = 0x00000000
DEPCMD(0) = 0x00000000
DEPCMD(1) = 0x00000000
DEPCMD(2) = 0x00000000
DEPCMD(3) = 0x00000000
DEPCMD(4) = 0x00000000
DEPCMD(5) = 0x00000000
DEPCMD(6) = 0x00000000
DEPCMD(7) = 0x00000000
DEPCMD(8) = 0x00000000
DEPCMD(9) = 0x00000000
DEPCMD(10) = 0x00000000
DEPCMD(11) = 0x00000000
DEPCMD(12) = 0x00000000
DEPCMD(13) = 0x00000000
DEPCMD(14) = 0x00000000
DEPCMD(15) = 0x00000000
DEPCMD(16) = 0x00000000
DEPCMD(17) = 0x00000000
DEPCMD(18) = 0x00000000
DEPCMD(19) = 0x00000000
DEPCMD(20) = 0x00000000
DEPCMD(21) = 0x00000000
DEPCMD(22) = 0x00000000
DEPCMD(23) = 0x00000000
DEPCMD(24) = 0x00000000
DEPCMD(25) = 0x00000000
DEPCMD(26) = 0x00000000
DEPCMD(27) = 0x00000000
DEPCMD(28) = 0x00000000
DEPCMD(29) = 0x00000000
DEPCMD(30) = 0x00000000
DEPCMD(31) = 0x00000000
OCFG = 0x00000000
OCTL = 0x00000040
OEVT = 0x00000000
OEVTEN = 0x00000000
OSTS = 0x0000000e

Is there something wrong with these reg values?

DCTL = 0x00000008 looks like the port is set to test mode.

anything i should do to make it generating eye diagram?

Thank you for taking your time.

  • Hi, ,

    USB experts are notified.

    Regards,
    Mariya
  • Hi Shawn lin

    The dwc3 controller driver support test mode to  generate test packet , TEST_K, TEST_J, signal. The user can put the usb controller in test mode by writing specific test mode in debugfs interface for specific USB instance. 

    From kernel boot prompt.

    # mount -t debugfs debugfs /mnt

    # echo "test_packet" > /mnt/48890000.usb/test_mode

    similary for "test_j", "test_k", "test_se0_nak", etc.

    Can you check first,

    1) insert the gadget module (for example modprobe g_zero) and connect to host pc and check device is enumerated.

    2) check generating the test pattern with above mentioned sequence.

    Regards

    Ravi

  • Hi Ravi,
    Thanks for your reply.
    As I posted in my question,
    We already tried the debugfs method to generate test pattern, but can't measure anything.
    We tried this on dra7 evm board, so the USB port should be good.

    Now we just like to check one thing first.
    Which one of these test mode: "test_packet", "test_j", "test_k", "test_se0_nak" can generate eye diagram?
    Or I just misunderstand some thing about this test mode?
    Please kindly give us some help,
    thank you so much.
  • Shawn

    The "test_packet" test mode is used to check eye diagram.

    Regards
    Ravi
  • Hi Ravi,

    thank you.

    Do we need to set the usb port to host or device mode first?

    Thanks again.