Skip to contentSkip to conversation

Staging: msm: fixed style issues found by checkpatch.pl

PATCH In review Prashant P. Shah 3 participants 9 messages Jul 6, 2011 Staging

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Staging: msm: fixed style issues found by checkpatch.pl

This is a patch to the msm drivers that fixes many style issues found by the checkpatch.pl tool
- extra spaces
- invalid code indent
- extra braces
- invalid comment style

---
 drivers/staging/msm/ebi2_lcd.c             |    7 +-
 drivers/staging/msm/ebi2_tmd20.c           |  133 ++++++++++++++--------------
 drivers/staging/msm/hdmi_sii9022.c         |    2 +-
 drivers/staging/msm/lcdc.c                 |   14 ++--
 drivers/staging/msm/lcdc_gordon.c          |    2 +-
 drivers/staging/msm/lcdc_st15.c            |    2 +-
 drivers/staging/msm/lcdc_toshiba_wvga_pt.c |    2 +-
 drivers/staging/msm/mddi.c                 |    2 +-
 drivers/staging/msm/mddi_sharp.c           |    4 +-
 drivers/staging/msm/mddi_toshiba.c         |    4 +-
 drivers/staging/msm/mddihost.c             |   19 +++--
 drivers/staging/msm/mddihosti.c            |   23 +++---
 drivers/staging/msm/mdp.c                  |   26 +++---
 drivers/staging/msm/mdp4_overlay.c         |    6 +-
 drivers/staging/msm/mdp4_util.c            |   18 ++--
 drivers/staging/msm/mdp_cursor.c           |    2 +-
 drivers/staging/msm/mdp_dma.c              |    7 +-
 drivers/staging/msm/mdp_hw_init.c          |    2 +-
 drivers/staging/msm/mdp_ppp.c              |   11 +--
 drivers/staging/msm/mdp_ppp_dq.c           |   10 +-
 drivers/staging/msm/mdp_ppp_v20.c          |   69 +++++----------
 drivers/staging/msm/msm_fb.c               |   54 ++++++------
 drivers/staging/msm/staging-devices.c      |   31 ++++---
 drivers/staging/msm/tv_ntsc.c              |    2 +-
 drivers/staging/msm/tvenc.c                |   18 ++--
 25 files changed, 222 insertions(+), 248 deletions(-)
drivers/staging/msm/ebi2_lcd.c +3 -4
index b41e123..604ed9f 100644
@@ -208,14 +208,13 @@ static int ebi2_lcd_probe(struct platform_device *pdev)
 	 * register in mdp driver
 	 */
 	rc = platform_device_add(mdp_dev);
-	if (rc) {
+	if (rc)
 		goto ebi2_lcd_probe_err;
-	}
 
 	pdev_list[pdev_list_cnt++] = pdev;
 	return 0;
 
-      ebi2_lcd_probe_err:
+ebi2_lcd_probe_err:
 	platform_device_put(mdp_dev);
 	return rc;
 }
@@ -247,4 +246,4 @@ static int __init ebi2_lcd_driver_init(void)
 	return ebi2_lcd_register_driver();
 }
 
-module_init(ebi2_lcd_driver_init);
\ No newline at end of file
+module_init(ebi2_lcd_driver_init);
drivers/staging/msm/ebi2_tmd20.c +67 -66

228 lines not on this page · raw message

drivers/staging/msm/hdmi_sii9022.c +1 -1
index 6b82b56..c76a3e1 100644
@@ -22,7 +22,7 @@
 #define DEVICE_NAME "sii9022"
 #define SII9022_DEVICE_ID   0xB0
 
-struct sii9022_i2c_addr_data{
+struct sii9022_i2c_addr_data {
 	u8 addr;
 	u8 data;
 };
drivers/staging/msm/lcdc.c +7 -7
index 8183394..5db5a9c 100644
@@ -79,8 +79,8 @@ static int lcdc_off(struct platform_device *pdev)
 	if (lcdc_pdata && lcdc_pdata->lcdc_gpio_config)
 		ret = lcdc_pdata->lcdc_gpio_config(0);
 
-//	pm_qos_update_requirement(PM_QOS_SYSTEM_BUS_FREQ , "lcdc",
-//					PM_QOS_DEFAULT_VALUE);
+	/* pm_qos_update_requirement(PM_QOS_SYSTEM_BUS_FREQ , "lcdc",
+					PM_QOS_DEFAULT_VALUE); */
 
 	return ret;
 }
@@ -100,8 +100,8 @@ static int lcdc_on(struct platform_device *pdev)
 	else
 		pm_qos_freq = 58000;
 
-//	pm_qos_update_requirement(PM_QOS_SYSTEM_BUS_FREQ , "lcdc",
-//						pm_qos_freq);
+	/* pm_qos_update_requirement(PM_QOS_SYSTEM_BUS_FREQ , "lcdc",
+						pm_qos_freq); */
 	mfd = platform_get_drvdata(pdev);
 
 	clk_enable(mdp_lcdc_pclk_clk);
@@ -210,7 +210,7 @@ lcdc_probe_err:
 
 static int lcdc_remove(struct platform_device *pdev)
 {
-//	pm_qos_remove_requirement(PM_QOS_SYSTEM_BUS_FREQ , "lcdc");
+	/* pm_qos_remove_requirement(PM_QOS_SYSTEM_BUS_FREQ , "lcdc"); */
 	return 0;
 }
 
@@ -231,8 +231,8 @@ static int __init lcdc_driver_init(void)
 		printk(KERN_ERR "error: can't get mdp_lcdc_pad_pclk_clk!\n");
 		return PTR_ERR(mdp_lcdc_pad_pclk_clk);
 	}
