From: Alim Akhtar <alim.akhtar@samsung.com>
To: Krzysztof Kozlowski <k.kozlowski@samsung.com>,
linux-samsung-soc@vger.kernel.org
Cc: kgene@kernel.org, javier@osg.samsung.com,
devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH 7/7] ARM: EXYNOS: Remove code for restart and poweroff for exynos SoCs
Date: Mon, 19 Oct 2015 13:57:15 +0530 [thread overview]
Message-ID: <5624A963.6000201@samsung.com> (raw)
In-Reply-To: <562494F8.6070003@samsung.com>
Hello Krzysztof,
On 10/19/2015 12:30 PM, Krzysztof Kozlowski wrote:
> On 19.10.2015 15:03, Alim Akhtar wrote:
>> Now we can use the generic syscon-{reboot/poweroff} drivers,
>> so we don't need special handling for reboot/poweroff in
>> exynos pmu driver. This patch remove the same.
>>
>> Signed-off-by: Alim Akhtar <alim.akhtar@samsung.com>
>> ---
>> arch/arm/mach-exynos/pmu.c | 43 -------------------------------------------
>> 1 file changed, 43 deletions(-)
>
> I think that removal of this stuff will effectively remove the
> restart/poweroff handlers from:
> 1. Other defconfigs, like multi_v7
> 2. Custom configs.
>
Well, I did have a plan to enable it on multi_v7
Not sure about other custom configs, if there are some, they should also
enable it I feel.
> Previously this code was always compiled in for ARCH_EXYNOS. Now it is
> not so I am thinking about selecting necessary drivers from main exynos
> Kconfig symbol. That could be tricky though, because "select" should be
> used only for non-visible symbols.
>
Probably adding these to mach-exynos/Kconfig as a "select" will do.
> Any ideas how to solve that?
>
> Best regards,
> Krzysztof
>
>>
>> diff --git a/arch/arm/mach-exynos/pmu.c b/arch/arm/mach-exynos/pmu.c
>> index de68938ee6aa..393c04aa727e 100644
>> --- a/arch/arm/mach-exynos/pmu.c
>> +++ b/arch/arm/mach-exynos/pmu.c
>> @@ -14,9 +14,6 @@
>> #include <linux/of_address.h>
>> #include <linux/platform_device.h>
>> #include <linux/delay.h>
>> -#include <linux/notifier.h>
>> -#include <linux/reboot.h>
>> -
>>
>> #include "exynos-pmu.h"
>> #include "regs-pmu.h"
>> @@ -681,23 +678,6 @@ static unsigned int const exynos5420_list_disable_pmu_reg[] = {
>> EXYNOS5420_CMU_RESET_FSYS_SYS_PWR_REG,
>> };
>>
>> -static void exynos_power_off(void)
>> -{
>> - unsigned int tmp;
>> -
>> - pr_info("Power down.\n");
>> - tmp = pmu_raw_readl(EXYNOS_PS_HOLD_CONTROL);
>> - tmp ^= (1 << 8);
>> - pmu_raw_writel(tmp, EXYNOS_PS_HOLD_CONTROL);
>> -
>> - /* Wait a little so we don't give a false warning below */
>> - mdelay(100);
>> -
>> - pr_err("Power down failed, please power off system manually.\n");
>> - while (1)
>> - ;
>> -}
>> -
>> static void exynos5420_powerdown_conf(enum sys_powerdown mode)
>> {
>> u32 this_cluster;
>> @@ -875,14 +855,6 @@ static void exynos5420_pmu_init(void)
>> pr_info("EXYNOS5420 PMU initialized\n");
>> }
>>
>> -static int pmu_restart_notify(struct notifier_block *this,
>> - unsigned long code, void *unused)
>> -{
>> - pmu_raw_writel(0x1, EXYNOS_SWRESET);
>> -
>> - return NOTIFY_DONE;
>> -}
>> -
>> static const struct exynos_pmu_data exynos3250_pmu_data = {
>> .pmu_config = exynos3250_pmu_config,
>> .pmu_init = exynos3250_pmu_init,
>> @@ -940,20 +912,11 @@ static const struct of_device_id exynos_pmu_of_device_ids[] = {
>> { /*sentinel*/ },
>> };
>>
>> -/*
>> - * Exynos PMU restart notifier, handles restart functionality
>> - */
>> -static struct notifier_block pmu_restart_handler = {
>> - .notifier_call = pmu_restart_notify,
>> - .priority = 128,
>> -};
>> -
>> static int exynos_pmu_probe(struct platform_device *pdev)
>> {
>> const struct of_device_id *match;
>> struct device *dev = &pdev->dev;
>> struct resource *res;
>> - int ret;
>>
>> res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
>> pmu_base_addr = devm_ioremap_resource(dev, res);
>> @@ -978,12 +941,6 @@ static int exynos_pmu_probe(struct platform_device *pdev)
>>
>> platform_set_drvdata(pdev, pmu_context);
>>
>> - ret = register_restart_handler(&pmu_restart_handler);
>> - if (ret)
>> - dev_warn(dev, "can't register restart handler err=%d\n", ret);
>> -
>> - pm_power_off = exynos_power_off;
>> -
>> dev_dbg(dev, "Exynos PMU Driver probe done\n");
>> return 0;
>> }
>>
>
>
next prev parent reply other threads:[~2015-10-19 8:27 UTC|newest]
Thread overview: 38+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-19 6:03 [PATCH 0/7] Switch to generic syscon regmap based drivers Alim Akhtar
2015-10-19 6:03 ` [PATCH 1/7] arm: dts: Add syscon-{reboot, poweroff} nodes for exynos3250 SoCs Alim Akhtar
2015-10-19 8:43 ` [1/7] " Pankaj Dubey
2015-10-19 13:03 ` [PATCH 1/7] " Javier Martinez Canillas
2015-10-20 9:00 ` Alim Akhtar
2015-10-19 6:03 ` [PATCH 2/7] arm: dts: Add syscon-{reboot, poweroff} nodes for exynos4 Alim Akhtar
2015-10-19 8:45 ` [2/7] " Pankaj Dubey
2015-10-19 13:08 ` [PATCH 2/7] " Javier Martinez Canillas
2015-10-19 6:03 ` [PATCH 3/7] arm: dts: Add syscon-{reboot, poweroff} nodes for exynos5 Alim Akhtar
2015-10-19 8:47 ` [3/7] " Pankaj Dubey
2015-10-19 13:09 ` [PATCH 3/7] " Javier Martinez Canillas
2015-10-19 6:03 ` [PATCH 4/7] arm: dts: Add syscon-{reboot, poweroff} nodes for exynos5410 SoC Alim Akhtar
2015-10-19 8:56 ` [4/7] " Pankaj Dubey
2015-10-19 13:10 ` [PATCH 4/7] " Javier Martinez Canillas
2015-10-19 6:03 ` [PATCH 5/7] ARM: exynos_defconfig: Normalize exynos defconfig Alim Akhtar
2015-10-19 13:25 ` Javier Martinez Canillas
2015-10-19 15:58 ` Alim Akhtar
2015-10-19 16:38 ` Javier Martinez Canillas
2015-10-19 6:03 ` [PATCH 6/7] ARM: exynos_defconfig: Enable generic syscon-{reboot, poweroff} drivers Alim Akhtar
2015-10-19 6:03 ` [PATCH 7/7] ARM: EXYNOS: Remove code for restart and poweroff for exynos SoCs Alim Akhtar
2015-10-19 7:00 ` Krzysztof Kozlowski
2015-10-19 8:27 ` Alim Akhtar [this message]
2015-10-19 9:56 ` Javier Martinez Canillas
2015-10-19 10:23 ` Alim Akhtar
2015-10-19 13:28 ` Krzysztof Kozlowski
2015-10-19 14:07 ` Javier Martinez Canillas
2015-10-19 16:13 ` Alim Akhtar
2015-10-19 16:42 ` Javier Martinez Canillas
2015-10-19 16:06 ` Alim Akhtar
2015-10-20 0:20 ` Krzysztof Kozlowski
2015-10-19 6:54 ` [PATCH 0/7] Switch to generic syscon regmap based drivers Krzysztof Kozlowski
2015-10-19 7:40 ` Alim Akhtar
2015-10-19 16:08 ` Tobias Jakobi
2015-10-19 16:36 ` Alim Akhtar
2015-10-19 21:18 ` Moritz Fischer
2015-10-20 8:56 ` Alim Akhtar
2015-10-20 13:43 ` Markus Reichl
2015-10-20 13:56 ` Krzysztof Kozlowski
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=5624A963.6000201@samsung.com \
--to=alim.akhtar@samsung.com \
--cc=devicetree@vger.kernel.org \
--cc=javier@osg.samsung.com \
--cc=k.kozlowski@samsung.com \
--cc=kgene@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-samsung-soc@vger.kernel.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 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).