summaryrefslogtreecommitdiffstats
path: root/drivers/rtc/rtc-mcp795.c
diff options
context:
space:
mode:
authorEmil Bartczak <emilbart@gmail.com>2016-12-08 00:27:41 +0100
committerAlexandre Belloni <alexandre.belloni@free-electrons.com>2016-12-19 00:59:24 +0100
commita2b42997513401903341cf96616839ad22f151b6 (patch)
treeab88ba0efc82b2a452560a366f349ce5f45e7dfc /drivers/rtc/rtc-mcp795.c
parentrtc: mcp795: fix month write resetting date to 1. (diff)
downloadlinux-a2b42997513401903341cf96616839ad22f151b6.tar.xz
linux-a2b42997513401903341cf96616839ad22f151b6.zip
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@gmail.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com>
Diffstat (limited to 'drivers/rtc/rtc-mcp795.c')
-rw-r--r--drivers/rtc/rtc-mcp795.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/rtc/rtc-mcp795.c b/drivers/rtc/rtc-mcp795.c
index 89b0ffa83064..8ed55f6ff8ba 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)