Rocks-4.3 kernel to support RTL8111b

To Beshr:

The vanilla install of Rockscluster 4.3 uses version 2.6.9-55EL of the linux kernel. Native support for the Realtek 8111B (r8168) did not come until 2.6.19.xx. I downloaded 2.6.23.13 from kernel.org. After rebuilding the kernel, you have to enable the kernel to map the hardware ID of the device to the correct module (r8169). Here is an archive of the files that I used to build the driver:

rocks-boot-drivers.tar.gz: I added the r8168 directory and modified the subdirs file to build this module for the kernel. It actually does not build anything since there are no entries in the SOURCE variable of the Makefile. Extract this tarball to your Rocks CVS tree ($ROCKS-SRC-ROOT/src/roll/kernel/src/rocks-boot/enterprise/4/images) The following entry was added to drivers/r8168/:


0x10ec 0x8168 "r8169" "RealTek RTL8168B/8111B, RTL8168C/8111C Gigabit Ethernet controller

Where 0x10ec 0x8168 is the hardware ID of my GigE controller.

Then I followed the instructions Creating a Custom Kernel RPM and Adding a Device Driver of the User Guide.

Good luck in building your cluster!

5 Responses to “Rocks-4.3 kernel to support RTL8111b”


  1. 1 Beshr 2008 2月 16 1:40 am

    Thanks a lot for your help Mr. Allan.

    But I have a question:
    What do you mean by:
    ” After rebuilding the kernel, you have to enable the kernel to map the hardware ID of the device to the correct module (r8169)” ?
    -Does this mean that:
    -I have to build the kernel,
    -then install it,
    -then restart and boot on it
    -and finally follow the instructions in the Rocks documentation?
    Is that right?
    Or just rebuild the kernel and follow the instructions in the Rocks documentation?

    Thanks again.

    -Beshr

  2. 2 Allan Espinosa 2008 2月 16 2:16 am

    “After rebuilding the kernel…” -> this refers to the instructions found in the “Creating a custom kernel rpm” instructions. The built package will be installed on your compute nodes and not the front end. Using the instructions from the “Adding a device driver”, I created the r8168 directory as defined in the archive above. This generates the hardware mappings.

    The generated rocks-boot*.rpm packages will be installed on your front end. It contains the vmlinuz and initrd files to boot the compute nodes from the network.

  3. 3 karolis 2008 4月 9 4:25 pm

    Hello,
    I have a question.
    I am getting error when compiling rocks-boot-drivers.tar.gz driver source, i have followed the instructions “Creating a Custom Kernel RPM” (using kernel 2.6.23.13 from kernel.org) and downloaded your prepared driver src when i do in rocks-boot dir “make rpm” everything goes ok but when started to compile RTL8111b module i got error:

    Building modules for kernel 2.6.23.13-1…

    Building r8168 module…

    make[4]: Entering directory `/export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168′
    make -C 2.6.23.13-1-i686 -f Makefile.build \
    PWD=/export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686 modules
    make[5]: Entering directory `/export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686′
    make -C ../../../i386/kernel/lib/modules/2.6.23.13-1/build \
    SUBDIRS=/export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686 modules
    make[6]: Entering directory `/export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/i386/kernel/usr/src/kernels/2.6.23.13-1-i386′
    CC [M] /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/r8168_n.o
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/r8168_n.c:2236: warning: ‘rtl8168_phy_power_down’ defined but not used
    CC [M] /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.o
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c: In function `rtl8168_set_loopback’:
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:177: error: structure has no member named `loopback_tx_ok’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:178: error: structure has no member named `loopback_rx_ok’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:179: error: structure has no member named `loopback_tx_err’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:180: error: structure has no member named `loopback_rx_err’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:187: error: structure has no member named `loopback_tx_schedule’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:188: error: structure has no member named `loopback_state’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:189: error: structure has no member named `loopback_type’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:191: error: structure has no member named `loopback_tasklet’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:193: error: structure has no member named `loopback_tx_schedule’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:198: error: structure has no member named `loopback_state’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:211: error: structure has no member named `loopback_tx_schedule’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:212: error: structure has no member named `loopback_state’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:213: error: structure has no member named `loopback_type’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:215: error: structure has no member named `loopback_tasklet’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:217: error: structure has no member named `loopback_tx_schedule’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:224: error: structure has no member named `loopback_state’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c: In function `rtl8168_loopback_test’:
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:236: error: structure has no member named `loopback_pkt_payload_len’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:241: error: structure has no member named `loopback_skb’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:244: error: structure has no member named `loopback_pkt_payload_len’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:244: error: structure has no member named `loopback_pkt_payload’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:244: error: structure has no member named `loopback_pkt_payload_len’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:244: error: structure has no member named `loopback_pkt_payload’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:244: error: structure has no member named `loopback_pkt_payload_len’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:245: error: structure has no member named `loopback_pkt_payload_len’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:254: error: structure has no member named `loopback_tx_schedule’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c: In function `rtl8168_priv_ioctl’:
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:392: error: structure has no member named `loopback_pkt_payload’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:393: error: structure has no member named `loopback_pkt_payload_len’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:395: error: structure has no member named `loopback_pkt_payload’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:401: error: structure has no member named `loopback_tx_ok’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:402: error: structure has no member named `loopback_rx_ok’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:403: error: structure has no member named `loopback_tx_err’
    /export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.c:404: error: structure has no member named `loopback_rx_err’
    make[7]: *** [/export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686/rtl_ioctl.o] Error 1
    make[6]: *** [_module_/export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686] Error 2
    make[6]: Leaving directory `/export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/i386/kernel/usr/src/kernels/2.6.23.13-1-i386′
    make[5]: *** [r8168.ko] Error 2
    make[5]: Leaving directory `/export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168/2.6.23.13-1-i686′
    make[4]: *** [build] Error 2
    make[4]: Leaving directory `/export/rocks-4.3/rocks/src/roll/kernel/BUILD/rocks-boot-4.3/enterprise/4/images/drivers/r8168′

    Rocks-4.3 src up2date.

    I havbe tryed with different kernels and RTL8111b drivers – when compiling driver module alone to kernel and loading, it works fine, but i cant get it compiled within rocks-boot source, cant get rocks-boot rpms with RTL driver compilde as module…

    I would be very happy for any advice

  4. 4 Allan Espinosa 2008 4月 9 4:50 pm

    Hi Karolis,

    I was also getting these errors before. In the kernel rpm that I built, the rtl8111b driver source code was not compiled. In the Makefile of the r8168 module, i emptied the list of source files to compile. It is only a placeholder module to add the hardware id to the vanilla module in the kernel.

    here is the content of the Makefile

    MODULES :=

    SOURCES :=

    HEADERS :=

  5. 5 Allan Espinosa 2008 4月 9 5:00 pm

    Btw, Karolis

    what kind of research applications do you run in your cluster? I am also interested in your setup

    Thanks.


コメントを残す

以下に詳細を記入するか、アイコンをクリックしてログインしてください。

WordPress.com ロゴ

WordPress.com アカウントを使ってコメントしています。 ログアウト / 変更 )

Twitter 画像

Twitter アカウントを使ってコメントしています。 ログアウト / 変更 )

Facebook の写真

Facebook アカウントを使ってコメントしています。 ログアウト / 変更 )

Google+ フォト

Google+ アカウントを使ってコメントしています。 ログアウト / 変更 )

%s と連携中





%d人のブロガーが「いいね」をつけました。