ENCX24J600 SPI driver not working

I’m using a raspberrypi-cm3 and my machine connects to the internet using ethernet spi using the encx24j600 driver. I have appended the overlay to the device tree and I’m using balenaOS distro.

The device tree overlay is written as such encx24j600-spi2-overlay.dts and encx24j600-overlay.dts. These are more or less copies of the enc28j60-overlay.dts and enc28j60-spi2-overlay.dts.

// Overlay for the Microchip ENCX24J600 Ethernet Controller - SPI2 Compute Module 
// Interrupt pin: 39


/ {
        compatible = "brcm,bcm2835";
        fragment@0 {
                target = <&spi2>;
                __overlay__ {
                        /* needed to avoid dtc warning */
                        #address-cells = <1>;
                        #size-cells = <0>;

                        status = "okay";

                        eth1: encx24j600@0{
                                compatible = "microchip,encx24j600";
                                reg = <0>; /* CE0 */
                                pinctrl-names = "default";
                                pinctrl-0 = <&eth1_pins>;
                                interrupt-parent = <&gpio>;
                                interrupts = <39 0x2>; /* Falling edge */
                                spi-max-frequency = <12000000>;
                                status = "okay";

        fragment@1 {
                target = <&gpio>;
                __overlay__ {
                        eth1_pins: eth1_pins {
                                brcm,pins = <39>;
                                brcm,function = <0>; /* in */
                                brcm,pull = <0>; /* none */

        __overrides__ {
                int_pin = <&eth1>, "interrupts:0",
                          <&eth1_pins>, "brcm,pins:0";
                speed   = <&eth1>, "spi-max-frequency:0";

When I flash my image on the device I find that I am only able to connect via ethernet to usb and SPI connection fails completely. dmesg logs show that the eth1 pin has a eth1: hw csum failure

The ifconfig logs for the eth1 pin looks like this
eth1 Link encap:Ethernet HWaddr 04:91:62:6B:9F:78
inet addr: Bcast: Mask:
inet6 addr: fe80::11f6:6f22:9b98:dec4/64 Scope:Link
RX packets:16381 errors:112 dropped:26 overruns:0 frame:187
TX packets:396 errors:180 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:3765249 (3.5 MiB) TX bytes:30358 (29.6 KiB)

Any help with this would be much appreciated. Thanks!

Hey prim,
Did you manage to sort out the problem? There are lots of RX and TX errors, and I don’t think that is caused by the overlay.
I found this that may be of help: Ethernet hw csum failure with ENC424J600 chip - Toradex Community
Let us know how it goes!