Project

General

Profile

Actions

Feature #10362

closed

Catch kernel module undefined symbols at build time

Added by Robert Mustacchi over 3 years ago. Updated about 3 years ago.

Status:
Closed
Priority:
Normal
Category:
kernel
Start date:
2019-02-09
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:
Gerrit CR:

Description

Many times while developing, it's possible to end up using an undefined symbol in the system. While genunix and unix check one another out by creating a shared library and linking against one another, the same cannot be said for regular kernel modules. In those cases, undefined symbols lead to krtld just complaining about the module and refusing to load it.

To minimize disruption to the system and to keep the existing system as straightforward as possible I put together something that uses mapfiles to describe the symbols that are provided by various modules or interfaces. This allows us to opt modules into this system. To prove that this works, I've prototyped this against all of the Intel networking kernel modules (i40e, ixgbe, igb, e1000g).

The README in the source for the change describes the full details of how to add additional mapfiles and to opt modules into this system.


Related issues

Related to illumos gate - Bug #11500: kernel ddi mapfile missing ddi_fm_dma_err_clearNew

Actions
Related to illumos gate - Bug #14002: Autogenerated dtrace.mapfile not cleaned up by clean nor clobberClosedRobert Mustacchi

Actions
Actions #1

Updated by Electric Monk about 3 years ago

  • Status changed from New to Closed

git commit 3e3ca1ce307a7d82ef007b435088f3f04a0f3e65

commit  3e3ca1ce307a7d82ef007b435088f3f04a0f3e65
Author: Robert Mustacchi <rm@joyent.com>
Date:   2019-06-14T21:23:50.000Z

    10362 Catch kernel module undefined symbols at build time
    Reviewed by: Jerry Jelinek <jerry.jelinek@joyent.com>
    Reviewed by: Patrick Mooney <patrick.mooney@joyent.com>
    Reviewed by: Gergő Doma <domag02@gmail.com>
    Reviewed by: Garrett D'Amore <garrett@damore.org>
    Approved by: Garrett D'Amore <garrett@damore.org>

Actions #2

Updated by Yuri Pankov almost 3 years ago

  • Related to Bug #11500: kernel ddi mapfile missing ddi_fm_dma_err_clear added
Actions #3

Updated by Robert Mustacchi 11 months ago

  • Related to Bug #14002: Autogenerated dtrace.mapfile not cleaned up by clean nor clobber added
Actions

Also available in: Atom PDF