-//	pm_qos_add_requirement(PM_QOS_SYSTEM_BUS_FREQ , "lcdc",
-//				PM_QOS_DEFAULT_VALUE);
+	/* pm_qos_add_requirement(PM_QOS_SYSTEM_BUS_FREQ , "lcdc",
+				PM_QOS_DEFAULT_VALUE); */
 	return lcdc_register_driver();
 }
 
drivers/staging/msm/lcdc_gordon.c +1 -1
index 399ec8c..0c122c3 100644
@@ -98,7 +98,7 @@ static unsigned char bit_shift[8] = { (1 << 7),	/* MSB */
 	(1 << 0)		               /* LSB */
 };
 
-struct gordon_state_type{
+struct gordon_state_type {
 	boolean disp_initialized;
 	boolean display_on;
 	boolean disp_powered_up;
drivers/staging/msm/lcdc_st15.c +1 -1
index fed8278..cce7e08 100644
@@ -22,7 +22,7 @@
 #define DEVICE_NAME "sii9022"
 #define SII9022_DEVICE_ID   0xB0
 
-struct sii9022_i2c_addr_data{
+struct sii9022_i2c_addr_data {
 	u8 addr;
 	u8 data;
 };
drivers/staging/msm/lcdc_toshiba_wvga_pt.c +1 -1
index edba78a..6bbbec0 100644
@@ -30,7 +30,7 @@ static int spi_sclk;
 static int spi_mosi;
 static int spi_miso;
 
-struct toshiba_state_type{
+struct toshiba_state_type {
 	boolean disp_initialized;
 	boolean display_on;
 	boolean disp_powered_up;
drivers/staging/msm/mddi.c +1 -1
index 132eb1a..049d603 100644
@@ -344,7 +344,7 @@ static int __init mddi_driver_init(void)
 
 	mddi_clk = clk_get(NULL, "mddi_clk");
 	if (IS_ERR(mddi_clk)) {
-		printk(KERN_ERR "can't find mddi_clk \n");
+		printk(KERN_ERR "can't find mddi_clk\n");
 		return PTR_ERR(mddi_clk);
 	}
 	clk_enable(mddi_clk);
drivers/staging/msm/mddi_sharp.c +2 -2
index 1da1be4..0b6e517 100644
@@ -667,9 +667,9 @@ void mddi_sharp_lcd_vsync_detected(boolean detected)
 		mddi_vsync_detect_enabled = FALSE;
 		mddi_sharp_vsync_attempts = 0;
 		/* need to clear this vsync wakeup */
-		if (!mddi_queue_register_write_int(REG_INTR, 0x0000)) {
+		if (!mddi_queue_register_write_int(REG_INTR, 0x0000))
 			MDDI_MSG_ERR("Vsync interrupt clear failed!\n");
-		}
+
 		if (!detected) {
 			/* give up after 5 failed attempts but show error */
 			MDDI_MSG_NOTICE("Vsync detection failed!\n");
drivers/staging/msm/mddi_toshiba.c +2 -2
index e96342d..2b801d7 100644
@@ -1668,8 +1668,8 @@ static struct platform_driver this_driver = {
 };
 
 static struct msm_fb_panel_data toshiba_panel_data = {
-	.on 		= mddi_toshiba_lcd_on,
-	.off 		= mddi_toshiba_lcd_off,
+	.on	= mddi_toshiba_lcd_on,
+	.off	= mddi_toshiba_lcd_off,
 };
 
 static int ch_used[3];
drivers/staging/msm/mddihost.c +11 -8
index 58a86d5..4bd747e 100644
@@ -79,7 +79,8 @@ void mddi_init(void)
 }
 
 int mddi_host_register_read(uint32 reg_addr,
-     uint32 *reg_value_ptr, boolean wait, mddi_host_type host) {
+	uint32 *reg_value_ptr, boolean wait, mddi_host_type host)
+{
 	mddi_linked_list_type *curr_llist_ptr;
 	mddi_register_access_packet_type *regacc_pkt_ptr;
 	uint16 curr_llist_idx;
@@ -153,8 +154,9 @@ int mddi_host_register_read(uint32 reg_addr,
 }				/* mddi_host_register_read */
 
 int mddi_host_register_write(uint32 reg_addr,
-     uint32 reg_val, enum mddi_data_packet_size_type packet_size,
-     boolean wait, mddi_llist_done_cb_type done_cb, mddi_host_type host) {
+	uint32 reg_val, enum mddi_data_packet_size_type packet_size,
+	boolean wait, mddi_llist_done_cb_type done_cb, mddi_host_type host)
+{
 	mddi_linked_list_type *curr_llist_ptr;
 	mddi_linked_list_type *curr_llist_dma_ptr;
 	mddi_register_access_packet_type *regacc_pkt_ptr;
@@ -227,8 +229,9 @@ int mddi_host_register_write(uint32 reg_addr,
 	return ret;
 }				/* mddi_host_register_write */
 
-boolean mddi_host_register_read_int
-    (uint32 reg_addr, uint32 *reg_value_ptr, mddi_host_type host) {
+boolean mddi_host_register_read_int(uint32 reg_addr,
+	uint32 *reg_value_ptr, mddi_host_type host)
+{
 	mddi_linked_list_type *curr_llist_ptr;
 	mddi_register_access_packet_type *regacc_pkt_ptr;
 	uint16 curr_llist_idx;
@@ -279,9 +282,9 @@ boolean mddi_host_register_read_int
 
 }				/* mddi_host_register_read */
 
-boolean mddi_host_register_write_int
-    (uint32 reg_addr,
-     uint32 reg_val, mddi_llist_done_cb_type done_cb, mddi_host_type host) {
+boolean mddi_host_register_write_int(uint32 reg_addr,
+	uint32 reg_val, mddi_llist_done_cb_type done_cb, mddi_host_type host)
+{
 	mddi_linked_list_type *curr_llist_ptr;
 	mddi_linked_list_type *curr_llist_dma_ptr;
 	mddi_register_access_packet_type *regacc_pkt_ptr;
drivers/staging/msm/mddihosti.c +11 -12
index f9d6e91..5165a62 100644
@@ -89,8 +89,10 @@ typedef struct {
 	mddi_rev_handler_type handler;	/* ISR to be executed */
 	uint16 pkt_type;
 } mddi_rev_pkt_handler_type;
-static mddi_rev_pkt_handler_type mddi_rev_pkt_handler[MAX_MDDI_REV_HANDLERS] =
-    { {NULL, INVALID_PKT_TYPE}, {NULL, INVALID_PKT_TYPE} };
+
+static mddi_rev_pkt_handler_type mddi_rev_pkt_handler[MAX_MDDI_REV_HANDLERS] = {
+	{NULL, INVALID_PKT_TYPE}, {NULL, INVALID_PKT_TYPE}
+};
 
 static boolean mddi_rev_encap_user_request = FALSE;
 static mddi_linked_list_notify_type mddi_rev_user;
@@ -415,15 +417,13 @@ static void mddi_report_state_change(uint32 int_reg)
 #endif
 
 		/* vote on sleep */
-		if (pmhctl->link_state == MDDI_LINK_HIBERNATING) {
+		if (pmhctl->link_state == MDDI_LINK_HIBERNATING)
 			mddi_vote_to_sleep(host_idx, TRUE);
-		}
 
 #ifdef DEBUG_MDDIHOSTI
 		/* need to stop polling timer */
-		if (mddi_gpio.polling_enabled) {
+		if (mddi_gpio.polling_enabled)
 			(void) timer_clr(&mddi_gpio_poll_timer, T_NONE);
-		}
 #endif
 	}
 }
@@ -954,7 +954,7 @@ static void mddi_process_rev_packets(void)
 		case 146:	/* register access packet */
 			{
 				mddi_register_access_packet_type
-				    * regacc_pkt_ptr;
+				    *regacc_pkt_ptr;
 
 				regacc_pkt_ptr =
 				    (mddi_register_access_packet_type *)
@@ -1860,9 +1860,8 @@ void mddi_host_powerdown(mddi_host_type host_idx)
 		return;
 	}
 
-	if (pmhctl->driver_state == MDDI_DRIVER_RESET) {
+	if (pmhctl->driver_state == MDDI_DRIVER_RESET)
 		return;
-	}
 
 	if (host_idx == MDDI_HOST_PRIM) {
 		/* disable timer */
@@ -2118,9 +2117,9 @@ void mddi_queue_reverse_encapsulation(boolean wait)
 	}
 	spin_unlock_irqrestore(&mddi_host_spin_lock, flags);
 
-	if (error) {
+	if (error)
 		MDDI_MSG_ERR("Reverse Encap request already in progress\n");
-	} else if (wait)
+	else if (wait)
 		wait_for_completion_killable(&(mddi_rev_user.done_comp));
 #endif
 }
@@ -2132,7 +2131,7 @@ boolean mddi_set_rev_handler(mddi_rev_handler_type handler, uint16 pkt_type)
 	MDDI_MSG_CRIT("No reverse link available\n");
 	(void)handler;
 	(void)pkt_type;
-	return (FALSE);
+	return FALSE;
 #else
 	unsigned long flags;
 	uint16 hdlr;
drivers/staging/msm/mdp.c +12 -14
index 58cb404..66c2fc7 100644
@@ -441,8 +441,8 @@ void mdp_pipe_ctrl(MDP_BLOCK_TYPE block, MDP_BLOCK_POWER_STATE state,
 			* other blocks
 			*/
 			if (block != MDP_MASTER_BLOCK) {
-				MSM_FB_INFO("mdp_block_power_cnt[block=%d] \
-				multiple power-off request\n", block);
+				MSM_FB_INFO("mdp_block_power_cnt[block=%d] "
+				"multiple power-off request\n", block);
 			}
 			mdp_block_power_cnt[block] = 0;
 		}
@@ -578,9 +578,9 @@ irqreturn_t mdp_isr(int irq, void *ptr)
 		}
 
 		/* LCDC UnderFlow */
-		if (mdp_interrupt & LCDC_UNDERFLOW) {
+		if (mdp_interrupt & LCDC_UNDERFLOW)
 			mdp_lcdc_underflow_cnt++;
-		}
+
 		/* LCDC Frame Start */
 		if (mdp_interrupt & LCDC_FRAME_START) {
 			/* let's disable LCDC interrupt */
@@ -652,9 +652,8 @@ static void mdp_drv_init(void)
 {
 	int i;
 
-	for (i = 0; i < MDP_MAX_BLOCK; i++) {
+	for (i = 0; i < MDP_MAX_BLOCK; i++)
 		mdp_debug[i] = 0;
-	}
 
 	/* initialize spin lock and workqueue */
 	spin_lock_init(&mdp_spin_lock);
@@ -697,9 +696,8 @@ static void mdp_drv_init(void)
 #endif
 
 	/* initializing mdp power block counter to 0 */
-	for (i = 0; i < MDP_MAX_BLOCK; i++) {
+	for (i = 0; i < MDP_MAX_BLOCK; i++)
 		mdp_block_power_cnt[i] = 0;
-	}
 
 #ifdef MSM_FB_ENABLE_DBGFS
 	{
@@ -871,9 +869,9 @@ static int mdp_probe(struct platform_device *pdev)
 		if (unlikely(!msm_mdp_base))
 			return -ENOMEM;
 
-		printk("irq clk setup\n");
+		printk(KERN_INFO "irq clk setup\n");
 		rc = mdp_irq_clk_setup();
-		printk("irq clk setup done\n");
+		printk(KERN_INFO "irq clk setup done\n");
 		if (rc)
 			return rc;
 
@@ -1031,14 +1029,13 @@ static int mdp_probe(struct platform_device *pdev)
 	platform_set_drvdata(msm_fb_dev, mfd);
 
 	rc = platform_device_add(msm_fb_dev);
-	if (rc) {
+	if (rc)
 		goto mdp_probe_err;
-	}
 
 	pdev_list[pdev_list_cnt++] = pdev;
 	return 0;
 
-      mdp_probe_err:
+mdp_probe_err:
 	platform_device_put(msm_fb_dev);
 	return rc;
 }
@@ -1052,7 +1049,8 @@ static void mdp_suspend_sub(void)
 	flush_workqueue(mdp_pipe_ctrl_wq);
 
 	/* let's wait for PPP completion */
-	while (mdp_block_power_cnt[MDP_PPP_BLOCK] > 0) ;
+	while (mdp_block_power_cnt[MDP_PPP_BLOCK] > 0)
+		;
 
 	/* try to power down */
 	mdp_pipe_ctrl(MDP_MASTER_BLOCK, MDP_BLOCK_POWER_OFF, FALSE);
drivers/staging/msm/mdp4_overlay.c +3 -3
index b9acf52..837693b 100644
@@ -730,7 +730,7 @@ void mdp4_mixer_blend_setup(struct mdp4_overlay_pipe *pipe)
 	uint32 c0, c1, c2, blend_op;
 	int off;
 
-	if (pipe->mixer_num) 	/* mixer number, /dev/fb0, /dev/fb1 */
+	if (pipe->mixer_num)	/* mixer number, /dev/fb0, /dev/fb1 */
 		overlay_base = MDP_BASE + MDP4_OVERLAYPROC1_BASE;/* 0x18000 */
 	else
 		overlay_base = MDP_BASE + MDP4_OVERLAYPROC0_BASE;/* 0x10000 */
@@ -739,7 +739,7 @@ void mdp4_mixer_blend_setup(struct mdp4_overlay_pipe *pipe)
 	off = 0x20 * (pipe->mixer_stage - MDP4_MIXER_STAGE0);
 
 	blend_op = 0;
-	if (pipe->alpha_enable) 	/* ARGB */
+	if (pipe->alpha_enable)	/* ARGB */
 		blend_op = MDP4_BLEND_FG_ALPHA_FG_PIXEL |
 				MDP4_BLEND_BG_ALPHA_FG_PIXEL;
 	else
@@ -747,7 +747,7 @@ void mdp4_mixer_blend_setup(struct mdp4_overlay_pipe *pipe)
 				MDP4_BLEND_FG_ALPHA_FG_CONST);
 
 
-	if (pipe->alpha_enable == 0) { 	/* not ARGB */
+	if (pipe->alpha_enable == 0) {	/* not ARGB */
 		if (pipe->is_fg) {
 			outpdw(overlay_base + off + 0x108, pipe->alpha);
 			outpdw(overlay_base + off + 0x10c, 0xff - pipe->alpha);
drivers/staging/msm/mdp4_util.c +9 -9
index fd97f52..fa84df3 100644
@@ -95,7 +95,7 @@ void mdp4_display_intf_sel(int output, ulong intf)
 
 	outpdw(MDP_BASE + 0x0038, bits);	/* MDP_DISP_INTF_SEL */
 
-  MSM_FB_INFO("mdp4_display_intf_sel: 0x%x\n", (int)inpdw(MDP_BASE + 0x0038));
+	MSM_FB_INFO("mdp4_display_intf_sel: 0x%x\n", (int)inpdw(MDP_BASE + 0x0038));
 }
 
 unsigned long mdp4_display_status(void)
@@ -118,7 +118,7 @@ void mdp4_ebi2_lcd_setup(int lcd, ulong base, int ystride)
 
 void mdp4_mddi_setup(int mddi, unsigned long id)
 {
-	ulong 	bits;
+	ulong bits;
 
 	if (mddi == MDDI_EXTERNAL_SET)
 		bits = 0x02;
@@ -926,7 +926,7 @@ void mdp4_mixer_blend_init(mixer_num)
 	unsigned char *overlay_base;
 	int off;
 
-	if (mixer_num) 	/* mixer number, /dev/fb0, /dev/fb1 */
+	if (mixer_num)	/* mixer number, /dev/fb0, /dev/fb1 */
 		overlay_base = MDP_BASE + MDP4_OVERLAYPROC1_BASE;/* 0x18000 */
 	else
 		overlay_base = MDP_BASE + MDP4_OVERLAYPROC0_BASE;/* 0x10000 */
@@ -961,11 +961,11 @@ static uint32 csc_post_bv_tab[3] = {0, 0, 0 };
 static  uint32 csc_pre_lv_tab[6] =  {0, 0xff, 0, 0xff, 0, 0xff };
 static  uint32 csc_post_lv_tab[6] = {0, 0xff, 0, 0xff, 0, 0xff };
 
-#define MDP4_CSC_MV_OFF 	0x4400
-#define MDP4_CSC_PRE_BV_OFF 	0x4500
-#define MDP4_CSC_POST_BV_OFF 	0x4580
-#define MDP4_CSC_PRE_LV_OFF 	0x4600
-#define MDP4_CSC_POST_LV_OFF 	0x4680
+#define MDP4_CSC_MV_OFF		0x4400
+#define MDP4_CSC_PRE_BV_OFF	0x4500
+#define MDP4_CSC_POST_BV_OFF	0x4580
+#define MDP4_CSC_PRE_LV_OFF	0x4600
+#define MDP4_CSC_POST_LV_OFF	0x4680
 
 void mdp4_vg_csc_mv_setup(int vp_num)
 {
@@ -1561,7 +1561,7 @@ void mdp4_mixer_gc_lut_setup(int mixer_num)
 	char val;
 	int i, off;
 
-	if (mixer_num) 	/* mixer number, /dev/fb0, /dev/fb1 */
+	if (mixer_num)	/* mixer number, /dev/fb0, /dev/fb1 */
 		base = MDP_BASE + MDP4_OVERLAYPROC1_BASE;/* 0x18000 */
 	else
 		base = MDP_BASE + MDP4_OVERLAYPROC0_BASE;/* 0x10000 */
drivers/staging/msm/mdp_cursor.c +1 -1
index 7d28f30..af09b9a 100644
@@ -76,7 +76,7 @@ int mdp_hw_cursor_update(struct fb_info *info, struct fb_cursor *cursor)
 		MDP_OUTP(MDP_BASE + 0x90048, mfd->cursor_buf_phys);
 		/* order the writes the cursor_buf before updating the
 		 * hardware */
-//		dma_coherent_pre_ops();
+		/* dma_coherent_pre_ops(); */
 		MDP_OUTP(MDP_BASE + 0x90060,
 			 (transp_en << 3) | (calpha_en << 1) |
 			 (inp32(MDP_BASE + 0x90060) & 0x1));
drivers/staging/msm/mdp_dma.c +3 -4
index 639918b..e5c0dd7 100644
@@ -520,9 +520,8 @@ void mdp_dma_pan_update(struct fb_info *info)
 	if (mfd->sw_currently_refreshing) {
 		/* we need to wait for the pending update */
 		mfd->pan_waiting = TRUE;
-		if (!mfd->ibuf_flushed) {
+		if (!mfd->ibuf_flushed)
 			wait_for_completion_killable(&mfd->pan_comp);
-		}
 		/* waiting for this update to complete */
 		mfd->pan_waiting = TRUE;
 		wait_for_completion_killable(&mfd->pan_comp);
@@ -550,8 +549,8 @@ void mdp_refresh_screen(unsigned long data)
 
 		if (!mfd->dma->busy) {
 			if (!queue_work(mdp_dma_wq, &mfd->dma_update_worker)) {
-				MSM_FB_DEBUG("mdp_dma: can't queue_work! -> \
-			MDP/MDDI/LCD clock speed needs to be increased\n");
+				MSM_FB_DEBUG("mdp_dma: can't queue_work! -> "
+			"MDP/MDDI/LCD clock speed needs to be increased\n");
 			}
 		}
 	} else {
drivers/staging/msm/mdp_hw_init.c +1 -1
index 807362a..4fa677d 100644
@@ -717,4 +717,4 @@ void mdp_hw_init(void)
 
 	/* MDP cmd block disable */
 	mdp_pipe_ctrl(MDP_CMD_BLOCK, MDP_BLOCK_POWER_OFF, FALSE);
-}
\ No newline at end of file
+}
drivers/staging/msm/mdp_ppp.c +4 -7
index 01b372f..2278b0a 100644
@@ -1023,15 +1023,12 @@ struct mdp_blit_req *req, struct file *p_src_file, struct file *p_dst_file)
 	if (iBuf->mdpImg.mdpOp & MDPOP_ROTATION) {
 		ppp_operation_reg |= PPP_OP_ROT_ON;
 
-		if (iBuf->mdpImg.mdpOp & MDPOP_ROT90) {
+		if (iBuf->mdpImg.mdpOp & MDPOP_ROT90)
 			ppp_operation_reg |= PPP_OP_ROT_90;
-		}
-		if (iBuf->mdpImg.mdpOp & MDPOP_LR) {
+		if (iBuf->mdpImg.mdpOp & MDPOP_LR)
 			ppp_operation_reg |= PPP_OP_FLIP_LR;
-		}
-		if (iBuf->mdpImg.mdpOp & MDPOP_UD) {
+		if (iBuf->mdpImg.mdpOp & MDPOP_UD)
 			ppp_operation_reg |= PPP_OP_FLIP_UD;
-		}
 	}
 
 	src0_ystride = src_width * inpBpp;
@@ -1218,7 +1215,7 @@ static int mdp_ppp_verify_req(struct mdp_blit_req *req)
 int get_gem_img(struct mdp_img *img, unsigned long *start, unsigned long *len)
 {
 	panic("waaaaaaaah");
-	//return kgsl_gem_obj_addr(img->memory_id, (int)img->priv, start, len);
+	/* return kgsl_gem_obj_addr(img->memory_id, (int)img->priv, start, len); */
 }
 
 int get_img(struct mdp_img *img, struct fb_info *info, unsigned long *start,
drivers/staging/msm/mdp_ppp_dq.c +5 -5
index 3a687c7..4671a64 100644
@@ -111,7 +111,7 @@ static void mdp_ppp_djob_cleaner(struct work_struct *work)
 {
 	struct mdp_ppp_djob *job;
 
-	MDP_PPP_DEBUG_MSG("mdp ppp display job cleaner started \n");
+	MDP_PPP_DEBUG_MSG("mdp ppp display job cleaner started\n");
 
 	/* cleanup display job */
 	job = container_of(work, struct mdp_ppp_djob, cleaner.work);
@@ -188,7 +188,7 @@ static void mdp_ppp_flush_dirty_djobs(void *cond)
 			break;
 		}
 
-		MDP_PPP_DEBUG_MSG("flushing djobs ... loop \n");
+		MDP_PPP_DEBUG_MSG("flushing djobs ... loop\n");
 
 		/* Retrieve the job that needs to be cleaned */
 		job = list_entry(mdp_ppp_djob_clnrq.next,
@@ -225,7 +225,7 @@ void mdp_ppp_wait(void)
 		spin_unlock_irqrestore(&mdp_ppp_dq_lock, flags);
 
 		/* block uninterruptibly until available */
-		MDP_PPP_DEBUG_MSG("waiting for mdp... \n");
+		MDP_PPP_DEBUG_MSG("waiting for mdp...\n");
 		wait_for_completion_killable(&mdp_ppp_comp);
 
 		/* if MDP PPP engine is still free,
@@ -251,14 +251,14 @@ static void mdp_ppp_process_roi(struct list_head *roi_cmd_list)
 	list_for_each_entry(node, roi_cmd_list, node) {
 		int i = 0;
 		for (; i < node->ncmds; i++) {
-			MDP_PPP_DEBUG_MSG("%d: reg: 0x%x val: 0x%x \n",
+			MDP_PPP_DEBUG_MSG("%d: reg: 0x%x val: 0x%x\n",
 					i, node->cmd[i].reg, node->cmd[i].val);
 			outpdw(node->cmd[i].reg, node->cmd[i].val);
 		}
 	}
 
 	/* kickoff MDP PPP engine */
-	MDP_PPP_DEBUG_MSG("kicking off mdp \n");
+	MDP_PPP_DEBUG_MSG("kicking off mdp\n");
 	outpdw(MDP_BASE + 0x30, 0x1000);
 }
 
drivers/staging/msm/mdp_ppp_v20.c +23 -46

158 lines not on this page · raw message

drivers/staging/msm/msm_fb.c +27 -27

167 lines not on this page · raw message

drivers/staging/msm/staging-devices.c +16 -15
index d6cd919..452009a 100644
@@ -17,7 +17,7 @@
 
 #include "msm_mdp.h"
 #include "memory_ll.h"
-//#include "android_pmem.h"
+/* #include "android_pmem.h" */
 
 #ifdef CONFIG_MSM_SOC_REV_A
 #define MSM_SMI_BASE 0xE0000000
@@ -26,8 +26,8 @@
 #endif
 
 
-#define TOUCHPAD_SUSPEND 	34
-#define TOUCHPAD_IRQ 		38
+#define TOUCHPAD_SUSPEND	34
+#define TOUCHPAD_IRQ		38
 
 #define MSM_PMEM_MDP_SIZE	0x1591000
 
@@ -42,7 +42,7 @@
 #define MSM_FB_SIZE             0x500000
 #define MSM_FB_SIZE_ST15	0x800000
 #define MSM_AUDIO_SIZE		0x80000
-#define MSM_GPU_PHYS_SIZE 	SZ_2M
+#define MSM_GPU_PHYS_SIZE	SZ_2M
 
 #ifdef CONFIG_MSM_SOC_REV_A
 #define MSM_SMI_BASE		0xE0000000
@@ -56,7 +56,7 @@
 #define MSM_PMEM_SMI_SIZE	0x01500000
 
 #define MSM_FB_BASE		MSM_PMEM_SMI_BASE
-#define MSM_GPU_PHYS_BASE 	(MSM_FB_BASE + MSM_FB_SIZE)
+#define MSM_GPU_PHYS_BASE	(MSM_FB_BASE + MSM_FB_SIZE)
 #define MSM_PMEM_SMIPOOL_BASE	(MSM_GPU_PHYS_BASE + MSM_GPU_PHYS_SIZE)
 #define MSM_PMEM_SMIPOOL_SIZE	(MSM_PMEM_SMI_SIZE - MSM_FB_SIZE \
 					- MSM_GPU_PHYS_SIZE)
@@ -159,9 +159,9 @@ static void __init qsd8x50_allocate_memory_regions(void)
 	else
 		size = MSM_FB_SIZE;
 
-	addr = alloc_bootmem(size); // (void *)MSM_FB_BASE;
+	addr = alloc_bootmem(size); /* (void *)MSM_FB_BASE; */
 	if (!addr)
-		printk("Failed to allocate bootmem for framebuffer\n");
+		printk(KERN_ERR "Failed to allocate bootmem for framebuffer\n");
 
 
 	msm_fb_resources[0].start = __pa(addr);
@@ -172,7 +172,7 @@ static void __init qsd8x50_allocate_memory_regions(void)
 
 static int msm_fb_lcdc_gpio_config(int on)
 {
-//	return 0;
+	/* return 0; */
 	if (machine_is_qsd8x50_st1()) {
 		if (on) {
 			gpio_set_value(32, 1);
@@ -195,7 +195,7 @@ static int msm_fb_lcdc_gpio_config(int on)
 			gpio_set_value(22, 0);
 			gpio_set_value(32, 1);
 			gpio_set_value(155, 1);
-			//st15_hdmi_power(1);
+			/* st15_hdmi_power(1); */
 			gpio_set_value(22, 1);
 
 		} else {
@@ -204,7 +204,7 @@ static int msm_fb_lcdc_gpio_config(int on)
 			gpio_set_value(22, 0);
 			gpio_set_value(32, 0);
 			gpio_set_value(155, 0);
-		//	st15_hdmi_power(0);
+			/* st15_hdmi_power(0); */
 		}
 	}
 	return 0;
@@ -273,15 +273,16 @@ static void __init msm_fb_add_devices(void)
 {
 	int rc;
 	msm_fb_register_device("mdp", &mdp_pdata);
-//	msm_fb_register_device("pmdh", &mddi_pdata);
-//	msm_fb_register_device("emdh", &mddi_pdata);
-//	msm_fb_register_device("tvenc", 0);
+	/* msm_fb_register_device("pmdh", &mddi_pdata); */
+	/* msm_fb_register_device("emdh", &mddi_pdata); */
+	/* msm_fb_register_device("tvenc", 0); */
 
 	if (machine_is_qsd8x50a_st1_5()) {
-/*		rc = st15_hdmi_vreg_init();
+		/*
+		rc = st15_hdmi_vreg_init();
 		if (rc)
 			return;
-*/
+		*/
 		rc = msm_gpios_request_enable(
 			msm_fb_st15_gpio_config_data,
 			ARRAY_SIZE(msm_fb_st15_gpio_config_data));
drivers/staging/msm/tv_ntsc.c +1 -1
index 5eb6761..6b814ab 100644
@@ -160,4 +160,4 @@ static int __init ntsc_init(void)
 	return ret;
 }
 
-module_init(ntsc_init);
\ No newline at end of file
+module_init(ntsc_init);
drivers/staging/msm/tvenc.c +9 -9
index 4fbb77b..01b7d5f 100644
@@ -54,8 +54,8 @@ static struct platform_driver tvenc_driver = {
 	.probe = tvenc_probe,
 	.remove = tvenc_remove,
 	.suspend = NULL,
-//	.suspend_late = NULL,
-//	.resume_early = NULL,
+	/* .suspend_late = NULL, */
+	/* .resume_early = NULL, */
 	.resume = NULL,
 	.shutdown = NULL,
 	.driver = {
@@ -77,8 +77,8 @@ static int tvenc_off(struct platform_device *pdev)
 	if (tvenc_pdata && tvenc_pdata->pm_vid_en)
 		ret = tvenc_pdata->pm_vid_en(0);
 
-	//pm_qos_update_requirement(PM_QOS_SYSTEM_BUS_FREQ , "tvenc",
-	//				PM_QOS_DEFAULT_VALUE);
+	/* pm_qos_update_requirement(PM_QOS_SYSTEM_BUS_FREQ , "tvenc",
+					PM_QOS_DEFAULT_VALUE); */
 
 	if (ret)
 		printk(KERN_ERR "%s: pm_vid_en(off) failed! %d\n",
@@ -91,8 +91,8 @@ static int tvenc_on(struct platform_device *pdev)
 {
 	int ret = 0;
 
-//	pm_qos_update_requirement(PM_QOS_SYSTEM_BUS_FREQ , "tvenc",
-//				128000);
+	/* pm_qos_update_requirement(PM_QOS_SYSTEM_BUS_FREQ , "tvenc",
+				128000); */
 	if (tvenc_pdata && tvenc_pdata->pm_vid_en)
 		ret = tvenc_pdata->pm_vid_en(1);
 
@@ -263,7 +263,7 @@ tvenc_probe_err:
 
 static int tvenc_remove(struct platform_device *pdev)
 {
-//	pm_qos_remove_requirement(PM_QOS_SYSTEM_BUS_FREQ , "tvenc");
+	/* pm_qos_remove_requirement(PM_QOS_SYSTEM_BUS_FREQ , "tvenc"); */
 	return 0;
 }
 
@@ -288,8 +288,8 @@ static int __init tvenc_driver_init(void)
 		return PTR_ERR(tvdac_clk);
 	}
 
-//	pm_qos_add_requirement(PM_QOS_SYSTEM_BUS_FREQ , "tvenc",
-//				PM_QOS_DEFAULT_VALUE);
+	/* pm_qos_add_requirement(PM_QOS_SYSTEM_BUS_FREQ , "tvenc",
+				PM_QOS_DEFAULT_VALUE); */
 	return tvenc_register_driver();
 }
 
Signature · 1 line
1.7.1
#1 lore raw
Quoted 8 lines · Prashant P. Shah

This is a patch to the msm drivers that fixes many style issues found by the checkpatch.pl tool
- extra spaces
- invalid code indent
- extra braces
- invalid comment style

How about one patch per thing you changed please?

So that would be one patch for fixing extra braces, one for extra spaces, and so on. That makes it easier to review.

greg k-h

#2 lore raw
In reply to Prashant P. Shah
Quoted 8 lines · Prashant P. Shah

This is a patch to the msm drivers that fixes many style issues found by the checkpatch.pl tool
- extra spaces
- invalid code indent
- extra braces
- invalid comment style

Also, did you successfully build this code before and after your changes?

greg k-h

#3 lore raw

Hi,

Quoted 2 lines

So that would be one patch for fixing extra braces, one for extra spaces, and so on. That makes it easier to review.

Ok I will redo them.

Quoted 3 lines · Greg KH

On Wed, Jul 06, 2011 at 01:19:34PM +0530, Prashant P. Shah wrote:
Also, did you successfully build this code before and after your changes?

I tried but the code does not build because of #include <mach/board.h> in the msm_fb.c file. I dont know how to fix that.

#4 lore raw
Quoted 8 lines · Prashant Shah
Quoted 3 lines · Greg KH

On Wed, Jul 06, 2011 at 01:19:34PM +0530, Prashant P. Shah wrote:
Also, did you successfully build this code before and after your changes?

I tried but the code does not build because of #include <mach/board.h> in the msm_fb.c file. I dont know how to fix that.

there are few #include <mach/..> ins the source files that dont compile on my machine.

#5 lore raw
In reply to Prashant Shah
Quoted 7 lines · Prashant Shah

Hi,

Quoted 2 lines

So that would be one patch for fixing extra braces, one for extra spaces, and so on. That makes it easier to review.

Ok I will redo them.

Quoted 7 lines
Quoted 3 lines · Greg KH

On Wed, Jul 06, 2011 at 01:19:34PM +0530, Prashant P. Shah wrote:
Also, did you successfully build this code before and after your changes?

I tried but the code does not build because of #include <mach/board.h> in the msm_fb.c file. I dont know how to fix that.

I say let's just delete this whole directory as if it doesn't build, no one is using it, and no one has tried to clean it up since it was originally added.

Stepan or David or Abhijeet or Daniel, any objection to just deleting drivers/staging/msm/ at this point in time for the 3.1 kernel release? You haven't sent any patches to me to clean this code up since the original patch, way over a year ago.

greg k-h

#6 lore raw
Quoted 16 lines · Greg KH
Quoted 7 lines · Prashant Shah

Hi,

Quoted 2 lines

So that would be one patch for fixing extra braces, one for extra spaces, and so on. That makes it easier to review.

Ok I will redo them.

Quoted 7 lines
Quoted 3 lines · Greg KH

On Wed, Jul 06, 2011 at 01:19:34PM +0530, Prashant P. Shah wrote:
Also, did you successfully build this code before and after your changes?

I tried but the code does not build because of #include <mach/board.h> in the msm_fb.c file. I dont know how to fix that.

Quoted 8 lines

I say let's just delete this whole directory as if it doesn't build, no one is using it, and no one has tried to clean it up since it was originally added.

Stepan or David or Abhijeet or Daniel, any objection to just deleting drivers/staging/msm/ at this point in time for the 3.1 kernel release? You haven't sent any patches to me to clean this code up since the original patch, way over a year ago.

I have none. The non-staging driver has been getting updates, and I asked the author if it was OK to remove the staging one. I believe the real driver supports everything the staging one did.

Should I generate a (large) patch, or is it easier for you to just remove the tree?

David

Signature · 2 lines
Sent by an employee of the Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum.
#7 lore raw
Quoted 27 lines · David Brown
Quoted 16 lines · Greg KH
Quoted 7 lines · Prashant Shah

Hi,

Quoted 2 lines

So that would be one patch for fixing extra braces, one for extra spaces, and so on. That makes it easier to review.

Ok I will redo them.

Quoted 7 lines
Quoted 3 lines · Greg KH

On Wed, Jul 06, 2011 at 01:19:34PM +0530, Prashant P. Shah wrote:
Also, did you successfully build this code before and after your changes?

I tried but the code does not build because of #include <mach/board.h> in the msm_fb.c file. I dont know how to fix that.

Quoted 8 lines

I say let's just delete this whole directory as if it doesn't build, no one is using it, and no one has tried to clean it up since it was originally added.

Stepan or David or Abhijeet or Daniel, any objection to just deleting drivers/staging/msm/ at this point in time for the 3.1 kernel release? You haven't sent any patches to me to clean this code up since the original patch, way over a year ago.

Quoted 6 lines

I have none. The non-staging driver has been getting updates, and I asked the author if it was OK to remove the staging one. I believe the real driver supports everything the staging one did.

Should I generate a (large) patch, or is it easier for you to just remove the tree?

I'll just remove it, it's easier that way. Can I add your "Acked-by:" to the patch?

thanks,

greg k-h

#8 lore raw
Quoted 32 lines · Greg KH
Quoted 31 lines · David Brown
Quoted 16 lines · Greg KH
Quoted 7 lines · Prashant Shah

Hi,

Quoted 2 lines

So that would be one patch for fixing extra braces, one for extra spaces, and so on. That makes it easier to review.

Ok I will redo them.

Quoted 7 lines
Quoted 3 lines · Greg KH

On Wed, Jul 06, 2011 at 01:19:34PM +0530, Prashant P. Shah wrote:
Also, did you successfully build this code before and after your changes?

I tried but the code does not build because of #include <mach/board.h> in the msm_fb.c file. I dont know how to fix that.

Quoted 8 lines

I say let's just delete this whole directory as if it doesn't build, no one is using it, and no one has tried to clean it up since it was originally added.

Stepan or David or Abhijeet or Daniel, any objection to just deleting drivers/staging/msm/ at this point in time for the 3.1 kernel release? You haven't sent any patches to me to clean this code up since the original patch, way over a year ago.

I have none. The non-staging driver has been getting updates, and I asked the author if it was OK to remove the staging one. I believe the real driver supports everything the staging one did.

Quoted 5 lines
Quoted 2 lines

Should I generate a (large) patch, or is it easier for you to just remove the tree?

I'll just remove it, it's easier that way. Can I add your "Acked-by:" to the patch?

Yes.

Thanks,
David

Signature · 2 lines
Sent by an employee of the Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum.