From: sassmann@kpanic.de (Stefan Assmann)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 1/2] mfd: twl-core: move TWL6030 defines to twl.h
Date: Wed, 30 Jul 2014 16:02:28 +0200 [thread overview]
Message-ID: <1406728949-7560-2-git-send-email-sassmann@kpanic.de> (raw)
In-Reply-To: <1406728949-7560-1-git-send-email-sassmann@kpanic.de>
These defines should be available to all drivers. Also added register
offset for CLK32KG_CFG_STATE and GRP defines.
Signed-off-by: Stefan Assmann <sassmann@kpanic.de>
---
drivers/regulator/twl-regulator.c | 11 -----------
include/linux/i2c/twl.h | 20 ++++++++++++++++++++
2 files changed, 20 insertions(+), 11 deletions(-)
diff --git a/drivers/regulator/twl-regulator.c b/drivers/regulator/twl-regulator.c
index fed28ab..ad0dd22 100644
--- a/drivers/regulator/twl-regulator.c
+++ b/drivers/regulator/twl-regulator.c
@@ -94,17 +94,6 @@ struct twlreg_info {
#define VREG_BC_PROC 3
#define VREG_BC_CLK_RST 4
-/* TWL6030 LDO register values for CFG_STATE */
-#define TWL6030_CFG_STATE_OFF 0x00
-#define TWL6030_CFG_STATE_ON 0x01
-#define TWL6030_CFG_STATE_OFF2 0x02
-#define TWL6030_CFG_STATE_SLEEP 0x03
-#define TWL6030_CFG_STATE_GRP_SHIFT 5
-#define TWL6030_CFG_STATE_APP_SHIFT 2
-#define TWL6030_CFG_STATE_APP_MASK (0x03 << TWL6030_CFG_STATE_APP_SHIFT)
-#define TWL6030_CFG_STATE_APP(v) (((v) & TWL6030_CFG_STATE_APP_MASK) >>\
- TWL6030_CFG_STATE_APP_SHIFT)
-
/* Flags for SMPS Voltage reading */
#define SMPS_OFFSET_EN BIT(0)
#define SMPS_EXTENDED_EN BIT(1)
diff --git a/include/linux/i2c/twl.h b/include/linux/i2c/twl.h
index 8cfb50f..8ad63a2 100644
--- a/include/linux/i2c/twl.h
+++ b/include/linux/i2c/twl.h
@@ -127,6 +127,20 @@ enum twl6030_module_ids {
#define REG_INT_MSK_STS_B 0x07
#define REG_INT_MSK_STS_C 0x08
+/* TWL6030 register values for CFG_STATE */
+#define TWL6030_GRP_APP (1 << 0)
+#define TWL6030_GRP_CON (1 << 1)
+#define TWL6030_GRP_MOD (1 << 2)
+#define TWL6030_CFG_STATE_OFF 0x00
+#define TWL6030_CFG_STATE_ON 0x01
+#define TWL6030_CFG_STATE_OFF2 0x02
+#define TWL6030_CFG_STATE_SLEEP 0x03
+#define TWL6030_CFG_STATE_GRP_SHIFT 5
+#define TWL6030_CFG_STATE_APP_SHIFT 2
+#define TWL6030_CFG_STATE_APP_MASK (0x03 << TWL6030_CFG_STATE_APP_SHIFT)
+#define TWL6030_CFG_STATE_APP(v) (((v) & TWL6030_CFG_STATE_APP_MASK) >>\
+ TWL6030_CFG_STATE_APP_SHIFT)
+
/* MASK INT REG GROUP A */
#define TWL6030_PWR_INT_MASK 0x07
#define TWL6030_RTC_INT_MASK 0x18
@@ -470,6 +484,12 @@ static inline int twl6030_mmc_card_detect(struct device *dev, int slot)
#define TWL4030_PM_MASTER_GLOBAL_TST 0xb6
+/*
+ * PM Receiver module register offsets (use TWL_MODULE_PM_RECEIVER)
+ */
+
+#define TWL6030_PM_RECEIVER_CLK32KG_CFG_STATE 0x8e
+
/*----------------------------------------------------------------------*/
/* Power bus message definitions */
--
1.9.3
WARNING: multiple messages have this Message-ID (diff)
From: Stefan Assmann <sassmann-llIHtaV5axyzQB+pC5nmwQ@public.gmane.org>
To: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
Cc: devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org,
mturquette-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org,
robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org,
pawel.moll-5wv7dgnIgG8@public.gmane.org,
peter.ujfalusi-l0cyMroinI0@public.gmane.org,
t-kristo-l0cyMroinI0@public.gmane.org,
sassmann-llIHtaV5axyzQB+pC5nmwQ@public.gmane.org
Subject: [PATCH 1/2] mfd: twl-core: move TWL6030 defines to twl.h
Date: Wed, 30 Jul 2014 16:02:28 +0200 [thread overview]
Message-ID: <1406728949-7560-2-git-send-email-sassmann@kpanic.de> (raw)
In-Reply-To: <1406728949-7560-1-git-send-email-sassmann-llIHtaV5axyzQB+pC5nmwQ@public.gmane.org>
These defines should be available to all drivers. Also added register
offset for CLK32KG_CFG_STATE and GRP defines.
Signed-off-by: Stefan Assmann <sassmann-llIHtaV5axyzQB+pC5nmwQ@public.gmane.org>
---
drivers/regulator/twl-regulator.c | 11 -----------
include/linux/i2c/twl.h | 20 ++++++++++++++++++++
2 files changed, 20 insertions(+), 11 deletions(-)
diff --git a/drivers/regulator/twl-regulator.c b/drivers/regulator/twl-regulator.c
index fed28ab..ad0dd22 100644
--- a/drivers/regulator/twl-regulator.c
+++ b/drivers/regulator/twl-regulator.c
@@ -94,17 +94,6 @@ struct twlreg_info {
#define VREG_BC_PROC 3
#define VREG_BC_CLK_RST 4
-/* TWL6030 LDO register values for CFG_STATE */
-#define TWL6030_CFG_STATE_OFF 0x00
-#define TWL6030_CFG_STATE_ON 0x01
-#define TWL6030_CFG_STATE_OFF2 0x02
-#define TWL6030_CFG_STATE_SLEEP 0x03
-#define TWL6030_CFG_STATE_GRP_SHIFT 5
-#define TWL6030_CFG_STATE_APP_SHIFT 2
-#define TWL6030_CFG_STATE_APP_MASK (0x03 << TWL6030_CFG_STATE_APP_SHIFT)
-#define TWL6030_CFG_STATE_APP(v) (((v) & TWL6030_CFG_STATE_APP_MASK) >>\
- TWL6030_CFG_STATE_APP_SHIFT)
-
/* Flags for SMPS Voltage reading */
#define SMPS_OFFSET_EN BIT(0)
#define SMPS_EXTENDED_EN BIT(1)
diff --git a/include/linux/i2c/twl.h b/include/linux/i2c/twl.h
index 8cfb50f..8ad63a2 100644
--- a/include/linux/i2c/twl.h
+++ b/include/linux/i2c/twl.h
@@ -127,6 +127,20 @@ enum twl6030_module_ids {
#define REG_INT_MSK_STS_B 0x07
#define REG_INT_MSK_STS_C 0x08
+/* TWL6030 register values for CFG_STATE */
+#define TWL6030_GRP_APP (1 << 0)
+#define TWL6030_GRP_CON (1 << 1)
+#define TWL6030_GRP_MOD (1 << 2)
+#define TWL6030_CFG_STATE_OFF 0x00
+#define TWL6030_CFG_STATE_ON 0x01
+#define TWL6030_CFG_STATE_OFF2 0x02
+#define TWL6030_CFG_STATE_SLEEP 0x03
+#define TWL6030_CFG_STATE_GRP_SHIFT 5
+#define TWL6030_CFG_STATE_APP_SHIFT 2
+#define TWL6030_CFG_STATE_APP_MASK (0x03 << TWL6030_CFG_STATE_APP_SHIFT)
+#define TWL6030_CFG_STATE_APP(v) (((v) & TWL6030_CFG_STATE_APP_MASK) >>\
+ TWL6030_CFG_STATE_APP_SHIFT)
+
/* MASK INT REG GROUP A */
#define TWL6030_PWR_INT_MASK 0x07
#define TWL6030_RTC_INT_MASK 0x18
@@ -470,6 +484,12 @@ static inline int twl6030_mmc_card_detect(struct device *dev, int slot)
#define TWL4030_PM_MASTER_GLOBAL_TST 0xb6
+/*
+ * PM Receiver module register offsets (use TWL_MODULE_PM_RECEIVER)
+ */
+
+#define TWL6030_PM_RECEIVER_CLK32KG_CFG_STATE 0x8e
+
/*----------------------------------------------------------------------*/
/* Power bus message definitions */
--
1.9.3
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2014-07-30 14:02 UTC|newest]
Thread overview: 44+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-30 14:02 [PATCH 0/2] Enable wifi on pandaboard Stefan Assmann
2014-07-30 14:02 ` Stefan Assmann
2014-07-30 14:02 ` Stefan Assmann [this message]
2014-07-30 14:02 ` [PATCH 1/2] mfd: twl-core: move TWL6030 defines to twl.h Stefan Assmann
2014-07-31 8:36 ` Lee Jones
2014-07-31 8:36 ` Lee Jones
2014-07-31 8:46 ` Stefan Assmann
2014-07-31 8:46 ` Stefan Assmann
2014-07-30 14:02 ` [PATCH 2/2] clk: initial clock driver for TWL6030 Stefan Assmann
2014-07-30 14:02 ` Stefan Assmann
2014-07-30 14:29 ` Andreas Färber
2014-07-30 14:29 ` Andreas Färber
2014-07-30 14:36 ` Stefan Assmann
2014-07-30 14:36 ` Stefan Assmann
2014-07-30 17:50 ` Mark Brown
2014-07-30 17:50 ` Mark Brown
2014-07-31 9:56 ` Stefan Assmann
2014-07-31 9:56 ` Stefan Assmann
2014-07-31 11:05 ` Mark Brown
2014-07-31 11:05 ` Mark Brown
2014-07-31 12:04 ` Stefan Assmann
2014-07-31 12:04 ` Stefan Assmann
2014-07-31 19:14 ` Mike Turquette
2014-07-31 19:14 ` Mike Turquette
2014-07-31 11:28 ` Tero Kristo
2014-07-31 11:28 ` Tero Kristo
2014-07-31 11:58 ` Stefan Assmann
2014-07-31 11:58 ` Stefan Assmann
2014-07-31 13:16 ` Tero Kristo
2014-07-31 13:16 ` Tero Kristo
2014-07-31 12:26 ` Peter Ujfalusi
2014-07-31 12:26 ` Peter Ujfalusi
2014-07-31 12:54 ` Stefan Assmann
2014-07-31 12:54 ` Stefan Assmann
2014-07-31 12:58 ` Peter Ujfalusi
2014-07-31 12:58 ` Peter Ujfalusi
2014-07-31 14:05 ` Stefan Assmann
2014-07-31 14:05 ` Stefan Assmann
2014-07-31 19:20 ` Mike Turquette
2014-07-31 19:20 ` Mike Turquette
2014-08-01 10:04 ` Stefan Assmann
2014-08-01 10:04 ` Stefan Assmann
2014-08-01 10:38 ` Mark Brown
2014-08-01 10:38 ` Mark Brown
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=1406728949-7560-2-git-send-email-sassmann@kpanic.de \
--to=sassmann@kpanic.de \
--cc=linux-arm-kernel@lists.infradead.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.