1 #ifndef _LINUX_PROC_FS_H
2 #define _LINUX_PROC_FS_H
3
4 #include <linux/config.h>
5 #include <linux/fs.h>
6
7
8
9
10
11 enum root_directory_inos {
12 PROC_ROOT_INO = 1,
13 PROC_LOADAVG,
14 PROC_UPTIME,
15 PROC_MEMINFO,
16 PROC_KMSG,
17 PROC_VERSION,
18 PROC_CPUINFO,
19 PROC_PCI,
20 PROC_SELF,
21 PROC_NET,
22 PROC_SCSI,
23 #ifdef CONFIG_DEBUG_MALLOC
24 PROC_MALLOC,
25 #endif
26 PROC_KCORE,
27 PROC_MODULES,
28 PROC_STAT,
29 PROC_DEVICES,
30 PROC_INTERRUPTS,
31 PROC_FILESYSTEMS,
32 PROC_KSYMS,
33 PROC_DMA,
34 PROC_IOPORTS,
35 PROC_PROFILE
36 };
37
38 enum pid_directory_inos {
39 PROC_PID_INO = 2,
40 PROC_PID_MEM,
41 PROC_PID_CWD,
42 PROC_PID_ROOT,
43 PROC_PID_EXE,
44 PROC_PID_FD,
45 PROC_PID_ENVIRON,
46 PROC_PID_CMDLINE,
47 PROC_PID_STAT,
48 PROC_PID_STATM,
49 PROC_PID_MAPS
50 };
51
52 enum pid_subdirectory_inos {
53 PROC_PID_FD_DIR = 1
54 };
55
56 enum net_directory_inos {
57 PROC_NET_UNIX = 128,
58 #ifdef CONFIG_INET
59 PROC_NET_ARP,
60 PROC_NET_ROUTE,
61 PROC_NET_DEV,
62 PROC_NET_RAW,
63 PROC_NET_TCP,
64 PROC_NET_UDP,
65 PROC_NET_SNMP,
66 #ifdef CONFIG_INET_RARP
67 PROC_NET_RARP,
68 #endif
69 #ifdef CONFIG_IP_MULTICAST
70 PROC_NET_IGMP,
71 #endif
72 #ifdef CONFIG_IP_FIREWALL
73 PROC_NET_IPFWFWD,
74 PROC_NET_IPFWBLK,
75 #endif
76 #ifdef CONFIG_IP_ACCT
77 PROC_NET_IPACCT,
78 #endif
79 #ifdef CONFIG_IP_MASQUERADE
80 PROC_NET_IPMSQHST,
81 #endif
82 #if defined(CONFIG_WAVELAN)
83 PROC_NET_WAVELAN,
84 #endif
85 #endif
86 #ifdef CONFIG_IPX
87 PROC_NET_IPX_INTERFACE,
88 PROC_NET_IPX_ROUTE,
89 PROC_NET_IPX,
90 #endif
91 #ifdef CONFIG_ATALK
92 PROC_NET_ATALK,
93 PROC_NET_AT_ROUTE,
94 PROC_NET_ATIF,
95 #endif
96 #ifdef CONFIG_AX25
97 PROC_NET_AX25_ROUTE,
98 PROC_NET_AX25,
99 #ifdef CONFIG_NETROM
100 PROC_NET_NR_NODES,
101 PROC_NET_NR_NEIGH,
102 PROC_NET_NR,
103 #endif
104 #endif
105 PROC_NET_SOCKSTAT,
106 PROC_NET_LAST
107 };
108
109 enum scsi_directory_inos {
110 PROC_SCSI_SCSI = 256,
111 PROC_SCSI_EATA,
112 PROC_SCSI_EATA_PIO,
113 PROC_SCSI_AHA152X,
114 PROC_SCSI_AHA1542,
115 PROC_SCSI_AHA1740,
116 PROC_SCSI_AIC7XXX,
117 PROC_SCSI_BUSLOGIC,
118 PROC_SCSI_U14_34F,
119 PROC_SCSI_FUTURE_DOMAIN,
120 PROC_SCSI_GENERIC_NCR5380,
121 PROC_SCSI_IN2000,
122 PROC_SCSI_PAS16,
123 PROC_SCSI_QLOGIC,
124 PROC_SCSI_SEAGATE,
125 PROC_SCSI_T128,
126 PROC_SCSI_NCR53C7xx,
127 PROC_SCSI_ULTRASTOR,
128 PROC_SCSI_7000FASST,
129 PROC_SCSI_SCSI_DEBUG,
130 PROC_SCSI_NOT_PRESENT,
131 PROC_SCSI_FILE,
132 PROC_SCSI_LAST = (PROC_SCSI_FILE + 16)
133 };
134
135 #define PROC_SUPER_MAGIC 0x9fa0
136
137 struct proc_dir_entry {
138 unsigned short low_ino;
139 unsigned short namelen;
140 char * name;
141 };
142
143 extern struct super_block *proc_read_super(struct super_block *,void *,int);
144 extern void proc_put_inode(struct inode *);
145 extern void proc_put_super(struct super_block *);
146 extern void proc_statfs(struct super_block *, struct statfs *, int);
147 extern void proc_read_inode(struct inode *);
148 extern void proc_write_inode(struct inode *);
149 extern int proc_match(int, const char *, struct proc_dir_entry *);
150
151 extern struct inode_operations proc_root_inode_operations;
152 extern struct inode_operations proc_base_inode_operations;
153 extern struct inode_operations proc_net_inode_operations;
154 extern struct inode_operations proc_scsi_inode_operations;
155 extern struct inode_operations proc_mem_inode_operations;
156 extern struct inode_operations proc_array_inode_operations;
157 extern struct inode_operations proc_arraylong_inode_operations;
158 extern struct inode_operations proc_kcore_inode_operations;
159 extern struct inode_operations proc_profile_inode_operations;
160 extern struct inode_operations proc_kmsg_inode_operations;
161 extern struct inode_operations proc_link_inode_operations;
162 extern struct inode_operations proc_fd_inode_operations;
163
164 #endif