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.
5 .\" 2006-02-09, some reformatting by Luc Van Oostenryck; some
6 .\" reformatting and rewordings by mtk
8 .\" Japanese Version Copyright (c) 2006 Akihiro MOTOKI all rights reserved.
9 .\" Translated 2006-07-31, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>
11 .TH GET_KERNEL_SYMS 2 2007-06-03 "Linux" "Linux Programmer's Manual"
14 .\"O get_kernel_syms \- retrieve exported kernel and module symbols
15 get_kernel_syms \- 公開されているカーネルやモジュールのシンボルの取得
19 .B #include <linux/module.h>
21 .BI "int get_kernel_syms(struct kernel_sym *" table );
28 .\"O .BR get_kernel_syms ()
29 .\"O returns the number of symbols available for query.
30 .\"O Otherwise it fills in a table of structures:
31 .BR get_kernel_syms ()
36 NULL 以外の場合、以下の構造体の列 (table) に値を入れて返す。
47 .\"O The symbols are interspersed with magic symbols of the form
48 .\"O .BI # module-name
49 .\"O with the kernel having an empty name.
50 .\"O The value associated with a symbol of this form is the address at
51 .\"O which the module is loaded.
54 という形式の、カーネルが空の名前を持っているマジックシンボル
55 (magic symbol) が散在している。この形式のシンボルに対応する値は
58 .\"O The symbols exported from each module follow their magic module tag
59 .\"O and the modules are returned in the reverse of the
60 .\"O order in which they were loaded.
61 個々のモジュールから公開 (export) されたシンボルは、マジックモジュールタグ
62 の後ろに置かれる。また、モジュールはロードされた順番とは逆順で返される。
63 .\"O .SH "RETURN VALUE"
65 .\"O On success, returns the number of symbols copied to
67 .\"O On error, \-1 is returned and
69 .\"O is set appropriately.
78 .\"O There is only one possible error return:
82 .\"O .BR get_kernel_syms ()
83 .\"O is not supported in this version of the kernel.
84 .BR get_kernel_syms ()
85 がこのバージョンのカーネルではサポートされていない。
88 .\"O This system call is only present on Linux up until kernel 2.4;
89 .\"O it was removed in Linux 2.6.
90 このシステムコールが存在するのはカーネル 2.4 までの Linux だけである。
92 .\" Removed in Linux 2.5.48
93 .\"O .SH "CONFORMING TO"
95 .\"O .BR get_kernel_syms ()
96 .\"O is Linux-specific.
97 .BR get_kernel_syms ()
101 .\"O There is no way to indicate the size of the buffer allocated for
103 .\"O If symbols have been added to the kernel since the
104 .\"O program queried for the symbol table size, memory will be corrupted.
106 用に確保したバッファの大きさを伝える方法がない。
107 プログラムがシンボルテーブルの大きさを問い合わせた後に、カーネルに
108 シンボルが追加されると、メモリの内容が破壊されることになる。
110 .\"O The length of exported symbol names is limited to 59 characters.
111 公開されるシンボル名の長さが 59 文字に制限されている。
113 .\"O Because of these limitations, this system call is deprecated in
115 .\"O .BR query_module (2)
116 .\"O (which is itself nowadays deprecated
117 .\"O in favor of other interfaces described on its manual page).
118 これらの制限があるので、このシステムコールを使うよりは
123 自身もそのマニュアルページに書かれているように
124 他のインタフェースを使うのが望ましいとされている)。
127 .BR create_module (2),
128 .BR delete_module (2),