LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* [PATCH 1/6] power/reset: arm-versatile: Register with kernel restart handler
@ 2015-01-25 18:13 Guenter Roeck
  2015-01-25 18:13 ` [PATCH 2/6] power/reset: at91: " Guenter Roeck
                   ` (5 more replies)
  0 siblings, 6 replies; 12+ messages in thread
From: Guenter Roeck @ 2015-01-25 18:13 UTC (permalink / raw)
  To: Sebastian Reichel
  Cc: linux-pm, Guenter Roeck, David Woodhouse,
	Dmitry Eremin-Solenikov, linux-kernel

Register with kernel restart handler instead of setting arm_pm_restart
directly. Select high priority since the restart handler is instantiated
through devicetree, indicating that it should be used if configured.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
---
 drivers/power/reset/arm-versatile-reboot.c | 17 ++++++++++++++---
 1 file changed, 14 insertions(+), 3 deletions(-)

diff --git a/drivers/power/reset/arm-versatile-reboot.c b/drivers/power/reset/arm-versatile-reboot.c
index 5b08bff..e533812 100644
--- a/drivers/power/reset/arm-versatile-reboot.c
+++ b/drivers/power/reset/arm-versatile-reboot.c
@@ -13,7 +13,6 @@
 #include <linux/reboot.h>
 #include <linux/regmap.h>
 #include <linux/of.h>
-#include <asm/system_misc.h>
 
 #define REALVIEW_SYS_LOCK_OFFSET	0x20
 #define REALVIEW_SYS_LOCK_VAL		0xA05F
@@ -57,7 +56,8 @@ static const struct of_device_id versatile_reboot_of_match[] = {
 	},
 };
 
-static void versatile_reboot(enum reboot_mode mode, const char *cmd)
+static int versatile_reboot(struct notifier_block *this, unsigned long mode,
+			    void *cmd)
 {
 	/* Unlock the reset register */
 	regmap_write(syscon_regmap, REALVIEW_SYS_LOCK_OFFSET,
@@ -87,12 +87,20 @@ static void versatile_reboot(enum reboot_mode mode, const char *cmd)
 		break;
 	}
 	dsb();
+
+	return NOTIFY_DONE;
 }
 
+static struct notifier_block versatile_reboot_nb = {
+	.notifier_call = versatile_reboot,
+	.priority = 192,
+};
+
 static int __init versatile_reboot_probe(void)
 {
 	const struct of_device_id *reboot_id;
 	struct device_node *np;
+	int err;
 
 	np = of_find_matching_node_and_match(NULL, versatile_reboot_of_match,
 						 &reboot_id);
@@ -104,7 +112,10 @@ static int __init versatile_reboot_probe(void)
 	if (IS_ERR(syscon_regmap))
 		return PTR_ERR(syscon_regmap);
 
-	arm_pm_restart = versatile_reboot;
+	err = register_restart_handler(&versatile_reboot_nb);
+	if (err)
+		return err;
+
 	pr_info("versatile reboot driver registered\n");
 	return 0;
 }
-- 
2.1.0


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

* [PATCH 2/6] power/reset: at91: Register with kernel restart handler
  2015-01-25 18:13 [PATCH 1/6] power/reset: arm-versatile: Register with kernel restart handler Guenter Roeck
@ 2015-01-25 18:13 ` Guenter Roeck
  2015-01-25 18:13 ` [PATCH 3/6] power/reset: Remove sun6i reboot driver Guenter Roeck
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 12+ messages in thread
From: Guenter Roeck @ 2015-01-25 18:13 UTC (permalink / raw)
  To: Sebastian Reichel
  Cc: linux-pm, Guenter Roeck, David Woodhouse,
	Dmitry Eremin-Solenikov, linux-kernel

Register with kernel restart handler instead of setting arm_pm_restart
directly. Register with high priority since the driver unconditionally
overwrites other restart handlers if instantiated.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
---
 drivers/power/reset/at91-reset.c | 28 ++++++++++++++++++----------
 1 file changed, 18 insertions(+), 10 deletions(-)

