PRU网络问题 - AM4379 - 嵌入式开发者社区 - 51ele.net
设为首页收藏本站

嵌入式开发者社区

 找回密码
 立即注册

QQ登录

只需一步,快速开始

查看: 590|回复: 9

[已解决] PRU网络问题

[复制链接]

3

主题

11

帖子

67

积分

注册会员

Rank: 2

积分
67
发表于 2018-12-24 17:42:54 | 显示全部楼层 |阅读模式
本帖最后由 zhangnanfeng 于 2018-12-24 17:46 编辑

各位好:
       本公司设计的板卡有两路网口,一路是千兆的以太网,使用网卡芯片KSZ9031接到ARM43777的rgmii1接口上,mdio_clk和mdio_data分别连接B17和A17使用CPSW驱动,该网口能正常工作。
另一路是PRU的网络使用网卡芯片TLK105L接到ARM am4377的pru1_mii1接口上,dio_clk和mdio_data分别连接A12和B12使用prueth驱动,在系统启动后无法识别到该网卡,串口终端报了如下红色部分错误:
[   10.809449]  remoteproc1: Note: remoteproc is still under development and considered experimental.
[   10.809452]  remoteproc1: THE BINARY FORMAT IS NOT YET FINALIZED, and backward compatibility isn't yet guaranteed.
[   10.861224]  remoteproc1: registered virtio0 (type 7)
[   10.861314] pru-rproc 54434000.pru0: PRU rproc node [url=]/ocp/pruss@54400000/pru0@54434000[/url] probed successfully
[   10.876510]  remoteproc2: 54438000.pru1 is available
[   10.876515]  remoteproc2: Note: remoteproc is still under development and considered experimental.
[   10.876518]  remoteproc2: THE BINARY FORMAT IS NOT YET FINALIZED, and backward compatibility isn't yet guaranteed.
[   10.914194]  remoteproc2: registered virtio1 (type 7)
[   10.914264] pru-rproc 54438000.pru1: PRU rproc node  ocp/pruss@54400000/pru1@54438000[/url] probed successfully
[   11.038885] prueth pruss1_eth: couldn't connect to phy  ocp/pruss@54400000/mdio@54432400/ethernet-phy@0
[   11.038903] prueth pruss1_eth: netdev init ethernet-mii0 failed: -19
[   11.038910] prueth pruss1_eth: no ethernet-mii1 node

[   11.091686]  remoteproc1: powering up 54434000.pru0
[   11.092129]  remoteproc1: Booting fw image am437x-pru1_0-fw, size 86264
[   11.092219] ti-pruss 54400000.pruss: configured system_events = 0x1000000000000000 intr_channels = 0x00000001 host_intr = 0x00000001
[   11.092225]  remoteproc1: remote processor 54434000.pru0 is now up
[   11.092606] virtio_rpmsg_bus virtio0: creating channel rpmsg-pru addr 0x1e
[   11.099879] virtio_rpmsg_bus virtio0: rpmsg host is online
[   11.100377]  remoteproc2: powering up 54438000.pru1
[   11.100831]  remoteproc2: Booting fw image am437x-pru1_1-fw, size 86264
[   11.100923] ti-pruss 54400000.pruss: configured system_events = 0x0800000000000000 intr_channels = 0x00000002 host_intr = 0x00000002
[   11.100928]  remoteproc2: remote processor 54438000.pru1 is now up
[   11.101287] virtio_rpmsg_bus virtio1: creating channel rpmsg-pru addr 0x1f
[   11.107582] virtio_rpmsg_bus virtio1: rpmsg host is online
设备树中参照了创龙的AM437X-IDK开发板增加了pru网络的配置,linux内核使用的是4.4.12的RT Linux内核,lsmod看出pru网络相关驱动也已经加载。完整的终端打印的启动log信息及设备树配置文件见附件,请帮助分析下可能是什么问题,非常感谢!

如下ifconfig只有一块网卡
root@am437x-evm:~# ifconfig
eth0      Link encap:Ethernet  HWaddr A0:F6:FD:1B:77:68  
           inet addr: 192.168.200.121 Bcast:0.0.0.0  Mask:255.255.255.0
           inet6 addr:fe80::a2f6:fdff:fe1b:7768/64 Scopeink
           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
           RX packets:777 errors:0 dropped:54 overruns:0 frame:0
           TX packets:12 errors:0 dropped:0 overruns:0 carrier:0
           collisions:0 txqueuelen:1000
           RX bytes:48430 (47.2 KiB)  TX bytes:1552 (1.5 kiB)
           Interrupt:239

lo        Link encapocal Loopback  
           inet addr:127.0.0.1  Mask:255.0.0.0
           inet6 addr: ::1/128 Scope:Host
           UP LOOPBACK RUNNING  MTU:65536  Metric:1
           RX packets:10 errors:0 dropped:0 overruns:0 frame:0
           TX packets:10 errors:0 dropped:0 overruns:0 carrier:0
           collisions:0 txqueuelen:0
           RX bytes:700 (700.0 B)  TX bytes:700 (700.0 B)

