[PATCH 11/11] staging: udlfb: fix checkpatch and style

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Fix warnings detected by tools

Signed-off-by: Bernie Thompson <bernie@xxxxxxxxxxxx>
Index: b/drivers/staging/udlfb/udlfb.c
===================================================================
--- a/drivers/staging/udlfb/udlfb.c	2010-08-18 11:26:50.000000000 -0700
+++ b/drivers/staging/udlfb/udlfb.c	2010-08-18 13:32:34.000000000 -0700
@@ -27,7 +27,6 @@
 #include <linux/slab.h>
 #include <linux/delay.h>
 
-
 #include "udlfb.h"
 
 static struct fb_fix_screeninfo dlfb_fix = {
@@ -256,6 +255,7 @@ static int dlfb_set_video_mode(struct dl
 	urb = dlfb_get_urb(dev);
 	if (!urb)
 		return -ENOMEM;
+
 	buf = (char *) urb->transfer_buffer;
 
 	/*
@@ -288,13 +288,14 @@ static int dlfb_ops_mmap(struct fb_info 
 	unsigned long offset = vma->vm_pgoff << PAGE_SHIFT;
 	unsigned long page, pos;
 
-	dl_notice("MMAP: %lu %u\n", offset + size, info->fix.smem_len);
-
 	if (offset + size > info->fix.smem_len)
 		return -EINVAL;
 
 	pos = (unsigned long)info->fix.smem_start + offset;
 
+	dl_notice("mmap() framebuffer addr:%lu size:%lu\n",
+		  pos, size);
+
 	while (size > 0) {
 		page = vmalloc_to_pfn((void *)pos);
 		if (remap_pfn_range(vma, start, page, PAGE_SIZE, PAGE_SHARED))
@@ -310,7 +311,6 @@ static int dlfb_ops_mmap(struct fb_info 
 
 	vma->vm_flags |= VM_RESERVED;	/* avoid to swap out this VMA */
 	return 0;
-
 }
 
 /*
@@ -378,7 +378,7 @@ static int dlfb_trim_hline(const u8 *bba
  * This has a slightly larger header overhead, but produces more even results.
  * It also processes all data (read and write) in a single pass.
  * Performance benchmarks of common cases show it having just slightly better
- * compression than 256 pixel raw -or- rle commands, with similar CPU consumpion.
+ * compression than 256 pixel raw or rle commands, with similar CPU consumpion.
  * But for very rl friendly data, will compress not quite as well.
  */
 static void dlfb_compress_hline(
@@ -1536,8 +1536,8 @@ static int dlfb_usb_probe(struct usb_int
 	struct usb_device *usbdev;
 	struct dlfb_data *dev = 0;
 	struct fb_info *info = 0;
-	int i;
 	int retval = -ENOMEM;
+	int i;
 
 	/* usb initialization */
 



_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/devel


[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux