netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] can: m_can: change comparison to bitshift when dealing with a mask
@ 2018-02-06  8:52 Wolfram Sang
  2018-02-08 14:39 ` Marc Kleine-Budde
  2018-02-08 14:42 ` Marc Kleine-Budde
  0 siblings, 2 replies; 3+ messages in thread
From: Wolfram Sang @ 2018-02-06  8:52 UTC (permalink / raw)
  To: linux-kernel
  Cc: linux-renesas-soc, Wolfram Sang, Wolfgang Grandegger,
	Marc Kleine-Budde, linux-can, netdev

Due to a typo, the mask was destroyed by a comparison instead of a bit
shift.

Reported-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
---
Only build tested.

 drivers/net/can/m_can/m_can.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/can/m_can/m_can.c b/drivers/net/can/m_can/m_can.c
index 2594f7779c6f14..74170b0d23cf1c 100644
--- a/drivers/net/can/m_can/m_can.c
+++ b/drivers/net/can/m_can/m_can.c
@@ -253,7 +253,7 @@ enum m_can_mram_cfg {
 
 /* Rx FIFO 0/1 Configuration (RXF0C/RXF1C) */
 #define RXFC_FWM_SHIFT	24
-#define RXFC_FWM_MASK	(0x7f < RXFC_FWM_SHIFT)
+#define RXFC_FWM_MASK	(0x7f << RXFC_FWM_SHIFT)
 #define RXFC_FS_SHIFT	16
 #define RXFC_FS_MASK	(0x7f << RXFC_FS_SHIFT)
 
-- 
2.11.0

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2018-02-08 14:42 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-02-06  8:52 [PATCH] can: m_can: change comparison to bitshift when dealing with a mask Wolfram Sang
2018-02-08 14:39 ` Marc Kleine-Budde
2018-02-08 14:42 ` Marc Kleine-Budde

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).