AnsweredAssumed Answered

RMII configuration with KSZ8081 and iMX6DL

Question asked by Roberto Mainetti on Apr 20, 2016
Latest reply on Apr 21, 2016 by Roberto Mainetti


I need some help configuring the ethernet. On my board I have a KSZ8081RNBIA in RMII and an iMX6DL.

I'm using "core-image-minimal", I configured the kernel (3.10.17-r0) to load the proper driver and I added in the device tree this code:


fec: ethernet@02188000 {

                compatible = "fsl,imx6q-fec";

                reg = <0x02188000 0x4000>;

                interrupts = <0 118 0x04 0 119 0x04>;

                clocks = <&clks 117>, <&clks 117>, <&clks 190>;

                clock-names = "ipg", "ahb", "ptp";

                status = "disabled";



&fec {

    pinctrl-names = "default";

    pinctrl-0 = <&pinctrl_enet_1>;

    phy-mode = "rmii";

    phy-handle = <&ethphy1>;

    status = "okay";

    mdio {

        #address-cells = <1>;

        #size-cells    = <0>;

        ethphy1: ethernet-phy@0 {

            compatible = "micrel,ksz8081";

            device_type = "ethernet-phy";

            reg = <0>;





enet {

        pinctrl_enet_1: enetgrp-1 {

            fsl,pins = <

                MX6QDL_PAD_ENET_TXD0__ENET_TX_DATA0   0x1b0b0

                MX6QDL_PAD_ENET_TXD1__ENET_TX_DATA1   0x1b0b0

                MX6QDL_PAD_ENET_TX_EN__ENET_TX_EN     0x1b0b0

                MX6QDL_PAD_ENET_RXD0__ENET_RX_DATA0   0x1b0b0

                MX6QDL_PAD_ENET_RXD1__ENET_RX_DATA1   0x1b0b0

                MX6QDL_PAD_ENET_CRS_DV__ENET_RX_EN    0x1b0b0

                MX6QDL_PAD_ENET_MDC__ENET_MDC         0x1b0b0

                MX6QDL_PAD_ENET_MDIO__ENET_MDIO          0x1b0b0

                MX6QDL_PAD_ENET_RX_ER__ENET_RX_ER     0x1b0b0

                MX6QDL_PAD_ENET_REF_CLK__GPIO1_IO23   0x80000000 // Connected to interrupt from KSZ8081

                MX6QDL_PAD_GPIO_16__ENET_REF_CLK      0x4001b0a8





But when I try to configure the connection (ifconfig ...) and then I try to send a ping it hungs (I have to press ctrl+c).


In the kernel log I find this line:

Configuring network interfaces... fec 2188000.ethernet eth0: Freescale FEC PHY driver (Micrel KSZ8081 or KSZ8091) (mii_bus:phy_addr=2188000.ethernet:00, irq=-1)


Is there some problem in the configuration? Should I add something about the interrupt connection to the device tree? I've already tried to add something but with no success.


Please help me,


Thank you in advance