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.

dts file phy_sel not found in 8.2.0.24

Other Parts Discussed in Thread: AM3352

Hi, 

I am porting the kernel from 4.9.59 to 5.10.100 according to our custom board speciifcations.. 

While poring with respect o dts file i found the error "Label or path phy_sel not found dts file" 

when i went back to 4.9.59 kernel that phy_sel is defined in am33xx.dtsi file.. hence forth i am not finding error. in 4.9.59 kernel compilations.. as i am able to find phy_sel that is defined in am33xx.dtsi 

when i compile with kernel 5.10.100.. its throwing above error.. when i went through am33xx.dtsi file.(8.2.0.24 sdk) i am not able to find phy_sel in MAC node.. how can we compile in current 5.10.100 kernel..

FYI, I am referring am335x-evmsk.dts (5.10.100 of 8.2.0.24) as we are loading during kernel booting.. 

Also 1 more observation i found that mac node is observed as below in 4.9.59 kernel,

mac: ethernet@4a100000 {
compatible = "ti,am335x-cpsw","ti,cpsw";
ti,hwmods = "cpgmac0";
clocks = <&cpsw_125mhz_gclk>, <&cpsw_cpts_rft_clk>;
clock-names = "fck", "cpts";
cpdma_channels = <8>;
ale_entries = <1024>;
bd_ram_size = <0x2000>;
mac_control = <0x20>;
slaves = <2>;
active_slave = <0>;
cpts_clock_mult = <0x80000000>;
cpts_clock_shift = <29>;
reg = <0x4a100000 0x800
0x4a101200 0x100>;
#address-cells = <1>;
#size-cells = <1>;
interrupt-parent = <&intc>;
/*
* c0_rx_thresh_pend
* c0_rx_pend
* c0_tx_pend
* c0_misc_pend
*/
interrupts = <40 41 42 43>;
ranges;
syscon = <&scm_conf>;
status = "disabled";

davinci_mdio: mdio@4a101000 {
compatible = "ti,cpsw-mdio","ti,davinci_mdio";
#address-cells = <1>;
#size-cells = <0>;
ti,hwmods = "davinci_mdio";
bus_freq = <1000000>;
reg = <0x4a101000 0x100>;
status = "disabled";
};

cpsw_emac0: slave@4a100200 {
/* Filled in by U-Boot */
mac-address = [ 00 00 00 00 00 00 ];
};

cpsw_emac1: slave@4a100300 {
/* Filled in by U-Boot */
mac-address = [ 00 00 00 00 00 00 ];
};

phy_sel: cpsw-phy-sel@44e10650 {
compatible = "ti,am3352-cpsw-phy-sel";
reg= <0x44e10650 0x4>;
reg-names = "gmii-sel";
};
};

But the same is not observed in the kernel which we are using 5.10.100.(8.2.0.24 sdk) is it 

