lkml.org 
[lkml]   [2014]   [Apr]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] Staging:dgnc:dgnc_driver open/close braces
Date
ERROR: that open brace { should be on the previous line
ERROR: else should follow close brace '}
ERROR: space required before the open parenthesis '(
ERROR: trailing whitespace
ERROR: open brace '{' following function declarations go on the next line
ERROR: space required after that ',' (ctx:VxV)
ERROR: space required before the open parenthesis '('

Signed-off-by: Paul McQuade <paulmcquad@gmail.com>
---
drivers/staging/dgnc/dgnc_driver.c | 22 ++++++++++------------
1 file changed, 10 insertions(+), 12 deletions(-)

diff --git a/drivers/staging/dgnc/dgnc_driver.c b/drivers/staging/dgnc/dgnc_driver.c
index b1a39b2..7c853c4 100644
--- a/drivers/staging/dgnc/dgnc_driver.c
+++ b/drivers/staging/dgnc/dgnc_driver.c
@@ -88,8 +88,7 @@ module_exit(dgnc_cleanup_module);
/*
* File operations permitted on Control/Management major.
*/
-static const struct file_operations dgnc_BoardFops =
-{
+static const struct file_operations dgnc_BoardFops = {
.owner = THIS_MODULE,
.unlocked_ioctl = dgnc_mgmt_ioctl,
.open = dgnc_mgmt_open,
@@ -153,8 +152,7 @@ struct board_id {
unsigned int is_pci_express;
};

-static struct board_id dgnc_Ids[] =
-{
+static struct board_id dgnc_Ids[] = {
{ PCI_DEVICE_CLASSIC_4_PCI_NAME, 4, 0 },
{ PCI_DEVICE_CLASSIC_4_422_PCI_NAME, 4, 0 },
{ PCI_DEVICE_CLASSIC_8_PCI_NAME, 8, 0 },
@@ -239,8 +237,7 @@ int dgnc_init_module(void)
pr_warn("WARNING: dgnc driver load failed. No Digi Neo or Classic boards found.\n");

dgnc_cleanup_module();
- }
- else {
+ } else {
dgnc_create_driver_sysfiles(&dgnc_driver);
}

@@ -410,7 +407,7 @@ static void dgnc_cleanup_board(struct dgnc_board *brd)
{
int i = 0;

- if(!brd || brd->magic != DGNC_BOARD_MAGIC)
+ if (!brd || brd->magic != DGNC_BOARD_MAGIC)
return;

switch (brd->device) {
@@ -488,7 +485,7 @@ static int dgnc_found_board(struct pci_dev *pdev, int id)
/* get the board structure and prep it */
brd = dgnc_Board[dgnc_NumBoards] =
kzalloc(sizeof(*brd), GFP_KERNEL);
- if (!brd)
+ if (!brd)
return -ENOMEM;

/* make a temporary message buffer for the boot messages */
@@ -532,7 +529,7 @@ static int dgnc_found_board(struct pci_dev *pdev, int id)
brd->irq = pci_irq;


- switch(brd->device) {
+ switch (brd->device) {

case PCI_DEVICE_CLASSIC_4_DID:
case PCI_DEVICE_CLASSIC_8_DID:
@@ -719,7 +716,8 @@ failed:
}


-static int dgnc_finalize_board_init(struct dgnc_board *brd) {
+static int dgnc_finalize_board_init(struct dgnc_board *brd)
+{
int rc = 0;

DPR_INIT(("dgnc_finalize_board_init() - start\n"));
@@ -895,7 +893,7 @@ int dgnc_ms_sleep(ulong ms)
*/
char *dgnc_ioctl_name(int cmd)
{
- switch(cmd) {
+ switch (cmd) {
case TCGETA: return "TCGETA";
case TCGETS: return "TCGETS";
--
1.8.3.2



\
 
 \ /
  Last update: 2014-04-09 19:21    [W:0.043 / U:0.544 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site