diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2005-10-21 03:22:18 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-10-28 11:16:50 -0400 |
commit | 1ef64e670e3bc27e0c3c83810ca36e19924c35c6 (patch) | |
tree | b024df98dcbe0bc28c967559da27a14254698887 | |
parent | 87b750dc4b7109aa744e7d331dc93df3fe5c1c28 (diff) |
[PATCH] gfp_t: sound
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-rw-r--r-- | arch/ppc/8xx_io/cs4218.h | 2 | ||||
-rw-r--r-- | arch/ppc/8xx_io/cs4218_tdm.c | 4 | ||||
-rw-r--r-- | include/sound/memalloc.h | 2 | ||||
-rw-r--r-- | sound/core/memalloc.c | 4 | ||||
-rw-r--r-- | sound/core/seq/instr/ainstr_gf1.c | 5 | ||||
-rw-r--r-- | sound/core/seq/instr/ainstr_iw.c | 4 | ||||
-rw-r--r-- | sound/core/seq/instr/ainstr_simple.c | 3 | ||||
-rw-r--r-- | sound/oss/dmasound/dmasound.h | 2 | ||||
-rw-r--r-- | sound/oss/dmasound/dmasound_atari.c | 4 | ||||
-rw-r--r-- | sound/oss/dmasound/dmasound_awacs.c | 4 | ||||
-rw-r--r-- | sound/oss/dmasound/dmasound_paula.c | 4 | ||||
-rw-r--r-- | sound/oss/dmasound/dmasound_q40.c | 4 |
12 files changed, 22 insertions, 20 deletions
diff --git a/arch/ppc/8xx_io/cs4218.h b/arch/ppc/8xx_io/cs4218.h index a3c38c5a5db2..f1c7392255f8 100644 --- a/arch/ppc/8xx_io/cs4218.h +++ b/arch/ppc/8xx_io/cs4218.h | |||
@@ -78,7 +78,7 @@ typedef struct { | |||
78 | const char *name2; | 78 | const char *name2; |
79 | void (*open)(void); | 79 | void (*open)(void); |
80 | void (*release)(void); | 80 | void (*release)(void); |
81 | void *(*dma_alloc)(unsigned int, int); | 81 | void *(*dma_alloc)(unsigned int, gfp_t); |
82 | void (*dma_free)(void *, unsigned int); | 82 | void (*dma_free)(void *, unsigned int); |
83 | int (*irqinit)(void); | 83 | int (*irqinit)(void); |
84 | #ifdef MODULE | 84 | #ifdef MODULE |
diff --git a/arch/ppc/8xx_io/cs4218_tdm.c b/arch/ppc/8xx_io/cs4218_tdm.c index 2ca9ec7ec3a7..532caa388dc2 100644 --- a/arch/ppc/8xx_io/cs4218_tdm.c +++ b/arch/ppc/8xx_io/cs4218_tdm.c | |||
@@ -318,7 +318,7 @@ struct cs_sound_settings { | |||
318 | 318 | ||
319 | static struct cs_sound_settings sound; | 319 | static struct cs_sound_settings sound; |
320 | 320 | ||
321 | static void *CS_Alloc(unsigned int size, int flags); | 321 | static void *CS_Alloc(unsigned int size, gfp_t flags); |
322 | static void CS_Free(void *ptr, unsigned int size); | 322 | static void CS_Free(void *ptr, unsigned int size); |
323 | static int CS_IrqInit(void); | 323 | static int CS_IrqInit(void); |
324 | #ifdef MODULE | 324 | #ifdef MODULE |
@@ -959,7 +959,7 @@ static TRANS transCSNormalRead = { | |||
959 | 959 | ||
960 | /*** Low level stuff *********************************************************/ | 960 | /*** Low level stuff *********************************************************/ |
961 | 961 | ||
962 | static void *CS_Alloc(unsigned int size, int flags) | 962 | static void *CS_Alloc(unsigned int size, gfp_t flags) |
963 | { | 963 | { |
964 | int order; | 964 | int order; |
965 | 965 | ||
diff --git a/include/sound/memalloc.h b/include/sound/memalloc.h index 3a2fd2cc9f19..83489c3abbaf 100644 --- a/include/sound/memalloc.h +++ b/include/sound/memalloc.h | |||
@@ -111,7 +111,7 @@ size_t snd_dma_get_reserved_buf(struct snd_dma_buffer *dmab, unsigned int id); | |||
111 | int snd_dma_reserve_buf(struct snd_dma_buffer *dmab, unsigned int id); | 111 | int snd_dma_reserve_buf(struct snd_dma_buffer *dmab, unsigned int id); |
112 | 112 | ||
113 | /* basic memory allocation functions */ | 113 | /* basic memory allocation functions */ |
114 | void *snd_malloc_pages(size_t size, unsigned int gfp_flags); | 114 | void *snd_malloc_pages(size_t size, gfp_t gfp_flags); |
115 | void snd_free_pages(void *ptr, size_t size); | 115 | void snd_free_pages(void *ptr, size_t size); |
116 | 116 | ||
117 | #endif /* __SOUND_MEMALLOC_H */ | 117 | #endif /* __SOUND_MEMALLOC_H */ |
diff --git a/sound/core/memalloc.c b/sound/core/memalloc.c index e72cec77f0db..129abab5ce98 100644 --- a/sound/core/memalloc.c +++ b/sound/core/memalloc.c | |||
@@ -190,7 +190,7 @@ static void unmark_pages(struct page *page, int order) | |||
190 | * | 190 | * |
191 | * Returns the pointer of the buffer, or NULL if no enoguh memory. | 191 | * Returns the pointer of the buffer, or NULL if no enoguh memory. |
192 | */ | 192 | */ |
193 | void *snd_malloc_pages(size_t size, unsigned int gfp_flags) | 193 | void *snd_malloc_pages(size_t size, gfp_t gfp_flags) |
194 | { | 194 | { |
195 | int pg; | 195 | int pg; |
196 | void *res; | 196 | void *res; |
@@ -235,7 +235,7 @@ static void *snd_malloc_dev_pages(struct device *dev, size_t size, dma_addr_t *d | |||
235 | { | 235 | { |
236 | int pg; | 236 | int pg; |
237 | void *res; | 237 | void *res; |
238 | unsigned int gfp_flags; | 238 | gfp_t gfp_flags; |
239 | 239 | ||
240 | snd_assert(size > 0, return NULL); | 240 | snd_assert(size > 0, return NULL); |
241 | snd_assert(dma != NULL, return NULL); | 241 | snd_assert(dma != NULL, return NULL); |
diff --git a/sound/core/seq/instr/ainstr_gf1.c b/sound/core/seq/instr/ainstr_gf1.c index 207c2c54bf1d..0e4df8826eed 100644 --- a/sound/core/seq/instr/ainstr_gf1.c +++ b/sound/core/seq/instr/ainstr_gf1.c | |||
@@ -51,7 +51,7 @@ static int snd_seq_gf1_copy_wave_from_stream(snd_gf1_ops_t *ops, | |||
51 | gf1_wave_t *wp, *prev; | 51 | gf1_wave_t *wp, *prev; |
52 | gf1_xwave_t xp; | 52 | gf1_xwave_t xp; |
53 | int err; | 53 | int err; |
54 | unsigned int gfp_mask; | 54 | gfp_t gfp_mask; |
55 | unsigned int real_size; | 55 | unsigned int real_size; |
56 | 56 | ||
57 | gfp_mask = atomic ? GFP_ATOMIC : GFP_KERNEL; | 57 | gfp_mask = atomic ? GFP_ATOMIC : GFP_KERNEL; |
@@ -144,7 +144,8 @@ static int snd_seq_gf1_put(void *private_data, snd_seq_kinstr_t *instr, | |||
144 | snd_gf1_ops_t *ops = (snd_gf1_ops_t *)private_data; | 144 | snd_gf1_ops_t *ops = (snd_gf1_ops_t *)private_data; |
145 | gf1_instrument_t *ip; | 145 | gf1_instrument_t *ip; |
146 | gf1_xinstrument_t ix; | 146 | gf1_xinstrument_t ix; |
147 | int err, gfp_mask; | 147 | int err; |
148 | gfp_t gfp_mask; | ||
148 | 149 | ||
149 | if (cmd != SNDRV_SEQ_INSTR_PUT_CMD_CREATE) | 150 | if (cmd != SNDRV_SEQ_INSTR_PUT_CMD_CREATE) |
150 | return -EINVAL; | 151 | return -EINVAL; |
diff --git a/sound/core/seq/instr/ainstr_iw.c b/sound/core/seq/instr/ainstr_iw.c index 67c24c8e8e7b..7c19fbbc5d0f 100644 --- a/sound/core/seq/instr/ainstr_iw.c +++ b/sound/core/seq/instr/ainstr_iw.c | |||
@@ -129,7 +129,7 @@ static int snd_seq_iwffff_copy_wave_from_stream(snd_iwffff_ops_t *ops, | |||
129 | iwffff_wave_t *wp, *prev; | 129 | iwffff_wave_t *wp, *prev; |
130 | iwffff_xwave_t xp; | 130 | iwffff_xwave_t xp; |
131 | int err; | 131 | int err; |
132 | unsigned int gfp_mask; | 132 | gfp_t gfp_mask; |
133 | unsigned int real_size; | 133 | unsigned int real_size; |
134 | 134 | ||
135 | gfp_mask = atomic ? GFP_ATOMIC : GFP_KERNEL; | 135 | gfp_mask = atomic ? GFP_ATOMIC : GFP_KERNEL; |
@@ -236,7 +236,7 @@ static int snd_seq_iwffff_put(void *private_data, snd_seq_kinstr_t *instr, | |||
236 | iwffff_layer_t *lp, *prev_lp; | 236 | iwffff_layer_t *lp, *prev_lp; |
237 | iwffff_xlayer_t lx; | 237 | iwffff_xlayer_t lx; |
238 | int err; | 238 | int err; |
239 | unsigned int gfp_mask; | 239 | gfp_t gfp_mask; |
240 | 240 | ||
241 | if (cmd != SNDRV_SEQ_INSTR_PUT_CMD_CREATE) | 241 | if (cmd != SNDRV_SEQ_INSTR_PUT_CMD_CREATE) |
242 | return -EINVAL; | 242 | return -EINVAL; |
diff --git a/sound/core/seq/instr/ainstr_simple.c b/sound/core/seq/instr/ainstr_simple.c index 6183d2151034..17ab94e76073 100644 --- a/sound/core/seq/instr/ainstr_simple.c +++ b/sound/core/seq/instr/ainstr_simple.c | |||
@@ -57,7 +57,8 @@ static int snd_seq_simple_put(void *private_data, snd_seq_kinstr_t *instr, | |||
57 | snd_simple_ops_t *ops = (snd_simple_ops_t *)private_data; | 57 | snd_simple_ops_t *ops = (snd_simple_ops_t *)private_data; |
58 | simple_instrument_t *ip; | 58 | simple_instrument_t *ip; |
59 | simple_xinstrument_t ix; | 59 | simple_xinstrument_t ix; |
60 | int err, gfp_mask; | 60 | int err; |
61 | gfp_t gfp_mask; | ||
61 | unsigned int real_size; | 62 | unsigned int real_size; |
62 | 63 | ||
63 | if (cmd != SNDRV_SEQ_INSTR_PUT_CMD_CREATE) | 64 | if (cmd != SNDRV_SEQ_INSTR_PUT_CMD_CREATE) |
diff --git a/sound/oss/dmasound/dmasound.h b/sound/oss/dmasound/dmasound.h index 9a2f50f0b184..222014cafc1a 100644 --- a/sound/oss/dmasound/dmasound.h +++ b/sound/oss/dmasound/dmasound.h | |||
@@ -116,7 +116,7 @@ typedef struct { | |||
116 | const char *name; | 116 | const char *name; |
117 | const char *name2; | 117 | const char *name2; |
118 | struct module *owner; | 118 | struct module *owner; |
119 | void *(*dma_alloc)(unsigned int, int); | 119 | void *(*dma_alloc)(unsigned int, gfp_t); |
120 | void (*dma_free)(void *, unsigned int); | 120 | void (*dma_free)(void *, unsigned int); |
121 | int (*irqinit)(void); | 121 | int (*irqinit)(void); |
122 | #ifdef MODULE | 122 | #ifdef MODULE |
diff --git a/sound/oss/dmasound/dmasound_atari.c b/sound/oss/dmasound/dmasound_atari.c index 8daaf87664ba..59eb53f89318 100644 --- a/sound/oss/dmasound/dmasound_atari.c +++ b/sound/oss/dmasound/dmasound_atari.c | |||
@@ -114,7 +114,7 @@ static ssize_t ata_ctx_u16le(const u_char *userPtr, size_t userCount, | |||
114 | /*** Low level stuff *********************************************************/ | 114 | /*** Low level stuff *********************************************************/ |
115 | 115 | ||
116 | 116 | ||
117 | static void *AtaAlloc(unsigned int size, int flags); | 117 | static void *AtaAlloc(unsigned int size, gfp_t flags); |
118 | static void AtaFree(void *, unsigned int size); | 118 | static void AtaFree(void *, unsigned int size); |
119 | static int AtaIrqInit(void); | 119 | static int AtaIrqInit(void); |
120 | #ifdef MODULE | 120 | #ifdef MODULE |
@@ -810,7 +810,7 @@ static TRANS transFalconExpanding = { | |||
810 | * Atari (TT/Falcon) | 810 | * Atari (TT/Falcon) |
811 | */ | 811 | */ |
812 | 812 | ||
813 | static void *AtaAlloc(unsigned int size, int flags) | 813 | static void *AtaAlloc(unsigned int size, gfp_t flags) |
814 | { | 814 | { |
815 | return atari_stram_alloc(size, "dmasound"); | 815 | return atari_stram_alloc(size, "dmasound"); |
816 | } | 816 | } |
diff --git a/sound/oss/dmasound/dmasound_awacs.c b/sound/oss/dmasound/dmasound_awacs.c index 2ceb46f1d40f..b2bf8bac842d 100644 --- a/sound/oss/dmasound/dmasound_awacs.c +++ b/sound/oss/dmasound/dmasound_awacs.c | |||
@@ -271,7 +271,7 @@ int expand_read_bal; /* Balance factor for expanding reads (not volume!) */ | |||
271 | 271 | ||
272 | /*** Low level stuff *********************************************************/ | 272 | /*** Low level stuff *********************************************************/ |
273 | 273 | ||
274 | static void *PMacAlloc(unsigned int size, int flags); | 274 | static void *PMacAlloc(unsigned int size, gfp_t flags); |
275 | static void PMacFree(void *ptr, unsigned int size); | 275 | static void PMacFree(void *ptr, unsigned int size); |
276 | static int PMacIrqInit(void); | 276 | static int PMacIrqInit(void); |
277 | #ifdef MODULE | 277 | #ifdef MODULE |
@@ -614,7 +614,7 @@ tas_init_frame_rates(unsigned int *prop, unsigned int l) | |||
614 | /* | 614 | /* |
615 | * PCI PowerMac, with AWACS, Screamer, Burgundy, DACA or Tumbler and DBDMA. | 615 | * PCI PowerMac, with AWACS, Screamer, Burgundy, DACA or Tumbler and DBDMA. |
616 | */ | 616 | */ |
617 | static void *PMacAlloc(unsigned int size, int flags) | 617 | static void *PMacAlloc(unsigned int size, gfp_t flags) |
618 | { | 618 | { |
619 | return kmalloc(size, flags); | 619 | return kmalloc(size, flags); |
620 | } | 620 | } |
diff --git a/sound/oss/dmasound/dmasound_paula.c b/sound/oss/dmasound/dmasound_paula.c index 558db5311e06..d59f60b26410 100644 --- a/sound/oss/dmasound/dmasound_paula.c +++ b/sound/oss/dmasound/dmasound_paula.c | |||
@@ -69,7 +69,7 @@ static int write_sq_block_size_half, write_sq_block_size_quarter; | |||
69 | /*** Low level stuff *********************************************************/ | 69 | /*** Low level stuff *********************************************************/ |
70 | 70 | ||
71 | 71 | ||
72 | static void *AmiAlloc(unsigned int size, int flags); | 72 | static void *AmiAlloc(unsigned int size, gfp_t flags); |
73 | static void AmiFree(void *obj, unsigned int size); | 73 | static void AmiFree(void *obj, unsigned int size); |
74 | static int AmiIrqInit(void); | 74 | static int AmiIrqInit(void); |
75 | #ifdef MODULE | 75 | #ifdef MODULE |
@@ -317,7 +317,7 @@ static inline void StopDMA(void) | |||
317 | enable_heartbeat(); | 317 | enable_heartbeat(); |
318 | } | 318 | } |
319 | 319 | ||
320 | static void *AmiAlloc(unsigned int size, int flags) | 320 | static void *AmiAlloc(unsigned int size, gfp_t flags) |
321 | { | 321 | { |
322 | return amiga_chip_alloc((long)size, "dmasound [Paula]"); | 322 | return amiga_chip_alloc((long)size, "dmasound [Paula]"); |
323 | } | 323 | } |
diff --git a/sound/oss/dmasound/dmasound_q40.c b/sound/oss/dmasound/dmasound_q40.c index 92c25a0174db..1ddaa6284b08 100644 --- a/sound/oss/dmasound/dmasound_q40.c +++ b/sound/oss/dmasound/dmasound_q40.c | |||
@@ -36,7 +36,7 @@ static int expand_data; /* Data for expanding */ | |||
36 | /*** Low level stuff *********************************************************/ | 36 | /*** Low level stuff *********************************************************/ |
37 | 37 | ||
38 | 38 | ||
39 | static void *Q40Alloc(unsigned int size, int flags); | 39 | static void *Q40Alloc(unsigned int size, gfp_t flags); |
40 | static void Q40Free(void *, unsigned int); | 40 | static void Q40Free(void *, unsigned int); |
41 | static int Q40IrqInit(void); | 41 | static int Q40IrqInit(void); |
42 | #ifdef MODULE | 42 | #ifdef MODULE |
@@ -358,7 +358,7 @@ static TRANS transQ40Compressing = { | |||
358 | 358 | ||
359 | /*** Low level stuff *********************************************************/ | 359 | /*** Low level stuff *********************************************************/ |
360 | 360 | ||
361 | static void *Q40Alloc(unsigned int size, int flags) | 361 | static void *Q40Alloc(unsigned int size, gfp_t flags) |
362 | { | 362 | { |
363 | return kmalloc(size, flags); /* change to vmalloc */ | 363 | return kmalloc(size, flags); /* change to vmalloc */ |
364 | } | 364 | } |