Create include/linux/module.h with stub definitions for kernel module support. U-Boot doesn't use loadable modules, so these are no-ops. Includes: - THIS_MODULE, try_module_get(), module_put() - module_init(), module_exit() - module_param() and variants - MODULE_* macros (LICENSE, AUTHOR, DESCRIPTION, etc.) Update compat.h to include module.h and remove duplicate definitions. Co-developed-by: Claude Opus 4.5 <noreply@anthropic.com> Signed-off-by: Simon Glass <simon.glass@canonical.com>
38 lines
970 B
C
38 lines
970 B
C
/* SPDX-License-Identifier: GPL-2.0-only */
|
|
/*
|
|
* Dynamic loading of modules into the kernel.
|
|
*
|
|
* Rewritten by Richard Henderson <rth@tamu.edu> Dec 1996
|
|
* Rewritten again by Rusty Russell, 2002
|
|
*
|
|
* Stub definitions for Linux kernel module support.
|
|
* U-Boot doesn't use loadable modules.
|
|
*/
|
|
#ifndef _LINUX_MODULE_H
|
|
#define _LINUX_MODULE_H
|
|
|
|
struct module;
|
|
|
|
#define THIS_MODULE 0
|
|
#define try_module_get(...) 1
|
|
#define module_put(...) do { } while (0)
|
|
#define __module_get(...) do { } while (0)
|
|
|
|
#define module_init(fn)
|
|
#define module_exit(fn)
|
|
|
|
#define module_param(name, type, perm)
|
|
#define module_param_call(name, set, get, arg, perm)
|
|
#define module_param_named(name, var, type, perm)
|
|
|
|
#define MODULE_PARM_DESC(name, desc)
|
|
#define MODULE_VERSION(ver)
|
|
#define MODULE_DESCRIPTION(desc)
|
|
#define MODULE_AUTHOR(author)
|
|
#define MODULE_LICENSE(license)
|
|
#define MODULE_ALIAS(alias)
|
|
#define MODULE_SOFTDEP(dep)
|
|
#define MODULE_INFO(tag, info)
|
|
|
|
#endif /* _LINUX_MODULE_H */
|