aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/hw/qib/qib_fs.c
diff options
context:
space:
mode:
authorMike Marciniszyn <mike.marciniszyn@intel.com>2012-07-19 09:04:25 -0400
committerRoland Dreier <roland@purestorage.com>2012-07-19 14:20:04 -0400
commit7fac33014f54c26bb1b1b4282b27c7988116d639 (patch)
tree0cefbb8483009cd98b08667e742ea95405da4d03 /drivers/infiniband/hw/qib/qib_fs.c
parent36a8f01cd24b125aa027c71c1288588edde5322d (diff)
IB/qib: checkpatch fixes
Elminate some simple_strto* usage. checkpatch also noted pr_ conversations, which have been done as recommended. The pr_fmt() define is used to shorten line length. Other multi-line string warnings are also elmininated. Reviewed-by: Dean Luick <dean.luick@intel.com> Signed-off-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
Diffstat (limited to 'drivers/infiniband/hw/qib/qib_fs.c')
-rw-r--r--drivers/infiniband/hw/qib/qib_fs.c21
1 files changed, 11 insertions, 10 deletions
diff --git a/drivers/infiniband/hw/qib/qib_fs.c b/drivers/infiniband/hw/qib/qib_fs.c
index 05e0f17c5b44..cff8a6c32161 100644
--- a/drivers/infiniband/hw/qib/qib_fs.c
+++ b/drivers/infiniband/hw/qib/qib_fs.c
@@ -1,5 +1,6 @@
1/* 1/*
2 * Copyright (c) 2006, 2007, 2008, 2009 QLogic Corporation. All rights reserved. 2 * Copyright (c) 2012 Intel Corporation. All rights reserved.
3 * Copyright (c) 2006 - 2012 QLogic Corporation. All rights reserved.
3 * Copyright (c) 2006 PathScale, Inc. All rights reserved. 4 * Copyright (c) 2006 PathScale, Inc. All rights reserved.
4 * 5 *
5 * This software is available to you under a choice of one of two 6 * This software is available to you under a choice of one of two
@@ -382,7 +383,7 @@ static int add_cntr_files(struct super_block *sb, struct qib_devdata *dd)
382 ret = create_file(unit, S_IFDIR|S_IRUGO|S_IXUGO, sb->s_root, &dir, 383 ret = create_file(unit, S_IFDIR|S_IRUGO|S_IXUGO, sb->s_root, &dir,
383 &simple_dir_operations, dd); 384 &simple_dir_operations, dd);
384 if (ret) { 385 if (ret) {
385 printk(KERN_ERR "create_file(%s) failed: %d\n", unit, ret); 386 pr_err("create_file(%s) failed: %d\n", unit, ret);
386 goto bail; 387 goto bail;
387 } 388 }
388 389
@@ -390,21 +391,21 @@ static int add_cntr_files(struct super_block *sb, struct qib_devdata *dd)
390 ret = create_file("counters", S_IFREG|S_IRUGO, dir, &tmp, 391 ret = create_file("counters", S_IFREG|S_IRUGO, dir, &tmp,
391 &cntr_ops[0], dd); 392 &cntr_ops[0], dd);
392 if (ret) { 393 if (ret) {
393 printk(KERN_ERR "create_file(%s/counters) failed: %d\n", 394 pr_err("create_file(%s/counters) failed: %d\n",
394 unit, ret); 395 unit, ret);
395 goto bail; 396 goto bail;
396 } 397 }
397 ret = create_file("counter_names", S_IFREG|S_IRUGO, dir, &tmp, 398 ret = create_file("counter_names", S_IFREG|S_IRUGO, dir, &tmp,
398 &cntr_ops[1], dd); 399 &cntr_ops[1], dd);
399 if (ret) { 400 if (ret) {
400 printk(KERN_ERR "create_file(%s/counter_names) failed: %d\n", 401 pr_err("create_file(%s/counter_names) failed: %d\n",
401 unit, ret); 402 unit, ret);
402 goto bail; 403 goto bail;
403 } 404 }
404 ret = create_file("portcounter_names", S_IFREG|S_IRUGO, dir, &tmp, 405 ret = create_file("portcounter_names", S_IFREG|S_IRUGO, dir, &tmp,
405 &portcntr_ops[0], dd); 406 &portcntr_ops[0], dd);
406 if (ret) { 407 if (ret) {
407 printk(KERN_ERR "create_file(%s/%s) failed: %d\n", 408 pr_err("create_file(%s/%s) failed: %d\n",
408 unit, "portcounter_names", ret); 409 unit, "portcounter_names", ret);
409 goto bail; 410 goto bail;
410 } 411 }
@@ -416,7 +417,7 @@ static int add_cntr_files(struct super_block *sb, struct qib_devdata *dd)
416 ret = create_file(fname, S_IFREG|S_IRUGO, dir, &tmp, 417 ret = create_file(fname, S_IFREG|S_IRUGO, dir, &tmp,
417 &portcntr_ops[i], dd); 418 &portcntr_ops[i], dd);
418 if (ret) { 419 if (ret) {
419 printk(KERN_ERR "create_file(%s/%s) failed: %d\n", 420 pr_err("create_file(%s/%s) failed: %d\n",
420 unit, fname, ret); 421 unit, fname, ret);
421 goto bail; 422 goto bail;
422 } 423 }
@@ -426,7 +427,7 @@ static int add_cntr_files(struct super_block *sb, struct qib_devdata *dd)
426 ret = create_file(fname, S_IFREG|S_IRUGO, dir, &tmp, 427 ret = create_file(fname, S_IFREG|S_IRUGO, dir, &tmp,
427 &qsfp_ops[i - 1], dd); 428 &qsfp_ops[i - 1], dd);
428 if (ret) { 429 if (ret) {
429 printk(KERN_ERR "create_file(%s/%s) failed: %d\n", 430 pr_err("create_file(%s/%s) failed: %d\n",
430 unit, fname, ret); 431 unit, fname, ret);
431 goto bail; 432 goto bail;
432 } 433 }
@@ -435,7 +436,7 @@ static int add_cntr_files(struct super_block *sb, struct qib_devdata *dd)
435 ret = create_file("flash", S_IFREG|S_IWUSR|S_IRUGO, dir, &tmp, 436 ret = create_file("flash", S_IFREG|S_IWUSR|S_IRUGO, dir, &tmp,
436 &flash_ops, dd); 437 &flash_ops, dd);
437 if (ret) 438 if (ret)
438 printk(KERN_ERR "create_file(%s/flash) failed: %d\n", 439 pr_err("create_file(%s/flash) failed: %d\n",
439 unit, ret); 440 unit, ret);
440bail: 441bail:
441 return ret; 442 return ret;
@@ -486,7 +487,7 @@ static int remove_device_files(struct super_block *sb,
486 487
487 if (IS_ERR(dir)) { 488 if (IS_ERR(dir)) {
488 ret = PTR_ERR(dir); 489 ret = PTR_ERR(dir);
489 printk(KERN_ERR "Lookup of %s failed\n", unit); 490 pr_err("Lookup of %s failed\n", unit);
490 goto bail; 491 goto bail;
491 } 492 }
492 493
@@ -532,7 +533,7 @@ static int qibfs_fill_super(struct super_block *sb, void *data, int silent)
532 533
533 ret = simple_fill_super(sb, QIBFS_MAGIC, files); 534 ret = simple_fill_super(sb, QIBFS_MAGIC, files);
534 if (ret) { 535 if (ret) {
535 printk(KERN_ERR "simple_fill_super failed: %d\n", ret); 536 pr_err("simple_fill_super failed: %d\n", ret);
536 goto bail; 537 goto bail;
537 } 538 }
538 539