OSDN Git Service

(split) Import translated manuals from JM CVS Repository.
[linuxjm/LDP_man-pages.git] / release / man2 / init_module.2
1 .\" Copyright (C) 1996 Free Software Foundation, Inc.
2 .\" This file is distributed according to the GNU General Public License.
3 .\" See the file COPYING in the top level source directory for details.
4 .\"
5 .\" 2006-02-09, some reformatting by Luc Van Oostenryck; some
6 .\" reformatting and rewordings by mtk
7 .\"
8 .\" Japanese Version Copyright (c) 2006 Akihiro MOTOKI all rights reserved.
9 .\" Translated 2006-07-29, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>
10 .\"
11 .TH INIT_MODULE 2 2006-02-09 "Linux" "Linux Programmer's Manual"
12 .SH Ì¾Á°
13 init_module \- ¥í¡¼¥À¥Ö¥ë¥â¥¸¥å¡¼¥ë¤Î¥¨¥ó¥È¥ê¤ò½é´ü²½¤¹¤ë
14 .SH ½ñ¼°
15 .nf
16 .B #include <linux/module.h>
17 .sp
18 .BI "int init_module(const char *" name ", struct module *" image );
19 .fi
20 .SH ÀâÌÀ
21 .BR init_module ()
22 ¤ÏºÆÇÛÃÖ¤µ¤ì¤¿¥â¥¸¥å¡¼¥ë¥¤¥á¡¼¥¸¤ò¥«¡¼¥Í¥ë¶õ´Ö¤Ë¥í¡¼¥É¤·¡¢
23 ¤½¤Î¥â¥¸¥å¡¼¥ë¤Î
24 .I init
25 ´Ø¿ô¤ò¼Â¹Ô¤¹¤ë¡£
26 .PP
27 ¥â¥¸¥å¡¼¥ë¥¤¥á¡¼¥¸¤ÏÀèƬÉôʬ¤Ë module ¹½Â¤ÂΤ¬¤¢¤ê¡¢¤½¤Î¸å¤í¤Ë
28 ŬÀڤʥ³¡¼¥É¤È¥Ç¡¼¥¿¤¬Â³¤¯¡£
29 ¤³¤Î module ¹½Â¤ÂΤϰʲ¼¤Î¤è¤¦¤ËÄêµÁ¤µ¤ì¤Æ¤¤¤ë:
30 .PP
31 .in +4n
32 .nf
33 struct module {
34     unsigned long         size_of_struct;
35     struct module        *next;
36     const char           *name;
37     unsigned long         size;
38     long                  usecount;
39     unsigned long         flags;
40     unsigned int          nsyms;
41     unsigned int          ndeps;
42     struct module_symbol *syms;
43     struct module_ref    *deps;
44     struct module_ref    *refs;
45     int                 (*init)(void);
46     void                (*cleanup)(void);
47     const struct exception_table_entry *ex_table_start;
48     const struct exception_table_entry *ex_table_end;
49 #ifdef __alpha__
50     unsigned long gp;
51 #endif
52 };
53 .fi
54 .in
55 .PP
56 .I next
57 ¤È
58 .I refs
59 °Ê³°¤ÎÁ´¤Æ¤Î¥Ý¥¤¥ó¥¿Í×ÁǤϥ⥸¥å¡¼¥ëËÜÂÎÆâÉô¤ò»Ø¤·¡¢
60 ¥«¡¼¥Í¥ë¶õ´Ö¤Ç¤ÎŬÀÚ¤ÊÃͤǽé´ü²½¤µ¤ì¤ë (¤Ä¤Þ¤ê¡¢¥â¥¸¥å¡¼¥ë¤Î»Ä¤ê¤Î
61 Éôʬ¤ÇºÆÇÛÃÖ¤µ¤ì¤ë) ¤³¤È¤¬´üÂÔ¤µ¤ì¤ë¡£
62 .PP
63 ¤³¤Î¥·¥¹¥Æ¥à¥³¡¼¥ë¤ò»È¤¦¤Ë¤ÏÆø¢¤¬É¬ÍפǤ¢¤ë¡£
64 .SH ÊÖ¤êÃÍ
65 À®¸ù¤¹¤ë¤È 0 ¤òÊÖ¤¹¡£¥¨¥é¡¼¤Î¾ì¹ç \-1 ¤òÊÖ¤·¡¢
66 .I errno
67 ¤òŬÀÚ¤ËÀßÄꤹ¤ë¡£
68 .SH ¥¨¥é¡¼
69 .TP
70 .B EBUSY
71 ¥â¥¸¥å¡¼¥ë¤Î½é´ü²½¥ë¡¼¥Á¥ó¤¬¼ºÇÔ¤·¤¿¡£
72 .TP
73 .B EFAULT
74 .I name
75 ¤ä
76 .I image
77 ¤¬¥×¥í¥°¥é¥à¤¬¥¢¥¯¥»¥¹¤Ç¤­¤ë¥¢¥É¥ì¥¹¶õ´Ö¤Î³°Éô¤Ë¤¢¤ë¡£
78 .TP
79 .B EINVAL
80 °ìÉô¤Î
81 .I image
82 ¥¹¥í¥Ã¥È¤Ë¤ª¤«¤·¤ÊÃͤ¬Æþ¤Ã¤Æ¤¤¤ë¡£¤Þ¤¿¤Ï
83 .I image\->name
84 ¤¬¸µ¤Î¥â¥¸¥å¡¼¥ë̾¤È°ìÃפ·¤Æ¤¤¤Ê¤¤¡£¤Þ¤¿¤Ï¡¢°ìÉô¤Î
85 .I image\->deps
86 ¥¨¥ó¥È¥ê¤¬¥í¡¼¥É¤µ¤ì¤¿¥â¥¸¥å¡¼¥ë¤ËÂбþ¤·¤Æ¤¤¤Ê¤¤¡£
87 ¤Þ¤¿¤Ï¡¢Â¾¤ËƱÍͤÎÌ·½â¤¬µ¯¤³¤Ã¤Æ¤¤¤ë¡£
88 .TP
89 .B ENOENT
90 ¤½¤Î̾Á°¤Î¥â¥¸¥å¡¼¥ë¤¬Â¸ºß¤·¤Ê¤¤¡£
91 .TP
92 .B EPERM
93 ¸Æ¤Ó½Ð¤·¸µ¤¬Æø¢
94 .RB ( CAP_SYS_MODULE
95 ¥±¡¼¥Ñ¥Ó¥ê¥Æ¥£) ¤ò»ý¤Ã¤Æ¤¤¤Ê¤«¤Ã¤¿¡£
96 .SH ½àµò
97 .BR init_module ()
98 ¤Ï Linux ¸ÇÍ­¤Ç¤¢¤ë¡£
99 .SH ´ØÏ¢¹àÌÜ
100 .BR create_module (2),
101 .BR delete_module (2),
102 .BR query_module (2)