From: Tomasz Figa <tomasz.figa@gmail.com>
To: linux-arm-kernel@lists.infradead.org
Cc: linux-samsung-soc@vger.kernel.org,
"Kukjin Kim" <kgene.kim@samsung.com>,
"Sylwester Nawrocki" <sylvester.nawrocki@gmail.com>,
"Heiko Stübner" <heiko@sntech.de>,
"Wim Van Sebroeck" <wim@iguana.be>,
linux-watchdog@vger.kernel.org, jhbird.choi@samsung.com,
"Tomasz Figa" <tomasz.figa@gmail.com>
Subject: [PATCH 1/6] watchdog: s3c2410_wdt: Use local register definitions
Date: Sun, 19 May 2013 00:37:02 +0200 [thread overview]
Message-ID: <1368916627-23139-2-git-send-email-tomasz.figa@gmail.com> (raw)
In-Reply-To: <1368916627-23139-1-git-send-email-tomasz.figa@gmail.com>
This patch moves register and bitfield definitions to the driver itself,
removing remaining dependencies on plat/ and mach/ headers.
Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com>
---
drivers/watchdog/s3c2410_wdt.c | 17 +++++++++++++----
1 file changed, 13 insertions(+), 4 deletions(-)
diff --git a/drivers/watchdog/s3c2410_wdt.c b/drivers/watchdog/s3c2410_wdt.c
index ee03135..3a9f696 100644
--- a/drivers/watchdog/s3c2410_wdt.c
+++ b/drivers/watchdog/s3c2410_wdt.c
@@ -42,12 +42,21 @@
#include <linux/err.h>
#include <linux/of.h>
-#include <mach/map.h>
+#define S3C2410_WTCON 0x00
+#define S3C2410_WTDAT 0x04
+#define S3C2410_WTCNT 0x08
-#undef S3C_VA_WATCHDOG
-#define S3C_VA_WATCHDOG (0)
+#define S3C2410_WTCON_RSTEN (1 << 0)
+#define S3C2410_WTCON_INTEN (1 << 2)
+#define S3C2410_WTCON_ENABLE (1 << 5)
-#include <plat/regs-watchdog.h>
+#define S3C2410_WTCON_DIV16 (0 << 3)
+#define S3C2410_WTCON_DIV32 (1 << 3)
+#define S3C2410_WTCON_DIV64 (2 << 3)
+#define S3C2410_WTCON_DIV128 (3 << 3)
+
+#define S3C2410_WTCON_PRESCALE(x) ((x) << 8)
+#define S3C2410_WTCON_PRESCALE_MASK (0xff << 8)
#define CONFIG_S3C2410_WATCHDOG_ATBOOT (0)
#define CONFIG_S3C2410_WATCHDOG_DEFAULT_TIME (15)
--
1.8.2.1
next prev parent reply other threads:[~2013-05-18 22:37 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-05-18 22:37 [PATCH 0/6] Samsung watchdog support clean-up Tomasz Figa
2013-05-18 22:37 ` Tomasz Figa [this message]
2013-05-18 22:37 ` [PATCH 2/6] ARM: SAMSUNG: uncompress: Use local definitions of watchdog registers Tomasz Figa
2013-05-18 22:50 ` [PATCH v2 " Tomasz Figa
2013-05-18 22:37 ` [PATCH 3/6] ARM: SAMSUNG: Add watchdog reset driver Tomasz Figa
2013-05-18 22:37 ` [PATCH 4/6] ARM: SAMSUNG: Let platforms use the new " Tomasz Figa
2013-05-18 22:37 ` [PATCH 5/6] ARM: SAMSUNG: Remove legacy watchdog reset code Tomasz Figa
2013-05-18 22:37 ` [PATCH 6/6] ARM: SAMSUNG: Remove unused plat/regs-watchdog.h header Tomasz Figa
2013-06-01 8:16 ` [PATCH 0/6] Samsung watchdog support clean-up Sylwester Nawrocki
2013-06-03 12:49 ` Tomasz Figa
2013-06-04 9:37 ` Kukjin Kim
2013-06-04 9:45 ` Tomasz Figa
2013-06-10 10:00 ` Kukjin Kim
2013-06-13 19:11 ` Tomasz Figa
2013-06-13 23:22 ` Kukjin Kim
2013-06-13 23:25 ` Tomasz Figa
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=1368916627-23139-2-git-send-email-tomasz.figa@gmail.com \
--to=tomasz.figa@gmail.com \
--cc=heiko@sntech.de \
--cc=jhbird.choi@samsung.com \
--cc=kgene.kim@samsung.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-samsung-soc@vger.kernel.org \
--cc=linux-watchdog@vger.kernel.org \
--cc=sylvester.nawrocki@gmail.com \
--cc=wim@iguana.be \
/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).