logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

rtapi_module_param - Specifying module parameters

Arguments

var    The variable where the parameter should be stored

       description
              A short description of the parameter or module

       num    The maximum number of values for an array parameter

       license
              The license of the module, for instance "GPL"

       author The author of the module

       function
              The pointer to the function to be exported

Description

       These  macros  are  portable  ways  to declare kernel module parameters.  They must be used in the global
       scope, and are not followed by a terminating semicolon.  They must be used after the associated  variable
       or function has been defined.

Interpretation Of License Strings

MODULE_LICENSE follows the kernel's definition of license strings.  Notably, "GPL" indicates "GNU General
       Public License v2 orlater".  (emphasis ours).

       "GPL"  GNU General Public License v2 or later

       "GPLv2"
              GNU General Public License v2

       "GPLandadditionalrights"
              GNU General Public License v2 rights and more

       "DualBSD/GPL"
              GNU General Public License v2 or BSD license choice

       "DualMIT/GPL"
              GNU General Public License v2 or MIT license choice

       "DualMPL/GPL"
              GNU General Public License v2 or Mozilla license choice

       "Proprietary"
              Non-free products

       It is still good practice to include a license block which indicates  the  author,  copyright  date,  and
       disclaimer of warranty as recommended by the GNU GPL.

Name

       rtapi_module_param - Specifying module parameters

Notes

       EXPORT_FUNCTION  makes a symbol available for use by a subsequently loaded component.  It is unrelated to
       HAL functions, which are described in hal_export_funct(3hal)

Realtime Considerations

       Not available in userspace code.

LinuxCNC Documentation                             2006-10-12                         rtapi_module_param(3rtapi)

Syntax


       RTAPI_MP_INT(var, description)

       RTAPI_MP_LONG(var, description)

       RTAPI_MP_STRING(var, description)

       RTAPI_MP_ARRAY_INT(var, num, description)

       RTAPI_MP_ARRAY_LONG(var, num, description)

       RTAPI_MP_ARRAY_STRING(var, num, description)

       MODULE_LICENSE(license)

       MODULE_AUTHOR(author)

       MODULE_DESCRIPTION(description)

       EXPORT_FUNCTION(function)

See Also