Welcome! Log In Create A New Profile

Advanced

r8168_kirkwood

Posted by ri8 
ri8
r8168_kirkwood
March 20, 2025 04:58AM
Hi bodhi,

i try to make work a rtl8168 pci-e card
working on moiplus, yet deb package for in do not
get compiled, with output :
root@debian:/usr/src# dkms build -m  r8168/8.051.02
Sign command: /lib/modules/6.12.6-kirkwood-tld-1/build/scripts/sign-file
Binary /lib/modules/6.12.6-kirkwood-tld-1/build/scripts/sign-file not found,ules won't be signed

Building module:
Cleaning build area...(bad exit status: 2)
make -j1 KERNELRELEASE=6.12.6-kirkwood-tld-1 -C /lib/modules/6.12.6-kirkwood-1/build M=/var/lib/dkms/r8168/8.051.02/build...(bad exit status: 2)
Error! Bad return status for module build on kernel: 6.12.6-kirkwood-tld-1 (armv5tel)
Consult /var/lib/dkms/r8168/8.051.02/build/make.log for more information.
Is it, again, an issue of initializing it in the u-boot?
i'm now on 6.12,
had 6.13 before, with the same output.
Thanx
alex



Edited 1 time(s). Last edit at 03/20/2025 05:02AM by ri8.
Re: r8168_kirkwood
March 20, 2025 05:12AM
Alex,

> Is it, again, an issue of initializing it in the
> u-boot?

No, u-boot does not have anything to do with kernel DKMS.

No idea why, but seems there is more info:

Quote

Consult /var/lib/dkms/r8168/8.051.02/build/make.log for more information.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
ri8
Re: r8168_kirkwood
March 21, 2025 06:24AM
bodhi,

alas,
my question should have also this
modprobe r8168 (ok)
modprobe r8169 (ok)
root@debian:/usr/src# dmesg|tail -2
[ 40.193638] mv643xx_eth_port mv643xx_eth_port.0 eth0: link up, 100 Mb/s, full duplex, flow control disabled
[ 456.085811] r8168: loading out-of-tree module taints kernel.

after which i installed deb package r8168-dkms,
and as it failed to compile,
downloaded sources from realtek for this rtl8186H ,
and made a try.
The logs were identical in both cases.

root@debian:/usr/src# less /var/lib/dkms/r8168/8.051.02/build/make.log
DKMS make.log for r8168-8.051.02 for kernel 6.12.6-kirkwood-tld-1 (armv5tel)
Fri Mar 21 03:44:28 PDT 2025
make: Entering directory '/usr/src/linux-headers-6.12.6-kirkwood-tld-1'
make[1]: *** arch/arm: Is a directory.  Stop.
make: *** [Makefile:224: __sub-make] Error 2
make: Leaving directory '/usr/src/linux-headers-6.12.6-kirkwood-tld-1'
/var/lib/dkms/r8168/8.051.02/build/make.log (END)

btw, i found an interesting discussion about usb,
nearly of the same time, as you delivered u-boot for moiplus
and downgraded nand installation to 4.2 , with no results.

Regards,
alex
ri8
Re: r8168_kirkwood
March 23, 2025 05:30AM
bodhi,

i did't know about it, but now, i came a little bit further:

root@debian:~# lscpu|grep arm
Architecture: armv5tel
root@debian:~#
so, with a swtich ARCH=armv5tel
and CROSS_COMPILE=arch-linux-noneabi- compilation
stops whith this log:
Consult /var/lib/dkms/r8168/8.051.02/build/make.log for more information.
root@debian:/usr/src# less /var/lib/dkms/r8168/8.051.02/build/make.log
DKMS make.log for r8168-8.051.02 for kernel 6.12.6-kirkwood-tld-1 (armv5tel)
Sun Mar 23 03:04:09 PDT 2025
make: Entering directory '/usr/src/linux-headers-6.12.6-kirkwood-tld-1'
warning: the compiler differs from the one used to build the kernel
  The kernel was built by: gcc (Debian 12.2.0-14) 12.2.0
  You are using:           arm-linux-gnueabi-gcc (Debian 12.2.0-14) 12.2.0
  CC [M]  /var/lib/dkms/r8168/8.051.02/build/r8168_n.o
