lkml.org 
[lkml]   [1999]   [Dec]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    Subjectto CONFIG_KMOD or not to CONFIG_KMOD
    Hi guys,

    What is the official status on the situations like:

    check some resource;
    if (resource == NULL) {
    char buf[32];
    sprintf(buffer, "foo-bar-XYZ");
    request_module(buffer);
    if (resource is still NULL)
    return -ENODEV; /* or whatever appropriate */
    }

    The #ifdef CONFIG_KMODE around this type of code can be omitted (because
    request_module() will be just noop) e.g. as is done in phone_open() (the
    new Linux Telephony thingy) or it can be left for performance when any CPU
    cycle is important e.g. as in fs/exec.c:search_binary_handler()

    Does everyone agree with such state of things or do you think one should
    go through the whole source and clean it up removing all #ifdef
    CONFIG_KMOD as they are strictly speaking superfluous?

    Regards,
    Tigran.


    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.rutgers.edu
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2005-03-22 13:55    [W:4.895 / U:0.008 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site