lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Thu,  8 Dec 2016 00:27:41 +0100
From:   Emil Bartczak <emilbart@...il.com>
To:     a.zummo@...ertech.it
Cc:     alexandre.belloni@...e-electrons.com, rtc-linux@...glegroups.com,
        linux-kernel@...r.kernel.org, Emil Bartczak <emilbart@...il.com>
Subject: [PATCH v2 5/6] rtc: mcp795: Prefer using the BIT() macro.

This patch doesn't change the code but replaces all bitmask values
with the BIT(x) macro.

Signed-off-by: Emil Bartczak <emilbart@...il.com>
---
 drivers/rtc/rtc-mcp795.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/rtc/rtc-mcp795.c b/drivers/rtc/rtc-mcp795.c
index 89b0ffa..8ed55f6 100644
--- a/drivers/rtc/rtc-mcp795.c
+++ b/drivers/rtc/rtc-mcp795.c
@@ -45,8 +45,8 @@
 #define MCP795_REG_MONTH	0x06
 #define MCP795_REG_CONTROL	0x08
 
-#define MCP795_ST_BIT	0x80
-#define MCP795_24_BIT	0x40
+#define MCP795_ST_BIT	BIT(7)
+#define MCP795_24_BIT	BIT(6)
 #define MCP795_LP_BIT	BIT(5)
 #define MCP795_EXTOSC_BIT	BIT(3)
 #define MCP795_OSCON_BIT	BIT(5)
-- 
2.7.4

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