Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

staging: android: Fix checkpatch block comments warnings

This patch is intended to fix the checkpatch warning for ``block``
comments for staging/android driver.

Signed-off-by: Sriram Raghunathan <sriram@marirs.net.in>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Sriram Raghunathan and committed by
Greg Kroah-Hartman
7e416174 56b4c049

+52 -32
-1
drivers/staging/android/ion/compat_ion.h
··· 1 1 /* 2 - 3 2 * drivers/staging/android/ion/compat_ion.h 4 3 * 5 4 * Copyright (C) 2013 Google, Inc.
+19 -13
drivers/staging/android/ion/ion.c
··· 1 1 /* 2 - 2 + * 3 3 * drivers/staging/android/ion/ion.c 4 4 * 5 5 * Copyright (C) 2011 Google, Inc. ··· 244 244 buffer->size = len; 245 245 INIT_LIST_HEAD(&buffer->vmas); 246 246 mutex_init(&buffer->lock); 247 - /* this will set up dma addresses for the sglist -- it is not 248 - technically correct as per the dma api -- a specific 249 - device isn't really taking ownership here. However, in practice on 250 - our systems the only dma_address space is physical addresses. 251 - Additionally, we can't afford the overhead of invalidating every 252 - allocation via dma_map_sg. The implicit contract here is that 253 - memory coming from the heaps is ready for dma, ie if it has a 254 - cached mapping that mapping has been invalidated */ 247 + /* 248 + * this will set up dma addresses for the sglist -- it is not 249 + * technically correct as per the dma api -- a specific 250 + * device isn't really taking ownership here. However, in practice on 251 + * our systems the only dma_address space is physical addresses. 252 + * Additionally, we can't afford the overhead of invalidating every 253 + * allocation via dma_map_sg. The implicit contract here is that 254 + * memory coming from the heaps is ready for dma, ie if it has a 255 + * cached mapping that mapping has been invalidated 256 + */ 255 257 for_each_sg(buffer->sg_table->sgl, sg, buffer->sg_table->nents, i) 256 258 sg_dma_address(sg) = sg_phys(sg); 257 259 mutex_lock(&dev->buffer_lock); ··· 755 753 get_task_struct(current->group_leader); 756 754 task_lock(current->group_leader); 757 755 pid = task_pid_nr(current->group_leader); 758 - /* don't bother to store task struct for kernel threads, 759 - they can't be killed anyway */ 756 + /* 757 + * don't bother to store task struct for kernel threads, 758 + * they can't be killed anyway 759 + */ 760 760 if (current->group_leader->flags & PF_KTHREAD) { 761 761 put_task_struct(current->group_leader); 762 762 task = NULL; ··· 1525 1521 1526 1522 heap->dev = dev; 1527 1523 down_write(&dev->lock); 1528 - /* use negative heap->id to reverse the priority -- when traversing 1529 - the list later attempt higher id numbers first */ 1524 + /* 1525 + * use negative heap->id to reverse the priority -- when traversing 1526 + * the list later attempt higher id numbers first 1527 + */ 1530 1528 plist_node_init(&heap->node, -heap->id); 1531 1529 plist_add(&heap->node, &dev->heaps); 1532 1530 debug_file = debugfs_create_file(heap->name, 0664,
+6 -4
drivers/staging/android/ion/ion.h
··· 28 28 struct ion_client; 29 29 struct ion_buffer; 30 30 31 - /* This should be removed some day when phys_addr_t's are fully 32 - plumbed in the kernel, and all instances of ion_phys_addr_t should 33 - be converted to phys_addr_t. For the time being many kernel interfaces 34 - do not accept phys_addr_t's that would have to */ 31 + /* 32 + * This should be removed some day when phys_addr_t's are fully 33 + * plumbed in the kernel, and all instances of ion_phys_addr_t should 34 + * be converted to phys_addr_t. For the time being many kernel interfaces 35 + * do not accept phys_addr_t's that would have to 36 + */ 35 37 #define ion_phys_addr_t unsigned long 36 38 37 39 /**
+4 -2
drivers/staging/android/ion/ion_cma_heap.c
··· 180 180 return ERR_PTR(-ENOMEM); 181 181 182 182 cma_heap->heap.ops = &ion_cma_ops; 183 - /* get device from private heaps data, later it will be 184 - * used to make the link with reserved CMA memory */ 183 + /* 184 + * get device from private heaps data, later it will be 185 + * used to make the link with reserved CMA memory 186 + */ 185 187 cma_heap->dev = data->priv; 186 188 cma_heap->heap.type = ION_HEAP_TYPE_DMA; 187 189 return &cma_heap->heap;
+2 -1
drivers/staging/android/ion/ion_priv.h
··· 346 346 * to keep a pool of pre allocated memory to use from your heap. Keeping 347 347 * a pool of memory that is ready for dma, ie any cached mapping have been 348 348 * invalidated from the cache, provides a significant performance benefit on 349 - * many systems */ 349 + * many systems 350 + */ 350 351 351 352 /** 352 353 * struct ion_page_pool - pagepool struct
+5 -2
drivers/staging/android/ion/ion_system_heap.c
··· 185 185 struct scatterlist *sg; 186 186 int i; 187 187 188 - /* uncached pages come from the page pools, zero them before returning 189 - for security purposes (other allocations are zerod at alloc time */ 188 + /* 189 + * uncached pages come from the page pools, zero them before returning 190 + * for security purposes (other allocations are zerod at 191 + * alloc time 192 + */ 190 193 if (!cached && !(buffer->private_flags & ION_PRIV_FLAG_SHRINKER_FREE)) 191 194 ion_heap_buffer_zero(buffer); 192 195
+16 -9
drivers/staging/android/uapi/ion.h
··· 40 40 ION_HEAP_TYPE_CARVEOUT, 41 41 ION_HEAP_TYPE_CHUNK, 42 42 ION_HEAP_TYPE_DMA, 43 - ION_HEAP_TYPE_CUSTOM, /* must be last so device specific heaps always 44 - are at the end of this enum */ 43 + ION_HEAP_TYPE_CUSTOM, /* 44 + * must be last so device specific heaps always 45 + * are at the end of this enum 46 + */ 45 47 ION_NUM_HEAPS = 16, 46 48 }; 47 49 ··· 58 56 * allocation flags - the lower 16 bits are used by core ion, the upper 16 59 57 * bits are reserved for use by the heaps themselves. 60 58 */ 61 - #define ION_FLAG_CACHED 1 /* mappings of this buffer should be 62 - cached, ion will do cache 63 - maintenance when the buffer is 64 - mapped for dma */ 65 - #define ION_FLAG_CACHED_NEEDS_SYNC 2 /* mappings of this buffer will created 66 - at mmap time, if this is set 67 - caches must be managed manually */ 59 + #define ION_FLAG_CACHED 1 /* 60 + * mappings of this buffer should be 61 + * cached, ion will do cache 62 + * maintenance when the buffer is 63 + * mapped for dma 64 + */ 65 + #define ION_FLAG_CACHED_NEEDS_SYNC 2 /* 66 + * mappings of this buffer will created 67 + * at mmap time, if this is set 68 + * caches must be managed 69 + * manually 70 + */ 68 71 69 72 /** 70 73 * DOC: Ion Userspace API