am437x-gp-evm.dts设备树中pru网络配置:
/* Dual-MAC Ethernet application node on PRU-ICSS1 */
pruss1_eth {
   compatible = "ti,am4372-prueth";
   pruss = <&pruss1>;
   sram = <&ocmcram_nocache>;
   interrupt-parent = <&pruss1_intc>;
   pinctrl-0 = <&pruss1_eth_default>;
   pinctrl-names = "default";
   pruss1_emac0: ethernet-mii0 {
    phy-handle = <&pruss1_eth0_phy>;
    phy-mode = "mii";
    interrupts = <20>, <22>;
    interrupt-names = "rx", "tx";
    /* Filled in by bootloader */
    local-mac-address = [00 00 00 00 00 00];
   };
};

pruss1_eth_default: pruss1_eth_default {
   pinctrl-single,pins = <
   0x58 ( PIN_INPUT | MUX_MODE5 ) /* (E8) gpmc_a6.pr1_mii_mt1_clk */
   0x54 ( PIN_OUTPUT | MUX_MODE5 ) /* (E7) gpmc_a5.pr1_mii1_txd0 */
   0x50 ( PIN_OUTPUT | MUX_MODE5 ) /* (D7) gpmc_a4.pr1_mii1_txd1 */
   0x4c ( PIN_OUTPUT | MUX_MODE5 ) /* (A4) gpmc_a3.pr1_mii1_txd2 */
   0x48 ( PIN_OUTPUT | MUX_MODE5 ) /* (C6) gpmc_a2.pr1_mii1_txd3 */
   0x6c ( PIN_INPUT | MUX_MODE5 ) /* (D8) gpmc_a11.pr1_mii1_rxd0 */
   0x68 ( PIN_INPUT | MUX_MODE5 ) /* (G8) gpmc_a10.pr1_mii1_rxd1 */
   0x64 ( PIN_INPUT | MUX_MODE5 ) /* (B4) gpmc_a9.pr1_mii1_rxd2 */
   0x60 ( PIN_INPUT | MUX_MODE5 ) /* (F7) gpmc_a8.pr1_mii1_rxd3 */
   0x40 ( PIN_OUTPUT | MUX_MODE5 ) /* (C3) gpmc_a0.pr1_mii1_txen */
   0x5c ( PIN_INPUT | MUX_MODE5 ) /* (F6) gpmc_a7.pr1_mii_mr1_clk */
   0x44 ( PIN_INPUT | MUX_MODE5 ) /* (C5) gpmc_a1.pr1_mii1_rxdv */
   0x74 ( PIN_INPUT | MUX_MODE5 ) /* (B3) gpmc_wpn.pr1_mii1_rxer */
   0x24c (PIN_INPUT | MUX_MODE5 ) /* (E24) gpio5_13.pr1_mii1_rxlink */
   0x244 (PIN_INPUT | MUX_MODE5 ) /* (F23) gpio5_11.pr1_mii1_crs */
   >;
};
pruss1_mdio_default: pruss1_mdio_default {
   pinctrl-single,pins = <
   0x8c ( PIN_OUTPUT | MUX_MODE5 ) /* (A12) gpmc_clk.pr1_mdio_mdclk */
    0x88 ( PIN_INPUT | MUX_MODE5 ) /* (B12) gpmc_csn3.pr1_mdio_data */
   0x248( PIN_INPUT_PULLUP | MUX_MODE7)     /* gpio5_12 */
   >;
};

& pruss1_mdio {
pinctrl-0 = <&pruss1_mdio_default>;
pinctrl-names = "default";
status = "okay";
reset-gpios = <&gpio5 12 GPIO_ACTIVE_LOW>;
reset-delay-us = <2>; /* PHY datasheet states 1uS min */
pruss1_eth0_phy: ethernet-phy@0 {
   reg = <0>;
};
};

am4372.dtsi设备树中pru网络配置:
pruss1: pruss@54400000 {
   compatible = "ti,am4372-pruss";
   ti,hwmods = "pruss";
   reg = <0x54400000 0x2000>,
         <0x54402000 0x2000>,
         <0x54410000 0x8000>,
         <0x54420000 0x2000>,
         <0x54426000 0x2000>,
         <0x5442e000 0x31c>,
         <0x54432000 0x58>;
   reg-names = "dram0", "dram1", "shrdram2", "intc", "cfg",
        "iep", "mii_rt";
   #address-cells = <1>;
   #size-cells = <1>;
   ranges;
   pruss1_intc: intc@54420000 {
    compatible = "ti,am4372-pruss-intc";
    interrupts = <GIC_SPI 20 IRQ_TYPE_LEVEL_HIGH
           GIC_SPI 21 IRQ_TYPE_LEVEL_HIGH
           GIC_SPI 22 IRQ_TYPE_LEVEL_HIGH
           GIC_SPI 23 IRQ_TYPE_LEVEL_HIGH
           GIC_SPI 24 IRQ_TYPE_LEVEL_HIGH
           GIC_SPI 26 IRQ_TYPE_LEVEL_HIGH
           GIC_SPI 27 IRQ_TYPE_LEVEL_HIGH>;
    interrupt-names = "host2", "host3", "host4",
        "host5", "host6", "host8",
        "host9";
    interrupt-controller;
    #interrupt-cells = <1>;
   };
   pru1_0: pru0@54434000 {
    compatible = "ti,am4372-pru";
    reg = <0x54434000 0x3000>,
          <0x54422000 0x400>,
          <0x54422400 0x100>;
    reg-names = "iram", "control", "debug";
    mboxes = <&mailbox &mbox_pru1_0>;
   };
   pru1_1: pru1@54438000 {
    compatible = "ti,am4372-pru";
    reg = <0x54438000 0x3000>,
          <0x54424000 0x400>,
          <0x54424400 0x100>;
    reg-names = "iram", "control", "debug";
    mboxes = <&mailbox &mbox_pru1_1>;
   };
   pruss1_mdio: mdio@54432400 {
    compatible = "ti,davinci_mdio";
    reg = <0x54432400 0x90>;
    clocks = <&dpll_core_m4_ck>;
    clock-names = "fck";
    bus_freq = <1000000>;
    #address-cells = <1>;
    #size-cells = <0>;
    status = "disabled";
   };
  };


