source: GPL/trunk/include/linux/module.h@ 598

Last change on this file since 598 was 598, checked in by David Azarewicz, 8 years ago

Merged/reintegrated v2 branch into trunk. Trunk is now v2

File size: 2.0 KB
Line 
1/*
2 * Dynamic loading of modules into the kernel.
3 *
4 * Rewritten by Richard Henderson <rth@tamu.edu> Dec 1996
5 */
6
7#ifndef _LINUX_MODULE_H
8#define _LINUX_MODULE_H
9
10/* Poke the use count of a module. */
11
12#define __MOD_DEC_USE_COUNT(mod) \
13 do {} while(0);
14
15#define MOD_INC_USE_COUNT
16#define MOD_DEC_USE_COUNT
17#define MOD_IN_USE
18
19#define EXPORT_NO_SYMBOLS
20
21#define __MODULE_STRING_1(x) #x
22#define __MODULE_STRING(x) __MODULE_STRING_1(x)
23
24/* For documentation purposes only. */
25
26#define MODULE_AUTHOR(name)
27
28#define MODULE_DESCRIPTION(desc)
29
30/* Could potentially be used by kmod... */
31
32#define MODULE_SUPPORTED_DEVICE(dev)
33
34/* Used to verify parameters given to the module. The TYPE arg should
35 be a string in the following format:
36 [min[-max]]{b,h,i,l,s}
37 The MIN and MAX specifiers delimit the length of the array. If MAX
38 is omitted, it defaults to MIN; if both are omitted, the default is 1.
39 The final character is a type specifier:
40 b byte
41 h short
42 i int
43 l long
44 s string
45*/
46
47#ifdef TARGET_OS2
48#define MODULE_PARM(var,type)
49#define MODULE_PARM_DESC(var,desc)
50#define MODULE_LICENSE(a)
51#define EXPORT_SYMBOL_GPL(a)
52#else
53#define MODULE_PARM(var,type) \
54const char __module_parm_##var[]= \
55"parm_" __MODULE_STRING(var) "=" type
56
57#define MODULE_PARM_DESC(var,desc) \
58const char __module_parm_desc_##var[]= \
59"parm_desc_" __MODULE_STRING(var) "=" desc
60#endif
61
62#define try_inc_mod_count(x) ++(*(unsigned long *)x)
63#define try_module_get(x) try_inc_mod_count(x)
64static inline void module_put(struct module *module)
65{
66 if (module)
67 do {} while(0);
68}
69
70#define MODULE_FIRMWARE(x)
71#define MODULE_ALIAS(x)
72
73extern int this_module[64];
74#define THIS_MODULE (void *)&this_module[0]
75#define MODULE_GENERIC_TABLE(gtype,name)
76#define MODULE_DEVICE_TABLE(type,name)
77#define EXPORT_SYMBOL(a)
78#define MODULE_ALIAS_CHARDEV(x)
79#define module_param(name, type, perm)
80#endif /* _LINUX_MODULE_H */
Note: See TracBrowser for help on using the repository browser.