diff --git a/drivers/power/reset/at91-reset.c b/drivers/power/reset/at91-reset.c
index 69a75d99..13584e2 100644
--- a/drivers/power/reset/at91-reset.c
+++ b/drivers/power/reset/at91-reset.c
@@ -17,8 +17,6 @@
 #include <linux/platform_device.h>
 #include <linux/reboot.h>
 
-#include <asm/system_misc.h>
-
 #include <soc/at91/at91sam9_ddrsdr.h>
 #include <soc/at91/at91sam9_sdramc.h>
 
@@ -54,7 +52,8 @@ static void __iomem *at91_ramc_base[2], *at91_rstc_base;
 * reset register it can be left driving the data bus and
 * killing the chance of a subsequent boot from NAND
 */
-static void at91sam9260_restart(enum reboot_mode mode, const char *cmd)
+static int at91sam9260_restart(struct notifier_block *this, unsigned long mode,
+			       void *cmd)
 {
 	asm volatile(
 		/* Align to cache lines */
@@ -76,9 +75,12 @@ static void at91sam9260_restart(enum reboot_mode mode, const char *cmd)
 		  "r" (1),
 		  "r" (AT91_SDRAMC_LPCB_POWER_DOWN),
 		  "r" (AT91_RSTC_KEY | AT91_RSTC_PERRST | AT91_RSTC_PROCRST));
+
+	return NOTIFY_DONE;
 }
 
-static void at91sam9g45_restart(enum reboot_mode mode, const char *cmd)
+static int at91sam9g45_restart(struct notifier_block *this, unsigned long mode,
+			       void *cmd)
 {
 	asm volatile(
 		/*
@@ -117,6 +119,8 @@ static void at91sam9g45_restart(enum reboot_mode mode, const char *cmd)
 		  "r" (AT91_DDRSDRC_LPCB_POWER_DOWN),
 		  "r" (AT91_RSTC_KEY | AT91_RSTC_PERRST | AT91_RSTC_PROCRST)
 		: "r0");
+
+	return NOTIFY_DONE;
 }
 
 static void __init at91_reset_status(struct platform_device *pdev)
@@ -161,6 +165,10 @@ static struct of_device_id at91_reset_of_match[] = {
 	{ /* sentinel */ }
 };
 
+static struct notifier_block at91_restart_nb = {
+	.priority = 192,
+};
+
 static int at91_reset_of_probe(struct platform_device *pdev)
 {
 	const struct of_device_id *match;
@@ -183,9 +191,8 @@ static int at91_reset_of_probe(struct platform_device *pdev)
 	}
 
 	match = of_match_node(at91_reset_of_match, pdev->dev.of_node);
-	arm_pm_restart = match->data;
-
-	return 0;
+	at91_restart_nb.notifier_call = match->data;
+	return register_restart_handler(&at91_restart_nb);
 }
 
 static int at91_reset_platform_probe(struct platform_device *pdev)
@@ -212,10 +219,11 @@ static int at91_reset_platform_probe(struct platform_device *pdev)
 	}
 
 	match = platform_get_device_id(pdev);
-	arm_pm_restart = (void (*)(enum reboot_mode, const char*))
-		match->driver_data;
+	at91_restart_nb.notifier_call =
+		(int (*)(struct notifier_block *,
+			 unsigned long, void *)) match->driver_data;
 
-	return 0;
+	return register_restart_handler(&at91_restart_nb);
 }
 
 static int at91_reset_probe(struct platform_device *pdev)
-- 
2.1.0


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