root@am437x-evm:~# lsmod
Module                  Size  Used by
atemsys                12408  0
pvrsrvkm              406858  0
dwc3                   62533  0
udc_core               12079  1 dwc3
pm33xx                  3658  0
ti_am335x_adc           5643  0
ti_am335x_tsc           5965  0
snd_soc_simple_card     7736  0
prueth                 14377  0
ti_emif_sram            6064  1 pm33xx
wkup_m3_ipc             7616  1 pm33xx
snd_soc_tlv320aic3x    48260  1
pru_rproc               9865  1 prueth
omap_rng                4353  0
am437x_vpfe            23581  0
edt_ft5x06             10689  0
omap_aes_driver        18260  0
rng_core                7698  1 omap_rng
ov2659                  9618  0
pruss                  11281  2 pru_rproc,prueth
dwc3_omap               4553  0
omap_des               11214  0
extcon                 13929  2 dwc3,dwc3_omap
wkup_m3_rproc           3669  1
remoteproc             26956  5 pruss,wkup_m3_rproc,pru_rproc,prueth,wkup_m3_ipc
virtio                  6677  1 remoteproc
virtio_ring            12035  1 remoteproc
omap_sham              20318  0
c_can_platform          6638  0
c_can                   9450  1 c_can_platform
can_dev                12254  1 c_can
cryptodev              38437  0
ti_am335x_tscadc        6106  2 ti_am335x_adc,ti_am335x_tsc
omap_wdt                4655  0




最佳答案

1. 是否确认了上电后,硬件上配置的pru网口的phy地址是否变了? 2. am4372.dtsi里面的compatible 不需要改,不同版本的内核会有所不同。 具体请查看: Documentation/devicetree/bindings/remoteproc/ti,pruss-remot ...

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有帐号?立即注册

x
最近访问 头像模式 列表模式
回复

使用道具 举报

0

主题

29

帖子

1314

积分

广州创龙

Rank: 8Rank: 8

积分
1314
发表于 2018-12-25 17:51:36 | 显示全部楼层
[   11.038885] prueth pruss1_eth: couldn't connect to phy /ocp/pruss@54400000/mdio@54432400/ethernet-phy@0

确认一下,上电后的phy地址和设备树里配置的是否一样。是否变了。
回复 支持 反对

使用道具 举报

0

主题

29

帖子

1314

积分

广州创龙

Rank: 8Rank: 8

积分
1314
发表于 2018-12-25 17:52:31 | 显示全部楼层
上电后,输入reboot指令重启启动(非断电重启),会有什么现象?
回复 支持 反对

使用道具 举报

3

主题

11

帖子

67

积分

注册会员

Rank: 2

积分
67
 楼主| 发表于 2018-12-26 09:35:26 | 显示全部楼层
544864579 发表于 2018-12-25 17:52
上电后,输入reboot指令重启启动(非断电重启),会有什么现象?

您好,如下是reboot之后刚开始打印的部分,后面的跟上电启动打印一样的,全部的完整的log见附件,谢谢!
root@am437x-evm:~# reboot

The system is going down for reboot NOW!console) (Tue Oct  6 07:33:46 2015):
INIT: Sending processes the TERM signal
Terminated
root@am437x-evm:~# UIM SYSFS Node Not Found
Stopping Dropbear SSH server: stopped /usr/sbin/dropbear (pid 711)
dropbear.
Stopping telnet daemon.
Stopping system message bus: dbus.
hwclock: can't open '/dev/misc/rtc': No such file or directory
mount: mounting tmpfs on /mnt/.psplash failed: No such file or directory
Stopping syslogd/klogd: stopped syslogd (pid 738)
stopped klogd (pid 741)
done
Stopping thttpd.
stopping statd: done
ALSA: Storing mixer settings...
/usr/sbin/alsactl: state_lock:121: file /var/lib/alsa/asound.state lock error: No such file or directory
/usr/sbin/alsactl: state_lock:121: file /var/lib/alsa/asound.state unlock error: No such file or directory
Stopping PVR
rmmod: ERROR: Module bufferclass_ti is not currently loaded
Stopping rpcbind daemon...
done.
Stopping Lighttpd Web Server: stopped /usr/sbin/lighttpd (pid 803)
lighttpd.
Deconfiguring network interfaces... done.
Stopping Matrix GUI applicationstart-stop-daemon: warning: killing process 818: No such process
refresh_screen: error while loading shared libraries: libQt5Widgets.so.5: cannot open shared object file: No such file or directory
.
Disabling thermal zones...
/etc/rc6.d/K98thermal-zone-init: line 13: /sys/class/thermal/thermal_zone*/mode: No such file or directory
grep: /var/lib/opkg/info/*.control: No such file or directory
Sending all processes the TERM signal...
Sending all processes the KILL signal...
urandom stop: failed.
Unmounting remote filesystems...
Deactivating swap...
Unmounting local filesystems...
[   65.228825] UBIFS (ubi0:0): background thread "ubifs_bgt0_0" stops
Rebooting... [   67.695124] reboot: Restarting system

U-Boot SPL 2014.07 (Jun 28 2018 - 15:22:39)
Could not probe the EEPROM at 0x50
Could not get board ID.


U-Boot 2014.07 (Jun 28 2018 - 15:22:39)

I2C:   ready
DRAM:  1 GiB
NAND:  512 MiB
MMC:   OMAP SD/MMC: 0, OMAP SD/MMC: 1

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有帐号?立即注册

x
回复 支持 反对

使用道具 举报

3

主题

11

帖子

67

积分

注册会员

Rank: 2

积分
67
 楼主| 发表于 2018-12-26 10:41:00 | 显示全部楼层
544864579 发表于 2018-12-25 17:52
上电后,输入reboot指令重启启动(非断电重启),会有什么现象?

您好:
      还有个问题需要请教您一下,我参考贵公司TL437X-IDK开发板中的设备数文件发现am4372.dtsi中pru相关的定义使用的是pruss_wrapper定义的,我不太明白为什么要这样用,我把我的am4372.dtsi中的pru相关的定义:
pruss1: pruss@54400000 {
   compatible = "ti,am4372-pruss";
   ti,hwmods = "pruss";
   reg = <0x54400000 0x2000>,
         <0x54402000 0x2000>,
         <0x54410000 0x8000>,
         <0x54420000 0x2000>,
         <0x54426000 0x2000>,
         <0x5442e000 0x31c>,
         <0x54432000 0x58>;
   reg-names = "dram0", "dram1", "shrdram2", "intc", "cfg",
        "iep", "mii_rt";
   #address-cells = <1>;
   #size-cells = <1>;
   ranges;
   pruss1_intc: intc@54420000 {
    compatible = "ti,am4372-pruss-intc";
    interrupts = <GIC_SPI 20 IRQ_TYPE_LEVEL_HIGH
           GIC_SPI 21 IRQ_TYPE_LEVEL_HIGH
           GIC_SPI 22 IRQ_TYPE_LEVEL_HIGH
           GIC_SPI 23 IRQ_TYPE_LEVEL_HIGH
           GIC_SPI 24 IRQ_TYPE_LEVEL_HIGH
           GIC_SPI 26 IRQ_TYPE_LEVEL_HIGH
           GIC_SPI 27 IRQ_TYPE_LEVEL_HIGH>;
    interrupt-names = "host2", "host3", "host4",
        "host5", "host6", "host8",
        "host9";
    interrupt-controller;
    #interrupt-cells = <1>;
   };
   pru1_0: pru0@54434000 {
    compatible = "ti,am4372-pru";
    reg = <0x54434000 0x3000>,
          <0x54422000 0x400>,
          <0x54422400 0x100>;
    reg-names = "iram", "control", "debug";
    mboxes = <&mailbox &mbox_pru1_0>;
   };
   pru1_1: pru1@54438000 {
    compatible = "ti,am4372-pru";
    reg = <0x54438000 0x3000>,
          <0x54424000 0x400>,
          <0x54424400 0x100>;
    reg-names = "iram", "control", "debug";
    mboxes = <&mailbox &mbox_pru1_1>;
   };
   pruss1_mdio: mdio@54432400 {
    compatible = "ti,davinci_mdio";
    reg = <0x54432400 0x90>;
    clocks = <&dpll_core_m4_ck>;
    clock-names = "fck";
    bus_freq = <1000000>;
    #address-cells = <1>;
    #size-cells = <0>;
    status = "disabled";
   };
  };

改成使用pruss_wrapper
pruss_wrapper: pruss_wrapper@54426000 {
   compatible = "ti,am4372-pruss-wrapper";
   reg = <0x54426000 0x2000>;
   ti,hwmods = "pruss";
   #address-cells = <1>;
   #size-cells = <1>;
   ranges;
   pruss1: pruss@54400000 {
    compatible = "ti,am4372-pruss";
    reg = <0x54400000 0x2000>,
          <0x54402000 0x2000>,
          <0x54410000 0x8000>,
          <0x54426000 0x2000>,
          <0x5442e000 0x31c>,
          <0x54432000 0x58>;
    reg-names = "dram0", "dram1", "shrdram2", "cfg",
         "iep", "mii_rt";
    #address-cells = <1>;
    #size-cells = <1>;
    ranges;
    pruss1_intc: intc@54420000 {
     compatible = "ti,am4372-pruss-intc";
     reg = <0x54420000 0x2000>;
     reg-names = "intc";
     interrupts =
         <GIC_SPI 20 IRQ_TYPE_LEVEL_HIGH
          GIC_SPI 21 IRQ_TYPE_LEVEL_HIGH
          GIC_SPI 22 IRQ_TYPE_LEVEL_HIGH
          GIC_SPI 23 IRQ_TYPE_LEVEL_HIGH
          GIC_SPI 24 IRQ_TYPE_LEVEL_HIGH
          GIC_SPI 26 IRQ_TYPE_LEVEL_HIGH
          GIC_SPI 27 IRQ_TYPE_LEVEL_HIGH>;
     interrupt-names = "host2", "host3",
         "host4", "host5",
         "host6", "host8",
         "host9";
     interrupt-controller;
     #interrupt-cells = <1>;
    };
    pru1_0: pru0@54434000 {
     compatible = "ti,am4372-pru";
     reg = <0x54434000 0x3000>,
           <0x54422000 0x400>,
           <0x54422400 0x100>;
     reg-names = "iram", "control", "debug";
     interrupt-parent = <&pruss1_intc>;
     interrupts = <16>, <17>;
     interrupt-names = "vring", "kick";
    };
    pru1_1: pru1@54438000 {
     compatible = "ti,am4372-pru";
     reg = <0x54438000 0x3000>,
           <0x54424000 0x400>,
           <0x54424400 0x100>;
     reg-names = "iram", "control", "debug";
     interrupt-parent = <&pruss1_intc>;
     interrupts = <18>, <19>;
     interrupt-names = "vring", "kick";
    };
    pruss1_mdio: mdio@54432400 {
     compatible = "ti,davinci_mdio";
     reg = <0x54432400 0x90>;
     clocks = <&dpll_core_m4_ck>;
     clock-names = "fck";
     bus_freq = <1000000>;
     #address-cells = <1>;
     #size-cells = <0>;
     status = "disabled";
    };
   };
   pruss0: pruss@54440000 {
    compatible = "ti,am4372-pruss";
    reg = <0x54440000 0x1000>,
          <0x54442000 0x1000>,
          <0x54466000 0x2000>,
          <0x5446e000 0x31c>,
          <0x54472000 0x58>;
    reg-names = "dram0", "dram1", "cfg",
         "iep", "mii_rt";
    #address-cells = <1>;
    #size-cells = <1>;
    ranges;
    pruss0_intc: intc@54460000 {
     compatible = "ti,am4372-pruss-intc";
     reg = <0x54460000 0x2000>;
     reg-names = "intc";
     interrupts =
         <GIC_SPI 159 IRQ_TYPE_LEVEL_HIGH
          GIC_SPI 160 IRQ_TYPE_LEVEL_HIGH
          GIC_SPI 161 IRQ_TYPE_LEVEL_HIGH
          GIC_SPI 162 IRQ_TYPE_LEVEL_HIGH
          GIC_SPI 163 IRQ_TYPE_LEVEL_HIGH
          GIC_SPI 164 IRQ_TYPE_LEVEL_HIGH
          GIC_SPI 165 IRQ_TYPE_LEVEL_HIGH>;
     interrupt-names = "host2", "host3",
         "host4", "host5",
         "host6", "host8",
         "host9";
     interrupt-controller;
     #interrupt-cells = <1>;
    };
    pru0_0: pru0@54474000 {
     compatible = "ti,am4372-pru";
     reg = <0x54474000 0x1000>,
           <0x54462000 0x400>,
           <0x54462400 0x100>;
     reg-names = "iram", "control", "debug";
     interrupt-parent = <&pruss0_intc>;
     interrupts = <16>, <17>;
     interrupt-names = "vring", "kick";
    };
    pru0_1: pru1@54478000 {
     compatible = "ti,am4372-pru";
     reg = <0x54478000 0x1000>,
           <0x54464000 0x400>,
           <0x54464400 0x100>;
     reg-names = "iram", "control", "debug";
     interrupt-parent = <&pruss0_intc>;
     interrupts = <18>, <19>;
     interrupt-names = "vring", "kick";
    };
   };
  };

启动只是打印如下错误:
[    8.453058] prueth pruss1_eth: unable to get pruss handle,
没有出现如下的错误:
[   11.038885] prueth pruss1_eth: couldn't connect to phy  ocp/pruss@54400000/mdio@54432400/ethernet-phy@0
[   11.038903] prueth pruss1_eth: netdev init ethernet-mii0 failed: -19
[   11.038910] prueth pruss1_eth: no ethernet-mii1 node

详细的log和设备树文件见附件!
麻烦帮助指导下,非常感谢!

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有帐号?立即注册

x
回复 支持 反对

使用道具 举报

0

主题

29

帖子

1314

积分

广州创龙

Rank: 8Rank: 8

积分
1314
发表于 2018-12-27 09:21:10 | 显示全部楼层
1. 是否确认了上电后,硬件上配置的pru网口的phy地址是否变了?
2. am4372.dtsi里面的compatible 不需要改,不同版本的内核会有所不同。
具体请查看:
Documentation/devicetree/bindings/remoteproc/ti,pruss-remoteproc.txt
drivers/remoteproc/pruss_soc_bus.c
回复 支持 反对

使用道具 举报

3

主题

11

帖子

67

积分

注册会员

Rank: 2

积分
67
 楼主| 发表于 2019-1-17 09:35:04 | 显示全部楼层
本帖最后由 zhangnanfeng 于 2019-1-17 09:42 编辑
544864579 发表于 2018-12-27 09:21
1. 是否确认了上电后,硬件上配置的pru网口的phy地址是否变了?
2. am4372.dtsi里面的compatible 不需要改 ...

您好:
      前几天硬件的人一直在查找问题,后来重新焊接了TLK105L芯片,目前启动能够已经能够扫到TLK PHY芯片了,如下,具体详细的log见附件.

[   10.876261] davinci_mdio 54432400.mdio: davinci mdio revision 1.6
[   10.882401] libphy: 54432400.mdio: probed
[   10.906664] davinci_mdio 54432400.mdio: phy[0]: device 54432400.mdio:00, driver TI TLK10X 10/100 Mbps PHY
[   10.926512] vpfe 48328000.vpfe: Invalid bus width.
[   10.931339] vpfe 48328000.vpfe: No platform data
[   10.936003] vpfe: probe of 48328000.vpfe failed with error -22
[   10.941218] PM: no-rtc available, rtc-only mode disabled.
[   10.948168]  remoteproc1: 54434000.pru0 is available
[   10.948172]  remoteproc1: Note: remoteproc is still under development and considered experimental.
[   10.948176]  remoteproc1: THE BINARY FORMAT IS NOT YET FINALIZED, and backward compatibility isn't yet guaranteed.
[   10.949689] pru-rproc 54434000.pru0: PRU rproc node /ocp/pruss@54400000/pru0@54434000 probed successfully
[   10.959079]  remoteproc2: 54438000.pru1 is available
[   10.959084]  remoteproc2: Note: remoteproc is still under development and considered experimental.
[   10.959088]  remoteproc2: THE BINARY FORMAT IS NOT YET FINALIZED, and backward compatibility isn't yet guaranteed.
[   10.960120] pru-rproc 54438000.pru1: PRU rproc node /ocp/pruss@54400000/pru1@54438000 probed successfully
[   11.106569] prueth pruss1_eth: no ethernet-mii1 node
[   11.111576] prueth pruss1_eth: freeing port 1
[   11.121545] c_can_platform 481d0000.can: c_can_platform device registered (regs=fa1d0000, irq=253)
Configuring network interfaces... [   11.567534] net eth0: initializing cpsw version 1.15 (0)
[   11.572888] net eth0: initialized cpsw ale version 1.4
[   11.657241] dwc3 48390000.usb: otg: primary host xhci-hcd.0.auto registered

如下ifconfig还是只能看到一个网卡,请问可能是什么原因?

root@am437x-evm:~# ifconfig
eth0      Link encap:Ethernet  HWaddr 10:CE:A9:8D:BA:8C  
          inet addr:192.168.200.99  Bcast:192.168.200.255  Mask:255.255.255.0
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
          Interrupt:239

lo        Link encapocal Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:10 errors:0 dropped:0 overruns:0 frame:0
          TX packets:10 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1
          RX bytes:700 (700.0 B)  TX bytes:700 (700.0 B)

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有帐号?立即注册

x
回复 支持 反对

使用道具 举报

23

主题

203

帖子

2424

积分

广州创龙

Rank: 8Rank: 8

积分
2424
发表于 2019-1-18 09:02:09 | 显示全部楼层
您好,
    1.TL437x-EVM开发板eth1网口问题
http://www.51ele.net/forum.php?m ... =3854&fromuid=50814
(出处: 嵌入式开发者社区)
回复 支持 反对

使用道具 举报

3

主题

11

帖子

67

积分

注册会员

Rank: 2

积分
67
 楼主| 发表于 2019-1-18 09:28:42 | 显示全部楼层
梁淑怡-Tronlong 发表于 2019-1-18 09:02
您好,
    1.TL437x-EVM开发板eth1网口问题
http://www.51ele.net/forum.php?m ... =3854&fromuid=50814

目前是没有识别到eth1网卡,根本操作不了,如下!
root@am437x-evm:~# ifconfig eth1 up
ifconfig: SIOCGIFFLAGS: No such device
root@am437x-evm:~# udhcpc -i eth1
udhcpc: SIOCGIFINDEX: No such device
回复 支持 反对

使用道具 举报

3

主题

11

帖子

67

积分

注册会员

Rank: 2

积分
67
 楼主| 发表于 2019-1-21 16:45:36 | 显示全部楼层
544864579 发表于 2018-12-27 09:21
1. 是否确认了上电后,硬件上配置的pru网口的phy地址是否变了?
2. am4372.dtsi里面的compatible 不需要改 ...

您好:
     目前通过修改设备树配置文件,已经可以找到prueth的eth1网卡,但是网线接到pru那个网口上电脑端去ping 该网卡eth1 ip ping不同,网线接到cpsw eth0那个网口ping eth0的IP和eth1的IP都可以ping通,请问这种情况可能是什么问题,具体的log和设备树在附件中,麻烦帮忙看下,非常感谢!

[    8.415238]  remoteproc1: 54434000.pru0 is available
[    8.420350]  remoteproc1: Note: remoteproc is still under development and considered experimental.
[    8.479644]  remoteproc1: THE BINARY FORMAT IS NOT YET FINALIZED, and backward compatibility isn't yet guaranteed.
[    8.496972] omap_hwmod: gfx: failed to hardreset
[    8.496997] pvrsrvkm 56000000.sgx: Unable to reset SGX!
[    8.523697] omap_hwmod: gfx: _wait_target_ready failed: -16
[    8.523715] PVR_KError): EnableSGXClocks: pm_runtime_get_sync failed (16)
[    8.523724] PVR_KError): SysInitialise: Failed to Enable system clocks (175)
[    8.549108] c_can_platform 481d0000.can: c_can_platform device registered (regs=fa1d0000, irq=218)
[    8.574754] PM: no-rtc available, rtc-only mode disabled.
[    8.866041]  remoteproc1: registered virtio0 (type 7)
[    8.871216] pru-rproc 54434000.pru0: PRU rproc node /ocp/pruss@54400000/pru0@54434000 probed successfully
[    8.907147]  remoteproc2: 54438000.pru1 is available
[    8.912151]  remoteproc2: Note: remoteproc is still under development and considered experimental.
[    8.953652]  remoteproc2: THE BINARY FORMAT IS NOT YET FINALIZED, and backward compatibility isn't yet guaranteed.
[    8.991433]  remoteproc2: registered virtio1 (type 7)
[    9.007851] pru-rproc 54438000.pru1: PRU rproc node /ocp/pruss@54400000/pru1@54438000 probed successfully
[    9.133174] prueth pruss1_eth: port 1: using random MAC addr: 2a:7e:fc:85:08:02
[    9.159662]  remoteproc1: powering up 54434000.pru0
[    9.165068]  remoteproc1: Booting fw image am437x-pru1_0-fw, size 86264
[    9.189371] ti-pruss 54400000.pruss: configured system_events = 0x1000000000000000 intr_channels = 0x00000001 host_intr = 0x00000001
[    9.216161] prueth pruss1_eth: port 2: using random MAC addr: 66:66:76:f0:1d:4f
[    9.216194] prueth pruss1_eth: couldn't connect to phy /ocp/pruss@54400000/mdio@54432400/ethernet-phy@1
[    9.216210] prueth pruss1_eth: netdev init ethernet-mii1 failed: -19
[    9.217675] prueth pruss1_eth: TI PRU ethernet driver initialized
[    9.335005]  remoteproc1: remote processor 54434000.pru0 is now up
[    9.379793] virtio_rpmsg_bus virtio0: creating channel rpmsg-pru addr 0x1e
[    9.385689] virtio_rpmsg_bus virtio0: rpmsg host is online
[    9.385944]  remoteproc2: powering up 54438000.pru1
[    9.386394]  remoteproc2: Booting fw image am437x-pru1_1-fw, size 86264
[    9.386482] ti-pruss 54400000.pruss: configured system_events = 0x0800000000000000 intr_channels = 0x00000002 host_intr = 0x00000002
[    9.386488]  remoteproc2: remote processor 54438000.pru1 is now up
[    9.386893] virtio_rpmsg_bus virtio1: rpmsg host is online
[    9.534075] virtio_rpmsg_bus virtio1: creating channel rpmsg-pru addr 0x1f
[    9.576542] dwc3 48390000.usb: otg: primary host xhci-hcd.0.auto registered
[    9.583555] dwc3 48390000.usb: otg: shared host xhci-hcd.0.auto registered
[    9.587414] rpmsg_pru rpmsg0: new rpmsg_pru device: /dev/rpmsg_pru30
[    9.587911] rpmsg_pru rpmsg1: new rpmsg_pru device: /dev/rpmsg_pru31
[    9.631597] dwc3 48390000.usb: otg: can't start till gadget registers
ALSA: Restoring mixer settings...
hwclock: can't open '/dev/misc/rtc': No such file or directory
Tue Oct  6 07:20:00 UTC 2015
[   10.077808] xhci-hcd xhci-hcd.1.auto: xHCI Host Controller
[   10.083360] xhci-hcd xhci-hcd.1.auto: new USB bus registered, assigned bus number 1
hwclock: can't open '/dev/misc/rtc': No such file or directory
INIT: Entering runlevel: 5
[   10.104950] xhci-hcd xhci-hcd.1.auto: hcc params 0x0238f06d hci version 0x100 quirks 0x00010010
[   10.125204] xhci-hcd xhci-hcd.1.auto: irq 265, io mem 0x483d0000
[   10.136850] hub 1-0:1.0: USB hub found
[   10.145743] hub 1-0:1.0: 1 port detected
[   10.156171] xhci-hcd xhci-hcd.1.auto: xHCI Host Controller
[   10.161706] xhci-hcd xhci-hcd.1.auto: new USB bus registered, assigned bus number 2
[   10.180730] usb usb2: We don't know the algorithms for LPM for this host, disabling LPM.
[   10.211796] hub 2-0:1.0: USB hub found
[   10.216711] hub 2-0:1.0: 1 port detected
Configuring network interfaces... [   10.405907] net eth0: initializing cpsw version 1.15 (0)
[   10.411259] net eth0: initialized cpsw ale version 1.4
[   10.497026] net eth0: phy found : id is : 0x221622
[   10.501913] libphy: PHY  not found
[   10.505331] net eth0: phy "" not found on slave 1, err -19
[   10.517729] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
udhcpc (v1.22.1) started
Sending discover...
Sending discover...
Sending discover...
No lease, forking to background
done.
Starting system message bus: dbus.
UIM SYSFS Node Not Found
Starting Dropbear SSH server: dropbear.
Starting telnet daemon.
Starting rpcbind daemon...done.
creating NFS state directory: done
starting statd: done
hwclock: can't open '/dev/misc/rtc': No such file or directory
Starting syslogd/klogd: done
Starting thttpdchdir: No such file or directory
.
Starting Lighttpd Web Server: lighttpd.
2015-10-06 07:20:11: (/home/teddy/tl437x/openembedded/tisdk/build/arago-tmp-external-linaro-toolchain/work/cortexa9t2hf-vfp-neon-linux-gnueabi/lighttpd/1.4.33-r1/lighttpd-1.4.33/src/log.c.166) server started
/
Starting Matrix GUI application.
Enabling thermal zones...
/etc/rc5.d/S98thermal-zone-init: line 7: /sys/class/thermal/thermal_zone*/mode: No such file or directory
grep: /var/lib/opkg/info/*.control: No such file or directory
Stopping Bootlog daemon: bootlogd.
umount: can't forcibly umount /mnt/.psplash: No such file or directory
-ash: can't access tty; job control turned off
root@am437x-evm:~# [   21.724830] atemsys: atemsys v1.3.11 loaded

==============
main
==============
map_addr ok

root@am437x-evm:~# ifconfig eth1 192.168.200.220
[   38.158071] net eth1: started
[   38.161181] IPv6: ADDRCONF(NETDEV_UP): eth1: link is not ready
root@am437x-evm:~# [   39.216169] eth1: Link is Up - 100Mbps/Full - flow control rx/tx
[   39.222229] IPv6: ADDRCONF(NETDEV_CHANGE): eth1: link becomes ready

root@am437x-evm:~# ifconfig
eth0      Link encap:Ethernet  HWaddr A0:F6:FD:1B:77:68  
          inet addr:192.168.200.99  Bcast:192.168.200.255  Mask:255.255.255.0
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
          Interrupt:205


eth1      Link encap:Ethernet  HWaddr 2A:7E:FC:85:08:02  
          inet addr:192.168.200.220  Bcast:192.168.200.255  Mask:255.255.255.0
          inet6 addr: fe80::287e:fcff:fe85:802/64 Scopeink
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:8 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 B)  TX bytes:648 (648.0 B)

lo        Link encapocal Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:61 errors:0 dropped:0 overruns:0 frame:0
          TX packets:61 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1
          RX bytes:6412 (6.2 KiB)  TX bytes:6412 (6.2 KiB)

root@am437x-evm:~# ethtool eth1
Settings for eth1:
        Supported ports: [ TP MII ]
        Supported link modes:   10baseT/Half 10baseT/Full
                                100baseT/Half 100baseT/Full
        Supported pause frame use: No
        Supports auto-negotiation: Yes
        Advertised link modes:  10baseT/Half 10baseT/Full
                                100baseT/Half 100baseT/Full
        Advertised pause frame use: No
        Advertised auto-negotiation: Yes
        Link partner advertised link modes:  10baseT/Half 10baseT/Full
                                             100baseT/Half 100baseT/Full
        Link partner advertised pause frame use: Symmetric Receive-only
        Link partner advertised auto-negotiation: Yes
        Speed: 100Mb/s
        Duplex: Full
        Port: MII
        PHYAD: 1
        Transceiver: external
        Auto-negotiation: on
        Link detected: yes
root@am437x-evm:~# ping 192.168.200.107&
root@am437x-evm:~# PING 192.168.200.107 (192.168.200.107): 56 data bytes

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有帐号?立即注册

x
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则  回帖提醒

QQ|手机版|小黑屋|嵌入式开发者社区 ( 粤ICP备15055271号-1  

GMT+8, 2019-4-25 17:58 , Processed in 0.187018 second(s), 61 queries .

Powered by Discuz! X3.2

© 2001-2015 Comsenz Inc.

快速回复 返回顶部 返回列表