please let me know how to address this.. as we are using ethernet port in our custom board

  • Hi Manu,

    I looked at the kernel history, the compatible = "ti,am3352-cpsw-phy-sel" driver was replaced with ti,am3352-phy-gmii-sel, and as a result also the label (phandle) in the DTS file was changed from phy_sel to phy_gmii_sel, see this commit here:

    https://git.ti.com/cgit/ti-linux-kernel/ti-linux-kernel/commit/?id=fcfa0e84eaf71537cffd0749f115be7024556a7f

    In general I'd recommend to not do your Kernel migration by "try-and-fix-errors", but instead start with one of the current-kernel top-level DTS files, and do your entire DTS board board again, based on the delta-changes you introduced initially for your board for the older Kernel. Otherwise you'll run risks to miss important changes.

    Regards, Andreas

  • My i know why they have changed ? and also the functionality of that (phy-gmii-sel)? 

  • Hi Andreas,

    I have done with the above changes i can able to see the swtich module got loaded during kernel bring up(logs) but after when i logged in console.. and able to see the ip address assigend with MAC and broad cast ip.. 

    but if itry to ping from my laptop to controller its not able to ping (we have connected laptop to controller directly via ethernet there is not switch) its telling "host unreachable" can you please provide the inputs are we missing any dependent modules ? or how to debug.. this 

    Note: if i ping to own ip(controller ip(loopback)) it can able to ping

    I verified with subnet mask it looks good

    i verified with wiresharsk and arp tool utility its not able to resolve.. 

    please provide inputs

  • Hi,

    Per your earlier question as to why they change the best answer I can give is why is that the community is always reviewing definitions and therefore it changed based on some community consensus. 

    What are ip addresses of the board and the laptop? Is the laptop a Linux laptop? Could you please attach the results of ifconfig for the board. Could also attached a picture of the wireshark output or the pcap file?

    Best Regards,

    Schuyler

  • laptop ip 

    Ethernet adapter Ethernet:

    Connection-specific DNS Suffix . :
    IPv4 Address. . . . . . . . . . . : 192.168.1.60
    Subnet Mask . . . . . . . . . . . : 255.255.255.0
    Default Gateway . . . . . . . . . :

     

    Is the laptop a Linux laptop? 

    - nope

    # ifconfig
    eth0 Link encap:Ethernet HWaddr 99:59:AD:E9:1E:4C
    inet addr:192.168.1.65 Bcast:192.168.1.255 Mask:255.255.255.0
    inet6 addr: 2001:db8:0:1::3%763860/64 Scope:Global
    inet6 addr: fe80::9a5d:adff:fee9:1e4c%763860/64 Scope:Link
    UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
    RX packets:0 errors:0 dropped:0 overruns:0 frame:0
    TX packets:73 errors:0 dropped:0 overruns:0 carrier:0
    collisions:0 txqueuelen:1000
    RX bytes:0 (0.0 B) TX bytes:12104 (11.8 KiB)

    lo Link encap:Local Loopback
    inet addr:127.0.0.1 Mask:255.0.0.0
    inet6 addr: ::1%763860/128 Scope:Host
    UP LOOPBACK RUNNING MTU:65536 Metric:1
    RX packets:25 errors:0 dropped:0 overruns:0 frame:0
    TX packets:25 errors:0 dropped:0 overruns:0 carrier:0
    collisions:0 txqueuelen:1000
    RX bytes:2035 (1.9 KiB) TX bytes:2035 (1.9 KiB)

  • if we are removing network support in uboot will not cause any problem for ping related in kernel

  •   hi any update on this ?

    I also observed that logs when ethernet is coming up.. do you have any idea on this which may help in ping issue?

    [  104.986376] EXT4-fs (mmcblk1p2): mounted filesystem with ordered data mode. Opts: (null)
    [  311.142660] EXT4-fs (mmcblk1p6): mounted filesystem with ordered data mode. Opts: (null)
    [  311.947970] cpsw 4a100000.ethernet eth0: Link is Down
    [  314.193138] cpsw 4a100000.ethernet: initializing cpsw version 1.12 (0)
    [  314.213851] Generic PHY fixed-0:00: attached PHY driver [Generic PHY] (mii_bus:phy_addr=fixed-0:00, irq=POLL)
    [  314.229271] cpsw 4a100000.ethernet eth0: Link is Up - 100Mbps/Full - flow control off
    [  314.249767] libphy: PHY  not found
    [  314.259837] cpsw 4a100000.ethernet: phy "" not found on slave 1, err -19
    [  314.338394] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready

    Below is the complete kernel log, as we are using ksz8863 switch.. 

     

    Starting kernel ...

    [ 0.000000] Booting Linux on physical CPU 0x0
    [ 0.000000] Linux version 5.10.100manu1-g7a7a3af903 (oe-user@oe-host) (arm-none-linux-gnueabihf-gcc (GNU Toolchain for the A-profile Architecture 9.2-2019.12 (arm-9.10)) 9.2.1 20191025, GNU ld (GNU Toolchain for the A-profile Architecture 9.2-2019.12 (arm-9.10)) 2.33.1.20191209) #1 PREEMPT Thu Feb 23 09:41:40 UTC 2023
    [ 0.000000] CPU: ARMv7 Processor [413fc082] revision 2 (ARMv7), cr=10c5387d
    [ 0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
    [ 0.000000] OF: fdt: Machine model: TI AM335x EVM
    [ 0.000000] Memory policy: Data cache writeback
    [ 0.000000] efi: UEFI not found.
    [ 0.000000] cma: Reserved 48 MiB at 0xbd000000
    [ 0.000000] Zone ranges:
    [ 0.000000] Normal [mem 0x0000000080000000-0x00000000afefffff]
    [ 0.000000] HighMem [mem 0x00000000aff00000-0x00000000bfffffff]
    [ 0.000000] Movable zone start for each node
    [ 0.000000] Early memory node ranges
    [ 0.000000] node 0: [mem 0x0000000080000000-0x00000000afefffff]
    [ 0.000000] node 0: [mem 0x00000000b0000000-0x00000000bfffffff]
    [ 0.000000] Initmem setup node 0 [mem 0x0000000080000000-0x00000000bfffffff]
    [ 0.000000] CPU: All CPU(s) started in SVC mode.
    [ 0.000000] AM335X ES2.1 (neon)
    [ 0.000000] Built 1 zonelists, mobility grouping on. Total pages: 260162
    [ 0.000000] Kernel command line: console=ttyO0,115200n8 root=PARTUUID=ec8077c2-02 rw rootfstype=ext4 rootwait
    [ 0.000000] Dentry cache hash table entries: 131072 (order: 7, 524288 bytes, linear)
    [ 0.000000] Inode-cache hash table entries: 65536 (order: 6, 262144 bytes, linear)
    [ 0.000000] mem auto-init: stack:off, heap alloc:off, heap free:off
    [ 0.000000] Memory: 970656K/1047552K available (11264K kernel code, 711K rwdata, 3632K rodata, 1024K init, 310K bss, 27744K reserved, 49152K cma-reserved, 212992K highmem)
    [ 0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
    [ 0.000000] rcu: Preemptible hierarchical RCU implementation.
    [ 0.000000] rcu: RCU event tracing is enabled.
    [ 0.000000] Trampoline variant of Tasks RCU enabled.
    [ 0.000000] rcu: RCU calculated value of scheduler-enlistment delay is 10 jiffies.
    [ 0.000000] NR_IRQS: 16, nr_irqs: 16, preallocated irqs: 16
    [ 0.000000] IRQ: Found an INTC at 0x(ptrval) (revision 5.0) with 128 interrupts
    [ 0.000000] random: get_random_bytes called from start_kernel+0x30c/0x4c8 with crng_init=0
    [ 0.000000] TI gptimer clocksource: always-on /ocp/interconnect@44c00000/segment@200000/target-module@31000
    [ 0.000023] sched_clock: 32 bits at 24MHz, resolution 41ns, wraps every 89478484971ns
    [ 0.000073] clocksource: dmtimer: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 79635851949 ns
    [ 0.000894] TI gptimer clockevent: 24000000 Hz at /ocp/interconnect@48000000/segment@0/target-module@40000
    [ 0.003643] Console: colour dummy device 80x30
    [ 0.003729] WARNING: Your 'console=ttyO0' has been replaced by 'ttyS0'
    [ 0.003750] This ensures that you still see kernel messages. Please
    [ 0.003768] update your kernel commandline.
    [ 0.003888] Calibrating delay loop... 298.59 BogoMIPS (lpj=1492992)
    [ 0.070980] pid_max: default: 32768 minimum: 301
    [ 0.071415] Mount-cache hash table entries: 2048 (order: 1, 8192 bytes, linear)
    [ 0.071468] Mountpoint-cache hash table entries: 2048 (order: 1, 8192 bytes, linear)
    [ 0.073424] CPU: Testing write buffer coherency: ok
    [ 0.073577] CPU0: Spectre v2: using BPIALL workaround
    [ 0.075443] Setting up static identity map for 0x80100000 - 0x80100060
    [ 0.075798] rcu: Hierarchical SRCU implementation.
    [ 0.076018] EFI services will not be available.
    [ 0.076832] devtmpfs: initialized
    [ 0.111605] VFP support v0.3: implementor 41 architecture 3 part 30 variant c rev 3
    [ 0.112204] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
    [ 0.112262] futex hash table entries: 256 (order: -1, 3072 bytes, linear)
    [ 0.119350] pinctrl core: initialized pinctrl subsystem
    [ 0.121614] DMI not present or invalid.
    [ 0.122621] NET: Registered protocol family 16
    [ 0.127913] DMA: preallocated 256 KiB pool for atomic coherent allocations
    [ 0.155786] l3-aon-clkctrl:0000:0: failed to disable
    [ 0.158691] thermal_sys: Registered thermal governor 'fair_share'
    [ 0.158717] thermal_sys: Registered thermal governor 'bang_bang'
    [ 0.158751] thermal_sys: Registered thermal governor 'step_wise'
    [ 0.158774] thermal_sys: Registered thermal governor 'user_space'
    [ 0.159481] cpuidle: using governor ladder
    [ 0.159575] cpuidle: using governor menu
    [ 2.561004] random: fast init done
    [ 3.584183] No ATAGs?
    [ 3.584238] hw-breakpoint: debug architecture 0x4 unsupported.
    [ 3.659338] iommu: Default domain type: Translated
    [ 3.665652] SCSI subsystem initialized
    [ 3.666927] mc: Linux media interface: v0.10
    [ 3.667039] videodev: Linux video capture interface: v2.00
    [ 3.667314] pps_core: LinuxPPS API ver. 1 registered
    [ 3.667343] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
    [ 3.667405] PTP clock support registered
    [ 3.667558] EDAC MC: Ver: 3.0.0
    [ 3.670302] Advanced Linux Sound Architecture Driver Initialized.
    [ 3.673722] clocksource: Switched to clocksource dmtimer
    [ 3.694866] NET: Registered protocol family 2
    [ 3.695453] IP idents hash table entries: 16384 (order: 5, 131072 bytes, linear)
    [ 3.698399] tcp_listen_portaddr_hash hash table entries: 512 (order: 0, 4096 bytes, linear)
    [ 3.698519] TCP established hash table entries: 8192 (order: 3, 32768 bytes, linear)
    [ 3.698755] TCP bind hash table entries: 8192 (order: 3, 32768 bytes, linear)
    [ 3.698975] TCP: Hash tables configured (established 8192 bind 8192)
    [ 3.699279] UDP hash table entries: 512 (order: 1, 8192 bytes, linear)
    [ 3.699364] UDP-Lite hash table entries: 512 (order: 1, 8192 bytes, linear)
    [ 3.699654] NET: Registered protocol family 1
    [ 3.700888] RPC: Registered named UNIX socket transport module.
    [ 3.700930] RPC: Registered udp transport module.
    [ 3.700951] RPC: Registered tcp transport module.
    [ 3.700972] RPC: Registered tcp NFSv4.1 backchannel transport module.
    [ 3.703549] PCI: CLS 0 bytes, default 64
    [ 3.705622] hw perfevents: enabled with armv7_cortex_a8 PMU driver, 5 counters available
    [ 3.708638] Initialise system trusted keyrings
    [ 3.709241] workingset: timestamp_bits=14 max_order=18 bucket_order=4
    [ 3.720435] squashfs: version 4.0 (2009/01/31) Phillip Lougher
    [ 3.723296] NFS: Registering the id_resolver key type
    [ 3.723389] Key type id_resolver registered
    [ 3.723414] Key type id_legacy registered
    [ 3.723665] nfs4filelayout_init: NFSv4 File Layout Driver Registering...
    [ 3.723990] nfs4flexfilelayout_init: NFSv4 Flexfile Layout Driver Registering...
    [ 3.724107] ntfs: driver 2.1.32 [Flags: R/O].
    [ 3.725497] Key type asymmetric registered
    [ 3.725543] Asymmetric key parser 'x509' registered
    [ 3.725702] bounce: pool size: 64 pages
    [ 3.725824] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 244)
    [ 3.725855] io scheduler mq-deadline registered
    [ 3.725879] io scheduler kyber registered
    [ 4.105101] ti-sysc 44e07000.target-module: dts flag should be at module level for ti,no-reset-on-init
    [ 4.855696] omap-mailbox 480c8000.mailbox: omap mailbox rev 0x400
    [ 5.178798] debugfs: Directory '49000000.dma' with parent 'dmaengine' already present!
    [ 5.178883] edma 49000000.dma: TI EDMA DMA engine driver
    [ 5.215739] pinctrl-single 44e10800.pinmux: 142 pins, size 568
    [ 5.364439] Serial: 8250/16550 driver, 10 ports, IRQ sharing enabled
    [ 5.376086] 44e09000.serial: ttyS0 at MMIO 0x44e09000 (irq = 20, base_baud = 3000000) is a 8250
    [ 6.076592] printk: console [ttyS0] enabled
    [ 6.085418] 48024000.serial: ttyS2 at MMIO 0x48024000 (irq = 26, base_baud = 3000000) is a 8250
    [ 6.098816] 481a6000.serial: ttyS3 at MMIO 0x481a6000 (irq = 37, base_baud = 3000000) is a 8250
    [ 6.111680] 481a8000.serial: ttyS4 at MMIO 0x481a8000 (irq = 38, base_baud = 3000000) is a 8250
    [ 6.128707] omap_rng 48310000.rng: Random Number Generator ver. 20
    [ 6.135558] random: crng init done
    [ 6.190861] brd: module loaded
    [ 6.211626] loop: module loaded
    [ 6.244212] cpsw 4a100000.ethernet: No slave[1] phy_id, phy-handle, or fixed-link property
    [ 6.252629] cpsw 4a100000.ethernet: initialized cpsw ale version 1.4
    [ 6.259243] cpsw 4a100000.ethernet: ALE Table size 1024
    [ 6.264820] cpsw 4a100000.ethernet: cpts: overflow check period 500 (jiffies)
    [ 6.272147] cpsw 4a100000.ethernet: Detected MACID = 98:5d:ad:e9:1e:4c
    [ 6.284743] i2c /dev entries driver
    [ 6.294317] omap_wdt: OMAP Watchdog Timer Rev 0x01: initial timeout 60 sec
    [ 6.306044] cpu cpu0: dev_pm_opp_set_rate: failed to find current OPP for freq 600000000 (-34)
    [ 6.315066] cpufreq: cpufreq_online: CPU0: Running at unlisted initial frequency: 600000 KHz, changing to: 300000 KHz
    [ 6.326617] cpuidle: enable-method property 'ti,am3352' found operations
    [ 6.336481] sdhci: Secure Digital Host Controller Interface driver
    [ 6.342762] sdhci: Copyright(c) Pierre Ossman
    [ 6.353493] sdhci-pltfm: SDHCI platform and OF driver helper
    [ 6.378023] ledtrig-cpu: registered to indicate activity on CPUs
    [ 6.387638] sdhci-omap 481d8000.mmc: supply vqmmc not found, using dummy regulator
    [ 6.399539] sdhci-omap 47810000.mmc: supply vqmmc not found, using dummy regulator
    [ 6.475170] NET: Registered protocol family 10
    [ 6.486039] Segment Routing with IPv6
    [ 6.490282] sit: IPv6, IPv4 and MPLS over IPv4 tunneling driver
    [ 6.516946] NET: Registered protocol family 17
    [ 6.521716] bridge: filtering via arp/ip/ip6tables is no longer available by default. Update your scripts to load br_netfilter if you need this.
    [ 6.554987] Key type dns_resolver registered
    [ 6.561449] omap_voltage_late_init: Voltage driver support not added
    [ 6.582935] Loading compiled-in X.509 certificates
    [ 6.606878] mmc1: SDHCI controller on 481d8000.mmc [481d8000.mmc] using External DMA
    [ 6.668006] OMAP GPIO hardware version 0.1
    [ 6.679376] mmc1: new high speed MMC card at address 0001
    [ 6.694820] mmcblk1: mmc1:0001 W62704 3.53 GiB
    [ 6.700792] mmcblk1boot0: mmc1:0001 W62704 partition 1 2.00 MiB
    [ 6.708496] mmcblk1boot1: mmc1:0001 W62704 partition 2 2.00 MiB
    [ 6.716276] mmcblk1rpmb: mmc1:0001 W62704 partition 3 512 KiB, chardev (242:0)
    [ 6.727036] rtc rtc0: invalid alarm value: 2023-02-20T45:85:00
    [ 6.736758] rtc-pcf8563 2-0051: registered as rtc0
    [ 6.744268] mmcblk1: p1 p2 p3 p4 < p5 p6 >
    [ 6.750876] rtc-pcf8563 2-0051: setting system clock to 2023-02-20T20:58:06 UTC (1676926686)
    [ 6.770006] omap_i2c 4819c000.i2c: bus 2 rev0.11 at 100 kHz
    [ 6.796864] omap_reset_deassert: timedout waiting for gfx:0
    [ 6.802764] ti-sysc: probe of 5600fe00.target-module failed with error -110
    [ 6.812971] ksz8863 spi0.0: chip id 0x8831
    [ 6.889888] genirq: Threaded irq requested with handler=NULL and !ONESHOT for spi0.0 (irq 59)
    [ 6.899148] spi0.0: Can't get IRQ 59 (PHY)
    [ 6.903314] No switch interrupt
    [ 6.918868] omap_gpio 44e07000.gpio: Could not set line 6 debounce to 200000 microseconds (-22)
    [ 6.937806] sdhci-omap 47810000.mmc: supply vqmmc not found, using dummy regulator
    [ 6.951056] cfg80211: Loading compiled-in X.509 certificates for regulatory database
    [ 6.959845] sdhci-omap 48060000.mmc: Got CD GPIO
    [ 6.976043] sdhci-omap 48060000.mmc: supply vqmmc not found, using dummy regulator
    [ 7.029329] cfg80211: Loaded X.509 cert 'sforshee: 00b28ddf47aef9cea7'
    [ 7.054340] platform regulatory.0: Direct firmware load for regulatory.db failed with error -2
    [ 7.063067] cfg80211: failed to load regulatory.db
    [ 7.074302] ALSA device list:
    [ 7.077357] No soundcards found.
    [ 7.215068] mmc0: SDHCI controller on 48060000.mmc [48060000.mmc] using External DMA
    [ 7.287936] mmc0: new high speed SDHC card at address aaaa
    [ 7.293632] mmc2: SDHCI controller on 47810000.mmc [47810000.mmc] using External DMA
    [ 7.305154] mmcblk0: mmc0:aaaa SA08G 7.40 GiB
    [ 7.317964] sdhci-omap 47810000.mmc: card claims to support voltages below defined range
    [ 7.326626] mmcblk0: p1 p2 p3
    [ 7.414206] mmc2: new SDIO card at address 0001
    [ 7.932791] EXT4-fs (mmcblk0p2): recovery complete
    [ 7.940982] EXT4-fs (mmcblk0p2): mounted filesystem with ordered data mode. Opts: (null)
    [ 7.949613] VFS: Mounted root (ext4 filesystem) on device 179:50.
    [ 7.958710] devtmpfs: mounted
    [ 7.971177] Freeing unused kernel memory: 1024K
    [ 7.979425] Run /sbin/init as init process
    [ 8.374476] systemd[1]: systemd 229 running in system mode. (+PAM -AUDIT -SELINUX +IMA -APPARMOR +SMACK +SYSVINIT +UTMP -LIBCRYPTSETUP -GCRYPT -GNUTLS +ACL +XZ -LZ4 -SECCOMP +BLKID -ELFUTILS +KMOD -IDN)
    [ 8.395976] systemd[1]: Detected architecture arm.

    Welcome to Arago 2016.12!

    with the above log can we confirm that ethernet switch is up...?

    We verified with ethtool,

    # /bin/ethtool -i eth0
    driver: cpsw
    version: 1.0
    firmware-version:
    expansion-rom-version:
    bus-info: 4a100000.ethernet
    supports-statistics: yes
    supports-test: no
    supports-eeprom-access: no
    supports-register-dump: yes
    supports-priv-flags: no
    root@SIEMENS-SEM3T:~#

    as per the above outpu.. test is not suppoerted for the driver ksz8863.

    could you please provide how to debug this ?