* [PATCH 3/6] power/reset: Remove sun6i reboot driver
  2015-01-25 18:13 [PATCH 1/6] power/reset: arm-versatile: Register with kernel restart handler Guenter Roeck
  2015-01-25 18:13 ` [PATCH 2/6] power/reset: at91: " Guenter Roeck
@ 2015-01-25 18:13 ` Guenter Roeck
  2015-01-25 18:23   ` Maxime Ripard
  2015-01-25 18:13 ` [PATCH 4/6] power/reset: st-poweroff: Register with kernel restart handler Guenter Roeck
                   ` (3 subsequent siblings)
  5 siblings, 1 reply; 12+ messages in thread
From: Guenter Roeck @ 2015-01-25 18:13 UTC (permalink / raw)
  To: Sebastian Reichel
  Cc: linux-pm, Guenter Roeck, David Woodhouse,
	Dmitry Eremin-Solenikov, linux-arm-kernel, linux-kernel,
	Maxime Ripard

sun6i restart is now handled by its watchdog driver directly,
so this driver is no longer needed.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
---
 drivers/power/reset/Kconfig        |  6 ---
 drivers/power/reset/Makefile       |  1 -
 drivers/power/reset/sun6i-reboot.c | 85 --------------------------------------
 3 files changed, 92 deletions(-)
 delete mode 100644 drivers/power/reset/sun6i-reboot.c

diff --git a/drivers/power/reset/Kconfig b/drivers/power/reset/Kconfig
index 028e765..720a310 100644
--- a/drivers/power/reset/Kconfig
+++ b/drivers/power/reset/Kconfig
@@ -110,12 +110,6 @@ config POWER_RESET_RESTART
 	  Instead they restart, and u-boot holds the SoC until the
 	  user presses a key. u-boot then boots into Linux.
 
-config POWER_RESET_SUN6I
-	bool "Allwinner A31 SoC reset driver"
-	depends on ARCH_SUNXI
-	help
-	  Reboot support for the Allwinner A31 SoCs.
-
 config POWER_RESET_ST
 	bool "ST restart power-off driver"
 	depends on ARCH_STI
diff --git a/drivers/power/reset/Makefile b/drivers/power/reset/Makefile
index 1d4804d..2f5e549 100644
--- a/drivers/power/reset/Makefile
+++ b/drivers/power/reset/Makefile
@@ -11,7 +11,6 @@ obj-$(CONFIG_POWER_RESET_MSM) += msm-poweroff.o
 obj-$(CONFIG_POWER_RESET_LTC2952) += ltc2952-poweroff.o
 obj-$(CONFIG_POWER_RESET_QNAP) += qnap-poweroff.o
 obj-$(CONFIG_POWER_RESET_RESTART) += restart-poweroff.o
-obj-$(CONFIG_POWER_RESET_SUN6I) += sun6i-reboot.o
 obj-$(CONFIG_POWER_RESET_ST) += st-poweroff.o
 obj-$(CONFIG_POWER_RESET_VERSATILE) += arm-versatile-reboot.o
 obj-$(CONFIG_POWER_RESET_VEXPRESS) += vexpress-poweroff.o
diff --git a/drivers/power/reset/sun6i-reboot.c b/drivers/power/reset/sun6i-reboot.c
deleted file mode 100644
index af2cd7f..0000000
--- a/drivers/power/reset/sun6i-reboot.c
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- * Allwinner A31 SoCs reset code
- *
- * Copyright (C) 2012-2014 Maxime Ripard
- *
- * Maxime Ripard <maxime.ripard@free-electrons.com>
- *
- * This file is licensed under the terms of the GNU General Public
- * License version 2.  This program is licensed "as is" without any
- * warranty of any kind, whether express or implied.
- */
-
-#include <linux/delay.h>
-#include <linux/io.h>
-#include <linux/module.h>
-#include <linux/of_address.h>
-#include <linux/platform_device.h>
-#include <linux/reboot.h>
-
-#include <asm/system_misc.h>
-
-#define SUN6I_WATCHDOG1_IRQ_REG		0x00
-#define SUN6I_WATCHDOG1_CTRL_REG	0x10
-#define SUN6I_WATCHDOG1_CTRL_RESTART		BIT(0)
-#define SUN6I_WATCHDOG1_CONFIG_REG	0x14
-#define SUN6I_WATCHDOG1_CONFIG_RESTART		BIT(0)
-#define SUN6I_WATCHDOG1_CONFIG_IRQ		BIT(1)
-#define SUN6I_WATCHDOG1_MODE_REG	0x18
-#define SUN6I_WATCHDOG1_MODE_ENABLE		BIT(0)
-
-static void __iomem *wdt_base;
-
-static void sun6i_wdt_restart(enum reboot_mode mode, const char *cmd)
-{
-	if (!wdt_base)
-		return;
-
-	/* Disable interrupts */
-	writel(0, wdt_base + SUN6I_WATCHDOG1_IRQ_REG);
-
-	/* We want to disable the IRQ and just reset the whole system */
-	writel(SUN6I_WATCHDOG1_CONFIG_RESTART,
-		wdt_base + SUN6I_WATCHDOG1_CONFIG_REG);
-
-	/* Enable timer. The default and lowest interval value is 0.5s */
-	writel(SUN6I_WATCHDOG1_MODE_ENABLE,
-		wdt_base + SUN6I_WATCHDOG1_MODE_REG);
-
-	/* Restart the watchdog. */
-	writel(SUN6I_WATCHDOG1_CTRL_RESTART,
-		wdt_base + SUN6I_WATCHDOG1_CTRL_REG);
-
-	while (1) {
-		mdelay(5);
-		writel(SUN6I_WATCHDOG1_MODE_ENABLE,
-			wdt_base + SUN6I_WATCHDOG1_MODE_REG);
-	}
-}
-
-static int sun6i_reboot_probe(struct platform_device *pdev)
-{
-	wdt_base = of_iomap(pdev->dev.of_node, 0);
-	if (!wdt_base) {
-		WARN(1, "failed to map watchdog base address");
-		return -ENODEV;
-	}
-
-	arm_pm_restart = sun6i_wdt_restart;
-
-	return 0;
-}
-
-static struct of_device_id sun6i_reboot_of_match[] = {
-	{ .compatible = "allwinner,sun6i-a31-wdt" },
-	{}
-};
-
-static struct platform_driver sun6i_reboot_driver = {
-	.probe = sun6i_reboot_probe,
-	.driver = {
-		.name = "sun6i-reboot",
-		.of_match_table = sun6i_reboot_of_match,
-	},
-};
-module_platform_driver(sun6i_reboot_driver);
-- 
2.1.0


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

* [PATCH 4/6] power/reset: st-poweroff: Register with kernel restart handler
  2015-01-25 18:13 [PATCH 1/6] power/reset: arm-versatile: Register with kernel restart handler Guenter Roeck
  2015-01-25 18:13 ` [PATCH 2/6] power/reset: at91: " Guenter Roeck
  2015-01-25 18:13 ` [PATCH 3/6] power/reset: Remove sun6i reboot driver Guenter Roeck
@ 2015-01-25 18:13 ` Guenter Roeck
  2015-01-25 18:13 ` [PATCH 5/6] power/reset: st-poweroff: Fix misleading Kconfig description Guenter Roeck
                   ` (2 subsequent siblings)
  5 siblings, 0 replies; 12+ messages in thread