/var/lib/dkms/r8168/8.051.02/build/r8168_n.c:2110:5: warning: no previous prototype for 'mdio_real_read' [-Wmissing-prototypes]
 2110 | u32 mdio_real_read(struct rtl8168_private *tp,
      |     ^~~~~~~~~~~~~~
/var/lib/dkms/r8168/8.051.02/build/r8168_n.c: In function 'rtl8168_get_drvinfo':
/var/lib/dkms/r8168/8.051.02/build/r8168_n.c:5229:17: error: implicit declaration of function 'strlcpy'; did you mean 'strncpy'? [-Werror=implicit-function-declaration]
 5229 |                 strlcpy(info->fw_version, rtl_fw->version,
      |                 ^~~~~~~
      |                 strncpy
/var/lib/dkms/r8168/8.051.02/build/r8168_n.c: At top level:
/var/lib/dkms/r8168/8.051.02/build/r8168_n.c:6888:20: error: initialization of 'int (*)(struct net_device *, struct ethtool_keee *)' from incompatible pointer type 'int (*)(struct net_device *, struct ethtool_eee *)' [-Werror=incompatible-pointer-types]
 6888 |         .get_eee = rtl_ethtool_get_eee,
      |                    ^~~~~~~~~~~~~~~~~~~
/var/lib/dkms/r8168/8.051.02/build/r8168_n.c:6888:20: note: (near initialization for 'rtl8168_ethtool_ops.get_eee')
/var/lib/dkms/r8168/8.051.02/build/r8168_n.c:6889:20: error: initialization of 'int (*)(struct net_device *, struct ethtool_keee *)' from incompatible pointer type 'int (*)(struct net_device *, struct ethtool_eee *)' [-Werror=incompatible-pointer-types]
 6889 |         .set_eee = rtl_ethtool_set_eee,
      |                    ^~~~~~~~~~~~~~~~~~~
/var/lib/dkms/r8168/8.051.02/build/r8168_n.c:6889:20: note: (near initialization for 'rtl8168_ethtool_ops.set_eee')
/var/lib/dkms/r8168/8.051.02/build/r8168_n.c: In function 'r8168_csum_workaround':
/var/lib/dkms/r8168/8.051.02/build/r8168_n.c:29208:24: error: implicit declaration of function 'skb_gso_segment'; did you mean 'skb_gso_reset'? [-Werror=implicit-function-declaration]
29208 |                 segs = skb_gso_segment(skb, features);
      |                        ^~~~~~~~~~~~~~~
      |                        skb_gso_reset
/var/lib/dkms/r8168/8.051.02/build/r8168_n.c:29208:22: warning: assignment to 'struct sk_buff *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
29208 |                 segs = skb_gso_segment(skb, features);
      |                      ^
cc1: some warnings being treated as errors
make[2]: *** [scripts/Makefile.build:229: /var/lib/dkms/r8168/8.051.02/build/r8168_n.o] Error 1
make[1]: *** [/usr/src/linux-headers-6.12.6-kirkwood-tld-1/Makefile:1945: /var/lib/dkms/r8168/8.051.02/build] Error 2
make: *** [Makefile:224: __sub-make] Error 2
make: Leaving directory '/usr/src/linux-headers-6.12.6-kirkwood-tld-1'

2. found a thread on r8186, - https://forum.doozan.com/read.php?2,23657,23666
with a link to source code
https://github.com/mtorromeo/r8168

, which compiles a r8186.ko, loadable with insmod src/r8186.ko,
but not resulting in a new eth device to pop up.

3. it doesn't help either, if putting on-board debian-6.12 r8168 in /etc/initramfs/modules,
and regenerating a new uInitrd afterwards; no new device after reboot

Regards,
alex



Edited 1 time(s). Last edit at 03/23/2025 05:44AM by ri8.
Author:

Your Email:


Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: