Fixing coding guidelines in drivers/staging/android/ion
cover Fixing coding guidelines in drivers/staging/android/ion
Coding guidelines are fixed by running checkpatch.pl
pjambhlekar (1):
Fixing coding guidelines in drivers/staging/android/ion/*
drivers/staging/android/ion/ion-ioctl.c | 2 +- drivers/staging/android/ion/ion.c | 8 ++++---- drivers/staging/android/ion/ion_cma_heap.c | 3 +-- drivers/staging/android/ion/ion_dummy_driver.c | 2 +- drivers/staging/android/ion/ion_system_heap.c | 2 -- 5 files changed, 7 insertions(+), 10 deletions(-)
Signature · 1 line
2.7.4
PATCH 1/1 Fixing coding guidelines in drivers/staging/android/ion/*
--- drivers/staging/android/ion/ion-ioctl.c | 2 +- drivers/staging/android/ion/ion.c | 8 ++++---- drivers/staging/android/ion/ion_cma_heap.c | 3 +-- drivers/staging/android/ion/ion_dummy_driver.c | 2 +- drivers/staging/android/ion/ion_system_heap.c | 2 -- 5 files changed, 7 insertions(+), 10 deletions(-)
drivers/staging/android/ion/ion-ioctl.c +1 -1
@@ -95,7 +95,7 @@ long ion_ioctl(struct file *filp, unsigned int cmd, unsigned long arg)struct ion_handle *handle; handle =ion_alloc (client, data.allocation.len, - data.allocation.align, + data.allocation.align, data.allocation.heap_id_mask, data.allocation.flags);if (IS_ERR (handle))
drivers/staging/android/ion/ion.c +4 -4
@@ -131,7 +131,7 @@ static struct ion_buffer *ion_buffer_create(struct ion_heap *heap, goto err2; } -if (buffer->sg_table ==NULL ) { +if (!buffer->sg_table) {WARN_ONCE (1 ,"This heap needs to set the sgtable" ); ret = -EINVAL ; goto err1;
@@ -350,7 +350,7 @@ struct ion_handle *ion_handle_get_by_id_nolock(struct ion_client *client, }struct ion_handle *ion_handle_get_by_id (struct ion_client *client, -int id) +int id) {struct ion_handle *handle;
@@ -433,7 +433,7 @@ struct ion_handle *ion_alloc(struct ion_client *client, size_t len, }up_read (&dev->lock); -if (buffer ==NULL ) +if (!buffer)return ERR_PTR (-ENODEV );if (IS_ERR (buffer))
@@ -491,7 +491,7 @@ static void *ion_buffer_kmap_get(struct ion_buffer *buffer)return buffer->vaddr; } vaddr = buffer->heap->ops->map_kernel (buffer->heap, buffer); -if (WARN_ONCE (vaddr ==NULL , +if (WARN_ONCE (!vaddr,"heap->ops->map_kernel should return ERR_PTR on error" ))return ERR_PTR (-EINVAL );if (IS_ERR (vaddr))
drivers/staging/android/ion/ion_cma_heap.c +1 -2
@@ -37,7 +37,6 @@ struct ion_cma_buffer_info {struct sg_table *table; }; -/* ION CMA heap operations functions */ static int ion_cma_allocate(struct ion_heap *heap, struct ion_buffer *buffer, unsigned long len, unsigned long align,
@@ -59,7 +58,7 @@ static int ion_cma_allocate(struct ion_heap *heap, struct ion_buffer *buffer,if (!info)return -ENOMEM ; - info->cpu_addr =dma_alloc_coherent (dev, len, &(info->handle), + info->cpu_addr =dma_alloc_coherent (dev, len, &info->handle,GFP_HIGHUSER | __GFP_ZERO);if (!info->cpu_addr) {
drivers/staging/android/ion/ion_dummy_driver.c +1 -1
@@ -75,7 +75,6 @@ static int __init ion_dummy_init(void)if (!heaps)return -ENOMEM ; -/* Allocate a dummy carveout heap */ carveout_ptr = alloc_pages_exact( dummy_heaps[ION_HEAP_TYPE_CARVEOUT].size,
@@ -153,4 +152,5 @@ static void __exit ion_dummy_exit(void) chunk_ptr =NULL ; } } +__exitcall (ion_dummy_exit);
drivers/staging/android/ion/ion_system_heap.c +0 -2
@@ -102,7 +102,6 @@ static void free_buffer_page(struct ion_system_heap *heap,ion_page_pool_free (pool, page); } - static struct page *alloc_largest_available(struct ion_system_heap *heap, struct ion_buffer *buffer, unsigned long size,
@@ -263,7 +262,6 @@ static struct ion_heap_ops system_heap_ops = {static int ion_system_heap_debug_show (struct ion_heap *heap,struct seq_file *s,void *unused) { -struct ion_system_heap *sys_heap =container_of (heap, struct ion_system_heap, heap);
Signature · 1 line
2.7.4
Greg Kroah-Hartman
maintainerRe: [PATCH 1/1] Fixing coding guidelines in drivers/staging/android/ion/*
Quoted 8 lines · pjambhlekar
Signed-off-by pjambhlekar <[email protected]>--- drivers/staging/android/ion/ion-ioctl.c | 2 +- drivers/staging/android/ion/ion.c | 8 ++++---- drivers/staging/android/ion/ion_cma_heap.c | 3 +-- drivers/staging/android/ion/ion_dummy_driver.c | 2 +- drivers/staging/android/ion/ion_system_heap.c | 2 -- 5 files changed, 7 insertions(+), 10 deletions(-)
How come you didn't read what my patch-bot sent you the last time you sent me this patch? Please fix up the problems it found last time and resend if you wish for us to be able to review this patch (hint, I can't take a path with no changelog text, and you forgot to use get_maintainer.pl to find the correct mailing list to cc:).
Also, I need a "full" name in your from and signed-off-by line, unless you really only use one word for when you sign legal documents?
Take your time, relax, fix things up, resend it to yourself first to verify you got it all correct, and then you can send it to us. Please take at least a day to do this before resending, there is no rush.
thanks,
greg k-h