aboutsummaryrefslogtreecommitdiffstats
path: root/sound/core/memalloc.c
diff options
context:
space:
mode:
authorYacine Belkadi <yacine.belkadi.1@gmail.com>2013-03-11 17:05:14 -0400
committerTakashi Iwai <tiwai@suse.de>2013-03-12 03:32:53 -0400
commiteb7c06e8e9c93b495e355421cffd3c43c266d7d2 (patch)
treef53aa110b92ff941f5d2d84d6ee38b1a45b3e005 /sound/core/memalloc.c
parenta817650ebb451ef27db2baa7e10d0c28609bed13 (diff)
ALSA: add/change some comments describing function return values
script/kernel-doc reports the following type of warnings (when run in verbose mode): Warning(sound/core/init.c:152): No description found for return value of 'snd_card_create' To fix that: - add missing descriptions of function return values - use "Return:" sections to describe those return values Along the way: - complete some descriptions - fix some typos Signed-off-by: Yacine Belkadi <yacine.belkadi.1@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/core/memalloc.c')
-rw-r--r--sound/core/memalloc.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/sound/core/memalloc.c b/sound/core/memalloc.c
index 691569238435..bdf826f4fe0c 100644
--- a/sound/core/memalloc.c
+++ b/sound/core/memalloc.c
@@ -81,7 +81,7 @@ static inline void dec_snd_pages(int order)
81 * 81 *
82 * Allocates the physically contiguous pages with the given size. 82 * Allocates the physically contiguous pages with the given size.
83 * 83 *
84 * Returns the pointer of the buffer, or NULL if no enoguh memory. 84 * Return: The pointer of the buffer, or %NULL if no enough memory.
85 */ 85 */
86void *snd_malloc_pages(size_t size, gfp_t gfp_flags) 86void *snd_malloc_pages(size_t size, gfp_t gfp_flags)
87{ 87{
@@ -175,9 +175,9 @@ static void snd_free_dev_pages(struct device *dev, size_t size, void *ptr,
175 * 175 *
176 * Calls the memory-allocator function for the corresponding 176 * Calls the memory-allocator function for the corresponding
177 * buffer type. 177 * buffer type.
178 * 178 *
179 * Returns zero if the buffer with the given size is allocated successfully, 179 * Return: Zero if the buffer with the given size is allocated successfully,
180 * other a negative value at error. 180 * otherwise a negative value on error.
181 */ 181 */
182int snd_dma_alloc_pages(int type, struct device *device, size_t size, 182int snd_dma_alloc_pages(int type, struct device *device, size_t size,
183 struct snd_dma_buffer *dmab) 183 struct snd_dma_buffer *dmab)
@@ -229,9 +229,9 @@ int snd_dma_alloc_pages(int type, struct device *device, size_t size,
229 * buffer type. When no space is left, this function reduces the size and 229 * buffer type. When no space is left, this function reduces the size and
230 * tries to allocate again. The size actually allocated is stored in 230 * tries to allocate again. The size actually allocated is stored in
231 * res_size argument. 231 * res_size argument.
232 * 232 *
233 * Returns zero if the buffer with the given size is allocated successfully, 233 * Return: Zero if the buffer with the given size is allocated successfully,
234 * other a negative value at error. 234 * otherwise a negative value on error.
235 */ 235 */
236int snd_dma_alloc_pages_fallback(int type, struct device *device, size_t size, 236int snd_dma_alloc_pages_fallback(int type, struct device *device, size_t size,
237 struct snd_dma_buffer *dmab) 237 struct snd_dma_buffer *dmab)
@@ -292,7 +292,7 @@ void snd_dma_free_pages(struct snd_dma_buffer *dmab)
292 * Looks for the reserved-buffer list and re-uses if the same buffer 292 * Looks for the reserved-buffer list and re-uses if the same buffer
293 * is found in the list. When the buffer is found, it's removed from the free list. 293 * is found in the list. When the buffer is found, it's removed from the free list.
294 * 294 *
295 * Returns the size of buffer if the buffer is found, or zero if not found. 295 * Return: The size of buffer if the buffer is found, or zero if not found.
296 */ 296 */
297size_t snd_dma_get_reserved_buf(struct snd_dma_buffer *dmab, unsigned int id) 297size_t snd_dma_get_reserved_buf(struct snd_dma_buffer *dmab, unsigned int id)
298{ 298{
@@ -326,8 +326,8 @@ size_t snd_dma_get_reserved_buf(struct snd_dma_buffer *dmab, unsigned int id)
326 * @id: the buffer id 326 * @id: the buffer id
327 * 327 *
328 * Reserves the given buffer as a reserved buffer. 328 * Reserves the given buffer as a reserved buffer.
329 * 329 *
330 * Returns zero if successful, or a negative code at error. 330 * Return: Zero if successful, or a negative code on error.
331 */ 331 */
332int snd_dma_reserve_buf(struct snd_dma_buffer *dmab, unsigned int id) 332int snd_dma_reserve_buf(struct snd_dma_buffer *dmab, unsigned int id)
333{ 333{