diff options
Diffstat (limited to 'include/linux')
70 files changed, 874 insertions, 1730 deletions
diff --git a/include/linux/Kbuild b/include/linux/Kbuild index 9f05279e7dd3..94cc04a143f2 100644 --- a/include/linux/Kbuild +++ b/include/linux/Kbuild | |||
@@ -4,6 +4,7 @@ header-y += hdlc/ | |||
4 | header-y += isdn/ | 4 | header-y += isdn/ |
5 | header-y += nfsd/ | 5 | header-y += nfsd/ |
6 | header-y += raid/ | 6 | header-y += raid/ |
7 | header-y += spi/ | ||
7 | header-y += sunrpc/ | 8 | header-y += sunrpc/ |
8 | header-y += tc_act/ | 9 | header-y += tc_act/ |
9 | header-y += netfilter/ | 10 | header-y += netfilter/ |
@@ -33,7 +34,6 @@ header-y += atmsvc.h | |||
33 | header-y += atm_zatm.h | 34 | header-y += atm_zatm.h |
34 | header-y += auto_fs4.h | 35 | header-y += auto_fs4.h |
35 | header-y += auxvec.h | 36 | header-y += auxvec.h |
36 | header-y += awe_voice.h | ||
37 | header-y += ax25.h | 37 | header-y += ax25.h |
38 | header-y += b1lli.h | 38 | header-y += b1lli.h |
39 | header-y += baycom.h | 39 | header-y += baycom.h |
@@ -46,6 +46,7 @@ header-y += coda_psdev.h | |||
46 | header-y += coff.h | 46 | header-y += coff.h |
47 | header-y += comstats.h | 47 | header-y += comstats.h |
48 | header-y += consolemap.h | 48 | header-y += consolemap.h |
49 | header-y += const.h | ||
49 | header-y += cycx_cfm.h | 50 | header-y += cycx_cfm.h |
50 | header-y += dlm_device.h | 51 | header-y += dlm_device.h |
51 | header-y += dm-ioctl.h | 52 | header-y += dm-ioctl.h |
@@ -91,7 +92,6 @@ header-y += ip_mp_alg.h | |||
91 | header-y += ipsec.h | 92 | header-y += ipsec.h |
92 | header-y += ipx.h | 93 | header-y += ipx.h |
93 | header-y += irda.h | 94 | header-y += irda.h |
94 | header-y += isdn_divertif.h | ||
95 | header-y += iso_fs.h | 95 | header-y += iso_fs.h |
96 | header-y += ixjuser.h | 96 | header-y += ixjuser.h |
97 | header-y += jffs2.h | 97 | header-y += jffs2.h |
@@ -121,6 +121,7 @@ header-y += pci_regs.h | |||
121 | header-y += personality.h | 121 | header-y += personality.h |
122 | header-y += pfkeyv2.h | 122 | header-y += pfkeyv2.h |
123 | header-y += pg.h | 123 | header-y += pg.h |
124 | header-y += phantom.h | ||
124 | header-y += pkt_cls.h | 125 | header-y += pkt_cls.h |
125 | header-y += pkt_sched.h | 126 | header-y += pkt_sched.h |
126 | header-y += posix_types.h | 127 | header-y += posix_types.h |
@@ -140,6 +141,7 @@ header-y += sockios.h | |||
140 | header-y += som.h | 141 | header-y += som.h |
141 | header-y += sound.h | 142 | header-y += sound.h |
142 | header-y += synclink.h | 143 | header-y += synclink.h |
144 | header-y += taskstats.h | ||
143 | header-y += telephony.h | 145 | header-y += telephony.h |
144 | header-y += termios.h | 146 | header-y += termios.h |
145 | header-y += ticable.h | 147 | header-y += ticable.h |
@@ -239,6 +241,7 @@ unifdef-y += ipv6.h | |||
239 | unifdef-y += ipv6_route.h | 241 | unifdef-y += ipv6_route.h |
240 | unifdef-y += isdn.h | 242 | unifdef-y += isdn.h |
241 | unifdef-y += isdnif.h | 243 | unifdef-y += isdnif.h |
244 | unifdef-y += isdn_divertif.h | ||
242 | unifdef-y += isdn_ppp.h | 245 | unifdef-y += isdn_ppp.h |
243 | unifdef-y += isicom.h | 246 | unifdef-y += isicom.h |
244 | unifdef-y += jbd.h | 247 | unifdef-y += jbd.h |
diff --git a/include/linux/awe_voice.h b/include/linux/awe_voice.h deleted file mode 100644 index bf33f17bea99..000000000000 --- a/include/linux/awe_voice.h +++ /dev/null | |||
@@ -1,525 +0,0 @@ | |||
1 | /* | ||
2 | * include/linux/awe_voice.h | ||
3 | * | ||
4 | * Voice information definitions for the low level driver for the | ||
5 | * AWE32/SB32/AWE64 wave table synth. | ||
6 | * version 0.4.4; Jan. 4, 2000 | ||
7 | * | ||
8 | * Copyright (C) 1996-2000 Takashi Iwai | ||
9 | * | ||
10 | * This program is free software; you can redistribute it and/or modify | ||
11 | * it under the terms of the GNU General Public License as published by | ||
12 | * the Free Software Foundation; either version 2 of the License, or | ||
13 | * (at your option) any later version. | ||
14 | * | ||
15 | * This program is distributed in the hope that it will be useful, | ||
16 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
17 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
18 | * GNU General Public License for more details. | ||
19 | * | ||
20 | * You should have received a copy of the GNU General Public License | ||
21 | * along with this program; if not, write to the Free Software | ||
22 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | ||
23 | */ | ||
24 | |||
25 | #ifndef AWE_VOICE_H | ||
26 | #define AWE_VOICE_H | ||
27 | |||
28 | #ifndef SAMPLE_TYPE_AWE32 | ||
29 | #define SAMPLE_TYPE_AWE32 0x20 | ||
30 | #endif | ||
31 | |||
32 | #define _LINUX_PATCHKEY_H_INDIRECT | ||
33 | #include <linux/patchkey.h> | ||
34 | #undef _LINUX_PATCHKEY_H_INDIRECT | ||
35 | |||
36 | /*---------------------------------------------------------------- | ||
37 | * patch information record | ||
38 | *----------------------------------------------------------------*/ | ||
39 | |||
40 | /* patch interface header: 16 bytes */ | ||
41 | typedef struct awe_patch_info { | ||
42 | short key; /* use AWE_PATCH here */ | ||
43 | #define AWE_PATCH _PATCHKEY(0x07) | ||
44 | |||
45 | short device_no; /* synthesizer number */ | ||
46 | unsigned short sf_id; /* file id (should be zero) */ | ||
47 | short optarg; /* optional argument */ | ||
48 | int len; /* data length (without this header) */ | ||
49 | |||
50 | short type; /* patch operation type */ | ||
51 | #define AWE_LOAD_INFO 0 /* awe_voice_rec */ | ||
52 | #define AWE_LOAD_DATA 1 /* awe_sample_info */ | ||
53 | #define AWE_OPEN_PATCH 2 /* awe_open_parm */ | ||
54 | #define AWE_CLOSE_PATCH 3 /* none */ | ||
55 | #define AWE_UNLOAD_PATCH 4 /* none */ | ||
56 | #define AWE_REPLACE_DATA 5 /* awe_sample_info (optarg=#channels)*/ | ||
57 | #define AWE_MAP_PRESET 6 /* awe_voice_map */ | ||
58 | /*#define AWE_PROBE_INFO 7*/ /* awe_voice_map (pat only) */ | ||
59 | #define AWE_PROBE_DATA 8 /* optarg=sample */ | ||
60 | #define AWE_REMOVE_INFO 9 /* optarg=(bank<<8)|instr */ | ||
61 | #define AWE_LOAD_CHORUS_FX 0x10 /* awe_chorus_fx_rec (optarg=mode) */ | ||
62 | #define AWE_LOAD_REVERB_FX 0x11 /* awe_reverb_fx_rec (optarg=mode) */ | ||
63 | |||
64 | short reserved; /* word alignment data */ | ||
65 | |||
66 | /* the actual patch data begins after this */ | ||
67 | #if defined(AWE_COMPAT_030) && AWE_COMPAT_030 | ||
68 | char data[0]; | ||
69 | #endif | ||
70 | } awe_patch_info; | ||
71 | |||
72 | /*#define AWE_PATCH_INFO_SIZE 16*/ | ||
73 | #define AWE_PATCH_INFO_SIZE sizeof(awe_patch_info) | ||
74 | |||
75 | |||
76 | /*---------------------------------------------------------------- | ||
77 | * open patch | ||
78 | *----------------------------------------------------------------*/ | ||
79 | |||
80 | #define AWE_PATCH_NAME_LEN 32 | ||
81 | |||
82 | typedef struct _awe_open_parm { | ||
83 | unsigned short type; /* sample type */ | ||
84 | #define AWE_PAT_TYPE_MISC 0 | ||
85 | #define AWE_PAT_TYPE_GM 1 | ||
86 | #define AWE_PAT_TYPE_GS 2 | ||
87 | #define AWE_PAT_TYPE_MT32 3 | ||
88 | #define AWE_PAT_TYPE_XG 4 | ||
89 | #define AWE_PAT_TYPE_SFX 5 | ||
90 | #define AWE_PAT_TYPE_GUS 6 | ||
91 | #define AWE_PAT_TYPE_MAP 7 | ||
92 | |||
93 | #define AWE_PAT_LOCKED 0x100 /* lock the samples */ | ||
94 | #define AWE_PAT_SHARED 0x200 /* sample is shared */ | ||
95 | |||
96 | short reserved; | ||
97 | char name[AWE_PATCH_NAME_LEN]; | ||
98 | } awe_open_parm; | ||
99 | |||
100 | /*#define AWE_OPEN_PARM_SIZE 28*/ | ||
101 | #define AWE_OPEN_PARM_SIZE sizeof(awe_open_parm) | ||
102 | |||
103 | |||
104 | /*---------------------------------------------------------------- | ||
105 | * raw voice information record | ||
106 | *----------------------------------------------------------------*/ | ||
107 | |||
108 | /* wave table envelope & effect parameters to control EMU8000 */ | ||
109 | typedef struct _awe_voice_parm { | ||
110 | unsigned short moddelay; /* modulation delay (0x8000) */ | ||
111 | unsigned short modatkhld; /* modulation attack & hold time (0x7f7f) */ | ||
112 | unsigned short moddcysus; /* modulation decay & sustain (0x7f7f) */ | ||
113 | unsigned short modrelease; /* modulation release time (0x807f) */ | ||
114 | short modkeyhold, modkeydecay; /* envelope change per key (not used) */ | ||
115 | unsigned short voldelay; /* volume delay (0x8000) */ | ||
116 | unsigned short volatkhld; /* volume attack & hold time (0x7f7f) */ | ||
117 | unsigned short voldcysus; /* volume decay & sustain (0x7f7f) */ | ||
118 | unsigned short volrelease; /* volume release time (0x807f) */ | ||
119 | short volkeyhold, volkeydecay; /* envelope change per key (not used) */ | ||
120 | unsigned short lfo1delay; /* LFO1 delay (0x8000) */ | ||
121 | unsigned short lfo2delay; /* LFO2 delay (0x8000) */ | ||
122 | unsigned short pefe; /* modulation pitch & cutoff (0x0000) */ | ||
123 | unsigned short fmmod; /* LFO1 pitch & cutoff (0x0000) */ | ||
124 | unsigned short tremfrq; /* LFO1 volume & freq (0x0000) */ | ||
125 | unsigned short fm2frq2; /* LFO2 pitch & freq (0x0000) */ | ||
126 | unsigned char cutoff; /* initial cutoff (0xff) */ | ||
127 | unsigned char filterQ; /* initial filter Q [0-15] (0x0) */ | ||
128 | unsigned char chorus; /* chorus send (0x00) */ | ||
129 | unsigned char reverb; /* reverb send (0x00) */ | ||
130 | unsigned short reserved[4]; /* not used */ | ||
131 | } awe_voice_parm; | ||
132 | |||
133 | typedef struct _awe_voice_parm_block { | ||
134 | unsigned short moddelay; /* modulation delay (0x8000) */ | ||
135 | unsigned char modatk, modhld; | ||
136 | unsigned char moddcy, modsus; | ||
137 | unsigned char modrel, moddummy; | ||
138 | short modkeyhold, modkeydecay; /* envelope change per key (not used) */ | ||
139 | unsigned short voldelay; /* volume delay (0x8000) */ | ||
140 | unsigned char volatk, volhld; | ||
141 | unsigned char voldcy, volsus; | ||
142 | unsigned char volrel, voldummy; | ||
143 | short volkeyhold, volkeydecay; /* envelope change per key (not used) */ | ||
144 | unsigned short lfo1delay; /* LFO1 delay (0x8000) */ | ||
145 | unsigned short lfo2delay; /* LFO2 delay (0x8000) */ | ||
146 | unsigned char env1fc, env1pit; | ||
147 | unsigned char lfo1fc, lfo1pit; | ||
148 | unsigned char lfo1freq, lfo1vol; | ||
149 | unsigned char lfo2freq, lfo2pit; | ||
150 | unsigned char cutoff; /* initial cutoff (0xff) */ | ||
151 | unsigned char filterQ; /* initial filter Q [0-15] (0x0) */ | ||
152 | unsigned char chorus; /* chorus send (0x00) */ | ||
153 | unsigned char reverb; /* reverb send (0x00) */ | ||
154 | unsigned short reserved[4]; /* not used */ | ||
155 | } awe_voice_parm_block; | ||
156 | |||
157 | #define AWE_VOICE_PARM_SIZE 48 | ||
158 | |||
159 | |||
160 | /* wave table parameters: 92 bytes */ | ||
161 | typedef struct _awe_voice_info { | ||
162 | unsigned short sf_id; /* file id (should be zero) */ | ||
163 | unsigned short sample; /* sample id */ | ||
164 | int start, end; /* sample offset correction */ | ||
165 | int loopstart, loopend; /* loop offset correction */ | ||
166 | short rate_offset; /* sample rate pitch offset */ | ||
167 | unsigned short mode; /* sample mode */ | ||
168 | #define AWE_MODE_ROMSOUND 0x8000 | ||
169 | #define AWE_MODE_STEREO 1 | ||
170 | #define AWE_MODE_LOOPING 2 | ||
171 | #define AWE_MODE_NORELEASE 4 /* obsolete */ | ||
172 | #define AWE_MODE_INIT_PARM 8 | ||
173 | |||
174 | short root; /* midi root key */ | ||
175 | short tune; /* pitch tuning (in cents) */ | ||
176 | signed char low, high; /* key note range */ | ||
177 | signed char vellow, velhigh; /* velocity range */ | ||
178 | signed char fixkey, fixvel; /* fixed key, velocity */ | ||
179 | signed char pan, fixpan; /* panning, fixed panning */ | ||
180 | short exclusiveClass; /* exclusive class (0 = none) */ | ||
181 | unsigned char amplitude; /* sample volume (127 max) */ | ||
182 | unsigned char attenuation; /* attenuation (0.375dB) */ | ||
183 | short scaleTuning; /* pitch scale tuning(%), normally 100 */ | ||
184 | awe_voice_parm parm; /* voice envelope parameters */ | ||
185 | short index; /* internal index (set by driver) */ | ||
186 | } awe_voice_info; | ||
187 | |||
188 | /*#define AWE_VOICE_INFO_SIZE 92*/ | ||
189 | #define AWE_VOICE_INFO_SIZE sizeof(awe_voice_info) | ||
190 | |||
191 | /*----------------------------------------------------------------*/ | ||
192 | |||
193 | /* The info entry of awe_voice_rec is changed from 0 to 1 | ||
194 | * for some compilers refusing zero size array. | ||
195 | * Due to this change, sizeof(awe_voice_rec) becomes different | ||
196 | * from older versions. | ||
197 | * Use AWE_VOICE_REC_SIZE instead. | ||
198 | */ | ||
199 | |||
200 | /* instrument info header: 4 bytes */ | ||
201 | typedef struct _awe_voice_rec_hdr { | ||
202 | unsigned char bank; /* midi bank number */ | ||
203 | unsigned char instr; /* midi preset number */ | ||
204 | char nvoices; /* number of voices */ | ||
205 | char write_mode; /* write mode; normally 0 */ | ||
206 | #define AWE_WR_APPEND 0 /* append anyway */ | ||
207 | #define AWE_WR_EXCLUSIVE 1 /* skip if already exists */ | ||
208 | #define AWE_WR_REPLACE 2 /* replace if already exists */ | ||
209 | } awe_voice_rec_hdr; | ||
210 | |||
211 | /*#define AWE_VOICE_REC_SIZE 4*/ | ||
212 | #define AWE_VOICE_REC_SIZE sizeof(awe_voice_rec_hdr) | ||
213 | |||
214 | /* the standard patch structure for one sample */ | ||
215 | typedef struct _awe_voice_rec_patch { | ||
216 | awe_patch_info patch; | ||
217 | awe_voice_rec_hdr hdr; | ||
218 | awe_voice_info info; | ||
219 | } awe_voice_rec_patch; | ||
220 | |||
221 | |||
222 | /* obsolete data type */ | ||
223 | #if defined(AWE_COMPAT_030) && AWE_COMPAT_030 | ||
224 | #define AWE_INFOARRAY_SIZE 0 | ||
225 | #else | ||
226 | #define AWE_INFOARRAY_SIZE 1 | ||
227 | #endif | ||
228 | |||
229 | typedef struct _awe_voice_rec { | ||
230 | unsigned char bank; /* midi bank number */ | ||
231 | unsigned char instr; /* midi preset number */ | ||
232 | short nvoices; /* number of voices */ | ||
233 | /* voice information follows here */ | ||
234 | awe_voice_info info[AWE_INFOARRAY_SIZE]; | ||
235 | } awe_voice_rec; | ||
236 | |||
237 | |||
238 | /*---------------------------------------------------------------- | ||
239 | * sample wave information | ||
240 | *----------------------------------------------------------------*/ | ||
241 | |||
242 | /* wave table sample header: 32 bytes */ | ||
243 | typedef struct awe_sample_info { | ||
244 | unsigned short sf_id; /* file id (should be zero) */ | ||
245 | unsigned short sample; /* sample id */ | ||
246 | int start, end; /* start & end offset */ | ||
247 | int loopstart, loopend; /* loop start & end offset */ | ||
248 | int size; /* size (0 = ROM) */ | ||
249 | short checksum_flag; /* use check sum = 1 */ | ||
250 | unsigned short mode_flags; /* mode flags */ | ||
251 | #define AWE_SAMPLE_8BITS 1 /* wave data is 8bits */ | ||
252 | #define AWE_SAMPLE_UNSIGNED 2 /* wave data is unsigned */ | ||
253 | #define AWE_SAMPLE_NO_BLANK 4 /* no blank loop is attached */ | ||
254 | #define AWE_SAMPLE_SINGLESHOT 8 /* single-shot w/o loop */ | ||
255 | #define AWE_SAMPLE_BIDIR_LOOP 16 /* bidirectional looping */ | ||
256 | #define AWE_SAMPLE_STEREO_LEFT 32 /* stereo left sound */ | ||
257 | #define AWE_SAMPLE_STEREO_RIGHT 64 /* stereo right sound */ | ||
258 | #define AWE_SAMPLE_REVERSE_LOOP 128 /* reverse looping */ | ||
259 | unsigned int checksum; /* check sum */ | ||
260 | #if defined(AWE_COMPAT_030) && AWE_COMPAT_030 | ||
261 | unsigned short data[0]; /* sample data follows here */ | ||
262 | #endif | ||
263 | } awe_sample_info; | ||
264 | |||
265 | /*#define AWE_SAMPLE_INFO_SIZE 32*/ | ||
266 | #define AWE_SAMPLE_INFO_SIZE sizeof(awe_sample_info) | ||
267 | |||
268 | |||
269 | /*---------------------------------------------------------------- | ||
270 | * voice preset mapping | ||
271 | *----------------------------------------------------------------*/ | ||
272 | |||
273 | typedef struct awe_voice_map { | ||
274 | int map_bank, map_instr, map_key; /* key = -1 means all keys */ | ||
275 | int src_bank, src_instr, src_key; | ||
276 | } awe_voice_map; | ||
277 | |||
278 | #define AWE_VOICE_MAP_SIZE sizeof(awe_voice_map) | ||
279 | |||
280 | |||
281 | /*---------------------------------------------------------------- | ||
282 | * awe hardware controls | ||
283 | *----------------------------------------------------------------*/ | ||
284 | |||
285 | #define _AWE_DEBUG_MODE 0x00 | ||
286 | #define _AWE_REVERB_MODE 0x01 | ||
287 | #define _AWE_CHORUS_MODE 0x02 | ||
288 | #define _AWE_REMOVE_LAST_SAMPLES 0x03 | ||
289 | #define _AWE_INITIALIZE_CHIP 0x04 | ||
290 | #define _AWE_SEND_EFFECT 0x05 | ||
291 | #define _AWE_TERMINATE_CHANNEL 0x06 | ||
292 | #define _AWE_TERMINATE_ALL 0x07 | ||
293 | #define _AWE_INITIAL_VOLUME 0x08 | ||
294 | #define _AWE_INITIAL_ATTEN _AWE_INITIAL_VOLUME | ||
295 | #define _AWE_RESET_CHANNEL 0x09 | ||
296 | #define _AWE_CHANNEL_MODE 0x0a | ||
297 | #define _AWE_DRUM_CHANNELS 0x0b | ||
298 | #define _AWE_MISC_MODE 0x0c | ||
299 | #define _AWE_RELEASE_ALL 0x0d | ||
300 | #define _AWE_NOTEOFF_ALL 0x0e | ||
301 | #define _AWE_CHN_PRESSURE 0x0f | ||
302 | /*#define _AWE_GET_CURRENT_MODE 0x10*/ | ||
303 | #define _AWE_EQUALIZER 0x11 | ||
304 | /*#define _AWE_GET_MISC_MODE 0x12*/ | ||
305 | /*#define _AWE_GET_FONTINFO 0x13*/ | ||
306 | |||
307 | #define _AWE_MODE_FLAG 0x80 | ||
308 | #define _AWE_COOKED_FLAG 0x40 /* not supported */ | ||
309 | #define _AWE_MODE_VALUE_MASK 0x3F | ||
310 | |||
311 | /*----------------------------------------------------------------*/ | ||
312 | |||
313 | #define _AWE_SET_CMD(p,dev,voice,cmd,p1,p2) \ | ||
314 | {((char*)(p))[0] = SEQ_PRIVATE;\ | ||
315 | ((char*)(p))[1] = dev;\ | ||
316 | ((char*)(p))[2] = _AWE_MODE_FLAG|(cmd);\ | ||
317 | ((char*)(p))[3] = voice;\ | ||
318 | ((unsigned short*)(p))[2] = p1;\ | ||
319 | ((unsigned short*)(p))[3] = p2;} | ||
320 | |||
321 | /* buffered access */ | ||
322 | #define _AWE_CMD(dev, voice, cmd, p1, p2) \ | ||
323 | {_SEQ_NEEDBUF(8);\ | ||
324 | _AWE_SET_CMD(_seqbuf + _seqbufptr, dev, voice, cmd, p1, p2);\ | ||
325 | _SEQ_ADVBUF(8);} | ||
326 | |||
327 | /* direct access */ | ||
328 | #define _AWE_CMD_NOW(seqfd,dev,voice,cmd,p1,p2) \ | ||
329 | {struct seq_event_rec tmp;\ | ||
330 | _AWE_SET_CMD(&tmp, dev, voice, cmd, p1, p2);\ | ||
331 | ioctl(seqfd, SNDCTL_SEQ_OUTOFBAND, &tmp);} | ||
332 | |||
333 | /*----------------------------------------------------------------*/ | ||
334 | |||
335 | /* set debugging mode */ | ||
336 | #define AWE_DEBUG_MODE(dev,p1) _AWE_CMD(dev, 0, _AWE_DEBUG_MODE, p1, 0) | ||
337 | /* set reverb mode; from 0 to 7 */ | ||
338 | #define AWE_REVERB_MODE(dev,p1) _AWE_CMD(dev, 0, _AWE_REVERB_MODE, p1, 0) | ||
339 | /* set chorus mode; from 0 to 7 */ | ||
340 | #define AWE_CHORUS_MODE(dev,p1) _AWE_CMD(dev, 0, _AWE_CHORUS_MODE, p1, 0) | ||
341 | |||
342 | /* reset channel */ | ||
343 | #define AWE_RESET_CHANNEL(dev,ch) _AWE_CMD(dev, ch, _AWE_RESET_CHANNEL, 0, 0) | ||
344 | #define AWE_RESET_CONTROL(dev,ch) _AWE_CMD(dev, ch, _AWE_RESET_CHANNEL, 1, 0) | ||
345 | |||
346 | /* send an effect to all layers */ | ||
347 | #define AWE_SEND_EFFECT(dev,voice,type,value) _AWE_CMD(dev,voice,_AWE_SEND_EFFECT,type,value) | ||
348 | #define AWE_ADD_EFFECT(dev,voice,type,value) _AWE_CMD(dev,voice,_AWE_SEND_EFFECT,((type)|0x80),value) | ||
349 | #define AWE_UNSET_EFFECT(dev,voice,type) _AWE_CMD(dev,voice,_AWE_SEND_EFFECT,((type)|0x40),0) | ||
350 | /* send an effect to a layer */ | ||
351 | #define AWE_SEND_LAYER_EFFECT(dev,voice,layer,type,value) _AWE_CMD(dev,voice,_AWE_SEND_EFFECT,((layer+1)<<8|(type)),value) | ||
352 | #define AWE_ADD_LAYER_EFFECT(dev,voice,layer,type,value) _AWE_CMD(dev,voice,_AWE_SEND_EFFECT,((layer+1)<<8|(type)|0x80),value) | ||
353 | #define AWE_UNSET_LAYER_EFFECT(dev,voice,layer,type) _AWE_CMD(dev,voice,_AWE_SEND_EFFECT,((layer+1)<<8|(type)|0x40),0) | ||
354 | |||
355 | /* terminate sound on the channel/voice */ | ||
356 | #define AWE_TERMINATE_CHANNEL(dev,voice) _AWE_CMD(dev,voice,_AWE_TERMINATE_CHANNEL,0,0) | ||
357 | /* terminate all sounds */ | ||
358 | #define AWE_TERMINATE_ALL(dev) _AWE_CMD(dev, 0, _AWE_TERMINATE_ALL, 0, 0) | ||
359 | /* release all sounds (w/o sustain effect) */ | ||
360 | #define AWE_RELEASE_ALL(dev) _AWE_CMD(dev, 0, _AWE_RELEASE_ALL, 0, 0) | ||
361 | /* note off all sounds (w sustain effect) */ | ||
362 | #define AWE_NOTEOFF_ALL(dev) _AWE_CMD(dev, 0, _AWE_NOTEOFF_ALL, 0, 0) | ||
363 | |||
364 | /* set initial attenuation */ | ||
365 | #define AWE_INITIAL_VOLUME(dev,atten) _AWE_CMD(dev, 0, _AWE_INITIAL_VOLUME, atten, 0) | ||
366 | #define AWE_INITIAL_ATTEN AWE_INITIAL_VOLUME | ||
367 | /* relative attenuation */ | ||
368 | #define AWE_SET_ATTEN(dev,atten) _AWE_CMD(dev, 0, _AWE_INITIAL_VOLUME, atten, 1) | ||
369 | |||
370 | /* set channel playing mode; mode=0/1/2 */ | ||
371 | #define AWE_SET_CHANNEL_MODE(dev,mode) _AWE_CMD(dev, 0, _AWE_CHANNEL_MODE, mode, 0) | ||
372 | #define AWE_PLAY_INDIRECT 0 /* indirect voice mode (default) */ | ||
373 | #define AWE_PLAY_MULTI 1 /* multi note voice mode */ | ||
374 | #define AWE_PLAY_DIRECT 2 /* direct single voice mode */ | ||
375 | #define AWE_PLAY_MULTI2 3 /* sequencer2 mode; used internally */ | ||
376 | |||
377 | /* set drum channel mask; channels is 32bit long value */ | ||
378 | #define AWE_DRUM_CHANNELS(dev,channels) _AWE_CMD(dev, 0, _AWE_DRUM_CHANNELS, ((channels) & 0xffff), ((channels) >> 16)) | ||
379 | |||
380 | /* set bass and treble control; values are from 0 to 11 */ | ||
381 | #define AWE_EQUALIZER(dev,bass,treble) _AWE_CMD(dev, 0, _AWE_EQUALIZER, bass, treble) | ||
382 | |||
383 | /* remove last loaded samples */ | ||
384 | #define AWE_REMOVE_LAST_SAMPLES(seqfd,dev) _AWE_CMD_NOW(seqfd, dev, 0, _AWE_REMOVE_LAST_SAMPLES, 0, 0) | ||
385 | /* initialize emu8000 chip */ | ||
386 | #define AWE_INITIALIZE_CHIP(seqfd,dev) _AWE_CMD_NOW(seqfd, dev, 0, _AWE_INITIALIZE_CHIP, 0, 0) | ||
387 | |||
388 | /* set miscellaneous modes; meta command */ | ||
389 | #define AWE_MISC_MODE(dev,mode,value) _AWE_CMD(dev, 0, _AWE_MISC_MODE, mode, value) | ||
390 | /* exclusive sound off; 1=off */ | ||
391 | #define AWE_EXCLUSIVE_SOUND(dev,mode) AWE_MISC_MODE(dev,AWE_MD_EXCLUSIVE_SOUND,mode) | ||
392 | /* default GUS bank number */ | ||
393 | #define AWE_SET_GUS_BANK(dev,bank) AWE_MISC_MODE(dev,AWE_MD_GUS_BANK,bank) | ||
394 | /* change panning position in realtime; 0=don't 1=do */ | ||
395 | #define AWE_REALTIME_PAN(dev,mode) AWE_MISC_MODE(dev,AWE_MD_REALTIME_PAN,mode) | ||
396 | |||
397 | /* extended pressure controls; not portable with other sound drivers */ | ||
398 | #define AWE_KEY_PRESSURE(dev,ch,note,vel) SEQ_START_NOTE(dev,ch,(note)+128,vel) | ||
399 | #define AWE_CHN_PRESSURE(dev,ch,vel) _AWE_CMD(dev,ch,_AWE_CHN_PRESSURE,vel,0) | ||
400 | |||
401 | /*----------------------------------------------------------------*/ | ||
402 | |||
403 | /* reverb mode parameters */ | ||
404 | #define AWE_REVERB_ROOM1 0 | ||
405 | #define AWE_REVERB_ROOM2 1 | ||
406 | #define AWE_REVERB_ROOM3 2 | ||
407 | #define AWE_REVERB_HALL1 3 | ||
408 | #define AWE_REVERB_HALL2 4 | ||
409 | #define AWE_REVERB_PLATE 5 | ||
410 | #define AWE_REVERB_DELAY 6 | ||
411 | #define AWE_REVERB_PANNINGDELAY 7 | ||
412 | #define AWE_REVERB_PREDEFINED 8 | ||
413 | /* user can define reverb modes up to 32 */ | ||
414 | #define AWE_REVERB_NUMBERS 32 | ||
415 | |||
416 | typedef struct awe_reverb_fx_rec { | ||
417 | unsigned short parms[28]; | ||
418 | } awe_reverb_fx_rec; | ||
419 | |||
420 | /*----------------------------------------------------------------*/ | ||
421 | |||
422 | /* chorus mode parameters */ | ||
423 | #define AWE_CHORUS_1 0 | ||
424 | #define AWE_CHORUS_2 1 | ||
425 | #define AWE_CHORUS_3 2 | ||
426 | #define AWE_CHORUS_4 3 | ||
427 | #define AWE_CHORUS_FEEDBACK 4 | ||
428 | #define AWE_CHORUS_FLANGER 5 | ||
429 | #define AWE_CHORUS_SHORTDELAY 6 | ||
430 | #define AWE_CHORUS_SHORTDELAY2 7 | ||
431 | #define AWE_CHORUS_PREDEFINED 8 | ||
432 | /* user can define chorus modes up to 32 */ | ||
433 | #define AWE_CHORUS_NUMBERS 32 | ||
434 | |||
435 | typedef struct awe_chorus_fx_rec { | ||
436 | unsigned short feedback; /* feedback level (0xE600-0xE6FF) */ | ||
437 | unsigned short delay_offset; /* delay (0-0x0DA3) [1/44100 sec] */ | ||
438 | unsigned short lfo_depth; /* LFO depth (0xBC00-0xBCFF) */ | ||
439 | unsigned int delay; /* right delay (0-0xFFFFFFFF) [1/256/44100 sec] */ | ||
440 | unsigned int lfo_freq; /* LFO freq LFO freq (0-0xFFFFFFFF) */ | ||
441 | } awe_chorus_fx_rec; | ||
442 | |||
443 | /*----------------------------------------------------------------*/ | ||
444 | |||
445 | /* misc mode types */ | ||
446 | enum { | ||
447 | /* 0*/ AWE_MD_EXCLUSIVE_OFF, /* obsolete */ | ||
448 | /* 1*/ AWE_MD_EXCLUSIVE_ON, /* obsolete */ | ||
449 | /* 2*/ AWE_MD_VERSION, /* read only */ | ||
450 | /* 3*/ AWE_MD_EXCLUSIVE_SOUND, /* 0/1: exclusive note on (default=1) */ | ||
451 | /* 4*/ AWE_MD_REALTIME_PAN, /* 0/1: do realtime pan change (default=1) */ | ||
452 | /* 5*/ AWE_MD_GUS_BANK, /* bank number for GUS patches (default=0) */ | ||
453 | /* 6*/ AWE_MD_KEEP_EFFECT, /* 0/1: keep effect values, (default=0) */ | ||
454 | /* 7*/ AWE_MD_ZERO_ATTEN, /* attenuation of max volume (default=32) */ | ||
455 | /* 8*/ AWE_MD_CHN_PRIOR, /* 0/1: set MIDI channel priority mode (default=1) */ | ||
456 | /* 9*/ AWE_MD_MOD_SENSE, /* integer: modwheel sensitivity (def=18) */ | ||
457 | /*10*/ AWE_MD_DEF_PRESET, /* integer: default preset number (def=0) */ | ||
458 | /*11*/ AWE_MD_DEF_BANK, /* integer: default bank number (def=0) */ | ||
459 | /*12*/ AWE_MD_DEF_DRUM, /* integer: default drumset number (def=0) */ | ||
460 | /*13*/ AWE_MD_TOGGLE_DRUM_BANK, /* 0/1: toggle drum flag with bank# (def=0) */ | ||
461 | /*14*/ AWE_MD_NEW_VOLUME_CALC, /* 0/1: volume calculation mode (def=1) */ | ||
462 | /*15*/ AWE_MD_CHORUS_MODE, /* integer: chorus mode (def=2) */ | ||
463 | /*16*/ AWE_MD_REVERB_MODE, /* integer: chorus mode (def=4) */ | ||
464 | /*17*/ AWE_MD_BASS_LEVEL, /* integer: bass level (def=5) */ | ||
465 | /*18*/ AWE_MD_TREBLE_LEVEL, /* integer: treble level (def=9) */ | ||
466 | /*19*/ AWE_MD_DEBUG_MODE, /* integer: debug level (def=0) */ | ||
467 | /*20*/ AWE_MD_PAN_EXCHANGE, /* 0/1: exchange panning direction (def=0) */ | ||
468 | AWE_MD_END, | ||
469 | }; | ||
470 | |||
471 | /*----------------------------------------------------------------*/ | ||
472 | |||
473 | /* effect parameters */ | ||
474 | enum { | ||
475 | |||
476 | /* modulation envelope parameters */ | ||
477 | /* 0*/ AWE_FX_ENV1_DELAY, /* WORD: ENVVAL */ | ||
478 | /* 1*/ AWE_FX_ENV1_ATTACK, /* BYTE: up ATKHLD */ | ||
479 | /* 2*/ AWE_FX_ENV1_HOLD, /* BYTE: lw ATKHLD */ | ||
480 | /* 3*/ AWE_FX_ENV1_DECAY, /* BYTE: lw DCYSUS */ | ||
481 | /* 4*/ AWE_FX_ENV1_RELEASE, /* BYTE: lw DCYSUS */ | ||
482 | /* 5*/ AWE_FX_ENV1_SUSTAIN, /* BYTE: up DCYSUS */ | ||
483 | /* 6*/ AWE_FX_ENV1_PITCH, /* BYTE: up PEFE */ | ||
484 | /* 7*/ AWE_FX_ENV1_CUTOFF, /* BYTE: lw PEFE */ | ||
485 | |||
486 | /* volume envelope parameters */ | ||
487 | /* 8*/ AWE_FX_ENV2_DELAY, /* WORD: ENVVOL */ | ||
488 | /* 9*/ AWE_FX_ENV2_ATTACK, /* BYTE: up ATKHLDV */ | ||
489 | /*10*/ AWE_FX_ENV2_HOLD, /* BYTE: lw ATKHLDV */ | ||
490 | /*11*/ AWE_FX_ENV2_DECAY, /* BYTE: lw DCYSUSV */ | ||
491 | /*12*/ AWE_FX_ENV2_RELEASE, /* BYTE: lw DCYSUSV */ | ||
492 | /*13*/ AWE_FX_ENV2_SUSTAIN, /* BYTE: up DCYSUSV */ | ||
493 | |||
494 | /* LFO1 (tremolo & vibrato) parameters */ | ||
495 | /*14*/ AWE_FX_LFO1_DELAY, /* WORD: LFO1VAL */ | ||
496 | /*15*/ AWE_FX_LFO1_FREQ, /* BYTE: lo TREMFRQ */ | ||
497 | /*16*/ AWE_FX_LFO1_VOLUME, /* BYTE: up TREMFRQ */ | ||
498 | /*17*/ AWE_FX_LFO1_PITCH, /* BYTE: up FMMOD */ | ||
499 | /*18*/ AWE_FX_LFO1_CUTOFF, /* BYTE: lo FMMOD */ | ||
500 | |||
501 | /* LFO2 (vibrato) parameters */ | ||
502 | /*19*/ AWE_FX_LFO2_DELAY, /* WORD: LFO2VAL */ | ||
503 | /*20*/ AWE_FX_LFO2_FREQ, /* BYTE: lo FM2FRQ2 */ | ||
504 | /*21*/ AWE_FX_LFO2_PITCH, /* BYTE: up FM2FRQ2 */ | ||
505 | |||
506 | /* Other overall effect parameters */ | ||
507 | /*22*/ AWE_FX_INIT_PITCH, /* SHORT: pitch offset */ | ||
508 | /*23*/ AWE_FX_CHORUS, /* BYTE: chorus effects send (0-255) */ | ||
509 | /*24*/ AWE_FX_REVERB, /* BYTE: reverb effects send (0-255) */ | ||
510 | /*25*/ AWE_FX_CUTOFF, /* BYTE: up IFATN */ | ||
511 | /*26*/ AWE_FX_FILTERQ, /* BYTE: up CCCA */ | ||
512 | |||
513 | /* Sample / loop offset changes */ | ||
514 | /*27*/ AWE_FX_SAMPLE_START, /* SHORT: offset */ | ||
515 | /*28*/ AWE_FX_LOOP_START, /* SHORT: offset */ | ||
516 | /*29*/ AWE_FX_LOOP_END, /* SHORT: offset */ | ||
517 | /*30*/ AWE_FX_COARSE_SAMPLE_START, /* SHORT: upper word offset */ | ||
518 | /*31*/ AWE_FX_COARSE_LOOP_START, /* SHORT: upper word offset */ | ||
519 | /*32*/ AWE_FX_COARSE_LOOP_END, /* SHORT: upper word offset */ | ||
520 | /*33*/ AWE_FX_ATTEN, /* BYTE: lo IFATN */ | ||
521 | |||
522 | AWE_FX_END, | ||
523 | }; | ||
524 | |||
525 | #endif /* AWE_VOICE_H */ | ||
diff --git a/include/linux/byteorder/generic.h b/include/linux/byteorder/generic.h index e86e4a938373..3dc715b02500 100644 --- a/include/linux/byteorder/generic.h +++ b/include/linux/byteorder/generic.h | |||
@@ -124,19 +124,8 @@ | |||
124 | #define be32_to_cpus __be32_to_cpus | 124 | #define be32_to_cpus __be32_to_cpus |
125 | #define cpu_to_be16s __cpu_to_be16s | 125 | #define cpu_to_be16s __cpu_to_be16s |
126 | #define be16_to_cpus __be16_to_cpus | 126 | #define be16_to_cpus __be16_to_cpus |
127 | #endif | ||
128 | 127 | ||
129 | |||
130 | #if defined(__KERNEL__) | ||
131 | /* | 128 | /* |
132 | * Handle ntohl and suches. These have various compatibility | ||
133 | * issues - like we want to give the prototype even though we | ||
134 | * also have a macro for them in case some strange program | ||
135 | * wants to take the address of the thing or something.. | ||
136 | * | ||
137 | * Note that these used to return a "long" in libc5, even though | ||
138 | * long is often 64-bit these days.. Thus the casts. | ||
139 | * | ||
140 | * They have to be macros in order to do the constant folding | 129 | * They have to be macros in order to do the constant folding |
141 | * correctly - if the argument passed into a inline function | 130 | * correctly - if the argument passed into a inline function |
142 | * it is no longer constant according to gcc.. | 131 | * it is no longer constant according to gcc.. |
@@ -147,17 +136,6 @@ | |||
147 | #undef htonl | 136 | #undef htonl |
148 | #undef htons | 137 | #undef htons |
149 | 138 | ||
150 | /* | ||
151 | * Do the prototypes. Somebody might want to take the | ||
152 | * address or some such sick thing.. | ||
153 | */ | ||
154 | extern __u32 ntohl(__be32); | ||
155 | extern __be32 htonl(__u32); | ||
156 | extern __u16 ntohs(__be16); | ||
157 | extern __be16 htons(__u16); | ||
158 | |||
159 | #if defined(__GNUC__) && defined(__OPTIMIZE__) | ||
160 | |||
161 | #define ___htonl(x) __cpu_to_be32(x) | 139 | #define ___htonl(x) __cpu_to_be32(x) |
162 | #define ___htons(x) __cpu_to_be16(x) | 140 | #define ___htons(x) __cpu_to_be16(x) |
163 | #define ___ntohl(x) __be32_to_cpu(x) | 141 | #define ___ntohl(x) __be32_to_cpu(x) |
@@ -168,9 +146,6 @@ extern __be16 htons(__u16); | |||
168 | #define htons(x) ___htons(x) | 146 | #define htons(x) ___htons(x) |
169 | #define ntohs(x) ___ntohs(x) | 147 | #define ntohs(x) ___ntohs(x) |
170 | 148 | ||
171 | #endif /* OPTIMIZE */ | ||
172 | |||
173 | #endif /* KERNEL */ | 149 | #endif /* KERNEL */ |
174 | 150 | ||
175 | |||
176 | #endif /* _LINUX_BYTEORDER_GENERIC_H */ | 151 | #endif /* _LINUX_BYTEORDER_GENERIC_H */ |
diff --git a/include/linux/byteorder/swab.h b/include/linux/byteorder/swab.h index 25f7f32883ec..142134ff1645 100644 --- a/include/linux/byteorder/swab.h +++ b/include/linux/byteorder/swab.h | |||
@@ -10,6 +10,10 @@ | |||
10 | * separated swab functions from cpu_to_XX, | 10 | * separated swab functions from cpu_to_XX, |
11 | * to clean up support for bizarre-endian architectures. | 11 | * to clean up support for bizarre-endian architectures. |
12 | * | 12 | * |
13 | * Trent Piepho <xyzzy@speakeasy.org> 2007114 | ||
14 | * make constant-folding work, provide C versions that | ||
15 | * gcc can optimize better, explain different versions | ||
16 | * | ||
13 | * See asm-i386/byteorder.h and suches for examples of how to provide | 17 | * See asm-i386/byteorder.h and suches for examples of how to provide |
14 | * architecture-dependent optimized versions | 18 | * architecture-dependent optimized versions |
15 | * | 19 | * |
@@ -17,40 +21,66 @@ | |||
17 | 21 | ||
18 | #include <linux/compiler.h> | 22 | #include <linux/compiler.h> |
19 | 23 | ||
24 | /* Functions/macros defined, there are a lot: | ||
25 | * | ||
26 | * ___swabXX | ||
27 | * Generic C versions of the swab functions. | ||
28 | * | ||
29 | * ___constant_swabXX | ||
30 | * C versions that gcc can fold into a compile-time constant when | ||
31 | * the argument is a compile-time constant. | ||
32 | * | ||
33 | * __arch__swabXX[sp]? | ||
34 | * Architecture optimized versions of all the swab functions | ||
35 | * (including the s and p versions). These can be defined in | ||
36 | * asm-arch/byteorder.h. Any which are not, are defined here. | ||
37 | * __arch__swabXXs() is defined in terms of __arch__swabXXp(), which | ||
38 | * is defined in terms of __arch__swabXX(), which is in turn defined | ||
39 | * in terms of ___swabXX(x). | ||
40 | * These must be macros. They may be unsafe for arguments with | ||
41 | * side-effects. | ||
42 | * | ||
43 | * __fswabXX | ||
44 | * Inline function versions of the __arch__ macros. These _are_ safe | ||
45 | * if the arguments have side-effects. Note there are no s and p | ||
46 | * versions of these. | ||
47 | * | ||
48 | * __swabXX[sb] | ||
49 | * There are the ones you should actually use. The __swabXX versions | ||
50 | * will be a constant given a constant argument and use the arch | ||
51 | * specific code (if any) for non-constant arguments. The s and p | ||
52 | * versions always use the arch specific code (constant folding | ||
53 | * doesn't apply). They are safe to use with arguments with | ||
54 | * side-effects. | ||
55 | * | ||
56 | * swabXX[sb] | ||
57 | * Nicknames for __swabXX[sb] to use in the kernel. | ||
58 | */ | ||
59 | |||
20 | /* casts are necessary for constants, because we never know how for sure | 60 | /* casts are necessary for constants, because we never know how for sure |
21 | * how U/UL/ULL map to __u16, __u32, __u64. At least not in a portable way. | 61 | * how U/UL/ULL map to __u16, __u32, __u64. At least not in a portable way. |
22 | */ | 62 | */ |
23 | #define ___swab16(x) \ | ||
24 | ({ \ | ||
25 | __u16 __x = (x); \ | ||
26 | ((__u16)( \ | ||
27 | (((__u16)(__x) & (__u16)0x00ffU) << 8) | \ | ||
28 | (((__u16)(__x) & (__u16)0xff00U) >> 8) )); \ | ||
29 | }) | ||
30 | 63 | ||
31 | #define ___swab32(x) \ | 64 | static __inline__ __attribute_const__ __u16 ___swab16(__u16 x) |
32 | ({ \ | 65 | { |
33 | __u32 __x = (x); \ | 66 | return x<<8 | x>>8; |
34 | ((__u32)( \ | 67 | } |
35 | (((__u32)(__x) & (__u32)0x000000ffUL) << 24) | \ | 68 | static __inline__ __attribute_const__ __u32 ___swab32(__u32 x) |
36 | (((__u32)(__x) & (__u32)0x0000ff00UL) << 8) | \ | 69 | { |
37 | (((__u32)(__x) & (__u32)0x00ff0000UL) >> 8) | \ | 70 | return x<<24 | x>>24 | |
38 | (((__u32)(__x) & (__u32)0xff000000UL) >> 24) )); \ | 71 | (x & (__u32)0x0000ff00UL)<<8 | |
39 | }) | 72 | (x & (__u32)0x00ff0000UL)>>8; |
40 | 73 | } | |
41 | #define ___swab64(x) \ | 74 | static __inline__ __attribute_const__ __u64 ___swab64(__u64 x) |
42 | ({ \ | 75 | { |
43 | __u64 __x = (x); \ | 76 | return x<<56 | x>>56 | |
44 | ((__u64)( \ | 77 | (x & (__u64)0x000000000000ff00ULL)<<40 | |
45 | (__u64)(((__u64)(__x) & (__u64)0x00000000000000ffULL) << 56) | \ | 78 | (x & (__u64)0x0000000000ff0000ULL)<<24 | |
46 | (__u64)(((__u64)(__x) & (__u64)0x000000000000ff00ULL) << 40) | \ | 79 | (x & (__u64)0x00000000ff000000ULL)<< 8 | |
47 | (__u64)(((__u64)(__x) & (__u64)0x0000000000ff0000ULL) << 24) | \ | 80 | (x & (__u64)0x000000ff00000000ULL)>> 8 | |
48 | (__u64)(((__u64)(__x) & (__u64)0x00000000ff000000ULL) << 8) | \ | 81 | (x & (__u64)0x0000ff0000000000ULL)>>24 | |
49 | (__u64)(((__u64)(__x) & (__u64)0x000000ff00000000ULL) >> 8) | \ | 82 | (x & (__u64)0x00ff000000000000ULL)>>40; |
50 | (__u64)(((__u64)(__x) & (__u64)0x0000ff0000000000ULL) >> 24) | \ | 83 | } |
51 | (__u64)(((__u64)(__x) & (__u64)0x00ff000000000000ULL) >> 40) | \ | ||
52 | (__u64)(((__u64)(__x) & (__u64)0xff00000000000000ULL) >> 56) )); \ | ||
53 | }) | ||
54 | 84 | ||
55 | #define ___constant_swab16(x) \ | 85 | #define ___constant_swab16(x) \ |
56 | ((__u16)( \ | 86 | ((__u16)( \ |
@@ -77,13 +107,13 @@ | |||
77 | * provide defaults when no architecture-specific optimization is detected | 107 | * provide defaults when no architecture-specific optimization is detected |
78 | */ | 108 | */ |
79 | #ifndef __arch__swab16 | 109 | #ifndef __arch__swab16 |
80 | # define __arch__swab16(x) ({ __u16 __tmp = (x) ; ___swab16(__tmp); }) | 110 | # define __arch__swab16(x) ___swab16(x) |
81 | #endif | 111 | #endif |
82 | #ifndef __arch__swab32 | 112 | #ifndef __arch__swab32 |
83 | # define __arch__swab32(x) ({ __u32 __tmp = (x) ; ___swab32(__tmp); }) | 113 | # define __arch__swab32(x) ___swab32(x) |
84 | #endif | 114 | #endif |
85 | #ifndef __arch__swab64 | 115 | #ifndef __arch__swab64 |
86 | # define __arch__swab64(x) ({ __u64 __tmp = (x) ; ___swab64(__tmp); }) | 116 | # define __arch__swab64(x) ___swab64(x) |
87 | #endif | 117 | #endif |
88 | 118 | ||
89 | #ifndef __arch__swab16p | 119 | #ifndef __arch__swab16p |
@@ -97,13 +127,13 @@ | |||
97 | #endif | 127 | #endif |
98 | 128 | ||
99 | #ifndef __arch__swab16s | 129 | #ifndef __arch__swab16s |
100 | # define __arch__swab16s(x) do { *(x) = __arch__swab16p((x)); } while (0) | 130 | # define __arch__swab16s(x) ((void)(*(x) = __arch__swab16p(x))) |
101 | #endif | 131 | #endif |
102 | #ifndef __arch__swab32s | 132 | #ifndef __arch__swab32s |
103 | # define __arch__swab32s(x) do { *(x) = __arch__swab32p((x)); } while (0) | 133 | # define __arch__swab32s(x) ((void)(*(x) = __arch__swab32p(x))) |
104 | #endif | 134 | #endif |
105 | #ifndef __arch__swab64s | 135 | #ifndef __arch__swab64s |
106 | # define __arch__swab64s(x) do { *(x) = __arch__swab64p((x)); } while (0) | 136 | # define __arch__swab64s(x) ((void)(*(x) = __arch__swab64p(x))) |
107 | #endif | 137 | #endif |
108 | 138 | ||
109 | 139 | ||
@@ -113,15 +143,15 @@ | |||
113 | #if defined(__GNUC__) && defined(__OPTIMIZE__) | 143 | #if defined(__GNUC__) && defined(__OPTIMIZE__) |
114 | # define __swab16(x) \ | 144 | # define __swab16(x) \ |
115 | (__builtin_constant_p((__u16)(x)) ? \ | 145 | (__builtin_constant_p((__u16)(x)) ? \ |
116 | ___swab16((x)) : \ | 146 | ___constant_swab16((x)) : \ |
117 | __fswab16((x))) | 147 | __fswab16((x))) |
118 | # define __swab32(x) \ | 148 | # define __swab32(x) \ |
119 | (__builtin_constant_p((__u32)(x)) ? \ | 149 | (__builtin_constant_p((__u32)(x)) ? \ |
120 | ___swab32((x)) : \ | 150 | ___constant_swab32((x)) : \ |
121 | __fswab32((x))) | 151 | __fswab32((x))) |
122 | # define __swab64(x) \ | 152 | # define __swab64(x) \ |
123 | (__builtin_constant_p((__u64)(x)) ? \ | 153 | (__builtin_constant_p((__u64)(x)) ? \ |
124 | ___swab64((x)) : \ | 154 | ___constant_swab64((x)) : \ |
125 | __fswab64((x))) | 155 | __fswab64((x))) |
126 | #else | 156 | #else |
127 | # define __swab16(x) __fswab16(x) | 157 | # define __swab16(x) __fswab16(x) |
diff --git a/include/linux/clockchips.h b/include/linux/clockchips.h index 4ea7e7bcfafe..8486e78f7335 100644 --- a/include/linux/clockchips.h +++ b/include/linux/clockchips.h | |||
@@ -54,17 +54,17 @@ enum clock_event_nofitiers { | |||
54 | /** | 54 | /** |
55 | * struct clock_event_device - clock event device descriptor | 55 | * struct clock_event_device - clock event device descriptor |
56 | * @name: ptr to clock event name | 56 | * @name: ptr to clock event name |
57 | * @hints: usage hints | 57 | * @features: features |
58 | * @max_delta_ns: maximum delta value in ns | 58 | * @max_delta_ns: maximum delta value in ns |
59 | * @min_delta_ns: minimum delta value in ns | 59 | * @min_delta_ns: minimum delta value in ns |
60 | * @mult: nanosecond to cycles multiplier | 60 | * @mult: nanosecond to cycles multiplier |
61 | * @shift: nanoseconds to cycles divisor (power of two) | 61 | * @shift: nanoseconds to cycles divisor (power of two) |
62 | * @rating: variable to rate clock event devices | 62 | * @rating: variable to rate clock event devices |
63 | * @irq: irq number (only for non cpu local devices) | 63 | * @irq: IRQ number (only for non CPU local devices) |
64 | * @cpumask: cpumask to indicate for which cpus this device works | 64 | * @cpumask: cpumask to indicate for which CPUs this device works |
65 | * @set_next_event: set next event | 65 | * @set_next_event: set next event function |
66 | * @set_mode: set mode function | 66 | * @set_mode: set mode function |
67 | * @evthandler: Assigned by the framework to be called by the low | 67 | * @event_handler: Assigned by the framework to be called by the low |
68 | * level handler of the event source | 68 | * level handler of the event source |
69 | * @broadcast: function to broadcast events | 69 | * @broadcast: function to broadcast events |
70 | * @list: list head for the management code | 70 | * @list: list head for the management code |
diff --git a/include/linux/clocksource.h b/include/linux/clocksource.h index daa4940cc0f1..2665ca04cf8f 100644 --- a/include/linux/clocksource.h +++ b/include/linux/clocksource.h | |||
@@ -12,6 +12,7 @@ | |||
12 | #include <linux/timex.h> | 12 | #include <linux/timex.h> |
13 | #include <linux/time.h> | 13 | #include <linux/time.h> |
14 | #include <linux/list.h> | 14 | #include <linux/list.h> |
15 | #include <linux/cache.h> | ||
15 | #include <linux/timer.h> | 16 | #include <linux/timer.h> |
16 | #include <asm/div64.h> | 17 | #include <asm/div64.h> |
17 | #include <asm/io.h> | 18 | #include <asm/io.h> |
@@ -52,6 +53,9 @@ struct clocksource; | |||
52 | * @xtime_interval: Used internally by timekeeping core, please ignore. | 53 | * @xtime_interval: Used internally by timekeeping core, please ignore. |
53 | */ | 54 | */ |
54 | struct clocksource { | 55 | struct clocksource { |
56 | /* | ||
57 | * First part of structure is read mostly | ||
58 | */ | ||
55 | char *name; | 59 | char *name; |
56 | struct list_head list; | 60 | struct list_head list; |
57 | int rating; | 61 | int rating; |
@@ -63,8 +67,15 @@ struct clocksource { | |||
63 | cycle_t (*vread)(void); | 67 | cycle_t (*vread)(void); |
64 | 68 | ||
65 | /* timekeeping specific data, ignore */ | 69 | /* timekeeping specific data, ignore */ |
66 | cycle_t cycle_last, cycle_interval; | 70 | cycle_t cycle_interval; |
67 | u64 xtime_nsec, xtime_interval; | 71 | u64 xtime_interval; |
72 | /* | ||
73 | * Second part is written at each timer interrupt | ||
74 | * Keep it in a different cache line to dirty no | ||
75 | * more than one cache line. | ||
76 | */ | ||
77 | cycle_t cycle_last ____cacheline_aligned_in_smp; | ||
78 | u64 xtime_nsec; | ||
68 | s64 error; | 79 | s64 error; |
69 | 80 | ||
70 | #ifdef CONFIG_CLOCKSOURCE_WATCHDOG | 81 | #ifdef CONFIG_CLOCKSOURCE_WATCHDOG |
diff --git a/include/linux/compat_ioctl.h b/include/linux/compat_ioctl.h deleted file mode 100644 index c26c3adcfacf..000000000000 --- a/include/linux/compat_ioctl.h +++ /dev/null | |||
@@ -1,830 +0,0 @@ | |||
1 | /* List here explicitly which ioctl's are known to have | ||
2 | * compatible types passed or none at all... Please include | ||
3 | * only stuff that is compatible on *all architectures*. | ||
4 | */ | ||
5 | |||
6 | COMPATIBLE_IOCTL(0x4B50) /* KDGHWCLK - not in the kernel, but don't complain */ | ||
7 | COMPATIBLE_IOCTL(0x4B51) /* KDSHWCLK - not in the kernel, but don't complain */ | ||
8 | |||
9 | /* Big T */ | ||
10 | COMPATIBLE_IOCTL(TCGETA) | ||
11 | COMPATIBLE_IOCTL(TCSETA) | ||
12 | COMPATIBLE_IOCTL(TCSETAW) | ||
13 | COMPATIBLE_IOCTL(TCSETAF) | ||
14 | COMPATIBLE_IOCTL(TCSBRK) | ||
15 | ULONG_IOCTL(TCSBRKP) | ||
16 | COMPATIBLE_IOCTL(TCXONC) | ||
17 | COMPATIBLE_IOCTL(TCFLSH) | ||
18 | COMPATIBLE_IOCTL(TCGETS) | ||
19 | COMPATIBLE_IOCTL(TCSETS) | ||
20 | COMPATIBLE_IOCTL(TCSETSW) | ||
21 | COMPATIBLE_IOCTL(TCSETSF) | ||
22 | COMPATIBLE_IOCTL(TIOCLINUX) | ||
23 | COMPATIBLE_IOCTL(TIOCSBRK) | ||
24 | COMPATIBLE_IOCTL(TIOCCBRK) | ||
25 | ULONG_IOCTL(TIOCMIWAIT) | ||
26 | COMPATIBLE_IOCTL(TIOCGICOUNT) | ||
27 | /* Little t */ | ||
28 | COMPATIBLE_IOCTL(TIOCGETD) | ||
29 | COMPATIBLE_IOCTL(TIOCSETD) | ||
30 | COMPATIBLE_IOCTL(TIOCEXCL) | ||
31 | COMPATIBLE_IOCTL(TIOCNXCL) | ||
32 | COMPATIBLE_IOCTL(TIOCCONS) | ||
33 | COMPATIBLE_IOCTL(TIOCGSOFTCAR) | ||
34 | COMPATIBLE_IOCTL(TIOCSSOFTCAR) | ||
35 | COMPATIBLE_IOCTL(TIOCSWINSZ) | ||
36 | COMPATIBLE_IOCTL(TIOCGWINSZ) | ||
37 | COMPATIBLE_IOCTL(TIOCMGET) | ||
38 | COMPATIBLE_IOCTL(TIOCMBIC) | ||
39 | COMPATIBLE_IOCTL(TIOCMBIS) | ||
40 | COMPATIBLE_IOCTL(TIOCMSET) | ||
41 | COMPATIBLE_IOCTL(TIOCPKT) | ||
42 | COMPATIBLE_IOCTL(TIOCNOTTY) | ||
43 | COMPATIBLE_IOCTL(TIOCSTI) | ||
44 | COMPATIBLE_IOCTL(TIOCOUTQ) | ||
45 | COMPATIBLE_IOCTL(TIOCSPGRP) | ||
46 | COMPATIBLE_IOCTL(TIOCGPGRP) | ||
47 | ULONG_IOCTL(TIOCSCTTY) | ||
48 | COMPATIBLE_IOCTL(TIOCGPTN) | ||
49 | COMPATIBLE_IOCTL(TIOCSPTLCK) | ||
50 | COMPATIBLE_IOCTL(TIOCSERGETLSR) | ||
51 | /* Little f */ | ||
52 | COMPATIBLE_IOCTL(FIOCLEX) | ||
53 | COMPATIBLE_IOCTL(FIONCLEX) | ||
54 | COMPATIBLE_IOCTL(FIOASYNC) | ||
55 | COMPATIBLE_IOCTL(FIONBIO) | ||
56 | COMPATIBLE_IOCTL(FIONREAD) /* This is also TIOCINQ */ | ||
57 | /* 0x00 */ | ||
58 | COMPATIBLE_IOCTL(FIBMAP) | ||
59 | COMPATIBLE_IOCTL(FIGETBSZ) | ||
60 | /* 0x03 -- HD/IDE ioctl's used by hdparm and friends. | ||
61 | * Some need translations, these do not. | ||
62 | */ | ||
63 | COMPATIBLE_IOCTL(HDIO_GET_IDENTITY) | ||
64 | COMPATIBLE_IOCTL(HDIO_DRIVE_TASK) | ||
65 | COMPATIBLE_IOCTL(HDIO_DRIVE_CMD) | ||
66 | ULONG_IOCTL(HDIO_SET_MULTCOUNT) | ||
67 | ULONG_IOCTL(HDIO_SET_UNMASKINTR) | ||
68 | ULONG_IOCTL(HDIO_SET_KEEPSETTINGS) | ||
69 | ULONG_IOCTL(HDIO_SET_32BIT) | ||
70 | ULONG_IOCTL(HDIO_SET_NOWERR) | ||
71 | ULONG_IOCTL(HDIO_SET_DMA) | ||
72 | ULONG_IOCTL(HDIO_SET_PIO_MODE) | ||
73 | ULONG_IOCTL(HDIO_SET_NICE) | ||
74 | ULONG_IOCTL(HDIO_SET_WCACHE) | ||
75 | ULONG_IOCTL(HDIO_SET_ACOUSTIC) | ||
76 | ULONG_IOCTL(HDIO_SET_BUSSTATE) | ||
77 | ULONG_IOCTL(HDIO_SET_ADDRESS) | ||
78 | COMPATIBLE_IOCTL(HDIO_SCAN_HWIF) | ||
79 | /* 0x330 is reserved -- it used to be HDIO_GETGEO_BIG */ | ||
80 | COMPATIBLE_IOCTL(0x330) | ||
81 | /* 0x02 -- Floppy ioctls */ | ||
82 | COMPATIBLE_IOCTL(FDMSGON) | ||
83 | COMPATIBLE_IOCTL(FDMSGOFF) | ||
84 | COMPATIBLE_IOCTL(FDSETEMSGTRESH) | ||
85 | COMPATIBLE_IOCTL(FDFLUSH) | ||
86 | COMPATIBLE_IOCTL(FDWERRORCLR) | ||
87 | COMPATIBLE_IOCTL(FDSETMAXERRS) | ||
88 | COMPATIBLE_IOCTL(FDGETMAXERRS) | ||
89 | COMPATIBLE_IOCTL(FDGETDRVTYP) | ||
90 | COMPATIBLE_IOCTL(FDEJECT) | ||
91 | COMPATIBLE_IOCTL(FDCLRPRM) | ||
92 | COMPATIBLE_IOCTL(FDFMTBEG) | ||
93 | COMPATIBLE_IOCTL(FDFMTEND) | ||
94 | COMPATIBLE_IOCTL(FDRESET) | ||
95 | COMPATIBLE_IOCTL(FDTWADDLE) | ||
96 | COMPATIBLE_IOCTL(FDFMTTRK) | ||
97 | COMPATIBLE_IOCTL(FDRAWCMD) | ||
98 | /* 0x12 */ | ||
99 | #ifdef CONFIG_BLOCK | ||
100 | COMPATIBLE_IOCTL(BLKRASET) | ||
101 | COMPATIBLE_IOCTL(BLKROSET) | ||
102 | COMPATIBLE_IOCTL(BLKROGET) | ||
103 | COMPATIBLE_IOCTL(BLKRRPART) | ||
104 | COMPATIBLE_IOCTL(BLKFLSBUF) | ||
105 | COMPATIBLE_IOCTL(BLKSECTSET) | ||
106 | COMPATIBLE_IOCTL(BLKSSZGET) | ||
107 | COMPATIBLE_IOCTL(BLKTRACESTART) | ||
108 | COMPATIBLE_IOCTL(BLKTRACESTOP) | ||
109 | COMPATIBLE_IOCTL(BLKTRACESETUP) | ||
110 | COMPATIBLE_IOCTL(BLKTRACETEARDOWN) | ||
111 | ULONG_IOCTL(BLKRASET) | ||
112 | ULONG_IOCTL(BLKFRASET) | ||
113 | #endif | ||
114 | /* RAID */ | ||
115 | COMPATIBLE_IOCTL(RAID_VERSION) | ||
116 | COMPATIBLE_IOCTL(GET_ARRAY_INFO) | ||
117 | COMPATIBLE_IOCTL(GET_DISK_INFO) | ||
118 | COMPATIBLE_IOCTL(PRINT_RAID_DEBUG) | ||
119 | COMPATIBLE_IOCTL(RAID_AUTORUN) | ||
120 | COMPATIBLE_IOCTL(CLEAR_ARRAY) | ||
121 | COMPATIBLE_IOCTL(ADD_NEW_DISK) | ||
122 | ULONG_IOCTL(HOT_REMOVE_DISK) | ||
123 | COMPATIBLE_IOCTL(SET_ARRAY_INFO) | ||
124 | COMPATIBLE_IOCTL(SET_DISK_INFO) | ||
125 | COMPATIBLE_IOCTL(WRITE_RAID_INFO) | ||
126 | COMPATIBLE_IOCTL(UNPROTECT_ARRAY) | ||
127 | COMPATIBLE_IOCTL(PROTECT_ARRAY) | ||
128 | ULONG_IOCTL(HOT_ADD_DISK) | ||
129 | ULONG_IOCTL(SET_DISK_FAULTY) | ||
130 | COMPATIBLE_IOCTL(RUN_ARRAY) | ||
131 | COMPATIBLE_IOCTL(STOP_ARRAY) | ||
132 | COMPATIBLE_IOCTL(STOP_ARRAY_RO) | ||
133 | COMPATIBLE_IOCTL(RESTART_ARRAY_RW) | ||
134 | COMPATIBLE_IOCTL(GET_BITMAP_FILE) | ||
135 | ULONG_IOCTL(SET_BITMAP_FILE) | ||
136 | /* DM */ | ||
137 | COMPATIBLE_IOCTL(DM_VERSION_32) | ||
138 | COMPATIBLE_IOCTL(DM_REMOVE_ALL_32) | ||
139 | COMPATIBLE_IOCTL(DM_LIST_DEVICES_32) | ||
140 | COMPATIBLE_IOCTL(DM_DEV_CREATE_32) | ||
141 | COMPATIBLE_IOCTL(DM_DEV_REMOVE_32) | ||
142 | COMPATIBLE_IOCTL(DM_DEV_RENAME_32) | ||
143 | COMPATIBLE_IOCTL(DM_DEV_SUSPEND_32) | ||
144 | COMPATIBLE_IOCTL(DM_DEV_STATUS_32) | ||
145 | COMPATIBLE_IOCTL(DM_DEV_WAIT_32) | ||
146 | COMPATIBLE_IOCTL(DM_TABLE_LOAD_32) | ||
147 | COMPATIBLE_IOCTL(DM_TABLE_CLEAR_32) | ||
148 | COMPATIBLE_IOCTL(DM_TABLE_DEPS_32) | ||
149 | COMPATIBLE_IOCTL(DM_TABLE_STATUS_32) | ||
150 | COMPATIBLE_IOCTL(DM_LIST_VERSIONS_32) | ||
151 | COMPATIBLE_IOCTL(DM_TARGET_MSG_32) | ||
152 | COMPATIBLE_IOCTL(DM_DEV_SET_GEOMETRY_32) | ||
153 | COMPATIBLE_IOCTL(DM_VERSION) | ||
154 | COMPATIBLE_IOCTL(DM_REMOVE_ALL) | ||
155 | COMPATIBLE_IOCTL(DM_LIST_DEVICES) | ||
156 | COMPATIBLE_IOCTL(DM_DEV_CREATE) | ||
157 | COMPATIBLE_IOCTL(DM_DEV_REMOVE) | ||
158 | COMPATIBLE_IOCTL(DM_DEV_RENAME) | ||
159 | COMPATIBLE_IOCTL(DM_DEV_SUSPEND) | ||
160 | COMPATIBLE_IOCTL(DM_DEV_STATUS) | ||
161 | COMPATIBLE_IOCTL(DM_DEV_WAIT) | ||
162 | COMPATIBLE_IOCTL(DM_TABLE_LOAD) | ||
163 | COMPATIBLE_IOCTL(DM_TABLE_CLEAR) | ||
164 | COMPATIBLE_IOCTL(DM_TABLE_DEPS) | ||
165 | COMPATIBLE_IOCTL(DM_TABLE_STATUS) | ||
166 | COMPATIBLE_IOCTL(DM_LIST_VERSIONS) | ||
167 | COMPATIBLE_IOCTL(DM_TARGET_MSG) | ||
168 | COMPATIBLE_IOCTL(DM_DEV_SET_GEOMETRY) | ||
169 | /* Big K */ | ||
170 | COMPATIBLE_IOCTL(PIO_FONT) | ||
171 | COMPATIBLE_IOCTL(GIO_FONT) | ||
172 | ULONG_IOCTL(KDSIGACCEPT) | ||
173 | COMPATIBLE_IOCTL(KDGETKEYCODE) | ||
174 | COMPATIBLE_IOCTL(KDSETKEYCODE) | ||
175 | ULONG_IOCTL(KIOCSOUND) | ||
176 | ULONG_IOCTL(KDMKTONE) | ||
177 | COMPATIBLE_IOCTL(KDGKBTYPE) | ||
178 | ULONG_IOCTL(KDSETMODE) | ||
179 | COMPATIBLE_IOCTL(KDGETMODE) | ||
180 | ULONG_IOCTL(KDSKBMODE) | ||
181 | COMPATIBLE_IOCTL(KDGKBMODE) | ||
182 | ULONG_IOCTL(KDSKBMETA) | ||
183 | COMPATIBLE_IOCTL(KDGKBMETA) | ||
184 | COMPATIBLE_IOCTL(KDGKBENT) | ||
185 | COMPATIBLE_IOCTL(KDSKBENT) | ||
186 | COMPATIBLE_IOCTL(KDGKBSENT) | ||
187 | COMPATIBLE_IOCTL(KDSKBSENT) | ||
188 | COMPATIBLE_IOCTL(KDGKBDIACR) | ||
189 | COMPATIBLE_IOCTL(KDSKBDIACR) | ||
190 | COMPATIBLE_IOCTL(KDKBDREP) | ||
191 | COMPATIBLE_IOCTL(KDGKBLED) | ||
192 | ULONG_IOCTL(KDSKBLED) | ||
193 | COMPATIBLE_IOCTL(KDGETLED) | ||
194 | ULONG_IOCTL(KDSETLED) | ||
195 | COMPATIBLE_IOCTL(GIO_SCRNMAP) | ||
196 | COMPATIBLE_IOCTL(PIO_SCRNMAP) | ||
197 | COMPATIBLE_IOCTL(GIO_UNISCRNMAP) | ||
198 | COMPATIBLE_IOCTL(PIO_UNISCRNMAP) | ||
199 | COMPATIBLE_IOCTL(PIO_FONTRESET) | ||
200 | COMPATIBLE_IOCTL(PIO_UNIMAPCLR) | ||
201 | /* Big S */ | ||
202 | COMPATIBLE_IOCTL(SCSI_IOCTL_GET_IDLUN) | ||
203 | COMPATIBLE_IOCTL(SCSI_IOCTL_DOORLOCK) | ||
204 | COMPATIBLE_IOCTL(SCSI_IOCTL_DOORUNLOCK) | ||
205 | COMPATIBLE_IOCTL(SCSI_IOCTL_TEST_UNIT_READY) | ||
206 | COMPATIBLE_IOCTL(SCSI_IOCTL_GET_BUS_NUMBER) | ||
207 | COMPATIBLE_IOCTL(SCSI_IOCTL_SEND_COMMAND) | ||
208 | COMPATIBLE_IOCTL(SCSI_IOCTL_PROBE_HOST) | ||
209 | COMPATIBLE_IOCTL(SCSI_IOCTL_GET_PCI) | ||
210 | /* Big T */ | ||
211 | COMPATIBLE_IOCTL(TUNSETNOCSUM) | ||
212 | COMPATIBLE_IOCTL(TUNSETDEBUG) | ||
213 | COMPATIBLE_IOCTL(TUNSETPERSIST) | ||
214 | COMPATIBLE_IOCTL(TUNSETOWNER) | ||
215 | /* Big V */ | ||
216 | COMPATIBLE_IOCTL(VT_SETMODE) | ||
217 | COMPATIBLE_IOCTL(VT_GETMODE) | ||
218 | COMPATIBLE_IOCTL(VT_GETSTATE) | ||
219 | COMPATIBLE_IOCTL(VT_OPENQRY) | ||
220 | ULONG_IOCTL(VT_ACTIVATE) | ||
221 | ULONG_IOCTL(VT_WAITACTIVE) | ||
222 | ULONG_IOCTL(VT_RELDISP) | ||
223 | ULONG_IOCTL(VT_DISALLOCATE) | ||
224 | COMPATIBLE_IOCTL(VT_RESIZE) | ||
225 | COMPATIBLE_IOCTL(VT_RESIZEX) | ||
226 | COMPATIBLE_IOCTL(VT_LOCKSWITCH) | ||
227 | COMPATIBLE_IOCTL(VT_UNLOCKSWITCH) | ||
228 | COMPATIBLE_IOCTL(VT_GETHIFONTMASK) | ||
229 | /* Little p (/dev/rtc, /dev/envctrl, etc.) */ | ||
230 | COMPATIBLE_IOCTL(RTC_AIE_ON) | ||
231 | COMPATIBLE_IOCTL(RTC_AIE_OFF) | ||
232 | COMPATIBLE_IOCTL(RTC_UIE_ON) | ||
233 | COMPATIBLE_IOCTL(RTC_UIE_OFF) | ||
234 | COMPATIBLE_IOCTL(RTC_PIE_ON) | ||
235 | COMPATIBLE_IOCTL(RTC_PIE_OFF) | ||
236 | COMPATIBLE_IOCTL(RTC_WIE_ON) | ||
237 | COMPATIBLE_IOCTL(RTC_WIE_OFF) | ||
238 | COMPATIBLE_IOCTL(RTC_ALM_SET) | ||
239 | COMPATIBLE_IOCTL(RTC_ALM_READ) | ||
240 | COMPATIBLE_IOCTL(RTC_RD_TIME) | ||
241 | COMPATIBLE_IOCTL(RTC_SET_TIME) | ||
242 | COMPATIBLE_IOCTL(RTC_WKALM_SET) | ||
243 | COMPATIBLE_IOCTL(RTC_WKALM_RD) | ||
244 | /* | ||
245 | * These two are only for the sbus rtc driver, but | ||
246 | * hwclock tries them on every rtc device first when | ||
247 | * running on sparc. On other architectures the entries | ||
248 | * are useless but harmless. | ||
249 | */ | ||
250 | COMPATIBLE_IOCTL(_IOR('p', 20, int[7])) /* RTCGET */ | ||
251 | COMPATIBLE_IOCTL(_IOW('p', 21, int[7])) /* RTCSET */ | ||
252 | /* Little m */ | ||
253 | COMPATIBLE_IOCTL(MTIOCTOP) | ||
254 | /* Socket level stuff */ | ||
255 | COMPATIBLE_IOCTL(FIOQSIZE) | ||
256 | COMPATIBLE_IOCTL(FIOSETOWN) | ||
257 | COMPATIBLE_IOCTL(SIOCSPGRP) | ||
258 | COMPATIBLE_IOCTL(FIOGETOWN) | ||
259 | COMPATIBLE_IOCTL(SIOCGPGRP) | ||
260 | COMPATIBLE_IOCTL(SIOCATMARK) | ||
261 | COMPATIBLE_IOCTL(SIOCSIFLINK) | ||
262 | COMPATIBLE_IOCTL(SIOCSIFENCAP) | ||
263 | COMPATIBLE_IOCTL(SIOCGIFENCAP) | ||
264 | COMPATIBLE_IOCTL(SIOCSIFNAME) | ||
265 | COMPATIBLE_IOCTL(SIOCSARP) | ||
266 | COMPATIBLE_IOCTL(SIOCGARP) | ||
267 | COMPATIBLE_IOCTL(SIOCDARP) | ||
268 | COMPATIBLE_IOCTL(SIOCSRARP) | ||
269 | COMPATIBLE_IOCTL(SIOCGRARP) | ||
270 | COMPATIBLE_IOCTL(SIOCDRARP) | ||
271 | COMPATIBLE_IOCTL(SIOCADDDLCI) | ||
272 | COMPATIBLE_IOCTL(SIOCDELDLCI) | ||
273 | COMPATIBLE_IOCTL(SIOCGMIIPHY) | ||
274 | COMPATIBLE_IOCTL(SIOCGMIIREG) | ||
275 | COMPATIBLE_IOCTL(SIOCSMIIREG) | ||
276 | COMPATIBLE_IOCTL(SIOCGIFVLAN) | ||
277 | COMPATIBLE_IOCTL(SIOCSIFVLAN) | ||
278 | COMPATIBLE_IOCTL(SIOCBRADDBR) | ||
279 | COMPATIBLE_IOCTL(SIOCBRDELBR) | ||
280 | /* SG stuff */ | ||
281 | COMPATIBLE_IOCTL(SG_SET_TIMEOUT) | ||
282 | COMPATIBLE_IOCTL(SG_GET_TIMEOUT) | ||
283 | COMPATIBLE_IOCTL(SG_EMULATED_HOST) | ||
284 | ULONG_IOCTL(SG_SET_TRANSFORM) | ||
285 | COMPATIBLE_IOCTL(SG_GET_TRANSFORM) | ||
286 | COMPATIBLE_IOCTL(SG_SET_RESERVED_SIZE) | ||
287 | COMPATIBLE_IOCTL(SG_GET_RESERVED_SIZE) | ||
288 | COMPATIBLE_IOCTL(SG_GET_SCSI_ID) | ||
289 | COMPATIBLE_IOCTL(SG_SET_FORCE_LOW_DMA) | ||
290 | COMPATIBLE_IOCTL(SG_GET_LOW_DMA) | ||
291 | COMPATIBLE_IOCTL(SG_SET_FORCE_PACK_ID) | ||
292 | COMPATIBLE_IOCTL(SG_GET_PACK_ID) | ||
293 | COMPATIBLE_IOCTL(SG_GET_NUM_WAITING) | ||
294 | COMPATIBLE_IOCTL(SG_SET_DEBUG) | ||
295 | COMPATIBLE_IOCTL(SG_GET_SG_TABLESIZE) | ||
296 | COMPATIBLE_IOCTL(SG_GET_COMMAND_Q) | ||
297 | COMPATIBLE_IOCTL(SG_SET_COMMAND_Q) | ||
298 | COMPATIBLE_IOCTL(SG_GET_VERSION_NUM) | ||
299 | COMPATIBLE_IOCTL(SG_NEXT_CMD_LEN) | ||
300 | COMPATIBLE_IOCTL(SG_SCSI_RESET) | ||
301 | COMPATIBLE_IOCTL(SG_GET_REQUEST_TABLE) | ||
302 | COMPATIBLE_IOCTL(SG_SET_KEEP_ORPHAN) | ||
303 | COMPATIBLE_IOCTL(SG_GET_KEEP_ORPHAN) | ||
304 | /* PPP stuff */ | ||
305 | COMPATIBLE_IOCTL(PPPIOCGFLAGS) | ||
306 | COMPATIBLE_IOCTL(PPPIOCSFLAGS) | ||
307 | COMPATIBLE_IOCTL(PPPIOCGASYNCMAP) | ||
308 | COMPATIBLE_IOCTL(PPPIOCSASYNCMAP) | ||
309 | COMPATIBLE_IOCTL(PPPIOCGUNIT) | ||
310 | COMPATIBLE_IOCTL(PPPIOCGRASYNCMAP) | ||
311 | COMPATIBLE_IOCTL(PPPIOCSRASYNCMAP) | ||
312 | COMPATIBLE_IOCTL(PPPIOCGMRU) | ||
313 | COMPATIBLE_IOCTL(PPPIOCSMRU) | ||
314 | COMPATIBLE_IOCTL(PPPIOCSMAXCID) | ||
315 | COMPATIBLE_IOCTL(PPPIOCGXASYNCMAP) | ||
316 | COMPATIBLE_IOCTL(PPPIOCSXASYNCMAP) | ||
317 | COMPATIBLE_IOCTL(PPPIOCXFERUNIT) | ||
318 | /* PPPIOCSCOMPRESS is translated */ | ||
319 | COMPATIBLE_IOCTL(PPPIOCGNPMODE) | ||
320 | COMPATIBLE_IOCTL(PPPIOCSNPMODE) | ||
321 | COMPATIBLE_IOCTL(PPPIOCGDEBUG) | ||
322 | COMPATIBLE_IOCTL(PPPIOCSDEBUG) | ||
323 | /* PPPIOCSPASS is translated */ | ||
324 | /* PPPIOCSACTIVE is translated */ | ||
325 | /* PPPIOCGIDLE is translated */ | ||
326 | COMPATIBLE_IOCTL(PPPIOCNEWUNIT) | ||
327 | COMPATIBLE_IOCTL(PPPIOCATTACH) | ||
328 | COMPATIBLE_IOCTL(PPPIOCDETACH) | ||
329 | COMPATIBLE_IOCTL(PPPIOCSMRRU) | ||
330 | COMPATIBLE_IOCTL(PPPIOCCONNECT) | ||
331 | COMPATIBLE_IOCTL(PPPIOCDISCONN) | ||
332 | COMPATIBLE_IOCTL(PPPIOCATTCHAN) | ||
333 | COMPATIBLE_IOCTL(PPPIOCGCHAN) | ||
334 | /* PPPOX */ | ||
335 | COMPATIBLE_IOCTL(PPPOEIOCSFWD) | ||
336 | COMPATIBLE_IOCTL(PPPOEIOCDFWD) | ||
337 | /* LP */ | ||
338 | COMPATIBLE_IOCTL(LPGETSTATUS) | ||
339 | /* ppdev */ | ||
340 | COMPATIBLE_IOCTL(PPSETMODE) | ||
341 | COMPATIBLE_IOCTL(PPRSTATUS) | ||
342 | COMPATIBLE_IOCTL(PPRCONTROL) | ||
343 | COMPATIBLE_IOCTL(PPWCONTROL) | ||
344 | COMPATIBLE_IOCTL(PPFCONTROL) | ||
345 | COMPATIBLE_IOCTL(PPRDATA) | ||
346 | COMPATIBLE_IOCTL(PPWDATA) | ||
347 | COMPATIBLE_IOCTL(PPCLAIM) | ||
348 | COMPATIBLE_IOCTL(PPRELEASE) | ||
349 | COMPATIBLE_IOCTL(PPYIELD) | ||
350 | COMPATIBLE_IOCTL(PPEXCL) | ||
351 | COMPATIBLE_IOCTL(PPDATADIR) | ||
352 | COMPATIBLE_IOCTL(PPNEGOT) | ||
353 | COMPATIBLE_IOCTL(PPWCTLONIRQ) | ||
354 | COMPATIBLE_IOCTL(PPCLRIRQ) | ||
355 | COMPATIBLE_IOCTL(PPSETPHASE) | ||
356 | COMPATIBLE_IOCTL(PPGETMODES) | ||
357 | COMPATIBLE_IOCTL(PPGETMODE) | ||
358 | COMPATIBLE_IOCTL(PPGETPHASE) | ||
359 | COMPATIBLE_IOCTL(PPGETFLAGS) | ||
360 | COMPATIBLE_IOCTL(PPSETFLAGS) | ||
361 | /* CDROM stuff */ | ||
362 | COMPATIBLE_IOCTL(CDROMPAUSE) | ||
363 | COMPATIBLE_IOCTL(CDROMRESUME) | ||
364 | COMPATIBLE_IOCTL(CDROMPLAYMSF) | ||
365 | COMPATIBLE_IOCTL(CDROMPLAYTRKIND) | ||
366 | COMPATIBLE_IOCTL(CDROMREADTOCHDR) | ||
367 | COMPATIBLE_IOCTL(CDROMREADTOCENTRY) | ||
368 | COMPATIBLE_IOCTL(CDROMSTOP) | ||
369 | COMPATIBLE_IOCTL(CDROMSTART) | ||
370 | COMPATIBLE_IOCTL(CDROMEJECT) | ||
371 | COMPATIBLE_IOCTL(CDROMVOLCTRL) | ||
372 | COMPATIBLE_IOCTL(CDROMSUBCHNL) | ||
373 | ULONG_IOCTL(CDROMEJECT_SW) | ||
374 | COMPATIBLE_IOCTL(CDROMMULTISESSION) | ||
375 | COMPATIBLE_IOCTL(CDROM_GET_MCN) | ||
376 | COMPATIBLE_IOCTL(CDROMRESET) | ||
377 | COMPATIBLE_IOCTL(CDROMVOLREAD) | ||
378 | COMPATIBLE_IOCTL(CDROMSEEK) | ||
379 | COMPATIBLE_IOCTL(CDROMPLAYBLK) | ||
380 | COMPATIBLE_IOCTL(CDROMCLOSETRAY) | ||
381 | ULONG_IOCTL(CDROM_SET_OPTIONS) | ||
382 | ULONG_IOCTL(CDROM_CLEAR_OPTIONS) | ||
383 | ULONG_IOCTL(CDROM_SELECT_SPEED) | ||
384 | ULONG_IOCTL(CDROM_SELECT_DISC) | ||
385 | ULONG_IOCTL(CDROM_MEDIA_CHANGED) | ||
386 | ULONG_IOCTL(CDROM_DRIVE_STATUS) | ||
387 | COMPATIBLE_IOCTL(CDROM_DISC_STATUS) | ||
388 | COMPATIBLE_IOCTL(CDROM_CHANGER_NSLOTS) | ||
389 | ULONG_IOCTL(CDROM_LOCKDOOR) | ||
390 | ULONG_IOCTL(CDROM_DEBUG) | ||
391 | COMPATIBLE_IOCTL(CDROM_GET_CAPABILITY) | ||
392 | /* Ignore cdrom.h about these next 5 ioctls, they absolutely do | ||
393 | * not take a struct cdrom_read, instead they take a struct cdrom_msf | ||
394 | * which is compatible. | ||
395 | */ | ||
396 | COMPATIBLE_IOCTL(CDROMREADMODE2) | ||
397 | COMPATIBLE_IOCTL(CDROMREADMODE1) | ||
398 | COMPATIBLE_IOCTL(CDROMREADRAW) | ||
399 | COMPATIBLE_IOCTL(CDROMREADCOOKED) | ||
400 | COMPATIBLE_IOCTL(CDROMREADALL) | ||
401 | /* DVD ioctls */ | ||
402 | COMPATIBLE_IOCTL(DVD_READ_STRUCT) | ||
403 | COMPATIBLE_IOCTL(DVD_WRITE_STRUCT) | ||
404 | COMPATIBLE_IOCTL(DVD_AUTH) | ||
405 | /* pktcdvd */ | ||
406 | COMPATIBLE_IOCTL(PACKET_CTRL_CMD) | ||
407 | /* Big A */ | ||
408 | /* sparc only */ | ||
409 | /* Big Q for sound/OSS */ | ||
410 | COMPATIBLE_IOCTL(SNDCTL_SEQ_RESET) | ||
411 | COMPATIBLE_IOCTL(SNDCTL_SEQ_SYNC) | ||
412 | COMPATIBLE_IOCTL(SNDCTL_SYNTH_INFO) | ||
413 | COMPATIBLE_IOCTL(SNDCTL_SEQ_CTRLRATE) | ||
414 | COMPATIBLE_IOCTL(SNDCTL_SEQ_GETOUTCOUNT) | ||
415 | COMPATIBLE_IOCTL(SNDCTL_SEQ_GETINCOUNT) | ||
416 | COMPATIBLE_IOCTL(SNDCTL_SEQ_PERCMODE) | ||
417 | COMPATIBLE_IOCTL(SNDCTL_FM_LOAD_INSTR) | ||
418 | COMPATIBLE_IOCTL(SNDCTL_SEQ_TESTMIDI) | ||
419 | COMPATIBLE_IOCTL(SNDCTL_SEQ_RESETSAMPLES) | ||
420 | COMPATIBLE_IOCTL(SNDCTL_SEQ_NRSYNTHS) | ||
421 | COMPATIBLE_IOCTL(SNDCTL_SEQ_NRMIDIS) | ||
422 | COMPATIBLE_IOCTL(SNDCTL_MIDI_INFO) | ||
423 | COMPATIBLE_IOCTL(SNDCTL_SEQ_THRESHOLD) | ||
424 | COMPATIBLE_IOCTL(SNDCTL_SYNTH_MEMAVL) | ||
425 | COMPATIBLE_IOCTL(SNDCTL_FM_4OP_ENABLE) | ||
426 | COMPATIBLE_IOCTL(SNDCTL_SEQ_PANIC) | ||
427 | COMPATIBLE_IOCTL(SNDCTL_SEQ_OUTOFBAND) | ||
428 | COMPATIBLE_IOCTL(SNDCTL_SEQ_GETTIME) | ||
429 | COMPATIBLE_IOCTL(SNDCTL_SYNTH_ID) | ||
430 | COMPATIBLE_IOCTL(SNDCTL_SYNTH_CONTROL) | ||
431 | COMPATIBLE_IOCTL(SNDCTL_SYNTH_REMOVESAMPLE) | ||
432 | /* Big T for sound/OSS */ | ||
433 | COMPATIBLE_IOCTL(SNDCTL_TMR_TIMEBASE) | ||
434 | COMPATIBLE_IOCTL(SNDCTL_TMR_START) | ||
435 | COMPATIBLE_IOCTL(SNDCTL_TMR_STOP) | ||
436 | COMPATIBLE_IOCTL(SNDCTL_TMR_CONTINUE) | ||
437 | COMPATIBLE_IOCTL(SNDCTL_TMR_TEMPO) | ||
438 | COMPATIBLE_IOCTL(SNDCTL_TMR_SOURCE) | ||
439 | COMPATIBLE_IOCTL(SNDCTL_TMR_METRONOME) | ||
440 | COMPATIBLE_IOCTL(SNDCTL_TMR_SELECT) | ||
441 | /* Little m for sound/OSS */ | ||
442 | COMPATIBLE_IOCTL(SNDCTL_MIDI_PRETIME) | ||
443 | COMPATIBLE_IOCTL(SNDCTL_MIDI_MPUMODE) | ||
444 | COMPATIBLE_IOCTL(SNDCTL_MIDI_MPUCMD) | ||
445 | /* Big P for sound/OSS */ | ||
446 | COMPATIBLE_IOCTL(SNDCTL_DSP_RESET) | ||
447 | COMPATIBLE_IOCTL(SNDCTL_DSP_SYNC) | ||
448 | COMPATIBLE_IOCTL(SNDCTL_DSP_SPEED) | ||
449 | COMPATIBLE_IOCTL(SNDCTL_DSP_STEREO) | ||
450 | COMPATIBLE_IOCTL(SNDCTL_DSP_GETBLKSIZE) | ||
451 | COMPATIBLE_IOCTL(SNDCTL_DSP_CHANNELS) | ||
452 | COMPATIBLE_IOCTL(SOUND_PCM_WRITE_FILTER) | ||
453 | COMPATIBLE_IOCTL(SNDCTL_DSP_POST) | ||
454 | COMPATIBLE_IOCTL(SNDCTL_DSP_SUBDIVIDE) | ||
455 | COMPATIBLE_IOCTL(SNDCTL_DSP_SETFRAGMENT) | ||
456 | COMPATIBLE_IOCTL(SNDCTL_DSP_GETFMTS) | ||
457 | COMPATIBLE_IOCTL(SNDCTL_DSP_SETFMT) | ||
458 | COMPATIBLE_IOCTL(SNDCTL_DSP_GETOSPACE) | ||
459 | COMPATIBLE_IOCTL(SNDCTL_DSP_GETISPACE) | ||
460 | COMPATIBLE_IOCTL(SNDCTL_DSP_NONBLOCK) | ||
461 | COMPATIBLE_IOCTL(SNDCTL_DSP_GETCAPS) | ||
462 | COMPATIBLE_IOCTL(SNDCTL_DSP_GETTRIGGER) | ||
463 | COMPATIBLE_IOCTL(SNDCTL_DSP_SETTRIGGER) | ||
464 | COMPATIBLE_IOCTL(SNDCTL_DSP_GETIPTR) | ||
465 | COMPATIBLE_IOCTL(SNDCTL_DSP_GETOPTR) | ||
466 | /* SNDCTL_DSP_MAPINBUF, XXX needs translation */ | ||
467 | /* SNDCTL_DSP_MAPOUTBUF, XXX needs translation */ | ||
468 | COMPATIBLE_IOCTL(SNDCTL_DSP_SETSYNCRO) | ||
469 | COMPATIBLE_IOCTL(SNDCTL_DSP_SETDUPLEX) | ||
470 | COMPATIBLE_IOCTL(SNDCTL_DSP_GETODELAY) | ||
471 | COMPATIBLE_IOCTL(SNDCTL_DSP_PROFILE) | ||
472 | COMPATIBLE_IOCTL(SOUND_PCM_READ_RATE) | ||
473 | COMPATIBLE_IOCTL(SOUND_PCM_READ_CHANNELS) | ||
474 | COMPATIBLE_IOCTL(SOUND_PCM_READ_BITS) | ||
475 | COMPATIBLE_IOCTL(SOUND_PCM_READ_FILTER) | ||
476 | /* Big C for sound/OSS */ | ||
477 | COMPATIBLE_IOCTL(SNDCTL_COPR_RESET) | ||
478 | COMPATIBLE_IOCTL(SNDCTL_COPR_LOAD) | ||
479 | COMPATIBLE_IOCTL(SNDCTL_COPR_RDATA) | ||
480 | COMPATIBLE_IOCTL(SNDCTL_COPR_RCODE) | ||
481 | COMPATIBLE_IOCTL(SNDCTL_COPR_WDATA) | ||
482 | COMPATIBLE_IOCTL(SNDCTL_COPR_WCODE) | ||
483 | COMPATIBLE_IOCTL(SNDCTL_COPR_RUN) | ||
484 | COMPATIBLE_IOCTL(SNDCTL_COPR_HALT) | ||
485 | COMPATIBLE_IOCTL(SNDCTL_COPR_SENDMSG) | ||
486 | COMPATIBLE_IOCTL(SNDCTL_COPR_RCVMSG) | ||
487 | /* Big M for sound/OSS */ | ||
488 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_VOLUME) | ||
489 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_BASS) | ||
490 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_TREBLE) | ||
491 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_SYNTH) | ||
492 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_PCM) | ||
493 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_SPEAKER) | ||
494 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_LINE) | ||
495 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_MIC) | ||
496 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_CD) | ||
497 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_IMIX) | ||
498 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_ALTPCM) | ||
499 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_RECLEV) | ||
500 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_IGAIN) | ||
501 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_OGAIN) | ||
502 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_LINE1) | ||
503 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_LINE2) | ||
504 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_LINE3) | ||
505 | COMPATIBLE_IOCTL(MIXER_READ(SOUND_MIXER_DIGITAL1)) | ||
506 | COMPATIBLE_IOCTL(MIXER_READ(SOUND_MIXER_DIGITAL2)) | ||
507 | COMPATIBLE_IOCTL(MIXER_READ(SOUND_MIXER_DIGITAL3)) | ||
508 | COMPATIBLE_IOCTL(MIXER_READ(SOUND_MIXER_PHONEIN)) | ||
509 | COMPATIBLE_IOCTL(MIXER_READ(SOUND_MIXER_PHONEOUT)) | ||
510 | COMPATIBLE_IOCTL(MIXER_READ(SOUND_MIXER_VIDEO)) | ||
511 | COMPATIBLE_IOCTL(MIXER_READ(SOUND_MIXER_RADIO)) | ||
512 | COMPATIBLE_IOCTL(MIXER_READ(SOUND_MIXER_MONITOR)) | ||
513 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_MUTE) | ||
514 | /* SOUND_MIXER_READ_ENHANCE, same value as READ_MUTE */ | ||
515 | /* SOUND_MIXER_READ_LOUD, same value as READ_MUTE */ | ||
516 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_RECSRC) | ||
517 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_DEVMASK) | ||
518 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_RECMASK) | ||
519 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_STEREODEVS) | ||
520 | COMPATIBLE_IOCTL(SOUND_MIXER_READ_CAPS) | ||
521 | COMPATIBLE_IOCTL(SOUND_MIXER_WRITE_VOLUME) | ||
522 | COMPATIBLE_IOCTL(SOUND_MIXER_WRITE_BASS) | ||
523 | COMPATIBLE_IOCTL(SOUND_MIXER_WRITE_TREBLE) | ||
524 | COMPATIBLE_IOCTL(SOUND_MIXER_WRITE_SYNTH) | ||
525 | COMPATIBLE_IOCTL(SOUND_MIXER_WRITE_PCM) | ||
526 | COMPATIBLE_IOCTL(SOUND_MIXER_WRITE_SPEAKER) | ||
527 | COMPATIBLE_IOCTL(SOUND_MIXER_WRITE_LINE) | ||
528 | COMPATIBLE_IOCTL(SOUND_MIXER_WRITE_MIC) | ||
529 | COMPATIBLE_IOCTL(SOUND_MIXER_WRITE_CD) | ||
530 | COMPATIBLE_IOCTL(SOUND_MIXER_WRITE_IMIX) | ||
531 | COMPATIBLE_IOCTL(SOUND_MIXER_WRITE_ALTPCM) | ||
532 | COMPATIBLE_IOCTL(SOUND_MIXER_WRITE_RECLEV) | ||
533 | COMPATIBLE_IOCTL(SOUND_MIXER_WRITE_IGAIN) | ||
534 | COMPATIBLE_IOCTL(SOUND_MIXER_WRITE_OGAIN) | ||
535 | COMPATIBLE_IOCTL(SOUND_MIXER_WRITE_LINE1) | ||
536 | COMPATIBLE_IOCTL(SOUND_MIXER_WRITE_LINE2) | ||
537 | COMPATIBLE_IOCTL(SOUND_MIXER_WRITE_LINE3) | ||
538 | COMPATIBLE_IOCTL(MIXER_WRITE(SOUND_MIXER_DIGITAL1)) | ||
539 | COMPATIBLE_IOCTL(MIXER_WRITE(SOUND_MIXER_DIGITAL2)) | ||
540 | COMPATIBLE_IOCTL(MIXER_WRITE(SOUND_MIXER_DIGITAL3)) | ||
541 | COMPATIBLE_IOCTL(MIXER_WRITE(SOUND_MIXER_PHONEIN)) | ||
542 | COMPATIBLE_IOCTL(MIXER_WRITE(SOUND_MIXER_PHONEOUT)) | ||
543 | COMPATIBLE_IOCTL(MIXER_WRITE(SOUND_MIXER_VIDEO)) | ||
544 | COMPATIBLE_IOCTL(MIXER_WRITE(SOUND_MIXER_RADIO)) | ||
545 | COMPATIBLE_IOCTL(MIXER_WRITE(SOUND_MIXER_MONITOR)) | ||
546 | COMPATIBLE_IOCTL(SOUND_MIXER_WRITE_MUTE) | ||
547 | /* SOUND_MIXER_WRITE_ENHANCE, same value as WRITE_MUTE */ | ||
548 | /* SOUND_MIXER_WRITE_LOUD, same value as WRITE_MUTE */ | ||
549 | COMPATIBLE_IOCTL(SOUND_MIXER_WRITE_RECSRC) | ||
550 | COMPATIBLE_IOCTL(SOUND_MIXER_INFO) | ||
551 | COMPATIBLE_IOCTL(SOUND_OLD_MIXER_INFO) | ||
552 | COMPATIBLE_IOCTL(SOUND_MIXER_ACCESS) | ||
553 | COMPATIBLE_IOCTL(SOUND_MIXER_AGC) | ||
554 | COMPATIBLE_IOCTL(SOUND_MIXER_3DSE) | ||
555 | COMPATIBLE_IOCTL(SOUND_MIXER_PRIVATE1) | ||
556 | COMPATIBLE_IOCTL(SOUND_MIXER_PRIVATE2) | ||
557 | COMPATIBLE_IOCTL(SOUND_MIXER_PRIVATE3) | ||
558 | COMPATIBLE_IOCTL(SOUND_MIXER_PRIVATE4) | ||
559 | COMPATIBLE_IOCTL(SOUND_MIXER_PRIVATE5) | ||
560 | COMPATIBLE_IOCTL(SOUND_MIXER_GETLEVELS) | ||
561 | COMPATIBLE_IOCTL(SOUND_MIXER_SETLEVELS) | ||
562 | COMPATIBLE_IOCTL(OSS_GETVERSION) | ||
563 | /* AUTOFS */ | ||
564 | ULONG_IOCTL(AUTOFS_IOC_READY) | ||
565 | ULONG_IOCTL(AUTOFS_IOC_FAIL) | ||
566 | COMPATIBLE_IOCTL(AUTOFS_IOC_CATATONIC) | ||
567 | COMPATIBLE_IOCTL(AUTOFS_IOC_PROTOVER) | ||
568 | COMPATIBLE_IOCTL(AUTOFS_IOC_EXPIRE) | ||
569 | COMPATIBLE_IOCTL(AUTOFS_IOC_EXPIRE_MULTI) | ||
570 | COMPATIBLE_IOCTL(AUTOFS_IOC_PROTOSUBVER) | ||
571 | COMPATIBLE_IOCTL(AUTOFS_IOC_ASKREGHOST) | ||
572 | COMPATIBLE_IOCTL(AUTOFS_IOC_TOGGLEREGHOST) | ||
573 | COMPATIBLE_IOCTL(AUTOFS_IOC_ASKUMOUNT) | ||
574 | /* Raw devices */ | ||
575 | COMPATIBLE_IOCTL(RAW_SETBIND) | ||
576 | COMPATIBLE_IOCTL(RAW_GETBIND) | ||
577 | /* SMB ioctls which do not need any translations */ | ||
578 | COMPATIBLE_IOCTL(SMB_IOC_NEWCONN) | ||
579 | /* Little a */ | ||
580 | COMPATIBLE_IOCTL(ATMSIGD_CTRL) | ||
581 | COMPATIBLE_IOCTL(ATMARPD_CTRL) | ||
582 | COMPATIBLE_IOCTL(ATMLEC_CTRL) | ||
583 | COMPATIBLE_IOCTL(ATMLEC_MCAST) | ||
584 | COMPATIBLE_IOCTL(ATMLEC_DATA) | ||
585 | COMPATIBLE_IOCTL(ATM_SETSC) | ||
586 | COMPATIBLE_IOCTL(SIOCSIFATMTCP) | ||
587 | COMPATIBLE_IOCTL(SIOCMKCLIP) | ||
588 | COMPATIBLE_IOCTL(ATMARP_MKIP) | ||
589 | COMPATIBLE_IOCTL(ATMARP_SETENTRY) | ||
590 | COMPATIBLE_IOCTL(ATMARP_ENCAP) | ||
591 | COMPATIBLE_IOCTL(ATMTCP_CREATE) | ||
592 | COMPATIBLE_IOCTL(ATMTCP_REMOVE) | ||
593 | COMPATIBLE_IOCTL(ATMMPC_CTRL) | ||
594 | COMPATIBLE_IOCTL(ATMMPC_DATA) | ||
595 | /* Watchdog */ | ||
596 | COMPATIBLE_IOCTL(WDIOC_GETSUPPORT) | ||
597 | COMPATIBLE_IOCTL(WDIOC_GETSTATUS) | ||
598 | COMPATIBLE_IOCTL(WDIOC_GETBOOTSTATUS) | ||
599 | COMPATIBLE_IOCTL(WDIOC_GETTEMP) | ||
600 | COMPATIBLE_IOCTL(WDIOC_SETOPTIONS) | ||
601 | COMPATIBLE_IOCTL(WDIOC_KEEPALIVE) | ||
602 | COMPATIBLE_IOCTL(WDIOC_SETTIMEOUT) | ||
603 | COMPATIBLE_IOCTL(WDIOC_GETTIMEOUT) | ||
604 | /* Big R */ | ||
605 | COMPATIBLE_IOCTL(RNDGETENTCNT) | ||
606 | COMPATIBLE_IOCTL(RNDADDTOENTCNT) | ||
607 | COMPATIBLE_IOCTL(RNDGETPOOL) | ||
608 | COMPATIBLE_IOCTL(RNDADDENTROPY) | ||
609 | COMPATIBLE_IOCTL(RNDZAPENTCNT) | ||
610 | COMPATIBLE_IOCTL(RNDCLEARPOOL) | ||
611 | /* Bluetooth */ | ||
612 | COMPATIBLE_IOCTL(HCIDEVUP) | ||
613 | COMPATIBLE_IOCTL(HCIDEVDOWN) | ||
614 | COMPATIBLE_IOCTL(HCIDEVRESET) | ||
615 | COMPATIBLE_IOCTL(HCIDEVRESTAT) | ||
616 | COMPATIBLE_IOCTL(HCIGETDEVLIST) | ||
617 | COMPATIBLE_IOCTL(HCIGETDEVINFO) | ||
618 | COMPATIBLE_IOCTL(HCIGETCONNLIST) | ||
619 | COMPATIBLE_IOCTL(HCIGETCONNINFO) | ||
620 | COMPATIBLE_IOCTL(HCISETRAW) | ||
621 | COMPATIBLE_IOCTL(HCISETSCAN) | ||
622 | COMPATIBLE_IOCTL(HCISETAUTH) | ||
623 | COMPATIBLE_IOCTL(HCISETENCRYPT) | ||
624 | COMPATIBLE_IOCTL(HCISETPTYPE) | ||
625 | COMPATIBLE_IOCTL(HCISETLINKPOL) | ||
626 | COMPATIBLE_IOCTL(HCISETLINKMODE) | ||
627 | COMPATIBLE_IOCTL(HCISETACLMTU) | ||
628 | COMPATIBLE_IOCTL(HCISETSCOMTU) | ||
629 | COMPATIBLE_IOCTL(HCIINQUIRY) | ||
630 | COMPATIBLE_IOCTL(HCIUARTSETPROTO) | ||
631 | COMPATIBLE_IOCTL(HCIUARTGETPROTO) | ||
632 | COMPATIBLE_IOCTL(RFCOMMCREATEDEV) | ||
633 | COMPATIBLE_IOCTL(RFCOMMRELEASEDEV) | ||
634 | COMPATIBLE_IOCTL(RFCOMMGETDEVLIST) | ||
635 | COMPATIBLE_IOCTL(RFCOMMGETDEVINFO) | ||
636 | COMPATIBLE_IOCTL(RFCOMMSTEALDLC) | ||
637 | COMPATIBLE_IOCTL(BNEPCONNADD) | ||
638 | COMPATIBLE_IOCTL(BNEPCONNDEL) | ||
639 | COMPATIBLE_IOCTL(BNEPGETCONNLIST) | ||
640 | COMPATIBLE_IOCTL(BNEPGETCONNINFO) | ||
641 | COMPATIBLE_IOCTL(CMTPCONNADD) | ||
642 | COMPATIBLE_IOCTL(CMTPCONNDEL) | ||
643 | COMPATIBLE_IOCTL(CMTPGETCONNLIST) | ||
644 | COMPATIBLE_IOCTL(CMTPGETCONNINFO) | ||
645 | COMPATIBLE_IOCTL(HIDPCONNADD) | ||
646 | COMPATIBLE_IOCTL(HIDPCONNDEL) | ||
647 | COMPATIBLE_IOCTL(HIDPGETCONNLIST) | ||
648 | COMPATIBLE_IOCTL(HIDPGETCONNINFO) | ||
649 | /* CAPI */ | ||
650 | COMPATIBLE_IOCTL(CAPI_REGISTER) | ||
651 | COMPATIBLE_IOCTL(CAPI_GET_MANUFACTURER) | ||
652 | COMPATIBLE_IOCTL(CAPI_GET_VERSION) | ||
653 | COMPATIBLE_IOCTL(CAPI_GET_SERIAL) | ||
654 | COMPATIBLE_IOCTL(CAPI_GET_PROFILE) | ||
655 | COMPATIBLE_IOCTL(CAPI_MANUFACTURER_CMD) | ||
656 | COMPATIBLE_IOCTL(CAPI_GET_ERRCODE) | ||
657 | COMPATIBLE_IOCTL(CAPI_INSTALLED) | ||
658 | COMPATIBLE_IOCTL(CAPI_GET_FLAGS) | ||
659 | COMPATIBLE_IOCTL(CAPI_SET_FLAGS) | ||
660 | COMPATIBLE_IOCTL(CAPI_CLR_FLAGS) | ||
661 | COMPATIBLE_IOCTL(CAPI_NCCI_OPENCOUNT) | ||
662 | COMPATIBLE_IOCTL(CAPI_NCCI_GETUNIT) | ||
663 | /* Siemens Gigaset */ | ||
664 | COMPATIBLE_IOCTL(GIGASET_REDIR) | ||
665 | COMPATIBLE_IOCTL(GIGASET_CONFIG) | ||
666 | COMPATIBLE_IOCTL(GIGASET_BRKCHARS) | ||
667 | COMPATIBLE_IOCTL(GIGASET_VERSION) | ||
668 | /* Misc. */ | ||
669 | COMPATIBLE_IOCTL(0x41545900) /* ATYIO_CLKR */ | ||
670 | COMPATIBLE_IOCTL(0x41545901) /* ATYIO_CLKW */ | ||
671 | COMPATIBLE_IOCTL(PCIIOC_CONTROLLER) | ||
672 | COMPATIBLE_IOCTL(PCIIOC_MMAP_IS_IO) | ||
673 | COMPATIBLE_IOCTL(PCIIOC_MMAP_IS_MEM) | ||
674 | COMPATIBLE_IOCTL(PCIIOC_WRITE_COMBINE) | ||
675 | /* USB */ | ||
676 | COMPATIBLE_IOCTL(USBDEVFS_RESETEP) | ||
677 | COMPATIBLE_IOCTL(USBDEVFS_SETINTERFACE) | ||
678 | COMPATIBLE_IOCTL(USBDEVFS_SETCONFIGURATION) | ||
679 | COMPATIBLE_IOCTL(USBDEVFS_GETDRIVER) | ||
680 | COMPATIBLE_IOCTL(USBDEVFS_DISCARDURB) | ||
681 | COMPATIBLE_IOCTL(USBDEVFS_CLAIMINTERFACE) | ||
682 | COMPATIBLE_IOCTL(USBDEVFS_RELEASEINTERFACE) | ||
683 | COMPATIBLE_IOCTL(USBDEVFS_CONNECTINFO) | ||
684 | COMPATIBLE_IOCTL(USBDEVFS_HUB_PORTINFO) | ||
685 | COMPATIBLE_IOCTL(USBDEVFS_RESET) | ||
686 | COMPATIBLE_IOCTL(USBDEVFS_SUBMITURB32) | ||
687 | COMPATIBLE_IOCTL(USBDEVFS_REAPURB32) | ||
688 | COMPATIBLE_IOCTL(USBDEVFS_REAPURBNDELAY32) | ||
689 | COMPATIBLE_IOCTL(USBDEVFS_CLEAR_HALT) | ||
690 | /* MTD */ | ||
691 | COMPATIBLE_IOCTL(MEMGETINFO) | ||
692 | COMPATIBLE_IOCTL(MEMERASE) | ||
693 | COMPATIBLE_IOCTL(MEMLOCK) | ||
694 | COMPATIBLE_IOCTL(MEMUNLOCK) | ||
695 | COMPATIBLE_IOCTL(MEMGETREGIONCOUNT) | ||
696 | COMPATIBLE_IOCTL(MEMGETREGIONINFO) | ||
697 | COMPATIBLE_IOCTL(MEMGETBADBLOCK) | ||
698 | COMPATIBLE_IOCTL(MEMSETBADBLOCK) | ||
699 | /* NBD */ | ||
700 | ULONG_IOCTL(NBD_SET_SOCK) | ||
701 | ULONG_IOCTL(NBD_SET_BLKSIZE) | ||
702 | ULONG_IOCTL(NBD_SET_SIZE) | ||
703 | COMPATIBLE_IOCTL(NBD_DO_IT) | ||
704 | COMPATIBLE_IOCTL(NBD_CLEAR_SOCK) | ||
705 | COMPATIBLE_IOCTL(NBD_CLEAR_QUE) | ||
706 | COMPATIBLE_IOCTL(NBD_PRINT_DEBUG) | ||
707 | ULONG_IOCTL(NBD_SET_SIZE_BLOCKS) | ||
708 | COMPATIBLE_IOCTL(NBD_DISCONNECT) | ||
709 | /* i2c */ | ||
710 | COMPATIBLE_IOCTL(I2C_SLAVE) | ||
711 | COMPATIBLE_IOCTL(I2C_SLAVE_FORCE) | ||
712 | COMPATIBLE_IOCTL(I2C_TENBIT) | ||
713 | COMPATIBLE_IOCTL(I2C_PEC) | ||
714 | COMPATIBLE_IOCTL(I2C_RETRIES) | ||
715 | COMPATIBLE_IOCTL(I2C_TIMEOUT) | ||
716 | /* wireless */ | ||
717 | COMPATIBLE_IOCTL(SIOCSIWCOMMIT) | ||
718 | COMPATIBLE_IOCTL(SIOCGIWNAME) | ||
719 | COMPATIBLE_IOCTL(SIOCSIWNWID) | ||
720 | COMPATIBLE_IOCTL(SIOCGIWNWID) | ||
721 | COMPATIBLE_IOCTL(SIOCSIWFREQ) | ||
722 | COMPATIBLE_IOCTL(SIOCGIWFREQ) | ||
723 | COMPATIBLE_IOCTL(SIOCSIWMODE) | ||
724 | COMPATIBLE_IOCTL(SIOCGIWMODE) | ||
725 | COMPATIBLE_IOCTL(SIOCSIWSENS) | ||
726 | COMPATIBLE_IOCTL(SIOCGIWSENS) | ||
727 | COMPATIBLE_IOCTL(SIOCSIWRANGE) | ||
728 | COMPATIBLE_IOCTL(SIOCSIWPRIV) | ||
729 | COMPATIBLE_IOCTL(SIOCGIWPRIV) | ||
730 | COMPATIBLE_IOCTL(SIOCSIWSTATS) | ||
731 | COMPATIBLE_IOCTL(SIOCGIWSTATS) | ||
732 | COMPATIBLE_IOCTL(SIOCSIWAP) | ||
733 | COMPATIBLE_IOCTL(SIOCGIWAP) | ||
734 | COMPATIBLE_IOCTL(SIOCSIWSCAN) | ||
735 | COMPATIBLE_IOCTL(SIOCSIWRATE) | ||
736 | COMPATIBLE_IOCTL(SIOCGIWRATE) | ||
737 | COMPATIBLE_IOCTL(SIOCSIWRTS) | ||
738 | COMPATIBLE_IOCTL(SIOCGIWRTS) | ||
739 | COMPATIBLE_IOCTL(SIOCSIWFRAG) | ||
740 | COMPATIBLE_IOCTL(SIOCGIWFRAG) | ||
741 | COMPATIBLE_IOCTL(SIOCSIWTXPOW) | ||
742 | COMPATIBLE_IOCTL(SIOCGIWTXPOW) | ||
743 | COMPATIBLE_IOCTL(SIOCSIWRETRY) | ||
744 | COMPATIBLE_IOCTL(SIOCGIWRETRY) | ||
745 | COMPATIBLE_IOCTL(SIOCSIWPOWER) | ||
746 | COMPATIBLE_IOCTL(SIOCGIWPOWER) | ||
747 | /* hiddev */ | ||
748 | COMPATIBLE_IOCTL(HIDIOCGVERSION) | ||
749 | COMPATIBLE_IOCTL(HIDIOCAPPLICATION) | ||
750 | COMPATIBLE_IOCTL(HIDIOCGDEVINFO) | ||
751 | COMPATIBLE_IOCTL(HIDIOCGSTRING) | ||
752 | COMPATIBLE_IOCTL(HIDIOCINITREPORT) | ||
753 | COMPATIBLE_IOCTL(HIDIOCGREPORT) | ||
754 | COMPATIBLE_IOCTL(HIDIOCSREPORT) | ||
755 | COMPATIBLE_IOCTL(HIDIOCGREPORTINFO) | ||
756 | COMPATIBLE_IOCTL(HIDIOCGFIELDINFO) | ||
757 | COMPATIBLE_IOCTL(HIDIOCGUSAGE) | ||
758 | COMPATIBLE_IOCTL(HIDIOCSUSAGE) | ||
759 | COMPATIBLE_IOCTL(HIDIOCGUCODE) | ||
760 | COMPATIBLE_IOCTL(HIDIOCGFLAG) | ||
761 | COMPATIBLE_IOCTL(HIDIOCSFLAG) | ||
762 | COMPATIBLE_IOCTL(HIDIOCGCOLLECTIONINDEX) | ||
763 | COMPATIBLE_IOCTL(HIDIOCGCOLLECTIONINFO) | ||
764 | /* dvb */ | ||
765 | COMPATIBLE_IOCTL(AUDIO_STOP) | ||
766 | COMPATIBLE_IOCTL(AUDIO_PLAY) | ||
767 | COMPATIBLE_IOCTL(AUDIO_PAUSE) | ||
768 | COMPATIBLE_IOCTL(AUDIO_CONTINUE) | ||
769 | COMPATIBLE_IOCTL(AUDIO_SELECT_SOURCE) | ||
770 | COMPATIBLE_IOCTL(AUDIO_SET_MUTE) | ||
771 | COMPATIBLE_IOCTL(AUDIO_SET_AV_SYNC) | ||
772 | COMPATIBLE_IOCTL(AUDIO_SET_BYPASS_MODE) | ||
773 | COMPATIBLE_IOCTL(AUDIO_CHANNEL_SELECT) | ||
774 | COMPATIBLE_IOCTL(AUDIO_GET_STATUS) | ||
775 | COMPATIBLE_IOCTL(AUDIO_GET_CAPABILITIES) | ||
776 | COMPATIBLE_IOCTL(AUDIO_CLEAR_BUFFER) | ||
777 | COMPATIBLE_IOCTL(AUDIO_SET_ID) | ||
778 | COMPATIBLE_IOCTL(AUDIO_SET_MIXER) | ||
779 | COMPATIBLE_IOCTL(AUDIO_SET_STREAMTYPE) | ||
780 | COMPATIBLE_IOCTL(AUDIO_SET_EXT_ID) | ||
781 | COMPATIBLE_IOCTL(AUDIO_SET_ATTRIBUTES) | ||
782 | COMPATIBLE_IOCTL(AUDIO_SET_KARAOKE) | ||
783 | COMPATIBLE_IOCTL(DMX_START) | ||
784 | COMPATIBLE_IOCTL(DMX_STOP) | ||
785 | COMPATIBLE_IOCTL(DMX_SET_FILTER) | ||
786 | COMPATIBLE_IOCTL(DMX_SET_PES_FILTER) | ||
787 | COMPATIBLE_IOCTL(DMX_SET_BUFFER_SIZE) | ||
788 | COMPATIBLE_IOCTL(DMX_GET_PES_PIDS) | ||
789 | COMPATIBLE_IOCTL(DMX_GET_CAPS) | ||
790 | COMPATIBLE_IOCTL(DMX_SET_SOURCE) | ||
791 | COMPATIBLE_IOCTL(DMX_GET_STC) | ||
792 | COMPATIBLE_IOCTL(FE_GET_INFO) | ||
793 | COMPATIBLE_IOCTL(FE_DISEQC_RESET_OVERLOAD) | ||
794 | COMPATIBLE_IOCTL(FE_DISEQC_SEND_MASTER_CMD) | ||
795 | COMPATIBLE_IOCTL(FE_DISEQC_RECV_SLAVE_REPLY) | ||
796 | COMPATIBLE_IOCTL(FE_DISEQC_SEND_BURST) | ||
797 | COMPATIBLE_IOCTL(FE_SET_TONE) | ||
798 | COMPATIBLE_IOCTL(FE_SET_VOLTAGE) | ||
799 | COMPATIBLE_IOCTL(FE_ENABLE_HIGH_LNB_VOLTAGE) | ||
800 | COMPATIBLE_IOCTL(FE_READ_STATUS) | ||
801 | COMPATIBLE_IOCTL(FE_READ_BER) | ||
802 | COMPATIBLE_IOCTL(FE_READ_SIGNAL_STRENGTH) | ||
803 | COMPATIBLE_IOCTL(FE_READ_SNR) | ||
804 | COMPATIBLE_IOCTL(FE_READ_UNCORRECTED_BLOCKS) | ||
805 | COMPATIBLE_IOCTL(FE_SET_FRONTEND) | ||
806 | COMPATIBLE_IOCTL(FE_GET_FRONTEND) | ||
807 | COMPATIBLE_IOCTL(FE_GET_EVENT) | ||
808 | COMPATIBLE_IOCTL(FE_DISHNETWORK_SEND_LEGACY_CMD) | ||
809 | COMPATIBLE_IOCTL(VIDEO_STOP) | ||
810 | COMPATIBLE_IOCTL(VIDEO_PLAY) | ||
811 | COMPATIBLE_IOCTL(VIDEO_FREEZE) | ||
812 | COMPATIBLE_IOCTL(VIDEO_CONTINUE) | ||
813 | COMPATIBLE_IOCTL(VIDEO_SELECT_SOURCE) | ||
814 | COMPATIBLE_IOCTL(VIDEO_SET_BLANK) | ||
815 | COMPATIBLE_IOCTL(VIDEO_GET_STATUS) | ||
816 | COMPATIBLE_IOCTL(VIDEO_SET_DISPLAY_FORMAT) | ||
817 | COMPATIBLE_IOCTL(VIDEO_FAST_FORWARD) | ||
818 | COMPATIBLE_IOCTL(VIDEO_SLOWMOTION) | ||
819 | COMPATIBLE_IOCTL(VIDEO_GET_CAPABILITIES) | ||
820 | COMPATIBLE_IOCTL(VIDEO_CLEAR_BUFFER) | ||
821 | COMPATIBLE_IOCTL(VIDEO_SET_ID) | ||
822 | COMPATIBLE_IOCTL(VIDEO_SET_STREAMTYPE) | ||
823 | COMPATIBLE_IOCTL(VIDEO_SET_FORMAT) | ||
824 | COMPATIBLE_IOCTL(VIDEO_SET_SYSTEM) | ||
825 | COMPATIBLE_IOCTL(VIDEO_SET_HIGHLIGHT) | ||
826 | COMPATIBLE_IOCTL(VIDEO_SET_SPU) | ||
827 | COMPATIBLE_IOCTL(VIDEO_GET_NAVI) | ||
828 | COMPATIBLE_IOCTL(VIDEO_SET_ATTRIBUTES) | ||
829 | COMPATIBLE_IOCTL(VIDEO_GET_SIZE) | ||
830 | COMPATIBLE_IOCTL(VIDEO_GET_FRAME_RATE) | ||
diff --git a/include/linux/console.h b/include/linux/console.h index de25ee3b7919..62ef6e11d0d2 100644 --- a/include/linux/console.h +++ b/include/linux/console.h | |||
@@ -51,7 +51,7 @@ struct consw { | |||
51 | int (*con_scrolldelta)(struct vc_data *, int); | 51 | int (*con_scrolldelta)(struct vc_data *, int); |
52 | int (*con_set_origin)(struct vc_data *); | 52 | int (*con_set_origin)(struct vc_data *); |
53 | void (*con_save_screen)(struct vc_data *); | 53 | void (*con_save_screen)(struct vc_data *); |
54 | u8 (*con_build_attr)(struct vc_data *, u8, u8, u8, u8, u8); | 54 | u8 (*con_build_attr)(struct vc_data *, u8, u8, u8, u8, u8, u8); |
55 | void (*con_invert_region)(struct vc_data *, u16 *, int); | 55 | void (*con_invert_region)(struct vc_data *, u16 *, int); |
56 | u16 *(*con_screen_pos)(struct vc_data *, int); | 56 | u16 *(*con_screen_pos)(struct vc_data *, int); |
57 | unsigned long (*con_getxy)(struct vc_data *, unsigned long, int *, int *); | 57 | unsigned long (*con_getxy)(struct vc_data *, unsigned long, int *, int *); |
@@ -92,9 +92,8 @@ void give_up_console(const struct consw *sw); | |||
92 | #define CON_BOOT (8) | 92 | #define CON_BOOT (8) |
93 | #define CON_ANYTIME (16) /* Safe to call when cpu is offline */ | 93 | #define CON_ANYTIME (16) /* Safe to call when cpu is offline */ |
94 | 94 | ||
95 | struct console | 95 | struct console { |
96 | { | 96 | char name[16]; |
97 | char name[8]; | ||
98 | void (*write)(struct console *, const char *, unsigned); | 97 | void (*write)(struct console *, const char *, unsigned); |
99 | int (*read)(struct console *, char *, unsigned); | 98 | int (*read)(struct console *, char *, unsigned); |
100 | struct tty_driver *(*device)(struct console *, int *); | 99 | struct tty_driver *(*device)(struct console *, int *); |
diff --git a/include/linux/console_struct.h b/include/linux/console_struct.h index a86162b26c0d..a461f76fb004 100644 --- a/include/linux/console_struct.h +++ b/include/linux/console_struct.h | |||
@@ -37,6 +37,7 @@ struct vc_data { | |||
37 | unsigned char vc_color; /* Foreground & background */ | 37 | unsigned char vc_color; /* Foreground & background */ |
38 | unsigned char vc_s_color; /* Saved foreground & background */ | 38 | unsigned char vc_s_color; /* Saved foreground & background */ |
39 | unsigned char vc_ulcolor; /* Color for underline mode */ | 39 | unsigned char vc_ulcolor; /* Color for underline mode */ |
40 | unsigned char vc_itcolor; | ||
40 | unsigned char vc_halfcolor; /* Color for half intensity mode */ | 41 | unsigned char vc_halfcolor; /* Color for half intensity mode */ |
41 | /* cursor */ | 42 | /* cursor */ |
42 | unsigned int vc_cursor_type; | 43 | unsigned int vc_cursor_type; |
@@ -71,10 +72,12 @@ struct vc_data { | |||
71 | unsigned int vc_deccolm : 1; /* 80/132 Column Mode */ | 72 | unsigned int vc_deccolm : 1; /* 80/132 Column Mode */ |
72 | /* attribute flags */ | 73 | /* attribute flags */ |
73 | unsigned int vc_intensity : 2; /* 0=half-bright, 1=normal, 2=bold */ | 74 | unsigned int vc_intensity : 2; /* 0=half-bright, 1=normal, 2=bold */ |
75 | unsigned int vc_italic:1; | ||
74 | unsigned int vc_underline : 1; | 76 | unsigned int vc_underline : 1; |
75 | unsigned int vc_blink : 1; | 77 | unsigned int vc_blink : 1; |
76 | unsigned int vc_reverse : 1; | 78 | unsigned int vc_reverse : 1; |
77 | unsigned int vc_s_intensity : 2; /* saved rendition */ | 79 | unsigned int vc_s_intensity : 2; /* saved rendition */ |
80 | unsigned int vc_s_italic:1; | ||
78 | unsigned int vc_s_underline : 1; | 81 | unsigned int vc_s_underline : 1; |
79 | unsigned int vc_s_blink : 1; | 82 | unsigned int vc_s_blink : 1; |
80 | unsigned int vc_s_reverse : 1; | 83 | unsigned int vc_s_reverse : 1; |
diff --git a/include/linux/const.h b/include/linux/const.h new file mode 100644 index 000000000000..07b300bfe34b --- /dev/null +++ b/include/linux/const.h | |||
@@ -0,0 +1,19 @@ | |||
1 | /* const.h: Macros for dealing with constants. */ | ||
2 | |||
3 | #ifndef _LINUX_CONST_H | ||
4 | #define _LINUX_CONST_H | ||
5 | |||
6 | /* Some constant macros are used in both assembler and | ||
7 | * C code. Therefore we cannot annotate them always with | ||
8 | * 'UL' and other type specifiers unilaterally. We | ||
9 | * use the following macros to deal with this. | ||
10 | */ | ||
11 | |||
12 | #ifdef __ASSEMBLY__ | ||
13 | #define _AC(X,Y) X | ||
14 | #else | ||
15 | #define __AC(X,Y) (X##Y) | ||
16 | #define _AC(X,Y) __AC(X,Y) | ||
17 | #endif | ||
18 | |||
19 | #endif /* !(_LINUX_CONST_H) */ | ||
diff --git a/include/linux/cpu.h b/include/linux/cpu.h index c22b0dfcbcd2..3b2df2523f1d 100644 --- a/include/linux/cpu.h +++ b/include/linux/cpu.h | |||
@@ -41,6 +41,9 @@ extern void cpu_remove_sysdev_attr(struct sysdev_attribute *attr); | |||
41 | extern int cpu_add_sysdev_attr_group(struct attribute_group *attrs); | 41 | extern int cpu_add_sysdev_attr_group(struct attribute_group *attrs); |
42 | extern void cpu_remove_sysdev_attr_group(struct attribute_group *attrs); | 42 | extern void cpu_remove_sysdev_attr_group(struct attribute_group *attrs); |
43 | 43 | ||
44 | extern struct sysdev_attribute attr_sched_mc_power_savings; | ||
45 | extern struct sysdev_attribute attr_sched_smt_power_savings; | ||
46 | extern int sched_create_sysfs_power_savings_entries(struct sysdev_class *cls); | ||
44 | 47 | ||
45 | #ifdef CONFIG_HOTPLUG_CPU | 48 | #ifdef CONFIG_HOTPLUG_CPU |
46 | extern void unregister_cpu(struct cpu *cpu); | 49 | extern void unregister_cpu(struct cpu *cpu); |
diff --git a/include/linux/cyclades.h b/include/linux/cyclades.h index 46d8254c1a79..72aa00cc4b2d 100644 --- a/include/linux/cyclades.h +++ b/include/linux/cyclades.h | |||
@@ -67,6 +67,8 @@ | |||
67 | #ifndef _LINUX_CYCLADES_H | 67 | #ifndef _LINUX_CYCLADES_H |
68 | #define _LINUX_CYCLADES_H | 68 | #define _LINUX_CYCLADES_H |
69 | 69 | ||
70 | #include <linux/types.h> | ||
71 | |||
70 | struct cyclades_monitor { | 72 | struct cyclades_monitor { |
71 | unsigned long int_count; | 73 | unsigned long int_count; |
72 | unsigned long char_count; | 74 | unsigned long char_count; |
@@ -108,7 +110,6 @@ struct cyclades_idle_stats { | |||
108 | #define CYZSETPOLLCYCLE 0x43590e | 110 | #define CYZSETPOLLCYCLE 0x43590e |
109 | #define CYZGETPOLLCYCLE 0x43590f | 111 | #define CYZGETPOLLCYCLE 0x43590f |
110 | #define CYGETCD1400VER 0x435910 | 112 | #define CYGETCD1400VER 0x435910 |
111 | #define CYGETCARDINFO 0x435911 | ||
112 | #define CYSETWAIT 0x435912 | 113 | #define CYSETWAIT 0x435912 |
113 | #define CYGETWAIT 0x435913 | 114 | #define CYGETWAIT 0x435913 |
114 | 115 | ||
@@ -149,14 +150,12 @@ struct CYZ_BOOT_CTRL { | |||
149 | * architectures and compilers. | 150 | * architectures and compilers. |
150 | */ | 151 | */ |
151 | 152 | ||
152 | #if defined(__alpha__) | 153 | #include <asm/types.h> |
153 | typedef unsigned long ucdouble; /* 64 bits, unsigned */ | 154 | |
154 | typedef unsigned int uclong; /* 32 bits, unsigned */ | 155 | typedef __u64 ucdouble; /* 64 bits, unsigned */ |
155 | #else | 156 | typedef __u32 uclong; /* 32 bits, unsigned */ |
156 | typedef unsigned long uclong; /* 32 bits, unsigned */ | 157 | typedef __u16 ucshort; /* 16 bits, unsigned */ |
157 | #endif | 158 | typedef __u8 ucchar; /* 8 bits, unsigned */ |
158 | typedef unsigned short ucshort; /* 16 bits, unsigned */ | ||
159 | typedef unsigned char ucchar; /* 8 bits, unsigned */ | ||
160 | 159 | ||
161 | /* | 160 | /* |
162 | * Memory Window Sizes | 161 | * Memory Window Sizes |
@@ -174,24 +173,24 @@ typedef unsigned char ucchar; /* 8 bits, unsigned */ | |||
174 | */ | 173 | */ |
175 | 174 | ||
176 | struct CUSTOM_REG { | 175 | struct CUSTOM_REG { |
177 | uclong fpga_id; /* FPGA Identification Register */ | 176 | __u32 fpga_id; /* FPGA Identification Register */ |
178 | uclong fpga_version; /* FPGA Version Number Register */ | 177 | __u32 fpga_version; /* FPGA Version Number Register */ |
179 | uclong cpu_start; /* CPU start Register (write) */ | 178 | __u32 cpu_start; /* CPU start Register (write) */ |
180 | uclong cpu_stop; /* CPU stop Register (write) */ | 179 | __u32 cpu_stop; /* CPU stop Register (write) */ |
181 | uclong misc_reg; /* Miscelaneous Register */ | 180 | __u32 misc_reg; /* Miscelaneous Register */ |
182 | uclong idt_mode; /* IDT mode Register */ | 181 | __u32 idt_mode; /* IDT mode Register */ |
183 | uclong uart_irq_status; /* UART IRQ status Register */ | 182 | __u32 uart_irq_status; /* UART IRQ status Register */ |
184 | uclong clear_timer0_irq; /* Clear timer interrupt Register */ | 183 | __u32 clear_timer0_irq; /* Clear timer interrupt Register */ |
185 | uclong clear_timer1_irq; /* Clear timer interrupt Register */ | 184 | __u32 clear_timer1_irq; /* Clear timer interrupt Register */ |
186 | uclong clear_timer2_irq; /* Clear timer interrupt Register */ | 185 | __u32 clear_timer2_irq; /* Clear timer interrupt Register */ |
187 | uclong test_register; /* Test Register */ | 186 | __u32 test_register; /* Test Register */ |
188 | uclong test_count; /* Test Count Register */ | 187 | __u32 test_count; /* Test Count Register */ |
189 | uclong timer_select; /* Timer select register */ | 188 | __u32 timer_select; /* Timer select register */ |
190 | uclong pr_uart_irq_status; /* Prioritized UART IRQ stat Reg */ | 189 | __u32 pr_uart_irq_status; /* Prioritized UART IRQ stat Reg */ |
191 | uclong ram_wait_state; /* RAM wait-state Register */ | 190 | __u32 ram_wait_state; /* RAM wait-state Register */ |
192 | uclong uart_wait_state; /* UART wait-state Register */ | 191 | __u32 uart_wait_state; /* UART wait-state Register */ |
193 | uclong timer_wait_state; /* timer wait-state Register */ | 192 | __u32 timer_wait_state; /* timer wait-state Register */ |
194 | uclong ack_wait_state; /* ACK wait State Register */ | 193 | __u32 ack_wait_state; /* ACK wait State Register */ |
195 | }; | 194 | }; |
196 | 195 | ||
197 | /* | 196 | /* |
@@ -201,34 +200,34 @@ struct CUSTOM_REG { | |||
201 | */ | 200 | */ |
202 | 201 | ||
203 | struct RUNTIME_9060 { | 202 | struct RUNTIME_9060 { |
204 | uclong loc_addr_range; /* 00h - Local Address Range */ | 203 | __u32 loc_addr_range; /* 00h - Local Address Range */ |
205 | uclong loc_addr_base; /* 04h - Local Address Base */ | 204 | __u32 loc_addr_base; /* 04h - Local Address Base */ |
206 | uclong loc_arbitr; /* 08h - Local Arbitration */ | 205 | __u32 loc_arbitr; /* 08h - Local Arbitration */ |
207 | uclong endian_descr; /* 0Ch - Big/Little Endian Descriptor */ | 206 | __u32 endian_descr; /* 0Ch - Big/Little Endian Descriptor */ |
208 | uclong loc_rom_range; /* 10h - Local ROM Range */ | 207 | __u32 loc_rom_range; /* 10h - Local ROM Range */ |
209 | uclong loc_rom_base; /* 14h - Local ROM Base */ | 208 | __u32 loc_rom_base; /* 14h - Local ROM Base */ |
210 | uclong loc_bus_descr; /* 18h - Local Bus descriptor */ | 209 | __u32 loc_bus_descr; /* 18h - Local Bus descriptor */ |
211 | uclong loc_range_mst; /* 1Ch - Local Range for Master to PCI */ | 210 | __u32 loc_range_mst; /* 1Ch - Local Range for Master to PCI */ |
212 | uclong loc_base_mst; /* 20h - Local Base for Master PCI */ | 211 | __u32 loc_base_mst; /* 20h - Local Base for Master PCI */ |
213 | uclong loc_range_io; /* 24h - Local Range for Master IO */ | 212 | __u32 loc_range_io; /* 24h - Local Range for Master IO */ |
214 | uclong pci_base_mst; /* 28h - PCI Base for Master PCI */ | 213 | __u32 pci_base_mst; /* 28h - PCI Base for Master PCI */ |
215 | uclong pci_conf_io; /* 2Ch - PCI configuration for Master IO */ | 214 | __u32 pci_conf_io; /* 2Ch - PCI configuration for Master IO */ |
216 | uclong filler1; /* 30h */ | 215 | __u32 filler1; /* 30h */ |
217 | uclong filler2; /* 34h */ | 216 | __u32 filler2; /* 34h */ |
218 | uclong filler3; /* 38h */ | 217 | __u32 filler3; /* 38h */ |
219 | uclong filler4; /* 3Ch */ | 218 | __u32 filler4; /* 3Ch */ |
220 | uclong mail_box_0; /* 40h - Mail Box 0 */ | 219 | __u32 mail_box_0; /* 40h - Mail Box 0 */ |
221 | uclong mail_box_1; /* 44h - Mail Box 1 */ | 220 | __u32 mail_box_1; /* 44h - Mail Box 1 */ |
222 | uclong mail_box_2; /* 48h - Mail Box 2 */ | 221 | __u32 mail_box_2; /* 48h - Mail Box 2 */ |
223 | uclong mail_box_3; /* 4Ch - Mail Box 3 */ | 222 | __u32 mail_box_3; /* 4Ch - Mail Box 3 */ |
224 | uclong filler5; /* 50h */ | 223 | __u32 filler5; /* 50h */ |
225 | uclong filler6; /* 54h */ | 224 | __u32 filler6; /* 54h */ |
226 | uclong filler7; /* 58h */ | 225 | __u32 filler7; /* 58h */ |
227 | uclong filler8; /* 5Ch */ | 226 | __u32 filler8; /* 5Ch */ |
228 | uclong pci_doorbell; /* 60h - PCI to Local Doorbell */ | 227 | __u32 pci_doorbell; /* 60h - PCI to Local Doorbell */ |
229 | uclong loc_doorbell; /* 64h - Local to PCI Doorbell */ | 228 | __u32 loc_doorbell; /* 64h - Local to PCI Doorbell */ |
230 | uclong intr_ctrl_stat; /* 68h - Interrupt Control/Status */ | 229 | __u32 intr_ctrl_stat; /* 68h - Interrupt Control/Status */ |
231 | uclong init_ctrl; /* 6Ch - EEPROM control, Init Control, etc */ | 230 | __u32 init_ctrl; /* 6Ch - EEPROM control, Init Control, etc */ |
232 | }; | 231 | }; |
233 | 232 | ||
234 | /* Values for the Local Base Address re-map register */ | 233 | /* Values for the Local Base Address re-map register */ |
@@ -270,8 +269,8 @@ struct RUNTIME_9060 { | |||
270 | #define ZF_TINACT ZF_TINACT_DEF | 269 | #define ZF_TINACT ZF_TINACT_DEF |
271 | 270 | ||
272 | struct FIRM_ID { | 271 | struct FIRM_ID { |
273 | uclong signature; /* ZFIRM/U signature */ | 272 | __u32 signature; /* ZFIRM/U signature */ |
274 | uclong zfwctrl_addr; /* pointer to ZFW_CTRL structure */ | 273 | __u32 zfwctrl_addr; /* pointer to ZFW_CTRL structure */ |
275 | }; | 274 | }; |
276 | 275 | ||
277 | /* Op. System id */ | 276 | /* Op. System id */ |
@@ -408,24 +407,24 @@ struct FIRM_ID { | |||
408 | */ | 407 | */ |
409 | 408 | ||
410 | struct CH_CTRL { | 409 | struct CH_CTRL { |
411 | uclong op_mode; /* operation mode */ | 410 | __u32 op_mode; /* operation mode */ |
412 | uclong intr_enable; /* interrupt masking */ | 411 | __u32 intr_enable; /* interrupt masking */ |
413 | uclong sw_flow; /* SW flow control */ | 412 | __u32 sw_flow; /* SW flow control */ |
414 | uclong flow_status; /* output flow status */ | 413 | __u32 flow_status; /* output flow status */ |
415 | uclong comm_baud; /* baud rate - numerically specified */ | 414 | __u32 comm_baud; /* baud rate - numerically specified */ |
416 | uclong comm_parity; /* parity */ | 415 | __u32 comm_parity; /* parity */ |
417 | uclong comm_data_l; /* data length/stop */ | 416 | __u32 comm_data_l; /* data length/stop */ |
418 | uclong comm_flags; /* other flags */ | 417 | __u32 comm_flags; /* other flags */ |
419 | uclong hw_flow; /* HW flow control */ | 418 | __u32 hw_flow; /* HW flow control */ |
420 | uclong rs_control; /* RS-232 outputs */ | 419 | __u32 rs_control; /* RS-232 outputs */ |
421 | uclong rs_status; /* RS-232 inputs */ | 420 | __u32 rs_status; /* RS-232 inputs */ |
422 | uclong flow_xon; /* xon char */ | 421 | __u32 flow_xon; /* xon char */ |
423 | uclong flow_xoff; /* xoff char */ | 422 | __u32 flow_xoff; /* xoff char */ |
424 | uclong hw_overflow; /* hw overflow counter */ | 423 | __u32 hw_overflow; /* hw overflow counter */ |
425 | uclong sw_overflow; /* sw overflow counter */ | 424 | __u32 sw_overflow; /* sw overflow counter */ |
426 | uclong comm_error; /* frame/parity error counter */ | 425 | __u32 comm_error; /* frame/parity error counter */ |
427 | uclong ichar; | 426 | __u32 ichar; |
428 | uclong filler[7]; | 427 | __u32 filler[7]; |
429 | }; | 428 | }; |
430 | 429 | ||
431 | 430 | ||
@@ -435,18 +434,18 @@ struct CH_CTRL { | |||
435 | */ | 434 | */ |
436 | 435 | ||
437 | struct BUF_CTRL { | 436 | struct BUF_CTRL { |
438 | uclong flag_dma; /* buffers are in Host memory */ | 437 | __u32 flag_dma; /* buffers are in Host memory */ |
439 | uclong tx_bufaddr; /* address of the tx buffer */ | 438 | __u32 tx_bufaddr; /* address of the tx buffer */ |
440 | uclong tx_bufsize; /* tx buffer size */ | 439 | __u32 tx_bufsize; /* tx buffer size */ |
441 | uclong tx_threshold; /* tx low water mark */ | 440 | __u32 tx_threshold; /* tx low water mark */ |
442 | uclong tx_get; /* tail index tx buf */ | 441 | __u32 tx_get; /* tail index tx buf */ |
443 | uclong tx_put; /* head index tx buf */ | 442 | __u32 tx_put; /* head index tx buf */ |
444 | uclong rx_bufaddr; /* address of the rx buffer */ | 443 | __u32 rx_bufaddr; /* address of the rx buffer */ |
445 | uclong rx_bufsize; /* rx buffer size */ | 444 | __u32 rx_bufsize; /* rx buffer size */ |
446 | uclong rx_threshold; /* rx high water mark */ | 445 | __u32 rx_threshold; /* rx high water mark */ |
447 | uclong rx_get; /* tail index rx buf */ | 446 | __u32 rx_get; /* tail index rx buf */ |
448 | uclong rx_put; /* head index rx buf */ | 447 | __u32 rx_put; /* head index rx buf */ |
449 | uclong filler[5]; /* filler to align structures */ | 448 | __u32 filler[5]; /* filler to align structures */ |
450 | }; | 449 | }; |
451 | 450 | ||
452 | /* | 451 | /* |
@@ -457,27 +456,27 @@ struct BUF_CTRL { | |||
457 | struct BOARD_CTRL { | 456 | struct BOARD_CTRL { |
458 | 457 | ||
459 | /* static info provided by the on-board CPU */ | 458 | /* static info provided by the on-board CPU */ |
460 | uclong n_channel; /* number of channels */ | 459 | __u32 n_channel; /* number of channels */ |
461 | uclong fw_version; /* firmware version */ | 460 | __u32 fw_version; /* firmware version */ |
462 | 461 | ||
463 | /* static info provided by the driver */ | 462 | /* static info provided by the driver */ |
464 | uclong op_system; /* op_system id */ | 463 | __u32 op_system; /* op_system id */ |
465 | uclong dr_version; /* driver version */ | 464 | __u32 dr_version; /* driver version */ |
466 | 465 | ||
467 | /* board control area */ | 466 | /* board control area */ |
468 | uclong inactivity; /* inactivity control */ | 467 | __u32 inactivity; /* inactivity control */ |
469 | 468 | ||
470 | /* host to FW commands */ | 469 | /* host to FW commands */ |
471 | uclong hcmd_channel; /* channel number */ | 470 | __u32 hcmd_channel; /* channel number */ |
472 | uclong hcmd_param; /* pointer to parameters */ | 471 | __u32 hcmd_param; /* pointer to parameters */ |
473 | 472 | ||
474 | /* FW to Host commands */ | 473 | /* FW to Host commands */ |
475 | uclong fwcmd_channel; /* channel number */ | 474 | __u32 fwcmd_channel; /* channel number */ |
476 | uclong fwcmd_param; /* pointer to parameters */ | 475 | __u32 fwcmd_param; /* pointer to parameters */ |
477 | uclong zf_int_queue_addr; /* offset for INT_QUEUE structure */ | 476 | __u32 zf_int_queue_addr; /* offset for INT_QUEUE structure */ |
478 | 477 | ||
479 | /* filler so the structures are aligned */ | 478 | /* filler so the structures are aligned */ |
480 | uclong filler[6]; | 479 | __u32 filler[6]; |
481 | }; | 480 | }; |
482 | 481 | ||
483 | /* Host Interrupt Queue */ | 482 | /* Host Interrupt Queue */ |
@@ -506,11 +505,10 @@ struct ZFW_CTRL { | |||
506 | /****************** ****************** *******************/ | 505 | /****************** ****************** *******************/ |
507 | #endif | 506 | #endif |
508 | 507 | ||
508 | #ifdef __KERNEL__ | ||
509 | |||
509 | /* Per card data structure */ | 510 | /* Per card data structure */ |
510 | struct resource; | ||
511 | struct cyclades_card { | 511 | struct cyclades_card { |
512 | unsigned long base_phys; | ||
513 | unsigned long ctl_phys; | ||
514 | void __iomem *base_addr; | 512 | void __iomem *base_addr; |
515 | void __iomem *ctl_addr; | 513 | void __iomem *ctl_addr; |
516 | int irq; | 514 | int irq; |
@@ -519,33 +517,18 @@ struct cyclades_card { | |||
519 | int nports; /* Number of ports in the card */ | 517 | int nports; /* Number of ports in the card */ |
520 | int bus_index; /* address shift - 0 for ISA, 1 for PCI */ | 518 | int bus_index; /* address shift - 0 for ISA, 1 for PCI */ |
521 | int intr_enabled; /* FW Interrupt flag - 0 disabled, 1 enabled */ | 519 | int intr_enabled; /* FW Interrupt flag - 0 disabled, 1 enabled */ |
522 | struct pci_dev *pdev; | ||
523 | #ifdef __KERNEL__ | ||
524 | spinlock_t card_lock; | 520 | spinlock_t card_lock; |
525 | #else | 521 | struct cyclades_port *ports; |
526 | unsigned long filler; | ||
527 | #endif | ||
528 | }; | 522 | }; |
529 | 523 | ||
530 | struct cyclades_chip { | ||
531 | int filler; | ||
532 | }; | ||
533 | |||
534 | |||
535 | #ifdef __KERNEL__ | ||
536 | |||
537 | /*************************************** | 524 | /*************************************** |
538 | * Memory access functions/macros * | 525 | * Memory access functions/macros * |
539 | * (required to support Alpha systems) * | 526 | * (required to support Alpha systems) * |
540 | ***************************************/ | 527 | ***************************************/ |
541 | 528 | ||
542 | #define cy_writeb(port,val) {writeb((val),(port)); mb();} | 529 | #define cy_writeb(port,val) do { writeb((val), (port)); mb(); } while (0) |
543 | #define cy_writew(port,val) {writew((val),(port)); mb();} | 530 | #define cy_writew(port,val) do { writew((val), (port)); mb(); } while (0) |
544 | #define cy_writel(port,val) {writel((val),(port)); mb();} | 531 | #define cy_writel(port,val) do { writel((val), (port)); mb(); } while (0) |
545 | |||
546 | #define cy_readb(port) readb(port) | ||
547 | #define cy_readw(port) readw(port) | ||
548 | #define cy_readl(port) readl(port) | ||
549 | 532 | ||
550 | /* | 533 | /* |
551 | * Statistics counters | 534 | * Statistics counters |
@@ -567,7 +550,7 @@ struct cyclades_icount { | |||
567 | 550 | ||
568 | struct cyclades_port { | 551 | struct cyclades_port { |
569 | int magic; | 552 | int magic; |
570 | int card; | 553 | struct cyclades_card *card; |
571 | int line; | 554 | int line; |
572 | int flags; /* defined in tty.h */ | 555 | int flags; /* defined in tty.h */ |
573 | int type; /* UART type */ | 556 | int type; /* UART type */ |
@@ -587,7 +570,6 @@ struct cyclades_port { | |||
587 | int close_delay; | 570 | int close_delay; |
588 | unsigned short closing_wait; | 571 | unsigned short closing_wait; |
589 | unsigned long event; | 572 | unsigned long event; |
590 | unsigned long last_active; | ||
591 | int count; /* # of fd on device */ | 573 | int count; /* # of fd on device */ |
592 | int breakon; | 574 | int breakon; |
593 | int breakoff; | 575 | int breakoff; |
@@ -598,7 +580,6 @@ struct cyclades_port { | |||
598 | int xmit_cnt; | 580 | int xmit_cnt; |
599 | int default_threshold; | 581 | int default_threshold; |
600 | int default_timeout; | 582 | int default_timeout; |
601 | unsigned long jiffies[3]; | ||
602 | unsigned long rflush_count; | 583 | unsigned long rflush_count; |
603 | struct cyclades_monitor mon; | 584 | struct cyclades_monitor mon; |
604 | struct cyclades_idle_stats idle_stats; | 585 | struct cyclades_idle_stats idle_stats; |
@@ -606,7 +587,7 @@ struct cyclades_port { | |||
606 | struct work_struct tqueue; | 587 | struct work_struct tqueue; |
607 | wait_queue_head_t open_wait; | 588 | wait_queue_head_t open_wait; |
608 | wait_queue_head_t close_wait; | 589 | wait_queue_head_t close_wait; |
609 | wait_queue_head_t shutdown_wait; | 590 | struct completion shutdown_wait; |
610 | wait_queue_head_t delta_msr_wait; | 591 | wait_queue_head_t delta_msr_wait; |
611 | int throttle; | 592 | int throttle; |
612 | }; | 593 | }; |
diff --git a/include/linux/dcache.h b/include/linux/dcache.h index 63f64a9a5bf7..aab53df4fafa 100644 --- a/include/linux/dcache.h +++ b/include/linux/dcache.h | |||
@@ -133,6 +133,7 @@ struct dentry_operations { | |||
133 | int (*d_delete)(struct dentry *); | 133 | int (*d_delete)(struct dentry *); |
134 | void (*d_release)(struct dentry *); | 134 | void (*d_release)(struct dentry *); |
135 | void (*d_iput)(struct dentry *, struct inode *); | 135 | void (*d_iput)(struct dentry *, struct inode *); |
136 | char *(*d_dname)(struct dentry *, char *, int); | ||
136 | }; | 137 | }; |
137 | 138 | ||
138 | /* the dentry parameter passed to d_hash and d_compare is the parent | 139 | /* the dentry parameter passed to d_hash and d_compare is the parent |
@@ -293,6 +294,11 @@ extern struct dentry * d_hash_and_lookup(struct dentry *, struct qstr *); | |||
293 | /* validate "insecure" dentry pointer */ | 294 | /* validate "insecure" dentry pointer */ |
294 | extern int d_validate(struct dentry *, struct dentry *); | 295 | extern int d_validate(struct dentry *, struct dentry *); |
295 | 296 | ||
297 | /* | ||
298 | * helper function for dentry_operations.d_dname() members | ||
299 | */ | ||
300 | extern char *dynamic_dname(struct dentry *, char *, int, const char *, ...); | ||
301 | |||
296 | extern char * d_path(struct dentry *, struct vfsmount *, char *, int); | 302 | extern char * d_path(struct dentry *, struct vfsmount *, char *, int); |
297 | 303 | ||
298 | /* Allocation counts.. */ | 304 | /* Allocation counts.. */ |
diff --git a/include/linux/device.h b/include/linux/device.h index 6579068134d1..2e1a2988b7e1 100644 --- a/include/linux/device.h +++ b/include/linux/device.h | |||
@@ -412,12 +412,13 @@ struct device { | |||
412 | struct klist_node knode_parent; /* node in sibling list */ | 412 | struct klist_node knode_parent; /* node in sibling list */ |
413 | struct klist_node knode_driver; | 413 | struct klist_node knode_driver; |
414 | struct klist_node knode_bus; | 414 | struct klist_node knode_bus; |
415 | struct device * parent; | 415 | struct device *parent; |
416 | 416 | ||
417 | struct kobject kobj; | 417 | struct kobject kobj; |
418 | char bus_id[BUS_ID_SIZE]; /* position on parent bus */ | 418 | char bus_id[BUS_ID_SIZE]; /* position on parent bus */ |
419 | struct device_type *type; | 419 | struct device_type *type; |
420 | unsigned is_registered:1; | 420 | unsigned is_registered:1; |
421 | unsigned uevent_suppress:1; | ||
421 | struct device_attribute uevent_attr; | 422 | struct device_attribute uevent_attr; |
422 | struct device_attribute *devt_attr; | 423 | struct device_attribute *devt_attr; |
423 | 424 | ||
@@ -458,7 +459,6 @@ struct device { | |||
458 | struct class *class; | 459 | struct class *class; |
459 | dev_t devt; /* dev_t, creates the sysfs "dev" */ | 460 | dev_t devt; /* dev_t, creates the sysfs "dev" */ |
460 | struct attribute_group **groups; /* optional groups */ | 461 | struct attribute_group **groups; /* optional groups */ |
461 | int uevent_suppress; | ||
462 | 462 | ||
463 | void (*release)(struct device * dev); | 463 | void (*release)(struct device * dev); |
464 | }; | 464 | }; |
diff --git a/include/linux/display.h b/include/linux/display.h new file mode 100644 index 000000000000..3bf70d639728 --- /dev/null +++ b/include/linux/display.h | |||
@@ -0,0 +1,61 @@ | |||
1 | /* | ||
2 | * Copyright (C) 2006 James Simmons <jsimmons@infradead.org> | ||
3 | * | ||
4 | * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License as published by | ||
8 | * the Free Software Foundation; either version 2 of the License, or (at | ||
9 | * your option) any later version. | ||
10 | * | ||
11 | * This program is distributed in the hope that it will be useful, but | ||
12 | * WITHOUT ANY WARRANTY; without even the implied warranty of | ||
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
14 | * General Public License for more details. | ||
15 | * | ||
16 | * You should have received a copy of the GNU General Public License along | ||
17 | * with this program; if not, write to the Free Software Foundation, Inc., | ||
18 | * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. | ||
19 | * | ||
20 | * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
21 | */ | ||
22 | |||
23 | #ifndef _LINUX_DISPLAY_H | ||
24 | #define _LINUX_DISPLAY_H | ||
25 | |||
26 | #include <linux/device.h> | ||
27 | |||
28 | struct display_device; | ||
29 | |||
30 | /* This structure defines all the properties of a Display. */ | ||
31 | struct display_driver { | ||
32 | int (*set_contrast)(struct display_device *, unsigned int); | ||
33 | int (*get_contrast)(struct display_device *); | ||
34 | void (*suspend)(struct display_device *, pm_message_t state); | ||
35 | void (*resume)(struct display_device *); | ||
36 | int (*probe)(struct display_device *, void *); | ||
37 | int (*remove)(struct display_device *); | ||
38 | int max_contrast; | ||
39 | }; | ||
40 | |||
41 | struct display_device { | ||
42 | struct module *owner; /* Owner module */ | ||
43 | struct display_driver *driver; | ||
44 | struct device *parent; /* This is the parent */ | ||
45 | struct device *dev; /* This is this display device */ | ||
46 | struct mutex lock; | ||
47 | void *priv_data; | ||
48 | char type[16]; | ||
49 | char *name; | ||
50 | int idx; | ||
51 | }; | ||
52 | |||
53 | extern struct display_device *display_device_register(struct display_driver *driver, | ||
54 | struct device *dev, void *devdata); | ||
55 | extern void display_device_unregister(struct display_device *dev); | ||
56 | |||
57 | extern int probe_edid(struct display_device *dev, void *devdata); | ||
58 | |||
59 | #define to_display_device(obj) container_of(obj, struct display_device, class_dev) | ||
60 | |||
61 | #endif | ||
diff --git a/include/linux/ds1wm.h b/include/linux/ds1wm.h new file mode 100644 index 000000000000..31f6e3c427fb --- /dev/null +++ b/include/linux/ds1wm.h | |||
@@ -0,0 +1,11 @@ | |||
1 | /* platform data for the DS1WM driver */ | ||
2 | |||
3 | struct ds1wm_platform_data { | ||
4 | int bus_shift; /* number of shifts needed to calculate the | ||
5 | * offset between DS1WM registers; | ||
6 | * e.g. on h5xxx and h2200 this is 2 | ||
7 | * (registers aligned to 4-byte boundaries), | ||
8 | * while on hx4700 this is 1 */ | ||
9 | void (*enable)(struct platform_device *pdev); | ||
10 | void (*disable)(struct platform_device *pdev); | ||
11 | }; | ||
diff --git a/include/linux/efi.h b/include/linux/efi.h index f8ebd7c1ddb3..0b9579a4cd42 100644 --- a/include/linux/efi.h +++ b/include/linux/efi.h | |||
@@ -213,7 +213,6 @@ typedef struct { | |||
213 | } efi_config_table_t; | 213 | } efi_config_table_t; |
214 | 214 | ||
215 | #define EFI_SYSTEM_TABLE_SIGNATURE ((u64)0x5453595320494249ULL) | 215 | #define EFI_SYSTEM_TABLE_SIGNATURE ((u64)0x5453595320494249ULL) |
216 | #define EFI_SYSTEM_TABLE_REVISION ((1 << 16) | 00) | ||
217 | 216 | ||
218 | typedef struct { | 217 | typedef struct { |
219 | efi_table_hdr_t hdr; | 218 | efi_table_hdr_t hdr; |
diff --git a/include/linux/ext3_fs.h b/include/linux/ext3_fs.h index 4eb18ac510ae..ece49a804fe1 100644 --- a/include/linux/ext3_fs.h +++ b/include/linux/ext3_fs.h | |||
@@ -824,6 +824,7 @@ extern int ext3_change_inode_journal_flag(struct inode *, int); | |||
824 | extern int ext3_get_inode_loc(struct inode *, struct ext3_iloc *); | 824 | extern int ext3_get_inode_loc(struct inode *, struct ext3_iloc *); |
825 | extern void ext3_truncate (struct inode *); | 825 | extern void ext3_truncate (struct inode *); |
826 | extern void ext3_set_inode_flags(struct inode *); | 826 | extern void ext3_set_inode_flags(struct inode *); |
827 | extern void ext3_get_inode_flags(struct ext3_inode_info *); | ||
827 | extern void ext3_set_aops(struct inode *inode); | 828 | extern void ext3_set_aops(struct inode *inode); |
828 | 829 | ||
829 | /* ioctl.c */ | 830 | /* ioctl.c */ |
diff --git a/include/linux/fb.h b/include/linux/fb.h index be913ec87169..dff7a728948c 100644 --- a/include/linux/fb.h +++ b/include/linux/fb.h | |||
@@ -4,6 +4,8 @@ | |||
4 | #include <asm/types.h> | 4 | #include <asm/types.h> |
5 | #include <linux/i2c.h> | 5 | #include <linux/i2c.h> |
6 | 6 | ||
7 | struct dentry; | ||
8 | |||
7 | /* Definitions of frame buffers */ | 9 | /* Definitions of frame buffers */ |
8 | 10 | ||
9 | #define FB_MAJOR 29 | 11 | #define FB_MAJOR 29 |
@@ -525,12 +527,20 @@ struct fb_cursor_user { | |||
525 | #define FB_EVENT_MODE_CHANGE_ALL 0x0B | 527 | #define FB_EVENT_MODE_CHANGE_ALL 0x0B |
526 | /* A software display blank change occured */ | 528 | /* A software display blank change occured */ |
527 | #define FB_EVENT_CONBLANK 0x0C | 529 | #define FB_EVENT_CONBLANK 0x0C |
530 | /* Get drawing requirements */ | ||
531 | #define FB_EVENT_GET_REQ 0x0D | ||
528 | 532 | ||
529 | struct fb_event { | 533 | struct fb_event { |
530 | struct fb_info *info; | 534 | struct fb_info *info; |
531 | void *data; | 535 | void *data; |
532 | }; | 536 | }; |
533 | 537 | ||
538 | struct fb_blit_caps { | ||
539 | u32 x; | ||
540 | u32 y; | ||
541 | u32 len; | ||
542 | u32 flags; | ||
543 | }; | ||
534 | 544 | ||
535 | extern int fb_register_client(struct notifier_block *nb); | 545 | extern int fb_register_client(struct notifier_block *nb); |
536 | extern int fb_unregister_client(struct notifier_block *nb); | 546 | extern int fb_unregister_client(struct notifier_block *nb); |
@@ -556,11 +566,25 @@ struct fb_pixmap { | |||
556 | u32 scan_align; /* alignment per scanline */ | 566 | u32 scan_align; /* alignment per scanline */ |
557 | u32 access_align; /* alignment per read/write (bits) */ | 567 | u32 access_align; /* alignment per read/write (bits) */ |
558 | u32 flags; /* see FB_PIXMAP_* */ | 568 | u32 flags; /* see FB_PIXMAP_* */ |
569 | u32 blit_x; /* supported bit block dimensions (1-32)*/ | ||
570 | u32 blit_y; /* Format: blit_x = 1 << (width - 1) */ | ||
571 | /* blit_y = 1 << (height - 1) */ | ||
572 | /* if 0, will be set to 0xffffffff (all)*/ | ||
559 | /* access methods */ | 573 | /* access methods */ |
560 | void (*writeio)(struct fb_info *info, void __iomem *dst, void *src, unsigned int size); | 574 | void (*writeio)(struct fb_info *info, void __iomem *dst, void *src, unsigned int size); |
561 | void (*readio) (struct fb_info *info, void *dst, void __iomem *src, unsigned int size); | 575 | void (*readio) (struct fb_info *info, void *dst, void __iomem *src, unsigned int size); |
562 | }; | 576 | }; |
563 | 577 | ||
578 | #ifdef CONFIG_FB_DEFERRED_IO | ||
579 | struct fb_deferred_io { | ||
580 | /* delay between mkwrite and deferred handler */ | ||
581 | unsigned long delay; | ||
582 | struct mutex lock; /* mutex that protects the page list */ | ||
583 | struct list_head pagelist; /* list of touched pages */ | ||
584 | /* callback */ | ||
585 | void (*deferred_io)(struct fb_info *info, struct list_head *pagelist); | ||
586 | }; | ||
587 | #endif | ||
564 | 588 | ||
565 | /* | 589 | /* |
566 | * Frame buffer operations | 590 | * Frame buffer operations |
@@ -579,8 +603,10 @@ struct fb_ops { | |||
579 | /* For framebuffers with strange non linear layouts or that do not | 603 | /* For framebuffers with strange non linear layouts or that do not |
580 | * work with normal memory mapped access | 604 | * work with normal memory mapped access |
581 | */ | 605 | */ |
582 | ssize_t (*fb_read)(struct file *file, char __user *buf, size_t count, loff_t *ppos); | 606 | ssize_t (*fb_read)(struct fb_info *info, char __user *buf, |
583 | ssize_t (*fb_write)(struct file *file, const char __user *buf, size_t count, loff_t *ppos); | 607 | size_t count, loff_t *ppos); |
608 | ssize_t (*fb_write)(struct fb_info *info, const char __user *buf, | ||
609 | size_t count, loff_t *ppos); | ||
584 | 610 | ||
585 | /* checks var and eventually tweaks it to something supported, | 611 | /* checks var and eventually tweaks it to something supported, |
586 | * DO NOT MODIFY PAR */ | 612 | * DO NOT MODIFY PAR */ |
@@ -634,10 +660,13 @@ struct fb_ops { | |||
634 | 660 | ||
635 | /* restore saved state */ | 661 | /* restore saved state */ |
636 | void (*fb_restore_state)(struct fb_info *info); | 662 | void (*fb_restore_state)(struct fb_info *info); |
663 | |||
664 | /* get capability given var */ | ||
665 | void (*fb_get_caps)(struct fb_info *info, struct fb_blit_caps *caps, | ||
666 | struct fb_var_screeninfo *var); | ||
637 | }; | 667 | }; |
638 | 668 | ||
639 | #ifdef CONFIG_FB_TILEBLITTING | 669 | #ifdef CONFIG_FB_TILEBLITTING |
640 | |||
641 | #define FB_TILE_CURSOR_NONE 0 | 670 | #define FB_TILE_CURSOR_NONE 0 |
642 | #define FB_TILE_CURSOR_UNDERLINE 1 | 671 | #define FB_TILE_CURSOR_UNDERLINE 1 |
643 | #define FB_TILE_CURSOR_LOWER_THIRD 2 | 672 | #define FB_TILE_CURSOR_LOWER_THIRD 2 |
@@ -709,6 +738,8 @@ struct fb_tile_ops { | |||
709 | /* cursor */ | 738 | /* cursor */ |
710 | void (*fb_tilecursor)(struct fb_info *info, | 739 | void (*fb_tilecursor)(struct fb_info *info, |
711 | struct fb_tilecursor *cursor); | 740 | struct fb_tilecursor *cursor); |
741 | /* get maximum length of the tile map */ | ||
742 | int (*fb_get_tilemax)(struct fb_info *info); | ||
712 | }; | 743 | }; |
713 | #endif /* CONFIG_FB_TILEBLITTING */ | 744 | #endif /* CONFIG_FB_TILEBLITTING */ |
714 | 745 | ||
@@ -778,6 +809,10 @@ struct fb_info { | |||
778 | struct mutex bl_curve_mutex; | 809 | struct mutex bl_curve_mutex; |
779 | u8 bl_curve[FB_BACKLIGHT_LEVELS]; | 810 | u8 bl_curve[FB_BACKLIGHT_LEVELS]; |
780 | #endif | 811 | #endif |
812 | #ifdef CONFIG_FB_DEFERRED_IO | ||
813 | struct delayed_work deferred_work; | ||
814 | struct fb_deferred_io *fbdefio; | ||
815 | #endif | ||
781 | 816 | ||
782 | struct fb_ops *fbops; | 817 | struct fb_ops *fbops; |
783 | struct device *device; /* This is the parent */ | 818 | struct device *device; /* This is the parent */ |
@@ -879,6 +914,16 @@ extern int fb_blank(struct fb_info *info, int blank); | |||
879 | extern void cfb_fillrect(struct fb_info *info, const struct fb_fillrect *rect); | 914 | extern void cfb_fillrect(struct fb_info *info, const struct fb_fillrect *rect); |
880 | extern void cfb_copyarea(struct fb_info *info, const struct fb_copyarea *area); | 915 | extern void cfb_copyarea(struct fb_info *info, const struct fb_copyarea *area); |
881 | extern void cfb_imageblit(struct fb_info *info, const struct fb_image *image); | 916 | extern void cfb_imageblit(struct fb_info *info, const struct fb_image *image); |
917 | /* | ||
918 | * Drawing operations where framebuffer is in system RAM | ||
919 | */ | ||
920 | extern void sys_fillrect(struct fb_info *info, const struct fb_fillrect *rect); | ||
921 | extern void sys_copyarea(struct fb_info *info, const struct fb_copyarea *area); | ||
922 | extern void sys_imageblit(struct fb_info *info, const struct fb_image *image); | ||
923 | extern ssize_t fb_sys_read(struct fb_info *info, char __user *buf, | ||
924 | size_t count, loff_t *ppos); | ||
925 | extern ssize_t fb_sys_write(struct fb_info *info, const char __user *buf, | ||
926 | size_t count, loff_t *ppos); | ||
882 | 927 | ||
883 | /* drivers/video/fbmem.c */ | 928 | /* drivers/video/fbmem.c */ |
884 | extern int register_framebuffer(struct fb_info *fb_info); | 929 | extern int register_framebuffer(struct fb_info *fb_info); |
@@ -913,6 +958,12 @@ static inline void __fb_pad_aligned_buffer(u8 *dst, u32 d_pitch, | |||
913 | } | 958 | } |
914 | } | 959 | } |
915 | 960 | ||
961 | /* drivers/video/fb_defio.c */ | ||
962 | extern void fb_deferred_io_init(struct fb_info *info); | ||
963 | extern void fb_deferred_io_cleanup(struct fb_info *info); | ||
964 | extern int fb_deferred_io_fsync(struct file *file, struct dentry *dentry, | ||
965 | int datasync); | ||
966 | |||
916 | /* drivers/video/fbsysfs.c */ | 967 | /* drivers/video/fbsysfs.c */ |
917 | extern struct fb_info *framebuffer_alloc(size_t size, struct device *dev); | 968 | extern struct fb_info *framebuffer_alloc(size_t size, struct device *dev); |
918 | extern void framebuffer_release(struct fb_info *info); | 969 | extern void framebuffer_release(struct fb_info *info); |
diff --git a/include/linux/font.h b/include/linux/font.h index 53b129f07f6f..40a24ab41b36 100644 --- a/include/linux/font.h +++ b/include/linux/font.h | |||
@@ -49,7 +49,8 @@ extern const struct font_desc *find_font(const char *name); | |||
49 | 49 | ||
50 | /* Get the default font for a specific screen size */ | 50 | /* Get the default font for a specific screen size */ |
51 | 51 | ||
52 | extern const struct font_desc *get_default_font(int xres, int yres); | 52 | extern const struct font_desc *get_default_font(int xres, int yres, |
53 | u32 font_w, u32 font_h); | ||
53 | 54 | ||
54 | /* Max. length for the name of a predefined font */ | 55 | /* Max. length for the name of a predefined font */ |
55 | #define MAX_FONT_NAME 32 | 56 | #define MAX_FONT_NAME 32 |
diff --git a/include/linux/fs.h b/include/linux/fs.h index bc6d27cecaac..7cf0c54a46a7 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h | |||
@@ -30,6 +30,7 @@ | |||
30 | #define SEEK_SET 0 /* seek relative to beginning of file */ | 30 | #define SEEK_SET 0 /* seek relative to beginning of file */ |
31 | #define SEEK_CUR 1 /* seek relative to current file position */ | 31 | #define SEEK_CUR 1 /* seek relative to current file position */ |
32 | #define SEEK_END 2 /* seek relative to end of file */ | 32 | #define SEEK_END 2 /* seek relative to end of file */ |
33 | #define SEEK_MAX SEEK_END | ||
33 | 34 | ||
34 | /* And dynamically-tunable limits and defaults: */ | 35 | /* And dynamically-tunable limits and defaults: */ |
35 | struct files_stat_struct { | 36 | struct files_stat_struct { |
@@ -91,6 +92,7 @@ extern int dir_notify_enable; | |||
91 | /* public flags for file_system_type */ | 92 | /* public flags for file_system_type */ |
92 | #define FS_REQUIRES_DEV 1 | 93 | #define FS_REQUIRES_DEV 1 |
93 | #define FS_BINARY_MOUNTDATA 2 | 94 | #define FS_BINARY_MOUNTDATA 2 |
95 | #define FS_HAS_SUBTYPE 4 | ||
94 | #define FS_REVAL_DOT 16384 /* Check the paths ".", ".." for staleness */ | 96 | #define FS_REVAL_DOT 16384 /* Check the paths ".", ".." for staleness */ |
95 | #define FS_RENAME_DOES_D_MOVE 32768 /* FS will handle d_move() | 97 | #define FS_RENAME_DOES_D_MOVE 32768 /* FS will handle d_move() |
96 | * during rename() internally. | 98 | * during rename() internally. |
@@ -847,11 +849,6 @@ extern int fcntl_getlease(struct file *filp); | |||
847 | /* fs/sync.c */ | 849 | /* fs/sync.c */ |
848 | extern int do_sync_mapping_range(struct address_space *mapping, loff_t offset, | 850 | extern int do_sync_mapping_range(struct address_space *mapping, loff_t offset, |
849 | loff_t endbyte, unsigned int flags); | 851 | loff_t endbyte, unsigned int flags); |
850 | static inline int do_sync_file_range(struct file *file, loff_t offset, | ||
851 | loff_t endbyte, unsigned int flags) | ||
852 | { | ||
853 | return do_sync_mapping_range(file->f_mapping, offset, endbyte, flags); | ||
854 | } | ||
855 | 852 | ||
856 | /* fs/locks.c */ | 853 | /* fs/locks.c */ |
857 | extern void locks_init_lock(struct file_lock *); | 854 | extern void locks_init_lock(struct file_lock *); |
@@ -960,6 +957,12 @@ struct super_block { | |||
960 | /* Granularity of c/m/atime in ns. | 957 | /* Granularity of c/m/atime in ns. |
961 | Cannot be worse than a second */ | 958 | Cannot be worse than a second */ |
962 | u32 s_time_gran; | 959 | u32 s_time_gran; |
960 | |||
961 | /* | ||
962 | * Filesystem subtype. If non-empty the filesystem type field | ||
963 | * in /proc/mounts will be "type.subtype" | ||
964 | */ | ||
965 | char *s_subtype; | ||
963 | }; | 966 | }; |
964 | 967 | ||
965 | extern struct timespec current_fs_time(struct super_block *sb); | 968 | extern struct timespec current_fs_time(struct super_block *sb); |
@@ -1735,6 +1738,8 @@ extern ssize_t generic_file_sendfile(struct file *, loff_t *, size_t, read_actor | |||
1735 | extern void do_generic_mapping_read(struct address_space *mapping, | 1738 | extern void do_generic_mapping_read(struct address_space *mapping, |
1736 | struct file_ra_state *, struct file *, | 1739 | struct file_ra_state *, struct file *, |
1737 | loff_t *, read_descriptor_t *, read_actor_t); | 1740 | loff_t *, read_descriptor_t *, read_actor_t); |
1741 | extern int generic_segment_checks(const struct iovec *iov, | ||
1742 | unsigned long *nr_segs, size_t *count, int access_flags); | ||
1738 | 1743 | ||
1739 | /* fs/splice.c */ | 1744 | /* fs/splice.c */ |
1740 | extern ssize_t generic_file_splice_read(struct file *, loff_t *, | 1745 | extern ssize_t generic_file_splice_read(struct file *, loff_t *, |
diff --git a/include/linux/futex.h b/include/linux/futex.h index 3f153b4e156c..820125c628c1 100644 --- a/include/linux/futex.h +++ b/include/linux/futex.h | |||
@@ -100,6 +100,35 @@ long do_futex(u32 __user *uaddr, int op, u32 val, unsigned long timeout, | |||
100 | extern int | 100 | extern int |
101 | handle_futex_death(u32 __user *uaddr, struct task_struct *curr, int pi); | 101 | handle_futex_death(u32 __user *uaddr, struct task_struct *curr, int pi); |
102 | 102 | ||
103 | /* | ||
104 | * Futexes are matched on equal values of this key. | ||
105 | * The key type depends on whether it's a shared or private mapping. | ||
106 | * Don't rearrange members without looking at hash_futex(). | ||
107 | * | ||
108 | * offset is aligned to a multiple of sizeof(u32) (== 4) by definition. | ||
109 | * We set bit 0 to indicate if it's an inode-based key. | ||
110 | */ | ||
111 | union futex_key { | ||
112 | struct { | ||
113 | unsigned long pgoff; | ||
114 | struct inode *inode; | ||
115 | int offset; | ||
116 | } shared; | ||
117 | struct { | ||
118 | unsigned long address; | ||
119 | struct mm_struct *mm; | ||
120 | int offset; | ||
121 | } private; | ||
122 | struct { | ||
123 | unsigned long word; | ||
124 | void *ptr; | ||
125 | int offset; | ||
126 | } both; | ||
127 | }; | ||
128 | int get_futex_key(u32 __user *uaddr, union futex_key *key); | ||
129 | void get_futex_key_refs(union futex_key *key); | ||
130 | void drop_futex_key_refs(union futex_key *key); | ||
131 | |||
103 | #ifdef CONFIG_FUTEX | 132 | #ifdef CONFIG_FUTEX |
104 | extern void exit_robust_list(struct task_struct *curr); | 133 | extern void exit_robust_list(struct task_struct *curr); |
105 | extern void exit_pi_state_list(struct task_struct *curr); | 134 | extern void exit_pi_state_list(struct task_struct *curr); |
diff --git a/include/linux/init.h b/include/linux/init.h index dbbdbd1bec77..8bc32bb2fce2 100644 --- a/include/linux/init.h +++ b/include/linux/init.h | |||
@@ -77,7 +77,8 @@ extern char *saved_command_line; | |||
77 | extern unsigned int reset_devices; | 77 | extern unsigned int reset_devices; |
78 | 78 | ||
79 | /* used by init/main.c */ | 79 | /* used by init/main.c */ |
80 | extern void setup_arch(char **); | 80 | void setup_arch(char **); |
81 | void prepare_namespace(void); | ||
81 | 82 | ||
82 | #endif | 83 | #endif |
83 | 84 | ||
diff --git a/include/linux/init_task.h b/include/linux/init_task.h index a2d95ff50e9b..795102309bf1 100644 --- a/include/linux/init_task.h +++ b/include/linux/init_task.h | |||
@@ -138,7 +138,7 @@ extern struct group_info init_groups; | |||
138 | .journal_info = NULL, \ | 138 | .journal_info = NULL, \ |
139 | .cpu_timers = INIT_CPU_TIMERS(tsk.cpu_timers), \ | 139 | .cpu_timers = INIT_CPU_TIMERS(tsk.cpu_timers), \ |
140 | .fs_excl = ATOMIC_INIT(0), \ | 140 | .fs_excl = ATOMIC_INIT(0), \ |
141 | .pi_lock = SPIN_LOCK_UNLOCKED, \ | 141 | .pi_lock = __SPIN_LOCK_UNLOCKED(tsk.pi_lock), \ |
142 | INIT_TRACE_IRQFLAGS \ | 142 | INIT_TRACE_IRQFLAGS \ |
143 | INIT_LOCKDEP \ | 143 | INIT_LOCKDEP \ |
144 | } | 144 | } |
diff --git a/include/linux/interrupt.h b/include/linux/interrupt.h index 0319f665dd3f..f7b01b9a35b3 100644 --- a/include/linux/interrupt.h +++ b/include/linux/interrupt.h | |||
@@ -44,6 +44,9 @@ | |||
44 | * IRQF_TIMER - Flag to mark this interrupt as timer interrupt | 44 | * IRQF_TIMER - Flag to mark this interrupt as timer interrupt |
45 | * IRQF_PERCPU - Interrupt is per cpu | 45 | * IRQF_PERCPU - Interrupt is per cpu |
46 | * IRQF_NOBALANCING - Flag to exclude this interrupt from irq balancing | 46 | * IRQF_NOBALANCING - Flag to exclude this interrupt from irq balancing |
47 | * IRQF_IRQPOLL - Interrupt is used for polling (only the interrupt that is | ||
48 | * registered first in an shared interrupt is considered for | ||
49 | * performance reasons) | ||
47 | */ | 50 | */ |
48 | #define IRQF_DISABLED 0x00000020 | 51 | #define IRQF_DISABLED 0x00000020 |
49 | #define IRQF_SAMPLE_RANDOM 0x00000040 | 52 | #define IRQF_SAMPLE_RANDOM 0x00000040 |
@@ -52,22 +55,29 @@ | |||
52 | #define IRQF_TIMER 0x00000200 | 55 | #define IRQF_TIMER 0x00000200 |
53 | #define IRQF_PERCPU 0x00000400 | 56 | #define IRQF_PERCPU 0x00000400 |
54 | #define IRQF_NOBALANCING 0x00000800 | 57 | #define IRQF_NOBALANCING 0x00000800 |
58 | #define IRQF_IRQPOLL 0x00001000 | ||
55 | 59 | ||
56 | /* | 60 | /* |
57 | * Migration helpers. Scheduled for removal in 1/2007 | 61 | * Migration helpers. Scheduled for removal in 9/2007 |
58 | * Do not use for new code ! | 62 | * Do not use for new code ! |
59 | */ | 63 | */ |
60 | #define SA_INTERRUPT IRQF_DISABLED | 64 | static inline |
61 | #define SA_SAMPLE_RANDOM IRQF_SAMPLE_RANDOM | 65 | unsigned long __deprecated deprecated_irq_flag(unsigned long flag) |
62 | #define SA_SHIRQ IRQF_SHARED | 66 | { |
63 | #define SA_PROBEIRQ IRQF_PROBE_SHARED | 67 | return flag; |
64 | #define SA_PERCPU IRQF_PERCPU | 68 | } |
65 | 69 | ||
66 | #define SA_TRIGGER_LOW IRQF_TRIGGER_LOW | 70 | #define SA_INTERRUPT deprecated_irq_flag(IRQF_DISABLED) |
67 | #define SA_TRIGGER_HIGH IRQF_TRIGGER_HIGH | 71 | #define SA_SAMPLE_RANDOM deprecated_irq_flag(IRQF_SAMPLE_RANDOM) |
68 | #define SA_TRIGGER_FALLING IRQF_TRIGGER_FALLING | 72 | #define SA_SHIRQ deprecated_irq_flag(IRQF_SHARED) |
69 | #define SA_TRIGGER_RISING IRQF_TRIGGER_RISING | 73 | #define SA_PROBEIRQ deprecated_irq_flag(IRQF_PROBE_SHARED) |
70 | #define SA_TRIGGER_MASK IRQF_TRIGGER_MASK | 74 | #define SA_PERCPU deprecated_irq_flag(IRQF_PERCPU) |
75 | |||
76 | #define SA_TRIGGER_LOW deprecated_irq_flag(IRQF_TRIGGER_LOW) | ||
77 | #define SA_TRIGGER_HIGH deprecated_irq_flag(IRQF_TRIGGER_HIGH) | ||
78 | #define SA_TRIGGER_FALLING deprecated_irq_flag(IRQF_TRIGGER_FALLING) | ||
79 | #define SA_TRIGGER_RISING deprecated_irq_flag(IRQF_TRIGGER_RISING) | ||
80 | #define SA_TRIGGER_MASK deprecated_irq_flag(IRQF_TRIGGER_MASK) | ||
71 | 81 | ||
72 | typedef irqreturn_t (*irq_handler_t)(int, void *); | 82 | typedef irqreturn_t (*irq_handler_t)(int, void *); |
73 | 83 | ||
@@ -83,11 +93,11 @@ struct irqaction { | |||
83 | }; | 93 | }; |
84 | 94 | ||
85 | extern irqreturn_t no_action(int cpl, void *dev_id); | 95 | extern irqreturn_t no_action(int cpl, void *dev_id); |
86 | extern int request_irq(unsigned int, irq_handler_t handler, | 96 | extern int __must_check request_irq(unsigned int, irq_handler_t handler, |
87 | unsigned long, const char *, void *); | 97 | unsigned long, const char *, void *); |
88 | extern void free_irq(unsigned int, void *); | 98 | extern void free_irq(unsigned int, void *); |
89 | 99 | ||
90 | extern int devm_request_irq(struct device *dev, unsigned int irq, | 100 | extern int __must_check devm_request_irq(struct device *dev, unsigned int irq, |
91 | irq_handler_t handler, unsigned long irqflags, | 101 | irq_handler_t handler, unsigned long irqflags, |
92 | const char *devname, void *dev_id); | 102 | const char *devname, void *dev_id); |
93 | extern void devm_free_irq(struct device *dev, unsigned int irq, void *dev_id); | 103 | extern void devm_free_irq(struct device *dev, unsigned int irq, void *dev_id); |
diff --git a/include/linux/ioctl32.h b/include/linux/ioctl32.h deleted file mode 100644 index 948809d99917..000000000000 --- a/include/linux/ioctl32.h +++ /dev/null | |||
@@ -1,17 +0,0 @@ | |||
1 | #ifndef IOCTL32_H | ||
2 | #define IOCTL32_H 1 | ||
3 | |||
4 | #include <linux/compiler.h> /* for __deprecated */ | ||
5 | |||
6 | struct file; | ||
7 | |||
8 | typedef int (*ioctl_trans_handler_t)(unsigned int, unsigned int, | ||
9 | unsigned long, struct file *); | ||
10 | |||
11 | struct ioctl_trans { | ||
12 | unsigned long cmd; | ||
13 | ioctl_trans_handler_t handler; | ||
14 | struct ioctl_trans *next; | ||
15 | }; | ||
16 | |||
17 | #endif | ||
diff --git a/include/linux/ipc.h b/include/linux/ipc.h index 6da6772c19ff..1980867a64a4 100644 --- a/include/linux/ipc.h +++ b/include/linux/ipc.h | |||
@@ -92,16 +92,19 @@ extern struct ipc_namespace init_ipc_ns; | |||
92 | 92 | ||
93 | #ifdef CONFIG_SYSVIPC | 93 | #ifdef CONFIG_SYSVIPC |
94 | #define INIT_IPC_NS(ns) .ns = &init_ipc_ns, | 94 | #define INIT_IPC_NS(ns) .ns = &init_ipc_ns, |
95 | extern int copy_ipcs(unsigned long flags, struct task_struct *tsk); | 95 | extern struct ipc_namespace *copy_ipcs(unsigned long flags, |
96 | struct ipc_namespace *ns); | ||
96 | #else | 97 | #else |
97 | #define INIT_IPC_NS(ns) | 98 | #define INIT_IPC_NS(ns) |
98 | static inline int copy_ipcs(unsigned long flags, struct task_struct *tsk) | 99 | static inline struct ipc_namespace *copy_ipcs(unsigned long flags, |
99 | { return 0; } | 100 | struct ipc_namespace *ns) |
101 | { | ||
102 | return ns; | ||
103 | } | ||
100 | #endif | 104 | #endif |
101 | 105 | ||
102 | #ifdef CONFIG_IPC_NS | 106 | #ifdef CONFIG_IPC_NS |
103 | extern void free_ipc_ns(struct kref *kref); | 107 | extern void free_ipc_ns(struct kref *kref); |
104 | extern int unshare_ipcs(unsigned long flags, struct ipc_namespace **ns); | ||
105 | #endif | 108 | #endif |
106 | 109 | ||
107 | static inline struct ipc_namespace *get_ipc_ns(struct ipc_namespace *ns) | 110 | static inline struct ipc_namespace *get_ipc_ns(struct ipc_namespace *ns) |
diff --git a/include/linux/irq.h b/include/linux/irq.h index a6899402b522..1695054e8c63 100644 --- a/include/linux/irq.h +++ b/include/linux/irq.h | |||
@@ -147,8 +147,6 @@ struct irq_chip { | |||
147 | * @dir: /proc/irq/ procfs entry | 147 | * @dir: /proc/irq/ procfs entry |
148 | * @affinity_entry: /proc/irq/smp_affinity procfs entry on SMP | 148 | * @affinity_entry: /proc/irq/smp_affinity procfs entry on SMP |
149 | * @name: flow handler name for /proc/interrupts output | 149 | * @name: flow handler name for /proc/interrupts output |
150 | * | ||
151 | * Pad this out to 32 bytes for cache and indexing reasons. | ||
152 | */ | 150 | */ |
153 | struct irq_desc { | 151 | struct irq_desc { |
154 | irq_flow_handler_t handle_irq; | 152 | irq_flow_handler_t handle_irq; |
@@ -175,7 +173,7 @@ struct irq_desc { | |||
175 | struct proc_dir_entry *dir; | 173 | struct proc_dir_entry *dir; |
176 | #endif | 174 | #endif |
177 | const char *name; | 175 | const char *name; |
178 | } ____cacheline_aligned; | 176 | } ____cacheline_internodealigned_in_smp; |
179 | 177 | ||
180 | extern struct irq_desc irq_desc[NR_IRQS]; | 178 | extern struct irq_desc irq_desc[NR_IRQS]; |
181 | 179 | ||
diff --git a/include/linux/isdn/capiutil.h b/include/linux/isdn/capiutil.h index 63bd9cf821a7..5a52f2c94f3f 100644 --- a/include/linux/isdn/capiutil.h +++ b/include/linux/isdn/capiutil.h | |||
@@ -187,7 +187,6 @@ typedef struct { | |||
187 | #define CDEBUG_SIZE 1024 | 187 | #define CDEBUG_SIZE 1024 |
188 | #define CDEBUG_GSIZE 4096 | 188 | #define CDEBUG_GSIZE 4096 |
189 | 189 | ||
190 | _cdebbuf *cdebbuf_alloc(void); | ||
191 | void cdebbuf_free(_cdebbuf *cdb); | 190 | void cdebbuf_free(_cdebbuf *cdb); |
192 | int cdebug_init(void); | 191 | int cdebug_init(void); |
193 | void cdebug_exit(void); | 192 | void cdebug_exit(void); |
diff --git a/include/linux/isdn_divertif.h b/include/linux/isdn_divertif.h index 0e7e44ce8301..07821ca5955f 100644 --- a/include/linux/isdn_divertif.h +++ b/include/linux/isdn_divertif.h | |||
@@ -24,6 +24,10 @@ | |||
24 | #define DIVERT_REL_ERR 0x04 /* module not registered */ | 24 | #define DIVERT_REL_ERR 0x04 /* module not registered */ |
25 | #define DIVERT_REG_NAME isdn_register_divert | 25 | #define DIVERT_REG_NAME isdn_register_divert |
26 | 26 | ||
27 | #ifdef __KERNEL__ | ||
28 | #include <linux/isdnif.h> | ||
29 | #include <linux/types.h> | ||
30 | |||
27 | /***************************************************************/ | 31 | /***************************************************************/ |
28 | /* structure exchanging data between isdn hl and divert module */ | 32 | /* structure exchanging data between isdn hl and divert module */ |
29 | /***************************************************************/ | 33 | /***************************************************************/ |
@@ -40,3 +44,4 @@ typedef struct | |||
40 | /* function register */ | 44 | /* function register */ |
41 | /*********************/ | 45 | /*********************/ |
42 | extern int DIVERT_REG_NAME(isdn_divert_if *); | 46 | extern int DIVERT_REG_NAME(isdn_divert_if *); |
47 | #endif | ||
diff --git a/include/linux/kallsyms.h b/include/linux/kallsyms.h index 3e3b92dabe3b..12178d2c882b 100644 --- a/include/linux/kallsyms.h +++ b/include/linux/kallsyms.h | |||
@@ -30,6 +30,9 @@ extern int sprint_symbol(char *buffer, unsigned long address); | |||
30 | /* Look up a kernel symbol and print it to the kernel messages. */ | 30 | /* Look up a kernel symbol and print it to the kernel messages. */ |
31 | extern void __print_symbol(const char *fmt, unsigned long address); | 31 | extern void __print_symbol(const char *fmt, unsigned long address); |
32 | 32 | ||
33 | int lookup_symbol_name(unsigned long addr, char *symname); | ||
34 | int lookup_symbol_attrs(unsigned long addr, unsigned long *size, unsigned long *offset, char *modname, char *name); | ||
35 | |||
33 | #else /* !CONFIG_KALLSYMS */ | 36 | #else /* !CONFIG_KALLSYMS */ |
34 | 37 | ||
35 | static inline unsigned long kallsyms_lookup_name(const char *name) | 38 | static inline unsigned long kallsyms_lookup_name(const char *name) |
@@ -58,6 +61,16 @@ static inline int sprint_symbol(char *buffer, unsigned long addr) | |||
58 | return 0; | 61 | return 0; |
59 | } | 62 | } |
60 | 63 | ||
64 | static inline int lookup_symbol_name(unsigned long addr, char *symname) | ||
65 | { | ||
66 | return -ERANGE; | ||
67 | } | ||
68 | |||
69 | static inline int lookup_symbol_attrs(unsigned long addr, unsigned long *size, unsigned long *offset, char *modname, char *name) | ||
70 | { | ||
71 | return -ERANGE; | ||
72 | } | ||
73 | |||
61 | /* Stupid that this does nothing, but I didn't create this mess. */ | 74 | /* Stupid that this does nothing, but I didn't create this mess. */ |
62 | #define __print_symbol(fmt, addr) | 75 | #define __print_symbol(fmt, addr) |
63 | #endif /*CONFIG_KALLSYMS*/ | 76 | #endif /*CONFIG_KALLSYMS*/ |
diff --git a/include/linux/kdebug.h b/include/linux/kdebug.h new file mode 100644 index 000000000000..5db38d6d8b92 --- /dev/null +++ b/include/linux/kdebug.h | |||
@@ -0,0 +1,20 @@ | |||
1 | #ifndef _LINUX_KDEBUG_H | ||
2 | #define _LINUX_KDEBUG_H | ||
3 | |||
4 | #include <asm/kdebug.h> | ||
5 | |||
6 | struct die_args { | ||
7 | struct pt_regs *regs; | ||
8 | const char *str; | ||
9 | long err; | ||
10 | int trapnr; | ||
11 | int signr; | ||
12 | }; | ||
13 | |||
14 | int register_die_notifier(struct notifier_block *nb); | ||
15 | int unregister_die_notifier(struct notifier_block *nb); | ||
16 | |||
17 | int notify_die(enum die_val val, const char *str, | ||
18 | struct pt_regs *regs, long err, int trap, int sig); | ||
19 | |||
20 | #endif /* _LINUX_KDEBUG_H */ | ||
diff --git a/include/linux/kexec.h b/include/linux/kexec.h index 696e5ec63f77..8c2c7fcd58ce 100644 --- a/include/linux/kexec.h +++ b/include/linux/kexec.h | |||
@@ -7,6 +7,8 @@ | |||
7 | #include <linux/linkage.h> | 7 | #include <linux/linkage.h> |
8 | #include <linux/compat.h> | 8 | #include <linux/compat.h> |
9 | #include <linux/ioport.h> | 9 | #include <linux/ioport.h> |
10 | #include <linux/elfcore.h> | ||
11 | #include <linux/elf.h> | ||
10 | #include <asm/kexec.h> | 12 | #include <asm/kexec.h> |
11 | 13 | ||
12 | /* Verify architecture specific macros are defined */ | 14 | /* Verify architecture specific macros are defined */ |
@@ -31,6 +33,19 @@ | |||
31 | #error KEXEC_ARCH not defined | 33 | #error KEXEC_ARCH not defined |
32 | #endif | 34 | #endif |
33 | 35 | ||
36 | #define KEXEC_NOTE_HEAD_BYTES ALIGN(sizeof(struct elf_note), 4) | ||
37 | #define KEXEC_CORE_NOTE_NAME "CORE" | ||
38 | #define KEXEC_CORE_NOTE_NAME_BYTES ALIGN(sizeof(KEXEC_CORE_NOTE_NAME), 4) | ||
39 | #define KEXEC_CORE_NOTE_DESC_BYTES ALIGN(sizeof(struct elf_prstatus), 4) | ||
40 | /* | ||
41 | * The per-cpu notes area is a list of notes terminated by a "NULL" | ||
42 | * note header. For kdump, the code in vmcore.c runs in the context | ||
43 | * of the second kernel to combine them into one note. | ||
44 | */ | ||
45 | #define KEXEC_NOTE_BYTES ( (KEXEC_NOTE_HEAD_BYTES * 2) + \ | ||
46 | KEXEC_CORE_NOTE_NAME_BYTES + \ | ||
47 | KEXEC_CORE_NOTE_DESC_BYTES ) | ||
48 | |||
34 | /* | 49 | /* |
35 | * This structure is used to hold the arguments that are used when loading | 50 | * This structure is used to hold the arguments that are used when loading |
36 | * kernel binaries. | 51 | * kernel binaries. |
@@ -136,7 +151,7 @@ extern struct kimage *kexec_crash_image; | |||
136 | /* Location of a reserved region to hold the crash kernel. | 151 | /* Location of a reserved region to hold the crash kernel. |
137 | */ | 152 | */ |
138 | extern struct resource crashk_res; | 153 | extern struct resource crashk_res; |
139 | typedef u32 note_buf_t[MAX_NOTE_BYTES/4]; | 154 | typedef u32 note_buf_t[KEXEC_NOTE_BYTES/4]; |
140 | extern note_buf_t *crash_notes; | 155 | extern note_buf_t *crash_notes; |
141 | 156 | ||
142 | 157 | ||
diff --git a/include/linux/kprobes.h b/include/linux/kprobes.h index 769be39b9681..23adf6075ae4 100644 --- a/include/linux/kprobes.h +++ b/include/linux/kprobes.h | |||
@@ -78,7 +78,7 @@ struct kprobe { | |||
78 | kprobe_opcode_t *addr; | 78 | kprobe_opcode_t *addr; |
79 | 79 | ||
80 | /* Allow user to indicate symbol name of the probe point */ | 80 | /* Allow user to indicate symbol name of the probe point */ |
81 | char *symbol_name; | 81 | const char *symbol_name; |
82 | 82 | ||
83 | /* Offset into the symbol */ | 83 | /* Offset into the symbol */ |
84 | unsigned int offset; | 84 | unsigned int offset; |
@@ -123,12 +123,18 @@ DECLARE_PER_CPU(struct kprobe *, current_kprobe); | |||
123 | DECLARE_PER_CPU(struct kprobe_ctlblk, kprobe_ctlblk); | 123 | DECLARE_PER_CPU(struct kprobe_ctlblk, kprobe_ctlblk); |
124 | 124 | ||
125 | #ifdef ARCH_SUPPORTS_KRETPROBES | 125 | #ifdef ARCH_SUPPORTS_KRETPROBES |
126 | extern void arch_prepare_kretprobe(struct kretprobe *rp, struct pt_regs *regs); | 126 | extern void arch_prepare_kretprobe(struct kretprobe_instance *ri, |
127 | struct pt_regs *regs); | ||
128 | extern int arch_trampoline_kprobe(struct kprobe *p); | ||
127 | #else /* ARCH_SUPPORTS_KRETPROBES */ | 129 | #else /* ARCH_SUPPORTS_KRETPROBES */ |
128 | static inline void arch_prepare_kretprobe(struct kretprobe *rp, | 130 | static inline void arch_prepare_kretprobe(struct kretprobe *rp, |
129 | struct pt_regs *regs) | 131 | struct pt_regs *regs) |
130 | { | 132 | { |
131 | } | 133 | } |
134 | static inline int arch_trampoline_kprobe(struct kprobe *p) | ||
135 | { | ||
136 | return 0; | ||
137 | } | ||
132 | #endif /* ARCH_SUPPORTS_KRETPROBES */ | 138 | #endif /* ARCH_SUPPORTS_KRETPROBES */ |
133 | /* | 139 | /* |
134 | * Function-return probe - | 140 | * Function-return probe - |
@@ -157,6 +163,16 @@ struct kretprobe_instance { | |||
157 | struct task_struct *task; | 163 | struct task_struct *task; |
158 | }; | 164 | }; |
159 | 165 | ||
166 | static inline void kretprobe_assert(struct kretprobe_instance *ri, | ||
167 | unsigned long orig_ret_address, unsigned long trampoline_address) | ||
168 | { | ||
169 | if (!orig_ret_address || (orig_ret_address == trampoline_address)) { | ||
170 | printk("kretprobe BUG!: Processing kretprobe %p @ %p\n", | ||
171 | ri->rp, ri->rp->kp.addr); | ||
172 | BUG(); | ||
173 | } | ||
174 | } | ||
175 | |||
160 | extern spinlock_t kretprobe_lock; | 176 | extern spinlock_t kretprobe_lock; |
161 | extern struct mutex kprobe_mutex; | 177 | extern struct mutex kprobe_mutex; |
162 | extern int arch_prepare_kprobe(struct kprobe *p); | 178 | extern int arch_prepare_kprobe(struct kprobe *p); |
@@ -199,8 +215,6 @@ void jprobe_return(void); | |||
199 | int register_kretprobe(struct kretprobe *rp); | 215 | int register_kretprobe(struct kretprobe *rp); |
200 | void unregister_kretprobe(struct kretprobe *rp); | 216 | void unregister_kretprobe(struct kretprobe *rp); |
201 | 217 | ||
202 | struct kretprobe_instance *get_free_rp_inst(struct kretprobe *rp); | ||
203 | void add_rp_inst(struct kretprobe_instance *ri); | ||
204 | void kprobe_flush_task(struct task_struct *tk); | 218 | void kprobe_flush_task(struct task_struct *tk); |
205 | void recycle_rp_inst(struct kretprobe_instance *ri, struct hlist_head *head); | 219 | void recycle_rp_inst(struct kretprobe_instance *ri, struct hlist_head *head); |
206 | #else /* CONFIG_KPROBES */ | 220 | #else /* CONFIG_KPROBES */ |
diff --git a/include/linux/list.h b/include/linux/list.h index f9d71eab05ee..9202703be2a4 100644 --- a/include/linux/list.h +++ b/include/linux/list.h | |||
@@ -426,6 +426,17 @@ static inline void list_splice_init_rcu(struct list_head *list, | |||
426 | container_of(ptr, type, member) | 426 | container_of(ptr, type, member) |
427 | 427 | ||
428 | /** | 428 | /** |
429 | * list_first_entry - get the first element from a list | ||
430 | * @ptr: the list head to take the element from. | ||
431 | * @type: the type of the struct this is embedded in. | ||
432 | * @member: the name of the list_struct within the struct. | ||
433 | * | ||
434 | * Note, that list is expected to be not empty. | ||
435 | */ | ||
436 | #define list_first_entry(ptr, type, member) \ | ||
437 | list_entry((ptr)->next, type, member) | ||
438 | |||
439 | /** | ||
429 | * list_for_each - iterate over a list | 440 | * list_for_each - iterate over a list |
430 | * @pos: the &struct list_head to use as a loop cursor. | 441 | * @pos: the &struct list_head to use as a loop cursor. |
431 | * @head: the head for your list. | 442 | * @head: the head for your list. |
diff --git a/include/linux/loop.h b/include/linux/loop.h index 191a595055f0..0b99b31f017b 100644 --- a/include/linux/loop.h +++ b/include/linux/loop.h | |||
@@ -64,6 +64,8 @@ struct loop_device { | |||
64 | wait_queue_head_t lo_event; | 64 | wait_queue_head_t lo_event; |
65 | 65 | ||
66 | request_queue_t *lo_queue; | 66 | request_queue_t *lo_queue; |
67 | struct gendisk *lo_disk; | ||
68 | struct list_head lo_list; | ||
67 | }; | 69 | }; |
68 | 70 | ||
69 | #endif /* __KERNEL__ */ | 71 | #endif /* __KERNEL__ */ |
diff --git a/include/linux/mc146818rtc.h b/include/linux/mc146818rtc.h index bdc01127dced..580b3f4956ee 100644 --- a/include/linux/mc146818rtc.h +++ b/include/linux/mc146818rtc.h | |||
@@ -22,8 +22,15 @@ extern spinlock_t rtc_lock; /* serialize CMOS RAM access */ | |||
22 | /* Some RTCs extend the mc146818 register set to support alarms of more | 22 | /* Some RTCs extend the mc146818 register set to support alarms of more |
23 | * than 24 hours in the future; or dates that include a century code. | 23 | * than 24 hours in the future; or dates that include a century code. |
24 | * This platform_data structure can pass this information to the driver. | 24 | * This platform_data structure can pass this information to the driver. |
25 | * | ||
26 | * Also, some platforms need suspend()/resume() hooks to kick in special | ||
27 | * handling of wake alarms, e.g. activating ACPI BIOS hooks or setting up | ||
28 | * a separate wakeup alarm used by some almost-clone chips. | ||
25 | */ | 29 | */ |
26 | struct cmos_rtc_board_info { | 30 | struct cmos_rtc_board_info { |
31 | void (*wake_on)(struct device *dev); | ||
32 | void (*wake_off)(struct device *dev); | ||
33 | |||
27 | u8 rtc_day_alarm; /* zero, or register index */ | 34 | u8 rtc_day_alarm; /* zero, or register index */ |
28 | u8 rtc_mon_alarm; /* zero, or register index */ | 35 | u8 rtc_mon_alarm; /* zero, or register index */ |
29 | u8 rtc_century; /* zero, or register index */ | 36 | u8 rtc_century; /* zero, or register index */ |
diff --git a/include/linux/mnt_namespace.h b/include/linux/mnt_namespace.h index 4af0b1fc282a..1fa4d9813b31 100644 --- a/include/linux/mnt_namespace.h +++ b/include/linux/mnt_namespace.h | |||
@@ -14,10 +14,9 @@ struct mnt_namespace { | |||
14 | int event; | 14 | int event; |
15 | }; | 15 | }; |
16 | 16 | ||
17 | extern int copy_mnt_ns(int, struct task_struct *); | 17 | extern struct mnt_namespace *copy_mnt_ns(int, struct mnt_namespace *, |
18 | extern void __put_mnt_ns(struct mnt_namespace *ns); | ||
19 | extern struct mnt_namespace *dup_mnt_ns(struct task_struct *, | ||
20 | struct fs_struct *); | 18 | struct fs_struct *); |
19 | extern void __put_mnt_ns(struct mnt_namespace *ns); | ||
21 | 20 | ||
22 | static inline void put_mnt_ns(struct mnt_namespace *ns) | 21 | static inline void put_mnt_ns(struct mnt_namespace *ns) |
23 | { | 22 | { |
diff --git a/include/linux/module.h b/include/linux/module.h index f0b0faf42d5d..6d3dc9c4ff96 100644 --- a/include/linux/module.h +++ b/include/linux/module.h | |||
@@ -370,16 +370,14 @@ struct module *module_text_address(unsigned long addr); | |||
370 | struct module *__module_text_address(unsigned long addr); | 370 | struct module *__module_text_address(unsigned long addr); |
371 | int is_module_address(unsigned long addr); | 371 | int is_module_address(unsigned long addr); |
372 | 372 | ||
373 | /* Returns module and fills in value, defined and namebuf, or NULL if | 373 | /* Returns 0 and fills in value, defined and namebuf, or -ERANGE if |
374 | symnum out of range. */ | 374 | symnum out of range. */ |
375 | struct module *module_get_kallsym(unsigned int symnum, unsigned long *value, | 375 | int module_get_kallsym(unsigned int symnum, unsigned long *value, char *type, |
376 | char *type, char *name, size_t namelen); | 376 | char *name, char *module_name, int *exported); |
377 | 377 | ||
378 | /* Look for this name: can be of form module:name. */ | 378 | /* Look for this name: can be of form module:name. */ |
379 | unsigned long module_kallsyms_lookup_name(const char *name); | 379 | unsigned long module_kallsyms_lookup_name(const char *name); |
380 | 380 | ||
381 | int is_exported(const char *name, const struct module *mod); | ||
382 | |||
383 | extern void __module_put_and_exit(struct module *mod, long code) | 381 | extern void __module_put_and_exit(struct module *mod, long code) |
384 | __attribute__((noreturn)); | 382 | __attribute__((noreturn)); |
385 | #define module_put_and_exit(code) __module_put_and_exit(THIS_MODULE, code); | 383 | #define module_put_and_exit(code) __module_put_and_exit(THIS_MODULE, code); |
@@ -456,6 +454,8 @@ const char *module_address_lookup(unsigned long addr, | |||
456 | unsigned long *symbolsize, | 454 | unsigned long *symbolsize, |
457 | unsigned long *offset, | 455 | unsigned long *offset, |
458 | char **modname); | 456 | char **modname); |
457 | int lookup_module_symbol_name(unsigned long addr, char *symname); | ||
458 | int lookup_module_symbol_attrs(unsigned long addr, unsigned long *size, unsigned long *offset, char *modname, char *name); | ||
459 | 459 | ||
460 | /* For extable.c to search modules' exception tables. */ | 460 | /* For extable.c to search modules' exception tables. */ |
461 | const struct exception_table_entry *search_module_extables(unsigned long addr); | 461 | const struct exception_table_entry *search_module_extables(unsigned long addr); |
@@ -527,20 +527,24 @@ static inline const char *module_address_lookup(unsigned long addr, | |||
527 | return NULL; | 527 | return NULL; |
528 | } | 528 | } |
529 | 529 | ||
530 | static inline struct module *module_get_kallsym(unsigned int symnum, | 530 | static inline int lookup_module_symbol_name(unsigned long addr, char *symname) |
531 | unsigned long *value, | ||
532 | char *type, char *name, | ||
533 | size_t namelen) | ||
534 | { | 531 | { |
535 | return NULL; | 532 | return -ERANGE; |
536 | } | 533 | } |
537 | 534 | ||
538 | static inline unsigned long module_kallsyms_lookup_name(const char *name) | 535 | static inline int lookup_module_symbol_attrs(unsigned long addr, unsigned long *size, unsigned long *offset, char *modname, char *name) |
539 | { | 536 | { |
540 | return 0; | 537 | return -ERANGE; |
541 | } | 538 | } |
542 | 539 | ||
543 | static inline int is_exported(const char *name, const struct module *mod) | 540 | static inline int module_get_kallsym(unsigned int symnum, unsigned long *value, |
541 | char *type, char *name, | ||
542 | char *module_name, int *exported) | ||
543 | { | ||
544 | return -ERANGE; | ||
545 | } | ||
546 | |||
547 | static inline unsigned long module_kallsyms_lookup_name(const char *name) | ||
544 | { | 548 | { |
545 | return 0; | 549 | return 0; |
546 | } | 550 | } |
diff --git a/include/linux/msdos_fs.h b/include/linux/msdos_fs.h index fa253fa73aa3..0e09c005dda8 100644 --- a/include/linux/msdos_fs.h +++ b/include/linux/msdos_fs.h | |||
@@ -205,7 +205,8 @@ struct fat_mount_options { | |||
205 | numtail:1, /* Does first alias have a numeric '~1' type tail? */ | 205 | numtail:1, /* Does first alias have a numeric '~1' type tail? */ |
206 | atari:1, /* Use Atari GEMDOS variation of MS-DOS fs */ | 206 | atari:1, /* Use Atari GEMDOS variation of MS-DOS fs */ |
207 | flush:1, /* write things quickly */ | 207 | flush:1, /* write things quickly */ |
208 | nocase:1; /* Does this need case conversion? 0=need case conversion*/ | 208 | nocase:1, /* Does this need case conversion? 0=need case conversion*/ |
209 | usefree:1; /* Use free_clusters for FAT32 */ | ||
209 | }; | 210 | }; |
210 | 211 | ||
211 | #define FAT_HASH_BITS 8 | 212 | #define FAT_HASH_BITS 8 |
diff --git a/include/linux/nfs_fs_sb.h b/include/linux/nfs_fs_sb.h index c95d5e642548..52b4378311c8 100644 --- a/include/linux/nfs_fs_sb.h +++ b/include/linux/nfs_fs_sb.h | |||
@@ -82,7 +82,7 @@ struct nfs_server { | |||
82 | struct rpc_clnt * client_acl; /* ACL RPC client handle */ | 82 | struct rpc_clnt * client_acl; /* ACL RPC client handle */ |
83 | struct nfs_iostats * io_stats; /* I/O statistics */ | 83 | struct nfs_iostats * io_stats; /* I/O statistics */ |
84 | struct backing_dev_info backing_dev_info; | 84 | struct backing_dev_info backing_dev_info; |
85 | atomic_t writeback; /* number of writeback pages */ | 85 | atomic_long_t writeback; /* number of writeback pages */ |
86 | int flags; /* various flags */ | 86 | int flags; /* various flags */ |
87 | unsigned int caps; /* server capabilities */ | 87 | unsigned int caps; /* server capabilities */ |
88 | unsigned int rsize; /* read size */ | 88 | unsigned int rsize; /* read size */ |
diff --git a/include/linux/nsproxy.h b/include/linux/nsproxy.h index 0b9f0dc30d61..189e0dc993ab 100644 --- a/include/linux/nsproxy.h +++ b/include/linux/nsproxy.h | |||
@@ -31,10 +31,11 @@ struct nsproxy { | |||
31 | }; | 31 | }; |
32 | extern struct nsproxy init_nsproxy; | 32 | extern struct nsproxy init_nsproxy; |
33 | 33 | ||
34 | struct nsproxy *dup_namespaces(struct nsproxy *orig); | ||
35 | int copy_namespaces(int flags, struct task_struct *tsk); | 34 | int copy_namespaces(int flags, struct task_struct *tsk); |
36 | void get_task_namespaces(struct task_struct *tsk); | 35 | void get_task_namespaces(struct task_struct *tsk); |
37 | void free_nsproxy(struct nsproxy *ns); | 36 | void free_nsproxy(struct nsproxy *ns); |
37 | int unshare_nsproxy_namespaces(unsigned long, struct nsproxy **, | ||
38 | struct fs_struct *); | ||
38 | 39 | ||
39 | static inline void put_nsproxy(struct nsproxy *ns) | 40 | static inline void put_nsproxy(struct nsproxy *ns) |
40 | { | 41 | { |
diff --git a/include/linux/pagemap.h b/include/linux/pagemap.h index b4def5e083ed..8a83537d6978 100644 --- a/include/linux/pagemap.h +++ b/include/linux/pagemap.h | |||
@@ -11,6 +11,7 @@ | |||
11 | #include <linux/compiler.h> | 11 | #include <linux/compiler.h> |
12 | #include <asm/uaccess.h> | 12 | #include <asm/uaccess.h> |
13 | #include <linux/gfp.h> | 13 | #include <linux/gfp.h> |
14 | #include <linux/bitops.h> | ||
14 | 15 | ||
15 | /* | 16 | /* |
16 | * Bits in mapping->flags. The lower __GFP_BITS_SHIFT bits are the page | 17 | * Bits in mapping->flags. The lower __GFP_BITS_SHIFT bits are the page |
@@ -19,6 +20,16 @@ | |||
19 | #define AS_EIO (__GFP_BITS_SHIFT + 0) /* IO error on async write */ | 20 | #define AS_EIO (__GFP_BITS_SHIFT + 0) /* IO error on async write */ |
20 | #define AS_ENOSPC (__GFP_BITS_SHIFT + 1) /* ENOSPC on async write */ | 21 | #define AS_ENOSPC (__GFP_BITS_SHIFT + 1) /* ENOSPC on async write */ |
21 | 22 | ||
23 | static inline void mapping_set_error(struct address_space *mapping, int error) | ||
24 | { | ||
25 | if (error) { | ||
26 | if (error == -ENOSPC) | ||
27 | set_bit(AS_ENOSPC, &mapping->flags); | ||
28 | else | ||
29 | set_bit(AS_EIO, &mapping->flags); | ||
30 | } | ||
31 | } | ||
32 | |||
22 | static inline gfp_t mapping_gfp_mask(struct address_space * mapping) | 33 | static inline gfp_t mapping_gfp_mask(struct address_space * mapping) |
23 | { | 34 | { |
24 | return (__force gfp_t)mapping->flags & __GFP_BITS_MASK; | 35 | return (__force gfp_t)mapping->flags & __GFP_BITS_MASK; |
diff --git a/include/linux/parport.h b/include/linux/parport.h index 80682aaa8f18..9cdd6943e01b 100644 --- a/include/linux/parport.h +++ b/include/linux/parport.h | |||
@@ -279,6 +279,10 @@ struct parport { | |||
279 | int dma; | 279 | int dma; |
280 | int muxport; /* which muxport (if any) this is */ | 280 | int muxport; /* which muxport (if any) this is */ |
281 | int portnum; /* which physical parallel port (not mux) */ | 281 | int portnum; /* which physical parallel port (not mux) */ |
282 | struct device *dev; /* Physical device associated with IO/DMA. | ||
283 | * This may unfortulately be null if the | ||
284 | * port has a legacy driver. | ||
285 | */ | ||
282 | 286 | ||
283 | struct parport *physport; | 287 | struct parport *physport; |
284 | /* If this is a non-default mux | 288 | /* If this is a non-default mux |
@@ -289,7 +293,7 @@ struct parport { | |||
289 | following structure members are | 293 | following structure members are |
290 | meaningless: devices, cad, muxsel, | 294 | meaningless: devices, cad, muxsel, |
291 | waithead, waittail, flags, pdir, | 295 | waithead, waittail, flags, pdir, |
292 | ieee1284, *_lock. | 296 | dev, ieee1284, *_lock. |
293 | 297 | ||
294 | It this is a default mux parport, or | 298 | It this is a default mux parport, or |
295 | there is no mux involved, this points to | 299 | there is no mux involved, this points to |
@@ -302,7 +306,7 @@ struct parport { | |||
302 | 306 | ||
303 | struct pardevice *waithead; | 307 | struct pardevice *waithead; |
304 | struct pardevice *waittail; | 308 | struct pardevice *waittail; |
305 | 309 | ||
306 | struct list_head list; | 310 | struct list_head list; |
307 | unsigned int flags; | 311 | unsigned int flags; |
308 | 312 | ||
diff --git a/include/linux/parport_pc.h b/include/linux/parport_pc.h index 1cc0f6b1a49a..ea8c6d84996d 100644 --- a/include/linux/parport_pc.h +++ b/include/linux/parport_pc.h | |||
@@ -38,7 +38,6 @@ struct parport_pc_private { | |||
38 | /* buffer suitable for DMA, if DMA enabled */ | 38 | /* buffer suitable for DMA, if DMA enabled */ |
39 | char *dma_buf; | 39 | char *dma_buf; |
40 | dma_addr_t dma_handle; | 40 | dma_addr_t dma_handle; |
41 | struct pci_dev *dev; | ||
42 | struct list_head list; | 41 | struct list_head list; |
43 | struct parport *port; | 42 | struct parport *port; |
44 | }; | 43 | }; |
@@ -232,7 +231,7 @@ extern int parport_pc_claim_resources(struct parport *p); | |||
232 | extern struct parport *parport_pc_probe_port (unsigned long base, | 231 | extern struct parport *parport_pc_probe_port (unsigned long base, |
233 | unsigned long base_hi, | 232 | unsigned long base_hi, |
234 | int irq, int dma, | 233 | int irq, int dma, |
235 | struct pci_dev *dev); | 234 | struct device *dev); |
236 | extern void parport_pc_unregister_port (struct parport *p); | 235 | extern void parport_pc_unregister_port (struct parport *p); |
237 | 236 | ||
238 | #endif | 237 | #endif |
diff --git a/include/linux/phantom.h b/include/linux/phantom.h new file mode 100644 index 000000000000..d3ebbfae6903 --- /dev/null +++ b/include/linux/phantom.h | |||
@@ -0,0 +1,42 @@ | |||
1 | /* | ||
2 | * Copyright (C) 2005-2007 Jiri Slaby <jirislaby@gmail.com> | ||
3 | * | ||
4 | * This program is free software; you can redistribute it and/or modify | ||
5 | * it under the terms of the GNU General Public License as published by | ||
6 | * the Free Software Foundation; either version 2 of the License, or | ||
7 | * (at your option) any later version. | ||
8 | */ | ||
9 | |||
10 | #ifndef __PHANTOM_H | ||
11 | #define __PHANTOM_H | ||
12 | |||
13 | #include <asm/types.h> | ||
14 | |||
15 | /* PHN_(G/S)ET_REG param */ | ||
16 | struct phm_reg { | ||
17 | __u32 reg; | ||
18 | __u32 value; | ||
19 | }; | ||
20 | |||
21 | /* PHN_(G/S)ET_REGS param */ | ||
22 | struct phm_regs { | ||
23 | __u32 count; | ||
24 | __u32 mask; | ||
25 | __u32 values[8]; | ||
26 | }; | ||
27 | |||
28 | #define PH_IOC_MAGIC 'p' | ||
29 | #define PHN_GET_REG _IOWR(PH_IOC_MAGIC, 0, struct phm_reg *) | ||
30 | #define PHN_SET_REG _IOW (PH_IOC_MAGIC, 1, struct phm_reg *) | ||
31 | #define PHN_GET_REGS _IOWR(PH_IOC_MAGIC, 2, struct phm_regs *) | ||
32 | #define PHN_SET_REGS _IOW (PH_IOC_MAGIC, 3, struct phm_regs *) | ||
33 | #define PH_IOC_MAXNR 3 | ||
34 | |||
35 | #define PHN_CONTROL 0x6 /* control byte in iaddr space */ | ||
36 | #define PHN_CTL_AMP 0x1 /* switch after torques change */ | ||
37 | #define PHN_CTL_BUT 0x2 /* is button switched */ | ||
38 | #define PHN_CTL_IRQ 0x10 /* is irq enabled */ | ||
39 | |||
40 | #define PHN_ZERO_FORCE 2048 /* zero torque on motor */ | ||
41 | |||
42 | #endif | ||
diff --git a/include/linux/pid_namespace.h b/include/linux/pid_namespace.h index 2833806d42c6..169c6c24209b 100644 --- a/include/linux/pid_namespace.h +++ b/include/linux/pid_namespace.h | |||
@@ -29,7 +29,7 @@ static inline void get_pid_ns(struct pid_namespace *ns) | |||
29 | kref_get(&ns->kref); | 29 | kref_get(&ns->kref); |
30 | } | 30 | } |
31 | 31 | ||
32 | extern int copy_pid_ns(int flags, struct task_struct *tsk); | 32 | extern struct pid_namespace *copy_pid_ns(int flags, struct pid_namespace *ns); |
33 | extern void free_pid_ns(struct kref *kref); | 33 | extern void free_pid_ns(struct kref *kref); |
34 | 34 | ||
35 | static inline void put_pid_ns(struct pid_namespace *ns) | 35 | static inline void put_pid_ns(struct pid_namespace *ns) |
diff --git a/include/linux/pnp.h b/include/linux/pnp.h index 9a5226f0f169..2a1897e6f937 100644 --- a/include/linux/pnp.h +++ b/include/linux/pnp.h | |||
@@ -177,6 +177,7 @@ static inline void pnp_set_card_drvdata (struct pnp_card_link *pcard, void *data | |||
177 | 177 | ||
178 | struct pnp_dev { | 178 | struct pnp_dev { |
179 | struct device dev; /* Driver Model device interface */ | 179 | struct device dev; /* Driver Model device interface */ |
180 | u64 dma_mask; | ||
180 | unsigned char number; /* used as an index, must be unique */ | 181 | unsigned char number; /* used as an index, must be unique */ |
181 | int status; | 182 | int status; |
182 | 183 | ||
@@ -363,6 +364,7 @@ int pnp_add_device(struct pnp_dev *dev); | |||
363 | int pnp_device_attach(struct pnp_dev *pnp_dev); | 364 | int pnp_device_attach(struct pnp_dev *pnp_dev); |
364 | void pnp_device_detach(struct pnp_dev *pnp_dev); | 365 | void pnp_device_detach(struct pnp_dev *pnp_dev); |
365 | extern struct list_head pnp_global; | 366 | extern struct list_head pnp_global; |
367 | extern int pnp_platform_devices; | ||
366 | 368 | ||
367 | /* multidevice card support */ | 369 | /* multidevice card support */ |
368 | int pnp_add_card(struct pnp_card *card); | 370 | int pnp_add_card(struct pnp_card *card); |
@@ -410,6 +412,7 @@ static inline int pnp_init_device(struct pnp_dev *dev) { return -ENODEV; } | |||
410 | static inline int pnp_add_device(struct pnp_dev *dev) { return -ENODEV; } | 412 | static inline int pnp_add_device(struct pnp_dev *dev) { return -ENODEV; } |
411 | static inline int pnp_device_attach(struct pnp_dev *pnp_dev) { return -ENODEV; } | 413 | static inline int pnp_device_attach(struct pnp_dev *pnp_dev) { return -ENODEV; } |
412 | static inline void pnp_device_detach(struct pnp_dev *pnp_dev) { ; } | 414 | static inline void pnp_device_detach(struct pnp_dev *pnp_dev) { ; } |
415 | #define pnp_platform_devices 0 | ||
413 | 416 | ||
414 | /* multidevice card support */ | 417 | /* multidevice card support */ |
415 | static inline int pnp_add_card(struct pnp_card *card) { return -ENODEV; } | 418 | static inline int pnp_add_card(struct pnp_card *card) { return -ENODEV; } |
diff --git a/include/linux/poison.h b/include/linux/poison.h index 95f518b17684..d93c300a3449 100644 --- a/include/linux/poison.h +++ b/include/linux/poison.h | |||
@@ -15,8 +15,8 @@ | |||
15 | * Magic nums for obj red zoning. | 15 | * Magic nums for obj red zoning. |
16 | * Placed in the first word before and the first word after an obj. | 16 | * Placed in the first word before and the first word after an obj. |
17 | */ | 17 | */ |
18 | #define RED_INACTIVE 0x5A2CF071UL /* when obj is inactive */ | 18 | #define RED_INACTIVE 0x09F911029D74E35BULL /* when obj is inactive */ |
19 | #define RED_ACTIVE 0x170FC2A5UL /* when obj is active */ | 19 | #define RED_ACTIVE 0xD84156C5635688C0ULL /* when obj is active */ |
20 | 20 | ||
21 | #define SLUB_RED_INACTIVE 0xbb | 21 | #define SLUB_RED_INACTIVE 0xbb |
22 | #define SLUB_RED_ACTIVE 0xcc | 22 | #define SLUB_RED_ACTIVE 0xcc |
diff --git a/include/linux/proc_fs.h b/include/linux/proc_fs.h index f4f7a63cae1f..3469f96bc8b2 100644 --- a/include/linux/proc_fs.h +++ b/include/linux/proc_fs.h | |||
@@ -106,6 +106,9 @@ int task_statm(struct mm_struct *, int *, int *, int *, int *); | |||
106 | char *task_mem(struct mm_struct *, char *); | 106 | char *task_mem(struct mm_struct *, char *); |
107 | void clear_refs_smap(struct mm_struct *mm); | 107 | void clear_refs_smap(struct mm_struct *mm); |
108 | 108 | ||
109 | struct proc_dir_entry *de_get(struct proc_dir_entry *de); | ||
110 | void de_put(struct proc_dir_entry *de); | ||
111 | |||
109 | extern struct proc_dir_entry *create_proc_entry(const char *name, mode_t mode, | 112 | extern struct proc_dir_entry *create_proc_entry(const char *name, mode_t mode, |
110 | struct proc_dir_entry *parent); | 113 | struct proc_dir_entry *parent); |
111 | extern void remove_proc_entry(const char *name, struct proc_dir_entry *parent); | 114 | extern void remove_proc_entry(const char *name, struct proc_dir_entry *parent); |
diff --git a/include/linux/quota.h b/include/linux/quota.h index 77db80a953d6..62439828395e 100644 --- a/include/linux/quota.h +++ b/include/linux/quota.h | |||
@@ -44,8 +44,6 @@ | |||
44 | typedef __kernel_uid32_t qid_t; /* Type in which we store ids in memory */ | 44 | typedef __kernel_uid32_t qid_t; /* Type in which we store ids in memory */ |
45 | typedef __u64 qsize_t; /* Type in which we store sizes */ | 45 | typedef __u64 qsize_t; /* Type in which we store sizes */ |
46 | 46 | ||
47 | extern spinlock_t dq_data_lock; | ||
48 | |||
49 | /* Size of blocks in which are counted size limits */ | 47 | /* Size of blocks in which are counted size limits */ |
50 | #define QUOTABLOCK_BITS 10 | 48 | #define QUOTABLOCK_BITS 10 |
51 | #define QUOTABLOCK_SIZE (1 << QUOTABLOCK_BITS) | 49 | #define QUOTABLOCK_SIZE (1 << QUOTABLOCK_BITS) |
@@ -139,6 +137,8 @@ struct if_dqinfo { | |||
139 | #include <linux/dqblk_v1.h> | 137 | #include <linux/dqblk_v1.h> |
140 | #include <linux/dqblk_v2.h> | 138 | #include <linux/dqblk_v2.h> |
141 | 139 | ||
140 | extern spinlock_t dq_data_lock; | ||
141 | |||
142 | /* Maximal numbers of writes for quota operation (insert/delete/update) | 142 | /* Maximal numbers of writes for quota operation (insert/delete/update) |
143 | * (over VFS all formats) */ | 143 | * (over VFS all formats) */ |
144 | #define DQUOT_INIT_ALLOC max(V1_INIT_ALLOC, V2_INIT_ALLOC) | 144 | #define DQUOT_INIT_ALLOC max(V1_INIT_ALLOC, V2_INIT_ALLOC) |
diff --git a/include/linux/quotaops.h b/include/linux/quotaops.h index 90c23f690c0d..5110201a4159 100644 --- a/include/linux/quotaops.h +++ b/include/linux/quotaops.h | |||
@@ -37,9 +37,6 @@ extern int dquot_release(struct dquot *dquot); | |||
37 | extern int dquot_commit_info(struct super_block *sb, int type); | 37 | extern int dquot_commit_info(struct super_block *sb, int type); |
38 | extern int dquot_mark_dquot_dirty(struct dquot *dquot); | 38 | extern int dquot_mark_dquot_dirty(struct dquot *dquot); |
39 | 39 | ||
40 | int remove_inode_dquot_ref(struct inode *inode, int type, | ||
41 | struct list_head *tofree_head); | ||
42 | |||
43 | extern int vfs_quota_on(struct super_block *sb, int type, int format_id, char *path); | 40 | extern int vfs_quota_on(struct super_block *sb, int type, int format_id, char *path); |
44 | extern int vfs_quota_on_mount(struct super_block *sb, char *qf_name, | 41 | extern int vfs_quota_on_mount(struct super_block *sb, char *qf_name, |
45 | int format_id, int type); | 42 | int format_id, int type); |
diff --git a/include/linux/reiserfs_fs_sb.h b/include/linux/reiserfs_fs_sb.h index 3a28742d86f9..1e5488ede037 100644 --- a/include/linux/reiserfs_fs_sb.h +++ b/include/linux/reiserfs_fs_sb.h | |||
@@ -401,9 +401,10 @@ struct reiserfs_sb_info { | |||
401 | int reserved_blocks; /* amount of blocks reserved for further allocations */ | 401 | int reserved_blocks; /* amount of blocks reserved for further allocations */ |
402 | spinlock_t bitmap_lock; /* this lock on now only used to protect reserved_blocks variable */ | 402 | spinlock_t bitmap_lock; /* this lock on now only used to protect reserved_blocks variable */ |
403 | struct dentry *priv_root; /* root of /.reiserfs_priv */ | 403 | struct dentry *priv_root; /* root of /.reiserfs_priv */ |
404 | #ifdef CONFIG_REISERFS_FS_XATTR | ||
404 | struct dentry *xattr_root; /* root of /.reiserfs_priv/.xa */ | 405 | struct dentry *xattr_root; /* root of /.reiserfs_priv/.xa */ |
405 | struct rw_semaphore xattr_dir_sem; | 406 | struct rw_semaphore xattr_dir_sem; |
406 | 407 | #endif | |
407 | int j_errno; | 408 | int j_errno; |
408 | #ifdef CONFIG_QUOTA | 409 | #ifdef CONFIG_QUOTA |
409 | char *s_qf_names[MAXQUOTAS]; | 410 | char *s_qf_names[MAXQUOTAS]; |
diff --git a/include/linux/rtc.h b/include/linux/rtc.h index 5e22d4510d11..6d5e4a46781e 100644 --- a/include/linux/rtc.h +++ b/include/linux/rtc.h | |||
@@ -4,7 +4,7 @@ | |||
4 | * service. It is used with both the legacy mc146818 and also EFI | 4 | * service. It is used with both the legacy mc146818 and also EFI |
5 | * Struct rtc_time and first 12 ioctl by Paul Gortmaker, 1996 - separated out | 5 | * Struct rtc_time and first 12 ioctl by Paul Gortmaker, 1996 - separated out |
6 | * from <linux/mc146818rtc.h> to this file for 2.4 kernels. | 6 | * from <linux/mc146818rtc.h> to this file for 2.4 kernels. |
7 | * | 7 | * |
8 | * Copyright (C) 1999 Hewlett-Packard Co. | 8 | * Copyright (C) 1999 Hewlett-Packard Co. |
9 | * Copyright (C) 1999 Stephane Eranian <eranian@hpl.hp.com> | 9 | * Copyright (C) 1999 Stephane Eranian <eranian@hpl.hp.com> |
10 | */ | 10 | */ |
@@ -13,7 +13,7 @@ | |||
13 | 13 | ||
14 | /* | 14 | /* |
15 | * The struct used to pass data via the following ioctl. Similar to the | 15 | * The struct used to pass data via the following ioctl. Similar to the |
16 | * struct tm in <time.h>, but it needs to be here so that the kernel | 16 | * struct tm in <time.h>, but it needs to be here so that the kernel |
17 | * source is self contained, allowing cross-compiles, etc. etc. | 17 | * source is self contained, allowing cross-compiles, etc. etc. |
18 | */ | 18 | */ |
19 | 19 | ||
@@ -50,7 +50,7 @@ struct rtc_wkalrm { | |||
50 | * pll_value*pll_posmult/pll_clock | 50 | * pll_value*pll_posmult/pll_clock |
51 | * -ve pll_value means clock will run slower by | 51 | * -ve pll_value means clock will run slower by |
52 | * pll_value*pll_negmult/pll_clock | 52 | * pll_value*pll_negmult/pll_clock |
53 | */ | 53 | */ |
54 | 54 | ||
55 | struct rtc_pll_info { | 55 | struct rtc_pll_info { |
56 | int pll_ctrl; /* placeholder for fancier control */ | 56 | int pll_ctrl; /* placeholder for fancier control */ |
@@ -106,7 +106,6 @@ extern int rtc_year_days(unsigned int day, unsigned int month, unsigned int year | |||
106 | extern int rtc_valid_tm(struct rtc_time *tm); | 106 | extern int rtc_valid_tm(struct rtc_time *tm); |
107 | extern int rtc_tm_to_time(struct rtc_time *tm, unsigned long *time); | 107 | extern int rtc_tm_to_time(struct rtc_time *tm, unsigned long *time); |
108 | extern void rtc_time_to_tm(unsigned long time, struct rtc_time *tm); | 108 | extern void rtc_time_to_tm(unsigned long time, struct rtc_time *tm); |
109 | extern void rtc_merge_alarm(struct rtc_time *now, struct rtc_time *alarm); | ||
110 | 109 | ||
111 | #include <linux/device.h> | 110 | #include <linux/device.h> |
112 | #include <linux/seq_file.h> | 111 | #include <linux/seq_file.h> |
@@ -136,7 +135,7 @@ struct rtc_task; | |||
136 | 135 | ||
137 | struct rtc_device | 136 | struct rtc_device |
138 | { | 137 | { |
139 | struct class_device class_dev; | 138 | struct device dev; |
140 | struct module *owner; | 139 | struct module *owner; |
141 | 140 | ||
142 | int id; | 141 | int id; |
@@ -145,7 +144,6 @@ struct rtc_device | |||
145 | const struct rtc_class_ops *ops; | 144 | const struct rtc_class_ops *ops; |
146 | struct mutex ops_lock; | 145 | struct mutex ops_lock; |
147 | 146 | ||
148 | struct class_device *rtc_dev; | ||
149 | struct cdev char_dev; | 147 | struct cdev char_dev; |
150 | struct mutex char_lock; | 148 | struct mutex char_lock; |
151 | 149 | ||
@@ -169,35 +167,34 @@ struct rtc_device | |||
169 | unsigned int uie_timer_active:1; | 167 | unsigned int uie_timer_active:1; |
170 | #endif | 168 | #endif |
171 | }; | 169 | }; |
172 | #define to_rtc_device(d) container_of(d, struct rtc_device, class_dev) | 170 | #define to_rtc_device(d) container_of(d, struct rtc_device, dev) |
173 | 171 | ||
174 | extern struct rtc_device *rtc_device_register(const char *name, | 172 | extern struct rtc_device *rtc_device_register(const char *name, |
175 | struct device *dev, | 173 | struct device *dev, |
176 | const struct rtc_class_ops *ops, | 174 | const struct rtc_class_ops *ops, |
177 | struct module *owner); | 175 | struct module *owner); |
178 | extern void rtc_device_unregister(struct rtc_device *rdev); | 176 | extern void rtc_device_unregister(struct rtc_device *rtc); |
179 | extern int rtc_interface_register(struct class_interface *intf); | ||
180 | 177 | ||
181 | extern int rtc_read_time(struct class_device *class_dev, struct rtc_time *tm); | 178 | extern int rtc_read_time(struct rtc_device *rtc, struct rtc_time *tm); |
182 | extern int rtc_set_time(struct class_device *class_dev, struct rtc_time *tm); | 179 | extern int rtc_set_time(struct rtc_device *rtc, struct rtc_time *tm); |
183 | extern int rtc_set_mmss(struct class_device *class_dev, unsigned long secs); | 180 | extern int rtc_set_mmss(struct rtc_device *rtc, unsigned long secs); |
184 | extern int rtc_read_alarm(struct class_device *class_dev, | 181 | extern int rtc_read_alarm(struct rtc_device *rtc, |
185 | struct rtc_wkalrm *alrm); | 182 | struct rtc_wkalrm *alrm); |
186 | extern int rtc_set_alarm(struct class_device *class_dev, | 183 | extern int rtc_set_alarm(struct rtc_device *rtc, |
187 | struct rtc_wkalrm *alrm); | 184 | struct rtc_wkalrm *alrm); |
188 | extern void rtc_update_irq(struct class_device *class_dev, | 185 | extern void rtc_update_irq(struct rtc_device *rtc, |
189 | unsigned long num, unsigned long events); | 186 | unsigned long num, unsigned long events); |
190 | 187 | ||
191 | extern struct class_device *rtc_class_open(char *name); | 188 | extern struct rtc_device *rtc_class_open(char *name); |
192 | extern void rtc_class_close(struct class_device *class_dev); | 189 | extern void rtc_class_close(struct rtc_device *rtc); |
193 | 190 | ||
194 | extern int rtc_irq_register(struct class_device *class_dev, | 191 | extern int rtc_irq_register(struct rtc_device *rtc, |
195 | struct rtc_task *task); | 192 | struct rtc_task *task); |
196 | extern void rtc_irq_unregister(struct class_device *class_dev, | 193 | extern void rtc_irq_unregister(struct rtc_device *rtc, |
197 | struct rtc_task *task); | 194 | struct rtc_task *task); |
198 | extern int rtc_irq_set_state(struct class_device *class_dev, | 195 | extern int rtc_irq_set_state(struct rtc_device *rtc, |
199 | struct rtc_task *task, int enabled); | 196 | struct rtc_task *task, int enabled); |
200 | extern int rtc_irq_set_freq(struct class_device *class_dev, | 197 | extern int rtc_irq_set_freq(struct rtc_device *rtc, |
201 | struct rtc_task *task, int freq); | 198 | struct rtc_task *task, int freq); |
202 | 199 | ||
203 | typedef struct rtc_task { | 200 | typedef struct rtc_task { |
diff --git a/include/linux/sched.h b/include/linux/sched.h index a1707583de49..3d95c480f58d 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h | |||
@@ -194,6 +194,14 @@ extern void sched_init_smp(void); | |||
194 | extern void init_idle(struct task_struct *idle, int cpu); | 194 | extern void init_idle(struct task_struct *idle, int cpu); |
195 | 195 | ||
196 | extern cpumask_t nohz_cpu_mask; | 196 | extern cpumask_t nohz_cpu_mask; |
197 | #if defined(CONFIG_SMP) && defined(CONFIG_NO_HZ) | ||
198 | extern int select_nohz_load_balancer(int cpu); | ||
199 | #else | ||
200 | static inline int select_nohz_load_balancer(int cpu) | ||
201 | { | ||
202 | return 0; | ||
203 | } | ||
204 | #endif | ||
197 | 205 | ||
198 | /* | 206 | /* |
199 | * Only dump TASK_* tasks. (0 for all tasks) | 207 | * Only dump TASK_* tasks. (0 for all tasks) |
@@ -226,6 +234,7 @@ extern void scheduler_tick(void); | |||
226 | extern void softlockup_tick(void); | 234 | extern void softlockup_tick(void); |
227 | extern void spawn_softlockup_task(void); | 235 | extern void spawn_softlockup_task(void); |
228 | extern void touch_softlockup_watchdog(void); | 236 | extern void touch_softlockup_watchdog(void); |
237 | extern void touch_all_softlockup_watchdogs(void); | ||
229 | #else | 238 | #else |
230 | static inline void softlockup_tick(void) | 239 | static inline void softlockup_tick(void) |
231 | { | 240 | { |
@@ -236,6 +245,9 @@ static inline void spawn_softlockup_task(void) | |||
236 | static inline void touch_softlockup_watchdog(void) | 245 | static inline void touch_softlockup_watchdog(void) |
237 | { | 246 | { |
238 | } | 247 | } |
248 | static inline void touch_all_softlockup_watchdogs(void) | ||
249 | { | ||
250 | } | ||
239 | #endif | 251 | #endif |
240 | 252 | ||
241 | 253 | ||
@@ -668,8 +680,14 @@ struct sched_group { | |||
668 | /* | 680 | /* |
669 | * CPU power of this group, SCHED_LOAD_SCALE being max power for a | 681 | * CPU power of this group, SCHED_LOAD_SCALE being max power for a |
670 | * single CPU. This is read only (except for setup, hotplug CPU). | 682 | * single CPU. This is read only (except for setup, hotplug CPU). |
683 | * Note : Never change cpu_power without recompute its reciprocal | ||
684 | */ | ||
685 | unsigned int __cpu_power; | ||
686 | /* | ||
687 | * reciprocal value of cpu_power to avoid expensive divides | ||
688 | * (see include/linux/reciprocal_div.h) | ||
671 | */ | 689 | */ |
672 | unsigned long cpu_power; | 690 | u32 reciprocal_cpu_power; |
673 | }; | 691 | }; |
674 | 692 | ||
675 | struct sched_domain { | 693 | struct sched_domain { |
@@ -801,8 +819,8 @@ struct task_struct { | |||
801 | volatile long state; /* -1 unrunnable, 0 runnable, >0 stopped */ | 819 | volatile long state; /* -1 unrunnable, 0 runnable, >0 stopped */ |
802 | struct thread_info *thread_info; | 820 | struct thread_info *thread_info; |
803 | atomic_t usage; | 821 | atomic_t usage; |
804 | unsigned long flags; /* per process flags, defined below */ | 822 | unsigned int flags; /* per process flags, defined below */ |
805 | unsigned long ptrace; | 823 | unsigned int ptrace; |
806 | 824 | ||
807 | int lock_depth; /* BKL lock depth */ | 825 | int lock_depth; /* BKL lock depth */ |
808 | 826 | ||
@@ -825,7 +843,7 @@ struct task_struct { | |||
825 | unsigned long long sched_time; /* sched_clock time spent running */ | 843 | unsigned long long sched_time; /* sched_clock time spent running */ |
826 | enum sleep_type sleep_type; | 844 | enum sleep_type sleep_type; |
827 | 845 | ||
828 | unsigned long policy; | 846 | unsigned int policy; |
829 | cpumask_t cpus_allowed; | 847 | cpumask_t cpus_allowed; |
830 | unsigned int time_slice, first_time_slice; | 848 | unsigned int time_slice, first_time_slice; |
831 | 849 | ||
@@ -845,11 +863,11 @@ struct task_struct { | |||
845 | 863 | ||
846 | /* task state */ | 864 | /* task state */ |
847 | struct linux_binfmt *binfmt; | 865 | struct linux_binfmt *binfmt; |
848 | long exit_state; | 866 | int exit_state; |
849 | int exit_code, exit_signal; | 867 | int exit_code, exit_signal; |
850 | int pdeath_signal; /* The signal sent when the parent dies */ | 868 | int pdeath_signal; /* The signal sent when the parent dies */ |
851 | /* ??? */ | 869 | /* ??? */ |
852 | unsigned long personality; | 870 | unsigned int personality; |
853 | unsigned did_exec:1; | 871 | unsigned did_exec:1; |
854 | pid_t pid; | 872 | pid_t pid; |
855 | pid_t tgid; | 873 | pid_t tgid; |
@@ -881,7 +899,7 @@ struct task_struct { | |||
881 | int __user *set_child_tid; /* CLONE_CHILD_SETTID */ | 899 | int __user *set_child_tid; /* CLONE_CHILD_SETTID */ |
882 | int __user *clear_child_tid; /* CLONE_CHILD_CLEARTID */ | 900 | int __user *clear_child_tid; /* CLONE_CHILD_CLEARTID */ |
883 | 901 | ||
884 | unsigned long rt_priority; | 902 | unsigned int rt_priority; |
885 | cputime_t utime, stime; | 903 | cputime_t utime, stime; |
886 | unsigned long nvcsw, nivcsw; /* context switch counts */ | 904 | unsigned long nvcsw, nivcsw; /* context switch counts */ |
887 | struct timespec start_time; | 905 | struct timespec start_time; |
@@ -1641,10 +1659,7 @@ static inline void arch_pick_mmap_layout(struct mm_struct *mm) | |||
1641 | extern long sched_setaffinity(pid_t pid, cpumask_t new_mask); | 1659 | extern long sched_setaffinity(pid_t pid, cpumask_t new_mask); |
1642 | extern long sched_getaffinity(pid_t pid, cpumask_t *mask); | 1660 | extern long sched_getaffinity(pid_t pid, cpumask_t *mask); |
1643 | 1661 | ||
1644 | #include <linux/sysdev.h> | ||
1645 | extern int sched_mc_power_savings, sched_smt_power_savings; | 1662 | extern int sched_mc_power_savings, sched_smt_power_savings; |
1646 | extern struct sysdev_attribute attr_sched_mc_power_savings, attr_sched_smt_power_savings; | ||
1647 | extern int sched_create_sysfs_power_savings_entries(struct sysdev_class *cls); | ||
1648 | 1663 | ||
1649 | extern void normalize_rt_tasks(void); | 1664 | extern void normalize_rt_tasks(void); |
1650 | 1665 | ||
diff --git a/include/linux/spi/Kbuild b/include/linux/spi/Kbuild new file mode 100644 index 000000000000..d375a082986e --- /dev/null +++ b/include/linux/spi/Kbuild | |||
@@ -0,0 +1 @@ | |||
header-y += spidev.h | |||
diff --git a/include/linux/spi/spi.h b/include/linux/spi/spi.h index 4f0f8c2e58a5..b6bedc3ee95c 100644 --- a/include/linux/spi/spi.h +++ b/include/linux/spi/spi.h | |||
@@ -32,11 +32,12 @@ extern struct bus_type spi_bus_type; | |||
32 | * @max_speed_hz: Maximum clock rate to be used with this chip | 32 | * @max_speed_hz: Maximum clock rate to be used with this chip |
33 | * (on this board); may be changed by the device's driver. | 33 | * (on this board); may be changed by the device's driver. |
34 | * The spi_transfer.speed_hz can override this for each transfer. | 34 | * The spi_transfer.speed_hz can override this for each transfer. |
35 | * @chip-select: Chipselect, distinguishing chips handled by "master". | 35 | * @chip_select: Chipselect, distinguishing chips handled by @master. |
36 | * @mode: The spi mode defines how data is clocked out and in. | 36 | * @mode: The spi mode defines how data is clocked out and in. |
37 | * This may be changed by the device's driver. | 37 | * This may be changed by the device's driver. |
38 | * The "active low" default for chipselect mode can be overridden, | 38 | * The "active low" default for chipselect mode can be overridden |
39 | * as can the "MSB first" default for each word in a transfer. | 39 | * (by specifying SPI_CS_HIGH) as can the "MSB first" default for |
40 | * each word in a transfer (by specifying SPI_LSB_FIRST). | ||
40 | * @bits_per_word: Data transfers involve one or more words; word sizes | 41 | * @bits_per_word: Data transfers involve one or more words; word sizes |
41 | * like eight or 12 bits are common. In-memory wordsizes are | 42 | * like eight or 12 bits are common. In-memory wordsizes are |
42 | * powers of two bytes (e.g. 20 bit samples use 32 bits). | 43 | * powers of two bytes (e.g. 20 bit samples use 32 bits). |
@@ -48,14 +49,18 @@ extern struct bus_type spi_bus_type; | |||
48 | * @controller_state: Controller's runtime state | 49 | * @controller_state: Controller's runtime state |
49 | * @controller_data: Board-specific definitions for controller, such as | 50 | * @controller_data: Board-specific definitions for controller, such as |
50 | * FIFO initialization parameters; from board_info.controller_data | 51 | * FIFO initialization parameters; from board_info.controller_data |
52 | * @modalias: Name of the driver to use with this device, or an alias | ||
53 | * for that name. This appears in the sysfs "modalias" attribute | ||
54 | * for driver coldplugging, and in uevents used for hotplugging | ||
51 | * | 55 | * |
52 | * An spi_device is used to interchange data between an SPI slave | 56 | * A @spi_device is used to interchange data between an SPI slave |
53 | * (usually a discrete chip) and CPU memory. | 57 | * (usually a discrete chip) and CPU memory. |
54 | * | 58 | * |
55 | * In "dev", the platform_data is used to hold information about this | 59 | * In @dev, the platform_data is used to hold information about this |
56 | * device that's meaningful to the device's protocol driver, but not | 60 | * device that's meaningful to the device's protocol driver, but not |
57 | * to its controller. One example might be an identifier for a chip | 61 | * to its controller. One example might be an identifier for a chip |
58 | * variant with slightly different functionality. | 62 | * variant with slightly different functionality; another might be |
63 | * information about how this particular board wires the chip's pins. | ||
59 | */ | 64 | */ |
60 | struct spi_device { | 65 | struct spi_device { |
61 | struct device dev; | 66 | struct device dev; |
@@ -77,13 +82,15 @@ struct spi_device { | |||
77 | void *controller_data; | 82 | void *controller_data; |
78 | const char *modalias; | 83 | const char *modalias; |
79 | 84 | ||
80 | // likely need more hooks for more protocol options affecting how | 85 | /* |
81 | // the controller talks to each chip, like: | 86 | * likely need more hooks for more protocol options affecting how |
82 | // - memory packing (12 bit samples into low bits, others zeroed) | 87 | * the controller talks to each chip, like: |
83 | // - priority | 88 | * - memory packing (12 bit samples into low bits, others zeroed) |
84 | // - drop chipselect after each word | 89 | * - priority |
85 | // - chipselect delays | 90 | * - drop chipselect after each word |
86 | // - ... | 91 | * - chipselect delays |
92 | * - ... | ||
93 | */ | ||
87 | }; | 94 | }; |
88 | 95 | ||
89 | static inline struct spi_device *to_spi_device(struct device *dev) | 96 | static inline struct spi_device *to_spi_device(struct device *dev) |
@@ -146,6 +153,11 @@ static inline struct spi_driver *to_spi_driver(struct device_driver *drv) | |||
146 | 153 | ||
147 | extern int spi_register_driver(struct spi_driver *sdrv); | 154 | extern int spi_register_driver(struct spi_driver *sdrv); |
148 | 155 | ||
156 | /** | ||
157 | * spi_unregister_driver - reverse effect of spi_register_driver | ||
158 | * @sdrv: the driver to unregister | ||
159 | * Context: can sleep | ||
160 | */ | ||
149 | static inline void spi_unregister_driver(struct spi_driver *sdrv) | 161 | static inline void spi_unregister_driver(struct spi_driver *sdrv) |
150 | { | 162 | { |
151 | if (sdrv) | 163 | if (sdrv) |
@@ -165,18 +177,20 @@ static inline void spi_unregister_driver(struct spi_driver *sdrv) | |||
165 | * @setup: updates the device mode and clocking records used by a | 177 | * @setup: updates the device mode and clocking records used by a |
166 | * device's SPI controller; protocol code may call this. This | 178 | * device's SPI controller; protocol code may call this. This |
167 | * must fail if an unrecognized or unsupported mode is requested. | 179 | * must fail if an unrecognized or unsupported mode is requested. |
180 | * It's always safe to call this unless transfers are pending on | ||
181 | * the device whose settings are being modified. | ||
168 | * @transfer: adds a message to the controller's transfer queue. | 182 | * @transfer: adds a message to the controller's transfer queue. |
169 | * @cleanup: frees controller-specific state | 183 | * @cleanup: frees controller-specific state |
170 | * | 184 | * |
171 | * Each SPI master controller can communicate with one or more spi_device | 185 | * Each SPI master controller can communicate with one or more @spi_device |
172 | * children. These make a small bus, sharing MOSI, MISO and SCK signals | 186 | * children. These make a small bus, sharing MOSI, MISO and SCK signals |
173 | * but not chip select signals. Each device may be configured to use a | 187 | * but not chip select signals. Each device may be configured to use a |
174 | * different clock rate, since those shared signals are ignored unless | 188 | * different clock rate, since those shared signals are ignored unless |
175 | * the chip is selected. | 189 | * the chip is selected. |
176 | * | 190 | * |
177 | * The driver for an SPI controller manages access to those devices through | 191 | * The driver for an SPI controller manages access to those devices through |
178 | * a queue of spi_message transactions, copyin data between CPU memory and | 192 | * a queue of spi_message transactions, copying data between CPU memory and |
179 | * an SPI slave device). For each such message it queues, it calls the | 193 | * an SPI slave device. For each such message it queues, it calls the |
180 | * message's completion function when the transaction completes. | 194 | * message's completion function when the transaction completes. |
181 | */ | 195 | */ |
182 | struct spi_master { | 196 | struct spi_master { |
@@ -280,27 +294,27 @@ extern struct spi_master *spi_busnum_to_master(u16 busnum); | |||
280 | * struct spi_transfer - a read/write buffer pair | 294 | * struct spi_transfer - a read/write buffer pair |
281 | * @tx_buf: data to be written (dma-safe memory), or NULL | 295 | * @tx_buf: data to be written (dma-safe memory), or NULL |
282 | * @rx_buf: data to be read (dma-safe memory), or NULL | 296 | * @rx_buf: data to be read (dma-safe memory), or NULL |
283 | * @tx_dma: DMA address of tx_buf, if spi_message.is_dma_mapped | 297 | * @tx_dma: DMA address of tx_buf, if @spi_message.is_dma_mapped |
284 | * @rx_dma: DMA address of rx_buf, if spi_message.is_dma_mapped | 298 | * @rx_dma: DMA address of rx_buf, if @spi_message.is_dma_mapped |
285 | * @len: size of rx and tx buffers (in bytes) | 299 | * @len: size of rx and tx buffers (in bytes) |
286 | * @speed_hz: Select a speed other then the device default for this | 300 | * @speed_hz: Select a speed other then the device default for this |
287 | * transfer. If 0 the default (from spi_device) is used. | 301 | * transfer. If 0 the default (from @spi_device) is used. |
288 | * @bits_per_word: select a bits_per_word other then the device default | 302 | * @bits_per_word: select a bits_per_word other then the device default |
289 | * for this transfer. If 0 the default (from spi_device) is used. | 303 | * for this transfer. If 0 the default (from @spi_device) is used. |
290 | * @cs_change: affects chipselect after this transfer completes | 304 | * @cs_change: affects chipselect after this transfer completes |
291 | * @delay_usecs: microseconds to delay after this transfer before | 305 | * @delay_usecs: microseconds to delay after this transfer before |
292 | * (optionally) changing the chipselect status, then starting | 306 | * (optionally) changing the chipselect status, then starting |
293 | * the next transfer or completing this spi_message. | 307 | * the next transfer or completing this @spi_message. |
294 | * @transfer_list: transfers are sequenced through spi_message.transfers | 308 | * @transfer_list: transfers are sequenced through @spi_message.transfers |
295 | * | 309 | * |
296 | * SPI transfers always write the same number of bytes as they read. | 310 | * SPI transfers always write the same number of bytes as they read. |
297 | * Protocol drivers should always provide rx_buf and/or tx_buf. | 311 | * Protocol drivers should always provide @rx_buf and/or @tx_buf. |
298 | * In some cases, they may also want to provide DMA addresses for | 312 | * In some cases, they may also want to provide DMA addresses for |
299 | * the data being transferred; that may reduce overhead, when the | 313 | * the data being transferred; that may reduce overhead, when the |
300 | * underlying driver uses dma. | 314 | * underlying driver uses dma. |
301 | * | 315 | * |
302 | * If the transmit buffer is null, zeroes will be shifted out | 316 | * If the transmit buffer is null, zeroes will be shifted out |
303 | * while filling rx_buf. If the receive buffer is null, the data | 317 | * while filling @rx_buf. If the receive buffer is null, the data |
304 | * shifted in will be discarded. Only "len" bytes shift out (or in). | 318 | * shifted in will be discarded. Only "len" bytes shift out (or in). |
305 | * It's an error to try to shift out a partial word. (For example, by | 319 | * It's an error to try to shift out a partial word. (For example, by |
306 | * shifting out three bytes with word size of sixteen or twenty bits; | 320 | * shifting out three bytes with word size of sixteen or twenty bits; |
@@ -309,7 +323,7 @@ extern struct spi_master *spi_busnum_to_master(u16 busnum); | |||
309 | * In-memory data values are always in native CPU byte order, translated | 323 | * In-memory data values are always in native CPU byte order, translated |
310 | * from the wire byte order (big-endian except with SPI_LSB_FIRST). So | 324 | * from the wire byte order (big-endian except with SPI_LSB_FIRST). So |
311 | * for example when bits_per_word is sixteen, buffers are 2N bytes long | 325 | * for example when bits_per_word is sixteen, buffers are 2N bytes long |
312 | * and hold N sixteen bit words in CPU byte order. | 326 | * (@len = 2N) and hold N sixteen bit words in CPU byte order. |
313 | * | 327 | * |
314 | * When the word size of the SPI transfer is not a power-of-two multiple | 328 | * When the word size of the SPI transfer is not a power-of-two multiple |
315 | * of eight bits, those in-memory words include extra bits. In-memory | 329 | * of eight bits, those in-memory words include extra bits. In-memory |
@@ -318,7 +332,7 @@ extern struct spi_master *spi_busnum_to_master(u16 busnum); | |||
318 | * | 332 | * |
319 | * All SPI transfers start with the relevant chipselect active. Normally | 333 | * All SPI transfers start with the relevant chipselect active. Normally |
320 | * it stays selected until after the last transfer in a message. Drivers | 334 | * it stays selected until after the last transfer in a message. Drivers |
321 | * can affect the chipselect signal using cs_change: | 335 | * can affect the chipselect signal using cs_change. |
322 | * | 336 | * |
323 | * (i) If the transfer isn't the last one in the message, this flag is | 337 | * (i) If the transfer isn't the last one in the message, this flag is |
324 | * used to make the chipselect briefly go inactive in the middle of the | 338 | * used to make the chipselect briefly go inactive in the middle of the |
@@ -372,7 +386,7 @@ struct spi_transfer { | |||
372 | * @queue: for use by whichever driver currently owns the message | 386 | * @queue: for use by whichever driver currently owns the message |
373 | * @state: for use by whichever driver currently owns the message | 387 | * @state: for use by whichever driver currently owns the message |
374 | * | 388 | * |
375 | * An spi_message is used to execute an atomic sequence of data transfers, | 389 | * A @spi_message is used to execute an atomic sequence of data transfers, |
376 | * each represented by a struct spi_transfer. The sequence is "atomic" | 390 | * each represented by a struct spi_transfer. The sequence is "atomic" |
377 | * in the sense that no other spi_message may use that SPI bus until that | 391 | * in the sense that no other spi_message may use that SPI bus until that |
378 | * sequence completes. On some systems, many such sequences can execute as | 392 | * sequence completes. On some systems, many such sequences can execute as |
@@ -464,8 +478,9 @@ static inline void spi_message_free(struct spi_message *m) | |||
464 | } | 478 | } |
465 | 479 | ||
466 | /** | 480 | /** |
467 | * spi_setup -- setup SPI mode and clock rate | 481 | * spi_setup - setup SPI mode and clock rate |
468 | * @spi: the device whose settings are being modified | 482 | * @spi: the device whose settings are being modified |
483 | * Context: can sleep | ||
469 | * | 484 | * |
470 | * SPI protocol drivers may need to update the transfer mode if the | 485 | * SPI protocol drivers may need to update the transfer mode if the |
471 | * device doesn't work with the mode 0 default. They may likewise need | 486 | * device doesn't work with the mode 0 default. They may likewise need |
@@ -474,7 +489,7 @@ static inline void spi_message_free(struct spi_message *m) | |||
474 | * The changes take effect the next time the device is selected and data | 489 | * The changes take effect the next time the device is selected and data |
475 | * is transferred to or from it. | 490 | * is transferred to or from it. |
476 | * | 491 | * |
477 | * Note that this call wil fail if the protocol driver specifies an option | 492 | * Note that this call will fail if the protocol driver specifies an option |
478 | * that the underlying controller or its driver does not support. For | 493 | * that the underlying controller or its driver does not support. For |
479 | * example, not all hardware supports wire transfers using nine bit words, | 494 | * example, not all hardware supports wire transfers using nine bit words, |
480 | * LSB-first wire encoding, or active-high chipselects. | 495 | * LSB-first wire encoding, or active-high chipselects. |
@@ -487,9 +502,10 @@ spi_setup(struct spi_device *spi) | |||
487 | 502 | ||
488 | 503 | ||
489 | /** | 504 | /** |
490 | * spi_async -- asynchronous SPI transfer | 505 | * spi_async - asynchronous SPI transfer |
491 | * @spi: device with which data will be exchanged | 506 | * @spi: device with which data will be exchanged |
492 | * @message: describes the data transfers, including completion callback | 507 | * @message: describes the data transfers, including completion callback |
508 | * Context: any (irqs may be blocked, etc) | ||
493 | * | 509 | * |
494 | * This call may be used in_irq and other contexts which can't sleep, | 510 | * This call may be used in_irq and other contexts which can't sleep, |
495 | * as well as from task contexts which can sleep. | 511 | * as well as from task contexts which can sleep. |
@@ -535,6 +551,7 @@ extern int spi_sync(struct spi_device *spi, struct spi_message *message); | |||
535 | * @spi: device to which data will be written | 551 | * @spi: device to which data will be written |
536 | * @buf: data buffer | 552 | * @buf: data buffer |
537 | * @len: data buffer size | 553 | * @len: data buffer size |
554 | * Context: can sleep | ||
538 | * | 555 | * |
539 | * This writes the buffer and returns zero or a negative error code. | 556 | * This writes the buffer and returns zero or a negative error code. |
540 | * Callable only from contexts that can sleep. | 557 | * Callable only from contexts that can sleep. |
@@ -558,8 +575,9 @@ spi_write(struct spi_device *spi, const u8 *buf, size_t len) | |||
558 | * @spi: device from which data will be read | 575 | * @spi: device from which data will be read |
559 | * @buf: data buffer | 576 | * @buf: data buffer |
560 | * @len: data buffer size | 577 | * @len: data buffer size |
578 | * Context: can sleep | ||
561 | * | 579 | * |
562 | * This writes the buffer and returns zero or a negative error code. | 580 | * This reads the buffer and returns zero or a negative error code. |
563 | * Callable only from contexts that can sleep. | 581 | * Callable only from contexts that can sleep. |
564 | */ | 582 | */ |
565 | static inline int | 583 | static inline int |
@@ -585,6 +603,7 @@ extern int spi_write_then_read(struct spi_device *spi, | |||
585 | * spi_w8r8 - SPI synchronous 8 bit write followed by 8 bit read | 603 | * spi_w8r8 - SPI synchronous 8 bit write followed by 8 bit read |
586 | * @spi: device with which data will be exchanged | 604 | * @spi: device with which data will be exchanged |
587 | * @cmd: command to be written before data is read back | 605 | * @cmd: command to be written before data is read back |
606 | * Context: can sleep | ||
588 | * | 607 | * |
589 | * This returns the (unsigned) eight bit number returned by the | 608 | * This returns the (unsigned) eight bit number returned by the |
590 | * device, or else a negative error code. Callable only from | 609 | * device, or else a negative error code. Callable only from |
@@ -605,6 +624,7 @@ static inline ssize_t spi_w8r8(struct spi_device *spi, u8 cmd) | |||
605 | * spi_w8r16 - SPI synchronous 8 bit write followed by 16 bit read | 624 | * spi_w8r16 - SPI synchronous 8 bit write followed by 16 bit read |
606 | * @spi: device with which data will be exchanged | 625 | * @spi: device with which data will be exchanged |
607 | * @cmd: command to be written before data is read back | 626 | * @cmd: command to be written before data is read back |
627 | * Context: can sleep | ||
608 | * | 628 | * |
609 | * This returns the (unsigned) sixteen bit number returned by the | 629 | * This returns the (unsigned) sixteen bit number returned by the |
610 | * device, or else a negative error code. Callable only from | 630 | * device, or else a negative error code. Callable only from |
diff --git a/include/linux/spi/spidev.h b/include/linux/spi/spidev.h new file mode 100644 index 000000000000..7d700be57490 --- /dev/null +++ b/include/linux/spi/spidev.h | |||
@@ -0,0 +1,124 @@ | |||
1 | /* | ||
2 | * include/linux/spi/spidev.h | ||
3 | * | ||
4 | * Copyright (C) 2006 SWAPP | ||
5 | * Andrea Paterniani <a.paterniani@swapp-eng.it> | ||
6 | * | ||
7 | * This program is free software; you can redistribute it and/or modify | ||
8 | * it under the terms of the GNU General Public License as published by | ||
9 | * the Free Software Foundation; either version 2 of the License, or | ||
10 | * (at your option) any later version. | ||
11 | * | ||
12 | * This program is distributed in the hope that it will be useful, | ||
13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
15 | * GNU General Public License for more details. | ||
16 | * | ||
17 | * You should have received a copy of the GNU General Public License | ||
18 | * along with this program; if not, write to the Free Software | ||
19 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | ||
20 | */ | ||
21 | |||
22 | #ifndef SPIDEV_H | ||
23 | #define SPIDEV_H | ||
24 | |||
25 | |||
26 | /* User space versions of kernel symbols for SPI clocking modes, | ||
27 | * matching <linux/spi/spi.h> | ||
28 | */ | ||
29 | |||
30 | #define SPI_CPHA 0x01 | ||
31 | #define SPI_CPOL 0x02 | ||
32 | |||
33 | #define SPI_MODE_0 (0|0) | ||
34 | #define SPI_MODE_1 (0|SPI_CPHA) | ||
35 | #define SPI_MODE_2 (SPI_CPOL|0) | ||
36 | #define SPI_MODE_3 (SPI_CPOL|SPI_CPHA) | ||
37 | |||
38 | |||
39 | /*---------------------------------------------------------------------------*/ | ||
40 | |||
41 | /* IOCTL commands */ | ||
42 | |||
43 | #define SPI_IOC_MAGIC 'k' | ||
44 | |||
45 | /** | ||
46 | * struct spi_ioc_transfer - describes a single SPI transfer | ||
47 | * @tx_buf: Holds pointer to userspace buffer with transmit data, or null. | ||
48 | * If no data is provided, zeroes are shifted out. | ||
49 | * @rx_buf: Holds pointer to userspace buffer for receive data, or null. | ||
50 | * @len: Length of tx and rx buffers, in bytes. | ||
51 | * @speed_hz: Temporary override of the device's bitrate. | ||
52 | * @bits_per_word: Temporary override of the device's wordsize. | ||
53 | * @delay_usecs: If nonzero, how long to delay after the last bit transfer | ||
54 | * before optionally deselecting the device before the next transfer. | ||
55 | * @cs_change: True to deselect device before starting the next transfer. | ||
56 | * | ||
57 | * This structure is mapped directly to the kernel spi_transfer structure; | ||
58 | * the fields have the same meanings, except of course that the pointers | ||
59 | * are in a different address space (and may be of different sizes in some | ||
60 | * cases, such as 32-bit i386 userspace over a 64-bit x86_64 kernel). | ||
61 | * Zero-initialize the structure, including currently unused fields, to | ||
62 | * accomodate potential future updates. | ||
63 | * | ||
64 | * SPI_IOC_MESSAGE gives userspace the equivalent of kernel spi_sync(). | ||
65 | * Pass it an array of related transfers, they'll execute together. | ||
66 | * Each transfer may be half duplex (either direction) or full duplex. | ||
67 | * | ||
68 | * struct spi_ioc_transfer mesg[4]; | ||
69 | * ... | ||
70 | * status = ioctl(fd, SPI_IOC_MESSAGE(4), mesg); | ||
71 | * | ||
72 | * So for example one transfer might send a nine bit command (right aligned | ||
73 | * in a 16-bit word), the next could read a block of 8-bit data before | ||
74 | * terminating that command by temporarily deselecting the chip; the next | ||
75 | * could send a different nine bit command (re-selecting the chip), and the | ||
76 | * last transfer might write some register values. | ||
77 | */ | ||
78 | struct spi_ioc_transfer { | ||
79 | __u64 tx_buf; | ||
80 | __u64 rx_buf; | ||
81 | |||
82 | __u32 len; | ||
83 | __u32 speed_hz; | ||
84 | |||
85 | __u16 delay_usecs; | ||
86 | __u8 bits_per_word; | ||
87 | __u8 cs_change; | ||
88 | __u32 pad; | ||
89 | |||
90 | /* If the contents of 'struct spi_ioc_transfer' ever change | ||
91 | * incompatibly, then the ioctl number (currently 0) must change; | ||
92 | * ioctls with constant size fields get a bit more in the way of | ||
93 | * error checking than ones (like this) where that field varies. | ||
94 | * | ||
95 | * NOTE: struct layout is the same in 64bit and 32bit userspace. | ||
96 | */ | ||
97 | }; | ||
98 | |||
99 | /* not all platforms use <asm-generic/ioctl.h> or _IOC_TYPECHECK() ... */ | ||
100 | #define SPI_MSGSIZE(N) \ | ||
101 | ((((N)*(sizeof (struct spi_ioc_transfer))) < (1 << _IOC_SIZEBITS)) \ | ||
102 | ? ((N)*(sizeof (struct spi_ioc_transfer))) : 0) | ||
103 | #define SPI_IOC_MESSAGE(N) _IOW(SPI_IOC_MAGIC, 0, char[SPI_MSGSIZE(N)]) | ||
104 | |||
105 | |||
106 | /* Read / Write of SPI mode (SPI_MODE_0..SPI_MODE_3) */ | ||
107 | #define SPI_IOC_RD_MODE _IOR(SPI_IOC_MAGIC, 1, __u8) | ||
108 | #define SPI_IOC_WR_MODE _IOW(SPI_IOC_MAGIC, 1, __u8) | ||
109 | |||
110 | /* Read / Write SPI bit justification */ | ||
111 | #define SPI_IOC_RD_LSB_FIRST _IOR(SPI_IOC_MAGIC, 2, __u8) | ||
112 | #define SPI_IOC_WR_LSB_FIRST _IOW(SPI_IOC_MAGIC, 2, __u8) | ||
113 | |||
114 | /* Read / Write SPI device word length (1..N) */ | ||
115 | #define SPI_IOC_RD_BITS_PER_WORD _IOR(SPI_IOC_MAGIC, 3, __u8) | ||
116 | #define SPI_IOC_WR_BITS_PER_WORD _IOW(SPI_IOC_MAGIC, 3, __u8) | ||
117 | |||
118 | /* Read / Write SPI device default max speed hz */ | ||
119 | #define SPI_IOC_RD_MAX_SPEED_HZ _IOR(SPI_IOC_MAGIC, 4, __u32) | ||
120 | #define SPI_IOC_WR_MAX_SPEED_HZ _IOW(SPI_IOC_MAGIC, 4, __u32) | ||
121 | |||
122 | |||
123 | |||
124 | #endif /* SPIDEV_H */ | ||
diff --git a/include/linux/spinlock_types.h b/include/linux/spinlock_types.h index dc5fb69e4de9..210549ba4ef4 100644 --- a/include/linux/spinlock_types.h +++ b/include/linux/spinlock_types.h | |||
@@ -85,6 +85,12 @@ typedef struct { | |||
85 | RW_DEP_MAP_INIT(lockname) } | 85 | RW_DEP_MAP_INIT(lockname) } |
86 | #endif | 86 | #endif |
87 | 87 | ||
88 | /* | ||
89 | * SPIN_LOCK_UNLOCKED and RW_LOCK_UNLOCKED defeat lockdep state tracking and | ||
90 | * are hence deprecated. | ||
91 | * Please use DEFINE_SPINLOCK()/DEFINE_RWLOCK() or | ||
92 | * __SPIN_LOCK_UNLOCKED()/__RW_LOCK_UNLOCKED() as appropriate. | ||
93 | */ | ||
88 | #define SPIN_LOCK_UNLOCKED __SPIN_LOCK_UNLOCKED(old_style_spin_init) | 94 | #define SPIN_LOCK_UNLOCKED __SPIN_LOCK_UNLOCKED(old_style_spin_init) |
89 | #define RW_LOCK_UNLOCKED __RW_LOCK_UNLOCKED(old_style_rw_init) | 95 | #define RW_LOCK_UNLOCKED __RW_LOCK_UNLOCKED(old_style_rw_init) |
90 | 96 | ||
diff --git a/include/linux/stacktrace.h b/include/linux/stacktrace.h index 50e2b01e517c..1d2b084c0185 100644 --- a/include/linux/stacktrace.h +++ b/include/linux/stacktrace.h | |||
@@ -6,15 +6,13 @@ struct stack_trace { | |||
6 | unsigned int nr_entries, max_entries; | 6 | unsigned int nr_entries, max_entries; |
7 | unsigned long *entries; | 7 | unsigned long *entries; |
8 | int skip; /* input argument: How many entries to skip */ | 8 | int skip; /* input argument: How many entries to skip */ |
9 | int all_contexts; /* input argument: if true do than one stack */ | ||
10 | }; | 9 | }; |
11 | 10 | ||
12 | extern void save_stack_trace(struct stack_trace *trace, | 11 | extern void save_stack_trace(struct stack_trace *trace); |
13 | struct task_struct *task); | ||
14 | 12 | ||
15 | extern void print_stack_trace(struct stack_trace *trace, int spaces); | 13 | extern void print_stack_trace(struct stack_trace *trace, int spaces); |
16 | #else | 14 | #else |
17 | # define save_stack_trace(trace, task) do { } while (0) | 15 | # define save_stack_trace(trace) do { } while (0) |
18 | # define print_stack_trace(trace) do { } while (0) | 16 | # define print_stack_trace(trace) do { } while (0) |
19 | #endif | 17 | #endif |
20 | 18 | ||
diff --git a/include/linux/stat.h b/include/linux/stat.h index 679ef0d70b6b..611c398dab72 100644 --- a/include/linux/stat.h +++ b/include/linux/stat.h | |||
@@ -53,6 +53,9 @@ | |||
53 | #define S_IWUGO (S_IWUSR|S_IWGRP|S_IWOTH) | 53 | #define S_IWUGO (S_IWUSR|S_IWGRP|S_IWOTH) |
54 | #define S_IXUGO (S_IXUSR|S_IXGRP|S_IXOTH) | 54 | #define S_IXUGO (S_IXUSR|S_IXGRP|S_IXOTH) |
55 | 55 | ||
56 | #define UTIME_NOW ((1l << 30) - 1l) | ||
57 | #define UTIME_OMIT ((1l << 30) - 2l) | ||
58 | |||
56 | #include <linux/types.h> | 59 | #include <linux/types.h> |
57 | #include <linux/time.h> | 60 | #include <linux/time.h> |
58 | 61 | ||
diff --git a/include/linux/svga.h b/include/linux/svga.h index eadb981bb37c..e1cc552e04fe 100644 --- a/include/linux/svga.h +++ b/include/linux/svga.h | |||
@@ -112,6 +112,7 @@ void svga_tilecopy(struct fb_info *info, struct fb_tilearea *area); | |||
112 | void svga_tilefill(struct fb_info *info, struct fb_tilerect *rect); | 112 | void svga_tilefill(struct fb_info *info, struct fb_tilerect *rect); |
113 | void svga_tileblit(struct fb_info *info, struct fb_tileblit *blit); | 113 | void svga_tileblit(struct fb_info *info, struct fb_tileblit *blit); |
114 | void svga_tilecursor(struct fb_info *info, struct fb_tilecursor *cursor); | 114 | void svga_tilecursor(struct fb_info *info, struct fb_tilecursor *cursor); |
115 | int svga_get_tilemax(struct fb_info *info); | ||
115 | 116 | ||
116 | int svga_compute_pll(const struct svga_pll *pll, u32 f_wanted, u16 *m, u16 *n, u16 *r, int node); | 117 | int svga_compute_pll(const struct svga_pll *pll, u32 f_wanted, u16 *m, u16 *n, u16 *r, int node); |
117 | int svga_check_timings(const struct svga_timing_regs *tm, struct fb_var_screeninfo *var, int node); | 118 | int svga_check_timings(const struct svga_timing_regs *tm, struct fb_var_screeninfo *var, int node); |
diff --git a/include/linux/sysdev.h b/include/linux/sysdev.h index 389ccf858d37..e699ab279c2c 100644 --- a/include/linux/sysdev.h +++ b/include/linux/sysdev.h | |||
@@ -22,6 +22,7 @@ | |||
22 | #define _SYSDEV_H_ | 22 | #define _SYSDEV_H_ |
23 | 23 | ||
24 | #include <linux/kobject.h> | 24 | #include <linux/kobject.h> |
25 | #include <linux/module.h> | ||
25 | #include <linux/pm.h> | 26 | #include <linux/pm.h> |
26 | 27 | ||
27 | 28 | ||
diff --git a/include/linux/time.h b/include/linux/time.h index 8ea8dea713c7..dda9be685ab6 100644 --- a/include/linux/time.h +++ b/include/linux/time.h | |||
@@ -109,7 +109,7 @@ extern void do_gettimeofday(struct timeval *tv); | |||
109 | extern int do_settimeofday(struct timespec *tv); | 109 | extern int do_settimeofday(struct timespec *tv); |
110 | extern int do_sys_settimeofday(struct timespec *tv, struct timezone *tz); | 110 | extern int do_sys_settimeofday(struct timespec *tv, struct timezone *tz); |
111 | #define do_posix_clock_monotonic_gettime(ts) ktime_get_ts(ts) | 111 | #define do_posix_clock_monotonic_gettime(ts) ktime_get_ts(ts) |
112 | extern long do_utimes(int dfd, char __user *filename, struct timeval *times); | 112 | extern long do_utimes(int dfd, char __user *filename, struct timespec *times, int flags); |
113 | struct itimerval; | 113 | struct itimerval; |
114 | extern int do_setitimer(int which, struct itimerval *value, | 114 | extern int do_setitimer(int which, struct itimerval *value, |
115 | struct itimerval *ovalue); | 115 | struct itimerval *ovalue); |
@@ -119,6 +119,7 @@ extern void getnstimeofday(struct timespec *tv); | |||
119 | 119 | ||
120 | extern struct timespec timespec_trunc(struct timespec t, unsigned gran); | 120 | extern struct timespec timespec_trunc(struct timespec t, unsigned gran); |
121 | extern int timekeeping_is_continuous(void); | 121 | extern int timekeeping_is_continuous(void); |
122 | extern void update_wall_time(void); | ||
122 | 123 | ||
123 | /** | 124 | /** |
124 | * timespec_to_ns - Convert timespec to nanoseconds | 125 | * timespec_to_ns - Convert timespec to nanoseconds |
diff --git a/include/linux/timer.h b/include/linux/timer.h index 719113b652dd..e0c5c16c992f 100644 --- a/include/linux/timer.h +++ b/include/linux/timer.h | |||
@@ -37,6 +37,7 @@ extern struct tvec_t_base_s boot_tvec_bases; | |||
37 | TIMER_INITIALIZER(_function, _expires, _data) | 37 | TIMER_INITIALIZER(_function, _expires, _data) |
38 | 38 | ||
39 | void fastcall init_timer(struct timer_list * timer); | 39 | void fastcall init_timer(struct timer_list * timer); |
40 | void fastcall init_timer_deferrable(struct timer_list *timer); | ||
40 | 41 | ||
41 | static inline void setup_timer(struct timer_list * timer, | 42 | static inline void setup_timer(struct timer_list * timer, |
42 | void (*function)(unsigned long), | 43 | void (*function)(unsigned long), |
diff --git a/include/linux/tty.h b/include/linux/tty.h index dee72b9a20fb..bb4576085203 100644 --- a/include/linux/tty.h +++ b/include/linux/tty.h | |||
@@ -313,6 +313,7 @@ extern int tty_hung_up_p(struct file * filp); | |||
313 | extern void do_SAK(struct tty_struct *tty); | 313 | extern void do_SAK(struct tty_struct *tty); |
314 | extern void __do_SAK(struct tty_struct *tty); | 314 | extern void __do_SAK(struct tty_struct *tty); |
315 | extern void disassociate_ctty(int priv); | 315 | extern void disassociate_ctty(int priv); |
316 | extern void no_tty(void); | ||
316 | extern void tty_flip_buffer_push(struct tty_struct *tty); | 317 | extern void tty_flip_buffer_push(struct tty_struct *tty); |
317 | extern speed_t tty_get_baud_rate(struct tty_struct *tty); | 318 | extern speed_t tty_get_baud_rate(struct tty_struct *tty); |
318 | extern speed_t tty_termios_baud_rate(struct ktermios *termios); | 319 | extern speed_t tty_termios_baud_rate(struct ktermios *termios); |
@@ -333,7 +334,6 @@ extern int tty_ioctl(struct inode *inode, struct file *file, unsigned int cmd, | |||
333 | 334 | ||
334 | extern dev_t tty_devnum(struct tty_struct *tty); | 335 | extern dev_t tty_devnum(struct tty_struct *tty); |
335 | extern void proc_clear_tty(struct task_struct *p); | 336 | extern void proc_clear_tty(struct task_struct *p); |
336 | extern void proc_set_tty(struct task_struct *tsk, struct tty_struct *tty); | ||
337 | extern struct tty_struct *get_current_tty(void); | 337 | extern struct tty_struct *get_current_tty(void); |
338 | 338 | ||
339 | extern struct mutex tty_mutex; | 339 | extern struct mutex tty_mutex; |
diff --git a/include/linux/utsname.h b/include/linux/utsname.h index e10267d402c5..f8d3b326e93a 100644 --- a/include/linux/utsname.h +++ b/include/linux/utsname.h | |||
@@ -49,9 +49,7 @@ static inline void get_uts_ns(struct uts_namespace *ns) | |||
49 | } | 49 | } |
50 | 50 | ||
51 | #ifdef CONFIG_UTS_NS | 51 | #ifdef CONFIG_UTS_NS |
52 | extern int unshare_utsname(unsigned long unshare_flags, | 52 | extern struct uts_namespace *copy_utsname(int flags, struct uts_namespace *ns); |
53 | struct uts_namespace **new_uts); | ||
54 | extern int copy_utsname(int flags, struct task_struct *tsk); | ||
55 | extern void free_uts_ns(struct kref *kref); | 53 | extern void free_uts_ns(struct kref *kref); |
56 | 54 | ||
57 | static inline void put_uts_ns(struct uts_namespace *ns) | 55 | static inline void put_uts_ns(struct uts_namespace *ns) |
@@ -59,21 +57,12 @@ static inline void put_uts_ns(struct uts_namespace *ns) | |||
59 | kref_put(&ns->kref, free_uts_ns); | 57 | kref_put(&ns->kref, free_uts_ns); |
60 | } | 58 | } |
61 | #else | 59 | #else |
62 | static inline int unshare_utsname(unsigned long unshare_flags, | 60 | static inline struct uts_namespace *copy_utsname(int flags, |
63 | struct uts_namespace **new_uts) | 61 | struct uts_namespace *ns) |
64 | { | 62 | { |
65 | if (unshare_flags & CLONE_NEWUTS) | 63 | return ns; |
66 | return -EINVAL; | ||
67 | |||
68 | return 0; | ||
69 | } | 64 | } |
70 | 65 | ||
71 | static inline int copy_utsname(int flags, struct task_struct *tsk) | ||
72 | { | ||
73 | if (flags & CLONE_NEWUTS) | ||
74 | return -EINVAL; | ||
75 | return 0; | ||
76 | } | ||
77 | static inline void put_uts_ns(struct uts_namespace *ns) | 66 | static inline void put_uts_ns(struct uts_namespace *ns) |
78 | { | 67 | { |
79 | } | 68 | } |
diff --git a/include/linux/vmalloc.h b/include/linux/vmalloc.h index 924e502905d4..4b7ee83787c1 100644 --- a/include/linux/vmalloc.h +++ b/include/linux/vmalloc.h | |||
@@ -53,6 +53,7 @@ extern void vunmap(void *addr); | |||
53 | 53 | ||
54 | extern int remap_vmalloc_range(struct vm_area_struct *vma, void *addr, | 54 | extern int remap_vmalloc_range(struct vm_area_struct *vma, void *addr, |
55 | unsigned long pgoff); | 55 | unsigned long pgoff); |
56 | void vmalloc_sync_all(void); | ||
56 | 57 | ||
57 | /* | 58 | /* |
58 | * Lowlevel-APIs (not for driver use!) | 59 | * Lowlevel-APIs (not for driver use!) |
diff --git a/include/linux/vt_kern.h b/include/linux/vt_kern.h index e0db669998f3..d961635d0e61 100644 --- a/include/linux/vt_kern.h +++ b/include/linux/vt_kern.h | |||
@@ -9,6 +9,7 @@ | |||
9 | #include <linux/vt.h> | 9 | #include <linux/vt.h> |
10 | #include <linux/kd.h> | 10 | #include <linux/kd.h> |
11 | #include <linux/tty.h> | 11 | #include <linux/tty.h> |
12 | #include <linux/mutex.h> | ||
12 | #include <linux/console_struct.h> | 13 | #include <linux/console_struct.h> |
13 | #include <linux/mm.h> | 14 | #include <linux/mm.h> |
14 | 15 | ||
@@ -82,7 +83,7 @@ void reset_vc(struct vc_data *vc); | |||
82 | 83 | ||
83 | #define CON_BUF_SIZE (CONFIG_BASE_SMALL ? 256 : PAGE_SIZE) | 84 | #define CON_BUF_SIZE (CONFIG_BASE_SMALL ? 256 : PAGE_SIZE) |
84 | extern char con_buf[CON_BUF_SIZE]; | 85 | extern char con_buf[CON_BUF_SIZE]; |
85 | extern struct semaphore con_buf_sem; | 86 | extern struct mutex con_buf_mtx; |
86 | extern char vt_dont_switch; | 87 | extern char vt_dont_switch; |
87 | 88 | ||
88 | struct vt_spawn_console { | 89 | struct vt_spawn_console { |
diff --git a/include/linux/workqueue.h b/include/linux/workqueue.h index b8abfc74d038..f16ba1e0687d 100644 --- a/include/linux/workqueue.h +++ b/include/linux/workqueue.h | |||
@@ -121,6 +121,12 @@ struct execute_work { | |||
121 | init_timer(&(_work)->timer); \ | 121 | init_timer(&(_work)->timer); \ |
122 | } while (0) | 122 | } while (0) |
123 | 123 | ||
124 | #define INIT_DELAYED_WORK_DEFERRABLE(_work, _func) \ | ||
125 | do { \ | ||
126 | INIT_WORK(&(_work)->work, (_func)); \ | ||
127 | init_timer_deferrable(&(_work)->timer); \ | ||
128 | } while (0) | ||
129 | |||
124 | /** | 130 | /** |
125 | * work_pending - Find out whether a work item is currently pending | 131 | * work_pending - Find out whether a work item is currently pending |
126 | * @work: The work item in question | 132 | * @work: The work item in question |