Open danglin44 opened 3 years ago
XMOS (port 2 talker) <--> EVB <--> Ultralite (port 3 listener)
The problem seems near the "no lis" output in the debug out below.
Starting kernel ...
94 77 avb=1 rr=1 giga=1 compatible: ksz9477 ports: 7f features: 80ea0000 m:-1 a:1 s:ffffffff ports: 7f 0= 5:20 1:01 6; 0:40 0 1= 0:01 2:02 1; 1:01 0 2= 1:02 3:04 2; 2:02 0 3= 2:04 4:08 3; 3:04 0 4= 3:08 5:10 4; 4:08 0 5= 4:10 0:40 5; 5:10 0 6= 6:40 6:20 7; 6:20 1 mask: 7f 20 7f mask: 20 7f; 400 200 port: 7 6 5 host: 5 10 xmii: 7808 78 08; 1000 2 jtag: 100c 74cd 1140 0189 7996 ced0 0060 0000 xmii: f808 f8 08; 1000 2 sw_init_phy_priv 0=p:0; f:1 c:6 i:6 sw_init_phy_priv 1=p:0; f:1 c:1 i:6 sw_init_phy_priv 2=p:1; f:2 c:1 i:1 sw_init_phy_priv 3=p:2; f:3 c:1 i:2 sw_init_phy_priv 4=p:3; f:4 c:1 i:3 sw_init_phy_priv 5=p:4; f:5 c:1 i:4 sw_init_phy_priv 6=p:6; f:6 c:1 i:7 sw_init_phy_priv 7=p:5; f:7 c:1 i:5 random: crng init done cached: 7808 eee txq wait: 000a sgmii_setup 0 1 1 cfg: 0019 libphy: Fixed MDIO Bus: probed microchipphy_genl_init() CAN device driver interface at91_can f000c000.can: device registered (reg_base=d0a01000, irq=43) libphy: MACB_mii_bus: probed status 00000000 states 00000000 result 00000000 fewer: 0 0 bw: 0 75,000,000; 50,000,000 50,000,000; 75,000,000 75,000,000 bw: 1 75,000,000; 50,000,000 50,000,000; 75,000,000 75,000,000 mrp_init 7f 5f pps pps0: new PPS source ptp0 sw_setup_special s:1 m:3 f:0 sw_setup_special d:7 c:0 sw_setup_dev 1:6 phy:0 l:0 sw_setup_dev 1:1 phy:1 l:0 1 f:1 l:1 sw_setup_dev 2:1 phy:2 l:0 2 f:2 l:2 sw_setup_dev 3:1 phy:3 l:0 3 f:3 l:3 sw_setup_dev 4:1 phy:4 l:0 4 f:4 l:4 sw_setup_dev 5:1 phy:5 l:0 5 f:5 l:5 Microchip KSZ9477 Switch sw.0:00: attached PHY driver [Microchip KSZ9477 Switch] (mii_bus:phy_addr=sw.0:00, irq=109) macb f0028000.ethernet eth0: Cadence GEM rev 0x00020119 at 0xf0028000 irq 44 (00:10:a1:94:77:10) ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver sw_setup_dev 6:1 phy:6 l:0 6 f:6 l:6 ehci-atmel: EHCI Atmel driver atmel-ehci 700000.ehci: EHCI Host Controller atmel-ehci 700000.ehci: new USB bus registered, assigned bus number 1 atmel-ehci 700000.ehci: irq 47, io mem 0x00700000 atmel-ehci 700000.ehci: USB 2.0 started, EHCI 1.00 usb usb1: New USB device found, idVendor=1d6b, idProduct=0002 usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1 usb usb1: Product: EHCI Host Controller usb usb1: Manufacturer: Linux 4.9.143 ehci_hcd usb usb1: SerialNumber: 700000.ehci hub 1-0:1.0: USB hub found hub 1-0:1.0: 3 ports detected ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver ohci-atmel: OHCI Atmel driver at91_ohci 600000.ohci: failed to find sfr node at91_ohci 600000.ohci: USB Host Controller at91_ohci 600000.ohci: new USB bus registered, assigned bus number 2 at91_ohci 600000.ohci: irq 47, io mem 0x00600000 usb usb2: New USB device found, idVendor=1d6b, idProduct=0001 usb usb2: New USB device strings: Mfr=3, Product=2, SerialNumber=1 usb usb2: Product: USB Host Controller usb usb2: Manufacturer: Linux 4.9.143 ohci_hcd usb usb2: SerialNumber: at91 hub 2-0:1.0: USB hub found hub 2-0:1.0: 3 ports detected usbcore: registered new interface driver cdc_acm cdc_acm: USB Abstract Control Model driver for USB modems and ISDN adapters usbcore: registered new interface driver usb-storage usbcore: registered new interface driver usbserial usbcore: registered new interface driver usbserial_generic usbserial: USB Serial support registered for generic usbcore: registered new interface driver ftdi_sio usbserial: USB Serial support registered for FTDI USB Serial Device usbcore: registered new interface driver pl2303 usbserial: USB Serial support registered for pl2303 atmel_usba_udc 500000.gadget: MMIO registers at 0xf8030000 mapped at d0a10000 atmel_usba_udc 500000.gadget: FIFO at 0x00500000 mapped at d2100000 g_serial gadget: Gadget Serial v2.4 g_serial gadget: g_serial ready rtc rtc0: invalid alarm value: 1900-1-1 0:0:0 at91_rtc fffffeb0.rtc: rtc core: registered fffffeb0.rtc as rtc0 at91_rtc fffffeb0.rtc: AT91 Real Time Clock driver. i2c /dev entries driver AT91: Starting after user reset sdhci: Secure Digital Host Controller Interface driver sdhci: Copyright(c) Pierre Ossman atmel_mci f0000000.mmc: version: 0x505 atmel_mci f0000000.mmc: using dma0chan7 for DMA transfers atmel_mci f0000000.mmc: Atmel MCI controller at 0xf0000000 irq 18, 1 slots sdhci-pltfm: SDHCI platform and OF driver helper atmel_aes f8038000.aes: version: 0x135 atmel_aes f8038000.aes: Atmel AES - Using dma1chan2, dma1chan3 for DMA transfers atmel_sha f8034000.sha: version: 0x410 atmel_sha f8034000.sha: using dma1chan4 for DMA transfers atmel_sha f8034000.sha: Atmel SHA1/SHA256/SHA224/SHA384/SHA512 atmel_tdes f803c000.tdes: version: 0x701 atmel_tdes f803c000.tdes: using dma1chan5, dma1chan6 for DMA transfers atmel_tdes f803c000.tdes: Atmel DES/TDES usbcore: registered new interface driver usbhid usbhid: USB HID core driver iio iio:device0: Resolution used: 12 bits iio iio:device0: ADC Touch screen is disabled. ip_tables: (C) 2000-2006 Netfilter Core Team NET: Registered protocol family 10 sit: IPv6, IPv4 and MPLS over IPv4 tunneling driver NET: Registered protocol family 17 bridge: filtering via arp/ip/ip6tables is no longer available by default. Update your scripts to load br_netfilter if you need this. can: controller area network core (rev 20120528 abi 9) NET: Registered protocol family 29 can: raw protocol (rev 20120528) can: broadcast manager protocol (rev 20161123 t) can: netlink gateway (rev 20130117) max_hops=1 8021q: 802.1Q VLAN Support v1.8 g_serial gadget: high-speed config #2: CDC ACM config input: gpio_keys as /devices/soc0/gpio_keys/input/input0 at91_rtc fffffeb0.rtc: setting system clock to 2020-11-02 21:56:01 UTC (1604354161) ALSA device list: No soundcards found. Waiting for root device /dev/mmcblk0p2... mmc0: host does not support reading read-only switch, assuming write-enable mmc0: new high speed SDHC card at address 0001 mmcblk0: mmc0:0001 SD16G 29.2 GiB mmcblk0: p1 p2 EXT4-fs (mmcblk0p2): couldn't mount as ext3 due to feature incompatibilities EXT4-fs (mmcblk0p2): couldn't mount as ext2 due to feature incompatibilities EXT4-fs (mmcblk0p2): recovery complete EXT4-fs (mmcblk0p2): mounted filesystem with ordered data mode. Opts: (null) VFS: Mounted root (ext4 filesystem) on device 179:2. devtmpfs: mounted Freeing unused kernel memory: 1024K EXT4-fs (mmcblk0p2): re-mounted. Opts: errors=remount-ro,data=ordered Starting logging: OK Initializing random number generator... done. Starting rpcbind: OK mtu: 6 cached: 7808 eee txq wait: 0040 sgmii_setup 0 1 1 cfg: 0019 status 00000000 states 00000000 result 00000000 fewer: 0 0 msg_conf1: 39 msg_conf2: 1004 clk_ctrl: 0 00000000:0065a890 0000000a:006d41b0 1:0 0:200334064 231000 0=0 215000 0=0 253000 0=0 213000 0=0 239000 0=0 213000 0 IPv6: ADDRCONF(NETDEV_UP): eth0.100: link is not ready macb f0028000.ethernet eth0: link up (1000/Full) IPv6: ADDRCONF(NETDEV_UP): eth0.101: link is not ready 72000 0=0 71000 0=0 76000 0=0 78000 0=0 77000 0=0 71000 0 delay_ticks: 20 0 = 1720 1870 0; 0 1 = 1720 1870 0; 0 2 = 1720 1870 0; 0 3 = 1720 1870 0; 0 4 = 1720 1870 0; 0 6 = 1720 1870 0; 0 ptp_start: 0079 1314 srp_cfg_idle_slope 5:0=49152 1542 1542; 750,000,000 75.000% 25.000% srp_cfg_idle_slope 5:1=1 1542 1542; 0 0.000% 100.000% srp_cfg_idle_slope 5:2=49152 1542 1542; 750,000,000 75.000% 25.000% srp_cfg_idle_slope 5:3=49152 1542 1542; 750,000,000 75.000% 25.000% remap: 0=1-0 0:0 srp_cfg_idle_slope 0:0=49152 1542 1542; 75,000,000 75.000% 25.000% srp_cfg_idle_slope 0:1=1 1542 1542; 0 0.000% 100.000% srp_cfg_idle_slope 0:2=49152 1542 1542; 75,000,000 75.000% 25.000% srp_cfg_idle_slope 0:3=49152 1542 1542; 75,000,000 75.000% 25.000% remap: 1=1-0 0:0 srp_cfg_idle_slope 1:0=49152 1542 1542; 75,000,000 75.000% 25.000% srp_cfg_idle_slope 1:1=1 1542 1542; 0 0.000% 100.000% srp_cfg_idle_slope 1:2=49152 1542 1542; 75,000,000 75.000% 25.000% srp_cfg_idle_slope 1:3=49152 1542 1542; 75,000,000 75.000% 25.000% remap: 2=1-0 0:0 srp_cfg_idle_slope 2:0=49152 1542 1542; 75,000,000 75.000% 25.000% srp_cfg_idle_slope 2:1=1 1542 1542; 0 0.000% 100.000% srp_cfg_idle_slope 2:2=49152 1542 1542; 75,000,000 75.000% 25.000% srp_cfg_idle_slope 2:3=49152 1542 1542; 75,000,000 75.000% 25.000% remap: 3=1-0 0:0 srp_cfg_idle_slope 3:0=49152 1542 1542; 75,000,000 75.000% 25.000% srp_cfg_idle_slope 3:1=1 1542 1542; 0 0.000% 100.000% srp_cfg_idle_slope 3:2=49152 1542 1542; 75,000,000 75.000% 25.000% srp_cfg_idle_slope 3:3=49152 1542 1542; 75,000,000 75.000% 25.000% remap: 4=1-0 0:0 srp_cfg_idle_slope 4:0=49152 1542 1542; 75,000,000 75.000% 25.000% srp_cfg_idle_slope 4:1=1 1542 1542; 0 0.000% 100.000% srp_cfg_idle_slope 4:2=49152 1542 1542; 75,000,000 75.000% 25.000% srp_cfg_idle_slope 4:3=49152 1542 1542; 75,000,000 75.000% 25.000% remap: 6=1-0 0:0 srp_cfg_idle_slope 6:0=49152 1542 1542; 750,000,000 75.00 srp_cfg_idle_slope 6:1=1 1542 1542; 0 0.000% 100.000% srp_cfg_idle_slope 6:2=49152 1542 1542; 750,000,000 75.000% 25.000% srp_cfg_idle_slope 6:3=49152 1542 1542; 750,000,000 75.000% 25.000% has asym pause: 0 0de1 sw_open_port r:20 t:20 d:1 l:20 proc_mrp_set_speed 0=0:0 0 0 has asym pause: 1 0de1 sw_open_port r:20 t:20 d:3 l:20 proc_mrp_set_speed 1=0:0 0 0 IPv6: ADDRCONF(NETDEV_UP): eth0.102: link is not ready IPv6: ADDRCONF(NETDEV_UP): eth0.103: link is not ready IPv6: ADDRCONF(NETDEV_UP): eth0.104: link is not ready IPv6: ADDRCONF(NETDEV_UP): eth0.105: link is not ready has asym pause: 2 0de1 sw_open_port r:20 t:20 d:7 l:20 proc_mrp_set_speed 2=0:0 0 0 has asym pause: 3 0de1 sw_open_port r:20 t:20 d:f l:20 proc_mrp_set_speed 3=0:0 0 0 has asym pause: 4 0de1 sw_open_port r:20 t:20 d:1f l:20 sgmii 0189 0000 sw_open_port r:20 t:20 d:5f l:20 Starting network... IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready Using IBA sgmii 0189 0000 sw_open_port r:20 t:20 d:5f l:20 proc_mrp_set_speed 0=0:0 0 0 proc_mrp_set_speed 1=0:0 0 0 proc_mrp_set_speed 2=0:0 0 0 proc_mrp_set_speed 3=0:0 0 0 id = 00947700 Starting om4-avb-opm daemon: OK Starting sshd: OK Starting telnetd: OK mrp_open_port 5=1 IPv6: ADDRCONF(NETDEV_CHANGE): eth0.102: link becomes ready IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready proc_mrp_set_speed 2=100:1 1 0 proc_mrp_chk_registered 2 IPv6: ADDRCONF(NETDEV_CHANGE): eth0.100: link becomes ready proc_mrp_set_speed 0=1000:1 1 0 proc_mrp_chk_registered 0 IPv6: ADDRCONF(NETDEV_CHANGE): eth0.101: link becomes ready proc_mrp_set_speed 1=1000:1 1 0 proc_mrp_chk_registered 1 Starting PTP watchdog Starting PTP daemon op_mode: 15 1 101:101 0 = 480 150 0; 0 p:6=7 1 = 480 150 0; 0 2 = 720 870 0; 0 3 = 1720 1870 0; 0 4 = 1720 1870 0; 0 6 = 1720 1870 0; 0 mode: 79 fc; e000 Starting PHC daemon Starting MRP daemon
Welcome to OM4-AVB om4avb login: mrp_open_port 2=1 proc_mrp_rx_domain 2=6 3 2 mrp_open_port 0=1 mrp_open_port 1=1 proc_mrp_rx_talker p:1 1 00:22:97:80:0d:ea:00:00 91:e0:f0:00:5f:20 002 3:1 f:800 i:1 l:150000 c:0 srp_create_stream cef2f740 bw: 53,952,000 srp_create_reserv ceeaff00 mrp_alloc_node cef2fd80 28 mrp_alloc_node cef2f7c0 mrp_cfg_dest_addr 1=91:e0:f0:00:5f:20 005f 2 new_code rx: 0030 0 8 srp_create_reserv cef32700 mrp_create_report cef2f800 srp_create_reserv cef32a00 mrp_create_report cef2f540 srp_create_reserv cef32680 mrp_create_report cef2f780 proc_mrp_get_tx 5 0 proc_mrp_get_tx cef2f800 proc_mrp_get_tx 0 1 proc_mrp_get_tx cef2f540 proc_mrp_get_tx 2 3 proc_mrp_get_tx cef2f780 proc_mrp_rx_talker p:1 1 00:22:97:80:0d:ea:00:00 91:e0:f0:00:5f:20 002 3:1 f:800 i:1 l:150000 c:0 new_code rx: 0030 0 8 mrp_create_report cef2f780 mrp_create_report cef2f540 mrp_create_report cef2f800 proc_mrp_get_tx 5 0 proc_mrp_get_tx cef2f780 proc_mrp_get_tx 0 1 proc_mrp_get_tx cef2f540 proc_mrp_get_tx 2 3 proc_mrp_get_tx cef2f800 as: 1=1 as: 2=1 avb: 2=1:0 0 remap: 2=0-1 1:0 proc_mrp_rx_domain 1=6 3 2 avb: 1=1:0 0 remap: 1=0-1 1:0 c: 1=8 0 new_code tx: 0=0030 0 8 new_code tx: 2=0100 0 3 co: 8 3 mrp_create_report cef2f540 co: 8 0 mrp_create_report cef2f780 proc_mrp_get_tx 2 3 proc_mrp_get_tx cef2f540 proc_mrp_get_tx 5 0 proc_mrp_get_tx cef2f780
Welcome to OM4-AVB om4avb login: root Password:
Enable Audio
srp_create_reserv ceeafa00 T:3 L:2 D:1 add pas mrp_alloc_node cef2fb80 24 mrp_alloc_node cef2ffc0 srp_create_reserv cf7c4700 l dec: 1=1 mrp_create_report ceddf1c0 proc_mrp_get_tx 1 2 proc_mrp_get_tx ceddf1c0 proc_mrp_rx_vlan 2=1:2 mrp_alloc_node cef2fcc0 20 mrp_alloc_node cef2fb40 mrp_cfg_vlan 1=2 2 0004 1=002.002 r:0004 t:0000 mrp_create_report cef2f9c0 mrp_create_report cef2fc80 mrp_create_report cef2fd40 proc_mrp_get_tx 5 0 proc_mrp_get_tx cef2f9c0 proc_mrp_get_tx 0 1 proc_mrp_get_tx cef2fc80 proc_mrp_get_tx 1 2 proc_mrp_get_tx cef2fd40 proc_mrp_rx_vlan 1=1:2 mrp_cfg_vlan 1=2 2 0006 1=002.002 r:0006 t:0023 mrp_create_report cef2fc00 mrp_create_report cef2fc40 mrp_create_report cef2f980 proc_mrp_get_tx 5 0 proc_mrp_get_tx cef2fc00 proc_mrp_get_tx 0 1 proc_mrp_get_tx cef2fc40 proc_mrp_get_tx 2 3 proc_mrp_get_tx cef2f980 proc_mrp_rx_talker p:1 1 00:22:97:80:0d:ea:00:00 91:e0:f0:00:5f:20 002 3:1 f:800 i:1 l:150000 c:0 mrp_create_report cef2f980 new_code tx: 0=0030 0 8 mrp_create_report cef2fc40 new_code tx: 2=0100 0 3 mrp_create_report cef2fc00 have listen: 2=ceeafa00 T:3 L:1 D:1 no lis: 1 proc_mrp_rx_listener p:2 1 00:22:97:80:0d:ea:00:00 s:2 T:3 L:1 D:1 no lis: 1 proc_mrp_get_tx 5 0 proc_mrp_get_tx cef2f980 proc_mrp_get_tx 0 1 proc_mrp_get_tx cef2fc40 proc_mrp_get_tx 2 3 proc_mrp_get_tx cef2fc00 proc_mrp_rx_vlan 2=1:2 1=002.002 r:0006 t:0027 mrp_create_report cef2fc00 mrp_create_report cef2fc40 mrp_create_report cef2f980 proc_mrp_get_tx 5 0 proc_mrp_get_tx cef2fc00 proc_mrp_get_tx 0 1 proc_mrp_get_tx cef2fc40 proc_mrp_get_tx 1 2 proc_mrp_get_tx cef2f980 proc_mrp_rx_vlan 1=1:2 1=002.002 r:0006 t:0027 mrp_create_report cef2f980 mrp_create_report cef2fc40 mrp_create_report cef2fc00 proc_mrp_get_tx 5 0 proc_mrp_get_tx cef2f980 proc_mrp_get_tx 0 1 proc_mrp_get_tx cef2fc40 proc_mrp_get_tx 2 3 proc_mrp_get_tx cef2fc00 proc_mrp_rx_talker p:1 1 00:22:97:80:0d:ea:00:00 91:e0:f0:00:5f:20 002 3:1 f:800 i:1 l:150000 c:0 mrp_create_report cef2fc00 new_code tx: 0=0030 0 8 mrp_create_report cef2fc40 new_code tx: 2=0100 0 3 mrp_create_re have listen: 2=ceeafa00 T:3 L:1 D:1 no lis: 1
This is problem: bw: 53,952,000
The settings in mrp_init() limit class A bandwidth to 50%.
tc = mrp->queue[SR_CLASS_A];
info->bandwidth[tc].deltaBandwidth = 50;
info->bandwidth[tc].deltaBandwidth = 75;
info->bandwidth[tc].adminIdleSlope = 75 << CREDIT_PERCENTAGE_S;
info->bandwidth[tc].operIdleSlope =
info->bandwidth[tc].adminIdleSlope;
info->deltaBandwidth = info->bandwidth[tc].deltaBandwidth;
tc = mrp->queue[SR_CLASS_B];
info->bandwidth[tc].deltaBandwidth = 25;
info->bandwidth[tc].deltaBandwidth = 0;
Settings for class B seem odd.
I also noticed that the maximum latency for class A is set to 50ms. I believe it should be 2ms.
info->latency[index].portTcMaxLatency = 1000; if (tc == SR_CLASS_A) info->latency[index].portTcMaxLatency = 50000; if (tc == SR_CLASS_B) info->latency[index].portTcMaxLatency = 50000;
We have been testing the EVB-KSZ9477 with various AVB endpoints. Generally, AVB streams work at 1 Gbps but not at 100 Mbps.
One test used the Motu Ultralite-AVB and XMOS XK-AUDIO-216-MC-AB. The Ultralite-AVB has a 100 Mbps Ethernet port and the XK-AUDIO-216-MC-AB has a 1 Gbps Ethernet port. Speakers were connected to the Ultralite and a microphone to XK-AUDIO-216-MC-AB. When the two devices are connected with a Motu switch and a stream is setup, audio data passes successfully. When the devices are connected with the EVB-KSZ9477, audio does not work.
If the XK-AUDIO-216-MC-AB is connected to the EVB, the EVB to the Motu switch, and the Motu switch to the Ultralite, audio works. If the link between the EVB and the Motu switch is set to 100 Mbps using ethtool, audio does not work.
In all cases, the PTP synchronization is okay.
We are trying to debug the mrp setup but so far we don't know what's wrong at 100 Mbps.