From: Geert Custers <geert.aj.custers@gmail.com>
To: aaro.koskinen@iki.fi
Cc: linux-kernel@vger.kernel.org, gregkh@linuxfoundation.org
Subject: [PATCH] staging: octeon-usb: Resolve some checkpatch.pl warnings
Date: Thu, 1 Dec 2016 15:58:12 +0100 [thread overview]
Message-ID: <20161201145812.GA7521@GEERT_PC.localdomain> (raw)
This patch removes some of the warnings that are present when running
the checkpatch.pl script. It corrects the warnings related to macro
precedents.
Signed-off-by: Geert Custers <geert.aj.custers@gmail.com>
---
drivers/staging/octeon-usb/octeon-hcd.c | 2 +-
drivers/staging/octeon-usb/octeon-hcd.h | 8 ++++----
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb/octeon-hcd.c
index 9a7858a..9e6974e 100644
--- a/drivers/staging/octeon-usb/octeon-hcd.c
+++ b/drivers/staging/octeon-usb/octeon-hcd.c
@@ -380,7 +380,7 @@ struct octeon_hcd {
#define CVMX_WAIT_FOR_FIELD32(address, _union, cond, timeout_usec) \
({int result; \
do { \
- u64 done = cvmx_get_cycle() + (u64)timeout_usec * \
+ u64 done = cvmx_get_cycle() + (u64)(timeout_usec) * \
octeon_get_clock_rate() / 1000000; \
union _union c; \
\
diff --git a/drivers/staging/octeon-usb/octeon-hcd.h b/drivers/staging/octeon-usb/octeon-hcd.h
index 3353aefe..dc702fc 100644
--- a/drivers/staging/octeon-usb/octeon-hcd.h
+++ b/drivers/staging/octeon-usb/octeon-hcd.h
@@ -51,10 +51,10 @@
#define CVMX_USBCXBASE 0x00016F0010000000ull
#define CVMX_USBCXREG1(reg, bid) \
- (CVMX_ADD_IO_SEG(CVMX_USBCXBASE | reg) + \
+ (CVMX_ADD_IO_SEG(CVMX_USBCXBASE | (reg)) + \
((bid) & 1) * 0x100000000000ull)
#define CVMX_USBCXREG2(reg, bid, off) \
- (CVMX_ADD_IO_SEG(CVMX_USBCXBASE | reg) + \
+ (CVMX_ADD_IO_SEG(CVMX_USBCXBASE | (reg)) + \
(((off) & 7) + ((bid) & 1) * 0x8000000000ull) * 32)
#define CVMX_USBCX_GAHBCFG(bid) CVMX_USBCXREG1(0x008, bid)
@@ -86,9 +86,9 @@
#define CVMX_USBNXBID2(bid) (((bid) & 1) * 0x100000000000ull)
#define CVMX_USBNXREG1(reg, bid) \
- (CVMX_ADD_IO_SEG(0x0001180068000000ull | reg) + CVMX_USBNXBID1(bid))
+ (CVMX_ADD_IO_SEG(0x0001180068000000ull | (reg)) + CVMX_USBNXBID1(bid))
#define CVMX_USBNXREG2(reg, bid) \
- (CVMX_ADD_IO_SEG(0x00016F0000000000ull | reg) + CVMX_USBNXBID2(bid))
+ (CVMX_ADD_IO_SEG(0x00016F0000000000ull | (reg)) + CVMX_USBNXBID2(bid))
#define CVMX_USBNX_CLK_CTL(bid) CVMX_USBNXREG1(0x10, bid)
#define CVMX_USBNX_DMA0_INB_CHN0(bid) CVMX_USBNXREG2(0x818, bid)
--
2.10.2
next reply other threads:[~2016-12-01 14:58 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-12-01 14:58 Geert Custers [this message]
2016-12-01 15:11 ` Greg KH
2016-12-01 15:16 Geert Custers
2016-12-01 15:22 ` Greg KH
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=20161201145812.GA7521@GEERT_PC.localdomain \
--to=geert.aj.custers@gmail.com \
--cc=aaro.koskinen@iki.fi \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.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
all inboxes | Powered by JetHome®