From: Guenter Roeck @ 2015-01-25 18:13 UTC (permalink / raw)
  To: Sebastian Reichel
  Cc: linux-pm, Guenter Roeck, David Woodhouse,
	Dmitry Eremin-Solenikov, linux-kernel

Register with kernel restart handler instead of setting arm_pm_restart
directly. Select high priority since the restart handler is instantiated
through devicetree, indicating that it should be used if configured.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
---
 drivers/power/reset/st-poweroff.c | 17 +++++++++++------
 1 file changed, 11 insertions(+), 6 deletions(-)

diff --git a/drivers/power/reset/st-poweroff.c b/drivers/power/reset/st-poweroff.c
index a0acf25..27383de 100644
--- a/drivers/power/reset/st-poweroff.c
+++ b/drivers/power/reset/st-poweroff.c
@@ -15,10 +15,9 @@
 #include <linux/of_platform.h>
 #include <linux/platform_device.h>
 #include <linux/mfd/syscon.h>
+#include <linux/reboot.h>
 #include <linux/regmap.h>
 
-#include <asm/system_misc.h>
-
 struct reset_syscfg {
 	struct regmap *regmap;
 	/* syscfg used for reset */
@@ -75,7 +74,8 @@ static struct reset_syscfg stid127_reset = {
 
 static struct reset_syscfg *st_restart_syscfg;
 
-static void st_restart(enum reboot_mode reboot_mode, const char *cmd)
+static int st_restart(struct notifier_block *this, unsigned long mode,
+		      void *cmd)
 {
 	/* reset syscfg updated */
 	regmap_update_bits(st_restart_syscfg->regmap,
@@ -88,8 +88,15 @@ static void st_restart(enum reboot_mode reboot_mode, const char *cmd)
 			   st_restart_syscfg->offset_rst_msk,
 			   st_restart_syscfg->mask_rst_msk,
 			   0);
+
+	return NOTIFY_DONE;
 }
 
+static struct notifier_block st_restart_nb = {
+	.notifier_call = st_restart,
+	.priority = 192,
+};
+
 static struct of_device_id st_reset_of_match[] = {
 	{
 		.compatible = "st,stih415-restart",
@@ -126,9 +133,7 @@ static int st_reset_probe(struct platform_device *pdev)
 		return PTR_ERR(st_restart_syscfg->regmap);
 	}
 
-	arm_pm_restart = st_restart;
-
-	return 0;
+	return register_restart_handler(&st_restart_nb);
 }
 
 static struct platform_driver st_reset_driver = {
-- 
2.1.0


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

* [PATCH 5/6] power/reset: st-poweroff: Fix misleading Kconfig description
  2015-01-25 18:13 [PATCH 1/6] power/reset: arm-versatile: Register with kernel restart handler Guenter Roeck
                   ` (2 preceding siblings ...)
  2015-01-25 18:13 ` [PATCH 4/6] power/reset: st-poweroff: Register with kernel restart handler Guenter Roeck
@ 2015-01-25 18:13 ` Guenter Roeck
  2015-01-25 18:13 ` [PATCH 6/6] power/reset: restart-poweroff: Remove arm dependencies Guenter Roeck
  2015-01-25 18:40 ` [PATCH 1/6] power/reset: arm-versatile: Register with kernel restart handler Sebastian Reichel
  5 siblings, 0 replies; 12+ messages in thread
From: Guenter Roeck @ 2015-01-25 18:13 UTC (permalink / raw)
  To: Sebastian Reichel
  Cc: linux-pm, Guenter Roeck, David Woodhouse,
	Dmitry Eremin-Solenikov, linux-kernel

The st-poweroff driver does not really power off the system
but resets it, so Kconfig should not claim that the driver
would handle power-off.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
---
 drivers/power/reset/Kconfig | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/power/reset/Kconfig b/drivers/power/reset/Kconfig
index 720a310..4b4b910 100644
--- a/drivers/power/reset/Kconfig
+++ b/drivers/power/reset/Kconfig
@@ -111,10 +111,10 @@ config POWER_RESET_RESTART
 	  user presses a key. u-boot then boots into Linux.
 
 config POWER_RESET_ST
-	bool "ST restart power-off driver"
+	bool "ST restart driver"
 	depends on ARCH_STI
 	help
-	  Power off and reset support for STMicroelectronics boards.
+	  Reset support for STMicroelectronics boards.
 
 config POWER_RESET_VERSATILE
 	bool "ARM Versatile family reboot driver"
-- 
2.1.0


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

* [PATCH 6/6] power/reset: restart-poweroff: Remove arm dependencies
  2015-01-25 18:13 [PATCH 1/6] power/reset: arm-versatile: Register with kernel restart handler Guenter Roeck
                   ` (3 preceding siblings ...)
  2015-01-25 18:13 ` [PATCH 5/6] power/reset: st-poweroff: Fix misleading Kconfig description Guenter Roeck
@ 2015-01-25 18:13 ` Guenter Roeck
  2015-01-25 18:40 ` [PATCH 1/6] power/reset: arm-versatile: Register with kernel restart handler Sebastian Reichel
  5 siblings, 0 replies; 12+ messages in thread
From: Guenter Roeck @ 2015-01-25 18:13 UTC (permalink / raw)
  To: Sebastian Reichel
  Cc: linux-pm, Guenter Roeck, David Woodhouse,
	Dmitry Eremin-Solenikov, linux-kernel

This driver is now arm specific anymore, so there is no need to include
an arm specific include file. Also drop unnecessary depencency on ARM
from Kconfig.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
---
 drivers/power/reset/Kconfig            | 1 -
 drivers/power/reset/restart-poweroff.c | 1 -
 2 files changed, 2 deletions(-)

diff --git a/drivers/power/reset/Kconfig b/drivers/power/reset/Kconfig
index 4b4b910..a4fd2cb 100644
--- a/drivers/power/reset/Kconfig
+++ b/drivers/power/reset/Kconfig
@@ -104,7 +104,6 @@ config POWER_RESET_QNAP
 
 config POWER_RESET_RESTART
 	bool "Restart power-off driver"
-	depends on ARM
 	help
 	  Some boards don't actually have the ability to power off.
 	  Instead they restart, and u-boot holds the SoC until the
diff --git a/drivers/power/reset/restart-poweroff.c b/drivers/power/reset/restart-poweroff.c
index f46f2c2..41b22c4 100644
--- a/drivers/power/reset/restart-poweroff.c
+++ b/drivers/power/reset/restart-poweroff.c
@@ -16,7 +16,6 @@
 #include <linux/of_platform.h>
 #include <linux/module.h>
 #include <linux/reboot.h>
-#include <asm/system_misc.h>
 
 static void restart_poweroff_do_poweroff(void)
 {
-- 
2.1.0


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

* Re: [PATCH 3/6] power/reset: Remove sun6i reboot driver
  2015-01-25 18:13 ` [PATCH 3/6] power/reset: Remove sun6i reboot driver Guenter Roeck
@ 2015-01-25 18:23   ` Maxime Ripard
  0 siblings, 0 replies; 12+ messages in thread
From: Maxime Ripard @ 2015-01-25 18:23 UTC (permalink / raw)
  To: Guenter Roeck
  Cc: Sebastian Reichel, linux-pm, David Woodhouse,
	Dmitry Eremin-Solenikov, linux-arm-kernel, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 419 bytes --]

On Sun, Jan 25, 2015 at 10:13:39AM -0800, Guenter Roeck wrote:
> sun6i restart is now handled by its watchdog driver directly,
> so this driver is no longer needed.
> 
> Signed-off-by: Guenter Roeck <linux@roeck-us.net>

Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com>

Thanks!
Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

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

* Re: [PATCH 1/6] power/reset: arm-versatile: Register with kernel restart handler
  2015-01-25 18:13 [PATCH 1/6] power/reset: arm-versatile: Register with kernel restart handler Guenter Roeck
                   ` (4 preceding siblings ...)
  2015-01-25 18:13 ` [PATCH 6/6] power/reset: restart-poweroff: Remove arm dependencies Guenter Roeck
@ 2015-01-25 18:40 ` Sebastian Reichel
  2015-01-25 19:07   ` Guenter Roeck
  5 siblings, 1 reply; 12+ messages in thread
From: Sebastian Reichel @ 2015-01-25 18:40 UTC (permalink / raw)
  To: Guenter Roeck
  Cc: linux-pm, David Woodhouse, Dmitry Eremin-Solenikov, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 416 bytes --]

Hi,

On Sun, Jan 25, 2015 at 10:13:37AM -0800, Guenter Roeck wrote:
> Register with kernel restart handler instead of setting arm_pm_restart
> directly. Select high priority since the restart handler is instantiated
> through devicetree, indicating that it should be used if configured.

This does not apply clean for me. Please rebase on top of 

http://git.infradead.org/battery-2.6.git/

-- Sebastian

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

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

* Re: [PATCH 1/6] power/reset: arm-versatile: Register with kernel restart handler
  2015-01-25 18:40 ` [PATCH 1/6] power/reset: arm-versatile: Register with kernel restart handler Sebastian Reichel
@ 2015-01-25 19:07   ` Guenter Roeck
  2015-01-25 20:06     ` Sebastian Reichel
  0 siblings, 1 reply; 12+ messages in thread
From: Guenter Roeck @ 2015-01-25 19:07 UTC (permalink / raw)
  To: Sebastian Reichel
  Cc: linux-pm, David Woodhouse, Dmitry Eremin-Solenikov, linux-kernel

On 01/25/2015 10:40 AM, Sebastian Reichel wrote:
> Hi,
>
> On Sun, Jan 25, 2015 at 10:13:37AM -0800, Guenter Roeck wrote:
>> Register with kernel restart handler instead of setting arm_pm_restart
>> directly. Select high priority since the restart handler is instantiated
>> through devicetree, indicating that it should be used if configured.
>
> This does not apply clean for me. Please rebase on top of
>
> http://git.infradead.org/battery-2.6.git/
>

Hi Sebastian,

Sure, will do. I assume you mean battery/next-next since it applies cleanly
to battery/master.

Thanks,
Guenter


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

* Re: [PATCH 1/6] power/reset: arm-versatile: Register with kernel restart handler
  2015-01-25 19:07   ` Guenter Roeck
@ 2015-01-25 20:06     ` Sebastian Reichel
  2015-01-25 20:15       ` Guenter Roeck
  0 siblings, 1 reply; 12+ messages in thread
From: Sebastian Reichel @ 2015-01-25 20:06 UTC (permalink / raw)
  To: Guenter Roeck
  Cc: linux-pm, David Woodhouse, Dmitry Eremin-Solenikov, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 2200 bytes --]

Hi Guenter,

On Sun, Jan 25, 2015 at 11:07:16AM -0800, Guenter Roeck wrote:
> On 01/25/2015 10:40 AM, Sebastian Reichel wrote:
> >On Sun, Jan 25, 2015 at 10:13:37AM -0800, Guenter Roeck wrote:
> >>Register with kernel restart handler instead of setting arm_pm_restart
> >>directly. Select high priority since the restart handler is instantiated
> >>through devicetree, indicating that it should be used if configured.
> >
> >This does not apply clean for me. Please rebase on top of
> >
> >http://git.infradead.org/battery-2.6.git/
> 
> Sure, will do. I assume you mean battery/next-next since it applies cleanly
> to battery/master.

uhm no, I was talking about battery/master.
It does not apply cleanly for me:

Applying: power/reset: arm-versatile: Register with kernel restart handler
error: patch failed: drivers/power/reset/arm-versatile-reboot.c:13
error: drivers/power/reset/arm-versatile-reboot.c: patch does not apply

The error looks correct:

$ grep -A8 "+++ b/drivers/power/reset/arm-versatile-reboot.c" guenter_roeck.patch
+++ b/drivers/power/reset/arm-versatile-reboot.c
@@ -13,7 +13,6 @@
 #include <linux/reboot.h>
 #include <linux/regmap.h>
 #include <linux/of.h>
-#include <asm/system_misc.h>
 
 #define REALVIEW_SYS_LOCK_OFFSET   0x20
 #define REALVIEW_SYS_LOCK_VAL      0xA05F
$ git blame -L13,20 drivers/power/reset/arm-versatile-reboot.c
0e545f57 (Linus Walleij 2014-05-22 10:20:38 +0200 13) #include <linux/reboot.h>
0e545f57 (Linus Walleij 2014-05-22 10:20:38 +0200 14) #include <linux/regmap.h>
0e545f57 (Linus Walleij 2014-05-22 10:20:38 +0200 15) #include <linux/of.h>
0e545f57 (Linus Walleij 2014-05-22 10:20:38 +0200 16) #include <asm/system_misc.h>
0e545f57 (Linus Walleij 2014-05-22 10:20:38 +0200 17) 
0160817d (Linus Walleij 2014-12-19 16:56:27 +0100 18) #define INTEGRATOR_HDR_CTRL_OFFSET        0x0C
0160817d (Linus Walleij 2014-12-19 16:56:27 +0100 19) #define INTEGRATOR_HDR_LOCK_OFFSET        0x14
0160817d (Linus Walleij 2014-12-19 16:56:27 +0100 20) #define INTEGRATOR_CM_CTRL_RESET  (1 << 3)
$ git show -s --format=%ci 0160817d
2015-01-20 13:58:27 +0100

Maybe update the battery/master branch?

-- Sebastian

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

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

* Re: [PATCH 1/6] power/reset: arm-versatile: Register with kernel restart handler
  2015-01-25 20:06     ` Sebastian Reichel
@ 2015-01-25 20:15       ` Guenter Roeck
  2015-01-25 20:31         ` Guenter Roeck
  0 siblings, 1 reply; 12+ messages in thread
From: Guenter Roeck @ 2015-01-25 20:15 UTC (permalink / raw)
  To: Sebastian Reichel
  Cc: linux-pm, David Woodhouse, Dmitry Eremin-Solenikov, linux-kernel

Hi Sebastian,

On 01/25/2015 12:06 PM, Sebastian Reichel wrote:
>
> Maybe update the battery/master branch?
>

I thought I did. Tip is "99a7956 power: ds2782_battery: Simplify the PM hooks"

Does that look correct ?

Guenter


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

* Re: [PATCH 1/6] power/reset: arm-versatile: Register with kernel restart handler
  2015-01-25 20:15       ` Guenter Roeck
@ 2015-01-25 20:31         ` Guenter Roeck
  0 siblings, 0 replies; 12+ messages in thread
From: Guenter Roeck @ 2015-01-25 20:31 UTC (permalink / raw)
  To: Sebastian Reichel
  Cc: linux-pm, David Woodhouse, Dmitry Eremin-Solenikov, linux-kernel

On 01/25/2015 12:15 PM, Guenter Roeck wrote:
> Hi Sebastian,
>
> On 01/25/2015 12:06 PM, Sebastian Reichel wrote:
>>
>> Maybe update the battery/master branch?
>>
>
> I thought I did. Tip is "99a7956 power: ds2782_battery: Simplify the PM hooks"
>
> Does that look correct ?
>
Never mind, that was -next. I just resent the series, rebased on top of battery/master.

Guenter


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

end of thread, other threads:[~2015-01-25 20:31 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-01-25 18:13 [PATCH 1/6] power/reset: arm-versatile: Register with kernel restart handler Guenter Roeck
2015-01-25 18:13 ` [PATCH 2/6] power/reset: at91: " Guenter Roeck
2015-01-25 18:13 ` [PATCH 3/6] power/reset: Remove sun6i reboot driver Guenter Roeck
2015-01-25 18:23   ` Maxime Ripard
2015-01-25 18:13 ` [PATCH 4/6] power/reset: st-poweroff: Register with kernel restart handler Guenter Roeck
2015-01-25 18:13 ` [PATCH 5/6] power/reset: st-poweroff: Fix misleading Kconfig description Guenter Roeck
2015-01-25 18:13 ` [PATCH 6/6] power/reset: restart-poweroff: Remove arm dependencies Guenter Roeck
2015-01-25 18:40 ` [PATCH 1/6] power/reset: arm-versatile: Register with kernel restart handler Sebastian Reichel
2015-01-25 19:07   ` Guenter Roeck
2015-01-25 20:06     ` Sebastian Reichel
2015-01-25 20:15       ` Guenter Roeck
2015-01-25 20:31         ` Guenter Roeck

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