From: Joe Perches <joe@perches.com>
To: linux-kernel@vger.kernel.org
Cc: Paul Mackerras <paulus@samba.org>, linuxppc-dev@lists.ozlabs.org
Subject: [PATCH 1/2] powerpc: pci-ioda: Remove unnecessary return value from printk
Date: Sun, 21 Sep 2014 10:55:05 -0700 [thread overview]
Message-ID: <66c8a7da00628a092e782b7818bf5bdea7408b34.1411320262.git.joe@perches.com> (raw)
In-Reply-To: <cover.1411320262.git.joe@perches.com>
The return value is unnecessary and unused, so make the functions
void instead of int.
Signed-off-by: Joe Perches <joe@perches.com>
---
arch/powerpc/platforms/powernv/pci-ioda.c | 9 +++------
1 file changed, 3 insertions(+), 6 deletions(-)
diff --git a/arch/powerpc/platforms/powernv/pci-ioda.c b/arch/powerpc/platforms/powernv/pci-ioda.c
index df241b1..16bb93f 100644
--- a/arch/powerpc/platforms/powernv/pci-ioda.c
+++ b/arch/powerpc/platforms/powernv/pci-ioda.c
@@ -42,12 +42,11 @@
#include "pci.h"
#define define_pe_printk_level(func, kern_level) \
-static int func(const struct pnv_ioda_pe *pe, const char *fmt, ...) \
+static void func(const struct pnv_ioda_pe *pe, const char *fmt, ...) \
{ \
struct va_format vaf; \
va_list args; \
char pfix[32]; \
- int r; \
\
va_start(args, fmt); \
\
@@ -61,12 +60,10 @@ static int func(const struct pnv_ioda_pe *pe, const char *fmt, ...) \
sprintf(pfix, "%04x:%02x ", \
pci_domain_nr(pe->pbus), \
pe->pbus->number); \
- r = printk(kern_level "pci %s: [PE# %.3d] %pV", \
- pfix, pe->pe_number, &vaf); \
+ printk(kern_level "pci %s: [PE# %.3d] %pV", \
+ pfix, pe->pe_number, &vaf); \
\
va_end(args); \
- \
- return r; \
} \
define_pe_printk_level(pe_err, KERN_ERR);
--
1.8.1.2.459.gbcd45b4.dirty
next prev parent reply other threads:[~2014-09-21 18:01 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-21 17:55 [PATCH 0/2] powerpc: pci-ioda: Neatening Joe Perches
2014-09-21 17:55 ` Joe Perches [this message]
2014-09-21 17:55 ` [PATCH 2/2] powerpc: pci-ioda: Use a single function to emit logging messages Joe Perches
2014-09-22 6:56 ` [PATCH 0/2] powerpc: pci-ioda: Neatening Michael Ellerman
2014-09-23 0:53 ` Gavin Shan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=66c8a7da00628a092e782b7818bf5bdea7408b34.1411320262.git.joe@perches.com \
--to=joe@perches.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=paulus@samba.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).