linux-pm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 13/38] ARM: EXYNOS: pm_domains: Remove legacy power domain registration code
       [not found] <1371486863-12398-1-git-send-email-t.figa@samsung.com>
@ 2013-06-17 16:33 ` Tomasz Figa
  2013-06-17 16:34 ` [PATCH v2 29/38] thermal: exynos: Support both Exynos4x12 SoCs Tomasz Figa
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 11+ messages in thread
From: Tomasz Figa @ 2013-06-17 16:33 UTC (permalink / raw)
  To: linux-samsung-soc
  Cc: linux-arm-kernel, Kukjin Kim, Arnd Bergmann, Olof Johansson,
	Marek Szyprowski, Sylwester Nawrocki, Thomas Abraham, Tomasz Figa,
	linux-pm, Rafael J. Wysocki, Kyungmin Park

This patch removes static definitions of power domains and code
responsible for registering them and adding devices to them, since only
DT based boot is now supported on Exynos.

Cc: linux-pm@vger.kernel.org
Cc: "Rafael J. Wysocki" <rjw@sisk.pl>
Signed-off-by: Tomasz Figa <t.figa@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
---
 arch/arm/mach-exynos/pm_domains.c | 94 +--------------------------------------
 1 file changed, 1 insertion(+), 93 deletions(-)

diff --git a/arch/arm/mach-exynos/pm_domains.c b/arch/arm/mach-exynos/pm_domains.c
index beb946d..1703593 100644
--- a/arch/arm/mach-exynos/pm_domains.c
+++ b/arch/arm/mach-exynos/pm_domains.c
@@ -74,16 +74,6 @@ static int exynos_pd_power_off(struct generic_pm_domain *domain)
 	return exynos_pd_power(domain, false);
 }
 
