- 20 1月, 2015 10 次提交
-
-
由 Frans Klaver 提交于
The function pointers for the timers and pm_power_off are assigned with C++ style foo = &func; Let's change it instead to the more C style foo = func; Signed-off-by: NFrans Klaver <frans.klaver@xsens.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Frans Klaver 提交于
ltc2952_poweroff_handler uses gotos to return from the function. Since we don't do cleanups exiting this function, just return IRQ_HANDLED on the spot and be done with it. While at it, remove the variable 'ret'. It was never used very much. Signed-off-by: NFrans Klaver <frans.klaver@xsens.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Frans Klaver 提交于
Documentation/SubmittingDrivers suggests these be implemented even when they do nothing. On the other hand, the platform code calls these functions 'legacy'. Suspend and resume operations should go into a pm_ops structure, pointed at by the driver's pm field. This approach would lead to a lot of boiler plate, while achieving nothing. Drop the functions instead. Signed-off-by: NFrans Klaver <frans.klaver@xsens.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Frans Klaver 提交于
As per Documentation/CodingStyle ch.4, we should keep global variables to a mininum. Move the panic state into the driver data, regardless of whether panic is a system state or not. This removes the need for the custom _init and _exit functions, so replace them with a call to the module_platform_driver() macro. Signed-off-by: NFrans Klaver <frans.klaver@xsens.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Frans Klaver 提交于
Documentation/CodingStyle ch.4 mentions in a side node that global variables should only be used if you really need them. Reduce the use of the global instance of ltc2952_poweroff so we may eventually remove it entirely. While at it, rename ltc2952_poweroff_data to ltc2952_poweroff, just to save that little bit of typing. Signed-off-by: NFrans Klaver <frans.klaver@xsens.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Frans Klaver 提交于
This reduces cleanup code and chance of errors. Signed-off-by: NFrans Klaver <frans.klaver@xsens.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Frans Klaver 提交于
The three gpio's used by this driver are stored in an array of pointers. This doesn't add much besides cleanups in a loop. In fact, it makes most of the usage sites harder to read. Unroll the loop, and live with the fact that cleanups become slightly larger. Signed-off-by: NFrans Klaver <frans.klaver@xsens.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Frans Klaver 提交于
Make use of the fact that we allocated resources can be automatically deallocated. This reduces cleanup code and chance of errors. It also removes the need for the virq member of the ltc2952_poweroff_data struct. Signed-off-by: NFrans Klaver <frans.klaver@xsens.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Frans Klaver 提交于
Make use of the fact that the allocated resources can be automatically deallocated. This reduces cleanup code and chance of leaks. Signed-off-by: NFrans Klaver <frans.klaver@xsens.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Linus Walleij 提交于
Augment the Versatile reset driver to also handle the core module reset sequence used on the Integrator/AP and Integrator/CP. Cc: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> Cc: David Woodhouse <dwmw2@infradead.org> Cc: Sebastian Reichel <sre@kernel.org> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 04 12月, 2014 1 次提交
-
-
由 Stefan Agner 提交于
Currently, all restart handler use the priority 128, including watchdogs. Probably most SoC have a watchdog, and some of them register it also as a restart handler. But if a SoC specifies a dedicated reboot capability using this syscon driver, this is usually the preferred reboot method. Hence, raise the priority of this driver to 192. Signed-off-by: NStefan Agner <stefan@agner.ch> Reviewed-by: NGuenter Roeck <linux@roeck-us.net> Acked-by: NMark Rutland <mark.rutland@arm.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 23 11月, 2014 1 次提交
-
-
由 Robin Gong 提交于
This driver register pm_power_off with snvs power off function. If your boards NOT use PMIC_ON_REQ to turn on/off external pmic, or use other pin to do, please disable the driver in dts, otherwise, your pm_power_off maybe overwrote by this driver. Signed-off-by: NRobin Gong <b38343@freescale.com> Acked-By: NSebastian Reichel <sre@kernel.org> Signed-off-by: NShawn Guo <shawn.guo@linaro.org>
-
- 17 11月, 2014 11 次提交
-
-
由 Guenter Roeck 提交于
Register with kernel restart handler instead of setting arm_pm_restart directly. Cc: Marc Carino <marc.ceeeee@gmail.com> Cc: Brian Norris <computersforpeace@gmail.com> Signed-off-by: NGuenter Roeck <linux@roeck-us.net>
-
由 Guenter Roeck 提交于
Register with kernel restart handler instead of setting arm_pm_restart directly. Cc: Haojian Zhuang <haojian.zhuang@linaro.org> Signed-off-by: NGuenter Roeck <linux@roeck-us.net>
-
由 Guenter Roeck 提交于
Register with kernel restart handler instead of setting arm_pm_restart directly. Move notifier registration to the end of the probe function to avoid having to implement error handling. Cc: Ivan Khoronzhuk <ivan.khoronzhuk@ti.com> Cc: Santosh Shilimkar <santosh.shilimkar@ti.com> Acked-by: NSantosh Shilimkar <santosh.shilimkar@ti.com> Tested-by: NIvan Khoronzhuk <ivan.khoronzhuk@ti.com> Signed-off-by: NGuenter Roeck <linux@roeck-us.net>
-
由 Guenter Roeck 提交于
Register with kernel restart handler instead of setting arm_pm_restart directly. Cc: Anders Berg <anders.berg@lsi.com> Tested-by: NAnders Berg <anders.berg@avagotech.com> Signed-off-by: NGuenter Roeck <linux@roeck-us.net>
-
由 Guenter Roeck 提交于
Register with kernel restart handler instead of setting arm_pm_restart directly. This patch also addresses the following compile warning. drivers/power/reset/xgene-reboot.c: In function 'xgene_reboot_probe': drivers/power/reset/xgene-reboot.c:77:17: warning: assignment from incompatible pointer type [enabled by default] The warning was due to a mismatch between the type of arm_pm_restart and the restart function. Cc: Loc Ho <lho@apm.com> Signed-off-by: NGuenter Roeck <linux@roeck-us.net>
-
由 Guenter Roeck 提交于
jiffies are not running at this stage of system shutdown, meaning an error in the reset function would never be reported. Replace with mdelay(). Cc: Loc Ho <lho@apm.com> Signed-off-by: NGuenter Roeck <linux@roeck-us.net>
-
由 Guenter Roeck 提交于
Using a local variable dev to point to the device is simpler then repeatedly dereferencing pdev->dev. Cc: Loc Ho <lho@apm.com> Signed-off-by: NGuenter Roeck <linux@roeck-us.net>
-
由 Guenter Roeck 提交于
Calling devm_kfree is unnecessary. Drop it. Cc: Loc Ho <lho@apm.com> Signed-off-by: NGuenter Roeck <linux@roeck-us.net>
-
由 Guenter Roeck 提交于
It is customary to return an error code of -ENOMEM if the system is out of memory. Also, in that case, the infrastructure will report an error, so it is unnecessary to report it again. Cc: Loc Ho <lho@apm.com> Signed-off-by: NGuenter Roeck <linux@roeck-us.net>
-
由 Guenter Roeck 提交于
Use the kernel restart handler instead of setting arm_pm_restart directly. This allows for more than one restart handler in the system. Signed-off-by: NGuenter Roeck <linux@roeck-us.net>
-
由 Robin Gong 提交于
This driver register pm_power_off with snvs power off function. If your boards NOT use PMIC_ON_REQ to turn on/off external pmic, or use other pin to do, please disable the driver in dts, otherwise, your pm_power_off maybe overwrote by this driver. Signed-off-by: NRobin Gong <b38343@freescale.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 13 11月, 2014 1 次提交
-
-
由 Alexandre Belloni 提交于
Move the (DDR) SDRAM controller headers to include/soc/at91 to remove the dependency on mach/ headers from the at91-reset driver. Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by: NNicolas Ferre <nicolas.ferre@atmel.com>
-
- 22 10月, 2014 1 次提交
-
-
由 Alexandre Belloni 提交于
In the case of at91sam9g45_restart(), the driver is writing AT91_DDRSDRC_LPCB_POWER_DOWN to AT91_DDRSDRC_RTR, this should actually be AT91_DDRSDRC_LPR. Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com> Acked-by: NSebastian Reichel <sre@kernel.org> Signed-off-by: NNicolas Ferre <nicolas.ferre@atmel.com>
-
- 20 10月, 2014 1 次提交
-
-
由 Wolfram Sang 提交于
A platform_driver does not need to set an owner, it will be populated by the driver core. Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
- 03 10月, 2014 1 次提交
-
-
由 Feng Kan 提交于
This patch is to fix some bugs in reboot driver. Which includes auto selection of the MFD_SYSCON for the driver, use of container to locate restart handler, correction of the count down failure timer and ordering of the header file. Signed-off-by: NFeng Kan <fkan@apm.com> Reviewed-by: NGuenter Roeck <linux@roeck-us.net> [ sre: return err instead of 0 in syscon_reboot_probe() ] Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 01 10月, 2014 1 次提交
-
-
由 Feng Kan 提交于
Add a generic SYSCON register mapped reset mechanism. Signed-off-by: NFeng Kan <fkan@apm.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 27 9月, 2014 2 次提交
-
-
由 Pramod Gurav 提交于
This change replaces use of arm_pm_restart with recently introduced reset mechanism in Linux kernel called restart_notifier. Choosing priority 128, which is default priority, as according to documentation, this mechanism is sufficient to restart the entire system. Cc: Guenter Roeck <linux@roeck-us.net> Cc: Josh Cartwright <joshc@codeaurora.org> Cc: Sebastian Reichel <sre@kernel.org> Cc: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> Cc: David Woodhouse <dwmw2@infradead.org> Cc: Stephen Boyd <sboyd@codeaurora.org> Cc: linux-pm@vger.kernel.org Reviewed-by: NGuenter Roeck <linux@roeck-us.net> Reviewed-by: NStephen Boyd <sboyd@codeaurora.org> Signed-off-by: NPramod Gurav <pramod.gurav@smartplayin.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 David Riley 提交于
This driver registers a restart handler to set a GPIO line high/low to reset a board based on devicetree bindings. Signed-off-by: NDavid Riley <davidriley@chromium.org> Reviewed-by: NGuenter Roeck <linux@roeck-us.net> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 26 9月, 2014 3 次提交
-
-
由 Lee Jones 提交于
This driver adds the restart functionality for STiH415 and STiH416 platforms from STMicroelectronics. This driver registers an arm_pm_restart function to reset the platform. Signed-off-by: NChristophe Kerello <christophe.kerello@st.com> Signed-off-by: NLee Jones <lee.jones@linaro.org> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Guenter Roeck 提交于
machine_restart is supported on non-ARM platforms, and and ultimately calls arm_pm_restart, so dont call arm_pm_restart directly but use the more generic function. Signed-off-by: NGuenter Roeck <linux@roeck-us.net> Acked-by: NCatalin Marinas <catalin.marinas@arm.com> Acked-by: NHeiko Stuebner <heiko@sntech.de> Cc: Russell King <linux@arm.linux.org.uk> Cc: Arnd Bergmann <arnd@arndb.de> Cc: David Woodhouse <dwmw2@infradead.org> Cc: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> Cc: Ingo Molnar <mingo@kernel.org> Cc: Jonas Jensen <jonas.jensen@gmail.com> Cc: Maxime Ripard <maxime.ripard@free-electrons.com> Cc: Randy Dunlap <rdunlap@infradead.org> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Tomasz Figa <t.figa@samsung.com> Cc: Will Deacon <will.deacon@arm.com> Cc: Wim Van Sebroeck <wim@iguana.be> Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
-
由 Linus Walleij 提交于
This driver enabled us to drive the reboot of the Versatile family of ARM reference boards. Even though only the RealView boards are supported initially, these boards all have the same procedure for reboot: - Write a magic value into an unlocking register - Write another magic value into a reset control register The driver will be reusable for Versatile and possibly also the Integrator family of reference boards. Cc: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> Cc: David Woodhouse <dwmw2@infradead.org> Acked-By: NSebastian Reichel <sre@kernel.org> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org> Signed-off-by: NArnd Bergmann <arnd@arndb.de>
-
- 16 9月, 2014 1 次提交
-
-
由 René Moll 提交于
This adds a driver for the LTC2952, an external power control chip, which signals the OS to shut down. Additionally this driver lets the kernel power down the board. Signed-off-by: NRené Moll <rene.moll@xsens.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 07 9月, 2014 1 次提交
-
-
由 Mark Brown 提交于
The xgene-reset driver uses xgene_restart() as arm_pm_restart() but that function should take an enum reset_type as the first argument rather than a char. Fix this; the paramter is not referenced in the implementation. Signed-off-by: NMark Brown <broonie@linaro.org> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 02 9月, 2014 2 次提交
-
-
由 Nicolas Ferre 提交于
The wakeup status is read from Shutdown Status Register and not the SHDW_CR which is the one at address 0. Signed-off-by: NNicolas Ferre <nicolas.ferre@atmel.com>
-
由 Nicolas Ferre 提交于
MACH_AT91 doesn't exist so we can't "depend" on it. Fix the typo by using the proper ARCH_AT91 config option. Signed-off-by: NNicolas Ferre <nicolas.ferre@atmel.com>
-
- 31 7月, 2014 1 次提交
-
-
由 Haojian Zhuang 提交于
Move reboot code from hisilicon platform driver into reset driver. Signed-off-by: NHaojian Zhuang <haojian.zhuang@linaro.org> Acked-by: NWei Xu <xuwei5@hisilicon.com> Signed-off-by: NOlof Johansson <olof@lixom.net>
-
- 23 7月, 2014 1 次提交
-
-
由 Marc Carino 提交于
Add support for reboot functionality on boards with ARM-based Broadcom STB chipsets. Make it built-in by default for ARCH_BRCMSTB, but allow it to be configurable under COMPILE_TEST. Signed-off-by: NMarc Carino <marc.ceeeee@gmail.com> Signed-off-by: NBrian Norris <computersforpeace@gmail.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 19 7月, 2014 1 次提交
-
-
由 Bjorn Helgaas 提交于
Per license_is_gpl_compatible(), the MODULE_LICENSE() string for GPL v2 is "GPL v2", not "GPLv2". Use "GPL v2" so this module doesn't taint the kernel. Signed-off-by: NBjorn Helgaas <bhelgaas@google.com> Acked-by: NAndrew Lunn <andrew@lunn.ch> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-