-#define EXYNOS_GPD(PD, BASE, NAME)			\
-static struct exynos_pm_domain PD = {			\
-	.base = (void __iomem *)BASE,			\
-	.name = NAME,					\
-	.pd = {						\
-		.power_off = exynos_pd_power_off,	\
-		.power_on = exynos_pd_power_on,	\
-	},						\
-}
-
 static void exynos_add_device_to_domain(struct exynos_pm_domain *pd,
 					 struct device *dev)
 {
@@ -156,7 +146,7 @@ static struct notifier_block platform_nb = {
 	.notifier_call = exynos_pm_notifier_call,
 };
 
-static __init int exynos_pm_dt_parse_domains(void)
+static __init int exynos4_pm_init_power_domain(void)
 {
 	struct platform_device *pdev;
 	struct device_node *np;
@@ -192,88 +182,6 @@ static __init int exynos_pm_dt_parse_domains(void)
 
 	return 0;
 }
-
-static __init __maybe_unused void exynos_pm_add_dev_to_genpd(struct platform_device *pdev,
-						struct exynos_pm_domain *pd)
-{
-	if (pdev->dev.bus) {
-		if (!pm_genpd_add_device(&pd->pd, &pdev->dev))
-			pm_genpd_dev_need_restore(&pdev->dev, true);
-		else
-			pr_info("%s: error in adding %s device to %s power"
-				"domain\n", __func__, dev_name(&pdev->dev),
-				pd->name);
-	}
-}
-
-EXYNOS_GPD(exynos4_pd_mfc, S5P_PMU_MFC_CONF, "pd-mfc");
-EXYNOS_GPD(exynos4_pd_g3d, S5P_PMU_G3D_CONF, "pd-g3d");
-EXYNOS_GPD(exynos4_pd_lcd0, S5P_PMU_LCD0_CONF, "pd-lcd0");
-EXYNOS_GPD(exynos4_pd_lcd1, S5P_PMU_LCD1_CONF, "pd-lcd1");
-EXYNOS_GPD(exynos4_pd_tv, S5P_PMU_TV_CONF, "pd-tv");
-EXYNOS_GPD(exynos4_pd_cam, S5P_PMU_CAM_CONF, "pd-cam");
-EXYNOS_GPD(exynos4_pd_gps, S5P_PMU_GPS_CONF, "pd-gps");
-
-static struct exynos_pm_domain *exynos4_pm_domains[] = {
-	&exynos4_pd_mfc,
-	&exynos4_pd_g3d,
-	&exynos4_pd_lcd0,
-	&exynos4_pd_lcd1,
-	&exynos4_pd_tv,
-	&exynos4_pd_cam,
-	&exynos4_pd_gps,
-};
-
-static __init int exynos4_pm_init_power_domain(void)
-{
-	int idx;
-
-	if (of_have_populated_dt())
-		return exynos_pm_dt_parse_domains();
-
-	for (idx = 0; idx < ARRAY_SIZE(exynos4_pm_domains); idx++) {
-		struct exynos_pm_domain *pd = exynos4_pm_domains[idx];
-		int on = __raw_readl(pd->base + 0x4) & S5P_INT_LOCAL_PWR_EN;
-
-		pm_genpd_init(&pd->pd, NULL, !on);
-	}
-
-#ifdef CONFIG_S5P_DEV_FIMD0
-	exynos_pm_add_dev_to_genpd(&s5p_device_fimd0, &exynos4_pd_lcd0);
-#endif
-#ifdef CONFIG_S5P_DEV_TV
-	exynos_pm_add_dev_to_genpd(&s5p_device_hdmi, &exynos4_pd_tv);
-	exynos_pm_add_dev_to_genpd(&s5p_device_mixer, &exynos4_pd_tv);
-#endif
-#ifdef CONFIG_S5P_DEV_MFC
-	exynos_pm_add_dev_to_genpd(&s5p_device_mfc, &exynos4_pd_mfc);
-#endif
-#ifdef CONFIG_S5P_DEV_FIMC0
-	exynos_pm_add_dev_to_genpd(&s5p_device_fimc0, &exynos4_pd_cam);
-#endif
-#ifdef CONFIG_S5P_DEV_FIMC1
-	exynos_pm_add_dev_to_genpd(&s5p_device_fimc1, &exynos4_pd_cam);
-#endif
-#ifdef CONFIG_S5P_DEV_FIMC2
-	exynos_pm_add_dev_to_genpd(&s5p_device_fimc2, &exynos4_pd_cam);
-#endif
-#ifdef CONFIG_S5P_DEV_FIMC3
-	exynos_pm_add_dev_to_genpd(&s5p_device_fimc3, &exynos4_pd_cam);
-#endif
-#ifdef CONFIG_S5P_DEV_CSIS0
-	exynos_pm_add_dev_to_genpd(&s5p_device_mipi_csis0, &exynos4_pd_cam);
-#endif
-#ifdef CONFIG_S5P_DEV_CSIS1
-	exynos_pm_add_dev_to_genpd(&s5p_device_mipi_csis1, &exynos4_pd_cam);
-#endif
-#ifdef CONFIG_S5P_DEV_G2D
-	exynos_pm_add_dev_to_genpd(&s5p_device_g2d, &exynos4_pd_lcd0);
-#endif
-#ifdef CONFIG_S5P_DEV_JPEG
-	exynos_pm_add_dev_to_genpd(&s5p_device_jpeg, &exynos4_pd_cam);
-#endif
-	return 0;
-}
 arch_initcall(exynos4_pm_init_power_domain);
 
 int __init exynos_pm_late_initcall(void)
-- 
1.8.2.1


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

* [PATCH v2 29/38] thermal: exynos: Support both Exynos4x12 SoCs
       [not found] <1371486863-12398-1-git-send-email-t.figa@samsung.com>
  2013-06-17 16:33 ` [PATCH v2 13/38] ARM: EXYNOS: pm_domains: Remove legacy power domain registration code Tomasz Figa
@ 2013-06-17 16:34 ` Tomasz Figa
  2013-06-17 19:59   ` Arnd Bergmann
  2013-06-17 16:34 ` [PATCH v2 31/38] cpufreq: exynos4x12: Remove check for SOC_EXYNOS4412 Tomasz Figa
  2013-06-17 16:34 ` [PATCH v2 33/38] thermal: exynos: " Tomasz Figa
  3 siblings, 1 reply; 11+ messages in thread
From: Tomasz Figa @ 2013-06-17 16:34 UTC (permalink / raw)
  To: linux-samsung-soc
  Cc: linux-arm-kernel, Kukjin Kim, Arnd Bergmann, Olof Johansson,
	Marek Szyprowski, Sylwester Nawrocki, Thomas Abraham, Tomasz Figa,
	linux-pm, Zhang Rui, Eduardo Valentin, Kyungmin Park

Exynos4212 and Exynos4412 have the same thermal block, so there is no
reason to include support only for Exynos4412 in this driver.

Cc: linux-pm@vger.kernel.org
Cc: Zhang Rui <rui.zhang@intel.com>
Cc: Eduardo Valentin <eduardo.valentin@ti.com>
Signed-off-by: Tomasz Figa <t.figa@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
---
 drivers/thermal/exynos_thermal.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/thermal/exynos_thermal.c b/drivers/thermal/exynos_thermal.c
index 788b1dd..4cbe3ee 100644
--- a/drivers/thermal/exynos_thermal.c
+++ b/drivers/thermal/exynos_thermal.c
@@ -817,7 +817,8 @@ static struct exynos_tmu_platform_data const exynos4210_default_tmu_data = {
 #define EXYNOS4210_TMU_DRV_DATA (NULL)
 #endif
 
-#if defined(CONFIG_SOC_EXYNOS5250) || defined(CONFIG_SOC_EXYNOS4412)
+#if defined(CONFIG_SOC_EXYNOS5250) || defined(CONFIG_SOC_EXYNOS4412) || \
+	defined(CONFIG_SOC_EXYNOS4212)
 static struct exynos_tmu_platform_data const exynos_default_tmu_data = {
 	.threshold_falling = 10,
 	.trigger_levels[0] = 85,
-- 
1.8.2.1

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

* [PATCH v2 31/38] cpufreq: exynos4x12: Remove check for SOC_EXYNOS4412
       [not found] <1371486863-12398-1-git-send-email-t.figa@samsung.com>
  2013-06-17 16:33 ` [PATCH v2 13/38] ARM: EXYNOS: pm_domains: Remove legacy power domain registration code Tomasz Figa
  2013-06-17 16:34 ` [PATCH v2 29/38] thermal: exynos: Support both Exynos4x12 SoCs Tomasz Figa
@ 2013-06-17 16:34 ` Tomasz Figa
  2013-06-18  3:18   ` Viresh Kumar
  2013-06-18  9:18   ` Kukjin Kim
  2013-06-17 16:34 ` [PATCH v2 33/38] thermal: exynos: " Tomasz Figa
  3 siblings, 2 replies; 11+ messages in thread
From: Tomasz Figa @ 2013-06-17 16:34 UTC (permalink / raw)
  To: linux-samsung-soc
  Cc: linux-arm-kernel, Kukjin Kim, Arnd Bergmann, Olof Johansson,
	Marek Szyprowski, Sylwester Nawrocki, Thomas Abraham, Tomasz Figa,
	linux-pm, Viresh Kumar, Kyungmin Park

Since SOC_EXYNOS4412 Kconfig symbol has been removed, it is enough to
check for SOC_EXYNOS4212 for both SoCs from Exynos4x12 series.

Cc: linux-pm@vger.kernel.org
Cc: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Tomasz Figa <t.figa@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
---
 drivers/cpufreq/Kconfig.arm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/cpufreq/Kconfig.arm b/drivers/cpufreq/Kconfig.arm
index a924408..b214ad6 100644
--- a/drivers/cpufreq/Kconfig.arm
+++ b/drivers/cpufreq/Kconfig.arm
@@ -32,7 +32,7 @@ config ARM_EXYNOS4210_CPUFREQ
 	  SoC (S5PV310 or S5PC210).
 
 config ARM_EXYNOS4X12_CPUFREQ
-	def_bool (SOC_EXYNOS4212 || SOC_EXYNOS4412)
+	def_bool SOC_EXYNOS4212
 	help
 	  This adds the CPUFreq driver for Samsung EXYNOS4X12
 	  SoC (EXYNOS4212 or EXYNOS4412).
-- 
1.8.2.1


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

* [PATCH v2 33/38] thermal: exynos: Remove check for SOC_EXYNOS4412
       [not found] <1371486863-12398-1-git-send-email-t.figa@samsung.com>
                   ` (2 preceding siblings ...)
  2013-06-17 16:34 ` [PATCH v2 31/38] cpufreq: exynos4x12: Remove check for SOC_EXYNOS4412 Tomasz Figa
@ 2013-06-17 16:34 ` Tomasz Figa
  2013-06-18  9:19   ` Kukjin Kim
  3 siblings, 1 reply; 11+ messages in thread
From: Tomasz Figa @ 2013-06-17 16:34 UTC (permalink / raw)
  To: linux-samsung-soc
  Cc: linux-arm-kernel, Kukjin Kim, Arnd Bergmann, Olof Johansson,
	Marek Szyprowski, Sylwester Nawrocki, Thomas Abraham, Tomasz Figa,
	linux-pm, Zhang Rui, Eduardo Valentin, Kyungmin Park

Since SOC_EXYNOS4412 Kconfig symbol has been removed, it is enough to
check for SOC_EXYNOS4212 for both SoCs from Exynos4x12 series.

Cc: linux-pm@vger.kernel.org
Cc: Zhang Rui <rui.zhang@intel.com>
Cc: Eduardo Valentin <eduardo.valentin@ti.com>
Signed-off-by: Tomasz Figa <t.figa@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
---
 drivers/thermal/exynos_thermal.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/thermal/exynos_thermal.c b/drivers/thermal/exynos_thermal.c
index 4cbe3ee..f88a2ad 100644
--- a/drivers/thermal/exynos_thermal.c
+++ b/drivers/thermal/exynos_thermal.c
@@ -817,8 +817,7 @@ static struct exynos_tmu_platform_data const exynos4210_default_tmu_data = {
 #define EXYNOS4210_TMU_DRV_DATA (NULL)
 #endif
 
-#if defined(CONFIG_SOC_EXYNOS5250) || defined(CONFIG_SOC_EXYNOS4412) || \
-	defined(CONFIG_SOC_EXYNOS4212)
+#if defined(CONFIG_SOC_EXYNOS5250) || defined(CONFIG_SOC_EXYNOS4212)
 static struct exynos_tmu_platform_data const exynos_default_tmu_data = {
 	.threshold_falling = 10,
 	.trigger_levels[0] = 85,
-- 
1.8.2.1


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

* Re: [PATCH v2 29/38] thermal: exynos: Support both Exynos4x12 SoCs
  2013-06-17 16:34 ` [PATCH v2 29/38] thermal: exynos: Support both Exynos4x12 SoCs Tomasz Figa
@ 2013-06-17 19:59   ` Arnd Bergmann
  2013-06-17 23:34     ` Eduardo Valentin
  0 siblings, 1 reply; 11+ messages in thread
From: Arnd Bergmann @ 2013-06-17 19:59 UTC (permalink / raw)
  To: Tomasz Figa
  Cc: linux-samsung-soc, linux-arm-kernel, Kukjin Kim, Olof Johansson,
	Marek Szyprowski, Sylwester Nawrocki, Thomas Abraham, linux-pm,
	Zhang Rui, Eduardo Valentin, Kyungmin Park

On Monday 17 June 2013, Tomasz Figa wrote:
> diff --git a/drivers/thermal/exynos_thermal.c b/drivers/thermal/exynos_thermal.c
> index 788b1dd..4cbe3ee 100644
> --- a/drivers/thermal/exynos_thermal.c
> +++ b/drivers/thermal/exynos_thermal.c
> @@ -817,7 +817,8 @@ static struct exynos_tmu_platform_data const exynos4210_default_tmu_data = {
>  #define EXYNOS4210_TMU_DRV_DATA (NULL)
>  #endif
>  
> -#if defined(CONFIG_SOC_EXYNOS5250) || defined(CONFIG_SOC_EXYNOS4412)
> +#if defined(CONFIG_SOC_EXYNOS5250) || defined(CONFIG_SOC_EXYNOS4412) || \
> +       defined(CONFIG_SOC_EXYNOS4212)
>  static struct exynos_tmu_platform_data const exynos_default_tmu_data = {
>         .threshold_falling = 10,
>         .trigger_levels[0] = 85,

The patch is correct, but generally speaking I think we should get away from
having the drivers get configured per SoC on such a fine-grained level.
Better make this driver (and others) always work on all exynos variants.

	Arnd

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

* Re: [PATCH v2 29/38] thermal: exynos: Support both Exynos4x12 SoCs
  2013-06-17 19:59   ` Arnd Bergmann
@ 2013-06-17 23:34     ` Eduardo Valentin
  2013-06-18  8:54       ` amit daniel kachhap
  2013-06-18 13:02       ` Arnd Bergmann
  0 siblings, 2 replies; 11+ messages in thread
From: Eduardo Valentin @ 2013-06-17 23:34 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Kukjin Kim, linux-pm, Tomasz Figa, Amit Daniel Kachhap,
	Eduardo Valentin, Kyungmin Park, linux-samsung-soc,
	Thomas Abraham, Sylwester Nawrocki, Olof Johansson, Zhang Rui,
	linux-arm-kernel, Marek Szyprowski


[-- Attachment #1.1: Type: text/plain, Size: 1493 bytes --]

Arnd,

On 17-06-2013 15:59, Arnd Bergmann wrote:
> On Monday 17 June 2013, Tomasz Figa wrote:
>> diff --git a/drivers/thermal/exynos_thermal.c b/drivers/thermal/exynos_thermal.c
>> index 788b1dd..4cbe3ee 100644
>> --- a/drivers/thermal/exynos_thermal.c
>> +++ b/drivers/thermal/exynos_thermal.c
>> @@ -817,7 +817,8 @@ static struct exynos_tmu_platform_data const exynos4210_default_tmu_data = {
>>  #define EXYNOS4210_TMU_DRV_DATA (NULL)
>>  #endif
>>  
>> -#if defined(CONFIG_SOC_EXYNOS5250) || defined(CONFIG_SOC_EXYNOS4412)
>> +#if defined(CONFIG_SOC_EXYNOS5250) || defined(CONFIG_SOC_EXYNOS4412) || \
>> +       defined(CONFIG_SOC_EXYNOS4212)
>>  static struct exynos_tmu_platform_data const exynos_default_tmu_data = {
>>         .threshold_falling = 10,
>>         .trigger_levels[0] = 85,
> 
> The patch is correct, but generally speaking I think we should get away from
> having the drivers get configured per SoC on such a fine-grained level.
> Better make this driver (and others) always work on all exynos variants.

Amit, correct if I am wrong, but:

The driver will work on supported exynos variants. Those that have the
need for thermal sensing. And each of them have specific thermal needs
(trigger points, thresholds, etc). That is what this file tries to
isolate. And there is specific data structures for each soc version.


> 
> 	Arnd
> 
> 


-- 
You have got to be excited about what you are doing. (L. Lamport)

Eduardo Valentin


[-- Attachment #1.2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 295 bytes --]

[-- Attachment #2: Type: text/plain, Size: 176 bytes --]

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* Re: [PATCH v2 31/38] cpufreq: exynos4x12: Remove check for SOC_EXYNOS4412
  2013-06-17 16:34 ` [PATCH v2 31/38] cpufreq: exynos4x12: Remove check for SOC_EXYNOS4412 Tomasz Figa
@ 2013-06-18  3:18   ` Viresh Kumar
  2013-06-18  9:18   ` Kukjin Kim
  1 sibling, 0 replies; 11+ messages in thread
From: Viresh Kumar @ 2013-06-18  3:18 UTC (permalink / raw)
  To: Tomasz Figa
  Cc: linux-samsung-soc, linux-arm-kernel, Kukjin Kim, Arnd Bergmann,
	Olof Johansson, Marek Szyprowski, Sylwester Nawrocki,
	Thomas Abraham, linux-pm, Kyungmin Park

On 17 June 2013 22:04, Tomasz Figa <t.figa@samsung.com> wrote:
> Since SOC_EXYNOS4412 Kconfig symbol has been removed, it is enough to
> check for SOC_EXYNOS4212 for both SoCs from Exynos4x12 series.
>
> Cc: linux-pm@vger.kernel.org
> Cc: Viresh Kumar <viresh.kumar@linaro.org>
> Signed-off-by: Tomasz Figa <t.figa@samsung.com>
> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
> ---
>  drivers/cpufreq/Kconfig.arm | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Looks good. You want it to get via samsung tree or cpufreq? I think
all cpufreq related patches should go through cpufreq unless there
is a real dependency on samsung tree.

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

* Re: [PATCH v2 29/38] thermal: exynos: Support both Exynos4x12 SoCs
  2013-06-17 23:34     ` Eduardo Valentin
@ 2013-06-18  8:54       ` amit daniel kachhap
  2013-06-18 13:02       ` Arnd Bergmann
  1 sibling, 0 replies; 11+ messages in thread
From: amit daniel kachhap @ 2013-06-18  8:54 UTC (permalink / raw)
  To: Eduardo Valentin
  Cc: Arnd Bergmann, Tomasz Figa, linux-samsung-soc, linux-arm-kernel,
	Kukjin Kim, Olof Johansson, Marek Szyprowski, Sylwester Nawrocki,
	Thomas Abraham, linux-pm, Zhang Rui, Kyungmin Park

Hi Eduardo,

On Tue, Jun 18, 2013 at 5:04 AM, Eduardo Valentin
<eduardo.valentin@ti.com> wrote:
> Arnd,
>
> On 17-06-2013 15:59, Arnd Bergmann wrote:
>> On Monday 17 June 2013, Tomasz Figa wrote:
>>> diff --git a/drivers/thermal/exynos_thermal.c b/drivers/thermal/exynos_thermal.c
>>> index 788b1dd..4cbe3ee 100644
>>> --- a/drivers/thermal/exynos_thermal.c
>>> +++ b/drivers/thermal/exynos_thermal.c
>>> @@ -817,7 +817,8 @@ static struct exynos_tmu_platform_data const exynos4210_default_tmu_data = {
>>>  #define EXYNOS4210_TMU_DRV_DATA (NULL)
>>>  #endif
>>>
>>> -#if defined(CONFIG_SOC_EXYNOS5250) || defined(CONFIG_SOC_EXYNOS4412)
>>> +#if defined(CONFIG_SOC_EXYNOS5250) || defined(CONFIG_SOC_EXYNOS4412) || \
>>> +       defined(CONFIG_SOC_EXYNOS4212)
>>>  static struct exynos_tmu_platform_data const exynos_default_tmu_data = {
>>>         .threshold_falling = 10,
>>>         .trigger_levels[0] = 85,
>>
>> The patch is correct, but generally speaking I think we should get away from
>> having the drivers get configured per SoC on such a fine-grained level.
>> Better make this driver (and others) always work on all exynos variants.
>
> Amit, correct if I am wrong, but:
>
> The driver will work on supported exynos variants. Those that have the
> need for thermal sensing. And each of them have specific thermal needs
> (trigger points, thresholds, etc). That is what this file tries to
> isolate. And there is specific data structures for each soc version.
Yes its correct that there may be some changes in data points for
different soc's. in the new re-structured code data is separated from
driver so more data can be added cleanly.

>
>
>>
>>       Arnd
>>
>>
>
>
> --
> You have got to be excited about what you are doing. (L. Lamport)
>
> Eduardo Valentin
>

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

* RE: [PATCH v2 31/38] cpufreq: exynos4x12: Remove check for SOC_EXYNOS4412
  2013-06-17 16:34 ` [PATCH v2 31/38] cpufreq: exynos4x12: Remove check for SOC_EXYNOS4412 Tomasz Figa
  2013-06-18  3:18   ` Viresh Kumar
@ 2013-06-18  9:18   ` Kukjin Kim
  1 sibling, 0 replies; 11+ messages in thread
From: Kukjin Kim @ 2013-06-18  9:18 UTC (permalink / raw)
  To: 'Tomasz Figa', linux-samsung-soc
  Cc: linux-arm-kernel, 'Arnd Bergmann',
	'Olof Johansson', 'Marek Szyprowski',
	'Sylwester Nawrocki', 'Thomas Abraham', linux-pm,
	'Viresh Kumar', 'Kyungmin Park'

Tomasz Figa wrote:
> 
> Since SOC_EXYNOS4412 Kconfig symbol has been removed, it is enough to
> check for SOC_EXYNOS4212 for both SoCs from Exynos4x12 series.
> 
> Cc: linux-pm@vger.kernel.org
> Cc: Viresh Kumar <viresh.kumar@linaro.org>
> Signed-off-by: Tomasz Figa <t.figa@samsung.com>
> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
> ---
>  drivers/cpufreq/Kconfig.arm | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/cpufreq/Kconfig.arm b/drivers/cpufreq/Kconfig.arm
> index a924408..b214ad6 100644
> --- a/drivers/cpufreq/Kconfig.arm
> +++ b/drivers/cpufreq/Kconfig.arm
> @@ -32,7 +32,7 @@ config ARM_EXYNOS4210_CPUFREQ
>  	  SoC (S5PV310 or S5PC210).
> 
>  config ARM_EXYNOS4X12_CPUFREQ
> -	def_bool (SOC_EXYNOS4212 || SOC_EXYNOS4412)
> +	def_bool SOC_EXYNOS4212
>  	help
>  	  This adds the CPUFreq driver for Samsung EXYNOS4X12
>  	  SoC (EXYNOS4212 or EXYNOS4412).
> --
> 1.8.2.1

NAK, the reason is same with my comments on 30th patch.

- Kukjin

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

* RE: [PATCH v2 33/38] thermal: exynos: Remove check for SOC_EXYNOS4412
  2013-06-17 16:34 ` [PATCH v2 33/38] thermal: exynos: " Tomasz Figa
@ 2013-06-18  9:19   ` Kukjin Kim
  0 siblings, 0 replies; 11+ messages in thread
From: Kukjin Kim @ 2013-06-18  9:19 UTC (permalink / raw)
  To: 'Tomasz Figa', linux-samsung-soc
  Cc: linux-arm-kernel, 'Arnd Bergmann',
	'Olof Johansson', 'Marek Szyprowski',
	'Sylwester Nawrocki', 'Thomas Abraham', linux-pm,
	'Zhang Rui', 'Eduardo Valentin',
	'Kyungmin Park'

Tomasz Figa wrote:
> 
> Since SOC_EXYNOS4412 Kconfig symbol has been removed, it is enough to
> check for SOC_EXYNOS4212 for both SoCs from Exynos4x12 series.
> 
> Cc: linux-pm@vger.kernel.org
> Cc: Zhang Rui <rui.zhang@intel.com>
> Cc: Eduardo Valentin <eduardo.valentin@ti.com>
> Signed-off-by: Tomasz Figa <t.figa@samsung.com>
> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
> ---
>  drivers/thermal/exynos_thermal.c | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/drivers/thermal/exynos_thermal.c
> b/drivers/thermal/exynos_thermal.c
> index 4cbe3ee..f88a2ad 100644
> --- a/drivers/thermal/exynos_thermal.c
> +++ b/drivers/thermal/exynos_thermal.c
> @@ -817,8 +817,7 @@ static struct exynos_tmu_platform_data const
> exynos4210_default_tmu_data = {
>  #define EXYNOS4210_TMU_DRV_DATA (NULL)
>  #endif
> 
> -#if defined(CONFIG_SOC_EXYNOS5250) || defined(CONFIG_SOC_EXYNOS4412) || \
> -	defined(CONFIG_SOC_EXYNOS4212)
> +#if defined(CONFIG_SOC_EXYNOS5250) || defined(CONFIG_SOC_EXYNOS4212)
>  static struct exynos_tmu_platform_data const exynos_default_tmu_data = {
>  	.threshold_falling = 10,
>  	.trigger_levels[0] = 85,
> --
> 1.8.2.1

NAK, the reason is same with my comments on 30th patch.

- Kukjin


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

* Re: [PATCH v2 29/38] thermal: exynos: Support both Exynos4x12 SoCs
  2013-06-17 23:34     ` Eduardo Valentin
  2013-06-18  8:54       ` amit daniel kachhap
@ 2013-06-18 13:02       ` Arnd Bergmann
  1 sibling, 0 replies; 11+ messages in thread
From: Arnd Bergmann @ 2013-06-18 13:02 UTC (permalink / raw)
  To: Eduardo Valentin
  Cc: Tomasz Figa, linux-samsung-soc, linux-arm-kernel, Kukjin Kim,
	Olof Johansson, Marek Szyprowski, Sylwester Nawrocki,
	Thomas Abraham, linux-pm, Zhang Rui, Kyungmin Park,
	Amit Daniel Kachhap

On Tuesday 18 June 2013, Eduardo Valentin wrote:
> The driver will work on supported exynos variants. Those that have the
> need for thermal sensing. And each of them have specific thermal needs
> (trigger points, thresholds, etc). That is what this file tries to
> isolate. And there is specific data structures for each soc version.

Correct. My point is that the driver itself is much larger than the
SoC-specific data sets in it. There is no reason to conditionally
build a 108 byte data structure, making it more maintainably by removing
all the #ifdef far outweighs the cost.

You can also change the driver to work only for DT based booting,
that will simplify it further and save you more in terms of object
code size than the exynos_tmu_platform_data instances.

	Arnd

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

end of thread, other threads:[~2013-06-18 13:02 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <1371486863-12398-1-git-send-email-t.figa@samsung.com>
2013-06-17 16:33 ` [PATCH v2 13/38] ARM: EXYNOS: pm_domains: Remove legacy power domain registration code Tomasz Figa
2013-06-17 16:34 ` [PATCH v2 29/38] thermal: exynos: Support both Exynos4x12 SoCs Tomasz Figa
2013-06-17 19:59   ` Arnd Bergmann
2013-06-17 23:34     ` Eduardo Valentin
2013-06-18  8:54       ` amit daniel kachhap
2013-06-18 13:02       ` Arnd Bergmann
2013-06-17 16:34 ` [PATCH v2 31/38] cpufreq: exynos4x12: Remove check for SOC_EXYNOS4412 Tomasz Figa
2013-06-18  3:18   ` Viresh Kumar
2013-06-18  9:18   ` Kukjin Kim
2013-06-17 16:34 ` [PATCH v2 33/38] thermal: exynos: " Tomasz Figa
2013-06-18  9:19   ` Kukjin Kim

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