linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATHC 0/2] update and cleanup patches for coretemp etc.
@ 2010-09-26  5:59 Chen Gong
  2010-09-26  5:59 ` [PATCH 1/2] hwmon: uniform the init style of pkgtemp Chen Gong
  2010-09-26  6:00 ` [PATCH 2/2] hwmon: cleanup some hotplug related macro definition Chen Gong
  0 siblings, 2 replies; 12+ messages in thread
From: Chen Gong @ 2010-09-26  5:59 UTC (permalink / raw)
  To: lm-sensors; +Cc: JBeulich, linux-kernel

[PATCH 1/2] hwmon: uniform the init style of pkgtemp
[PATCH 2/2] hwmon: cleanup some hotplug related macro definition

These 2 patches are no new functions, just unify the codes to avoid
potential issues and some cleanup work.

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

* [PATCH 1/2] hwmon: uniform the init style of pkgtemp
  2010-09-26  5:59 [PATHC 0/2] update and cleanup patches for coretemp etc Chen Gong
@ 2010-09-26  5:59 ` Chen Gong
  2010-09-27  7:10   ` Jan Beulich
  2010-10-02  3:26   ` [1/2] " Guenter Roeck
  2010-09-26  6:00 ` [PATCH 2/2] hwmon: cleanup some hotplug related macro definition Chen Gong
  1 sibling, 2 replies; 12+ messages in thread
From: Chen Gong @ 2010-09-26  5:59 UTC (permalink / raw)
  To: lm-sensors; +Cc: JBeulich, linux-kernel, Chen Gong

pkgtemp is derived from coretemp, so some reasonable
logics should be applied onto pkgtemp, too. Such as
the init logic here.

Signed-off-by: Chen Gong <gong.chen@linux.intel.com>
---
 drivers/hwmon/pkgtemp.c |   23 +++++++----------------
 1 files changed, 7 insertions(+), 16 deletions(-)

diff --git a/drivers/hwmon/pkgtemp.c b/drivers/hwmon/pkgtemp.c
index f119039..6186041 100644
--- a/drivers/hwmon/pkgtemp.c
+++ b/drivers/hwmon/pkgtemp.c
@@ -392,7 +392,6 @@ static struct notifier_block pkgtemp_cpu_notifier __refdata = {
 static int __init pkgtemp_init(void)
 {
 	int i, err = -ENODEV;
-	struct pdev_entry *p, *n;
 
 	/* quick check if we run Intel */
 	if (cpu_data(0).x86_vendor != X86_VENDOR_INTEL)
@@ -402,31 +401,23 @@ static int __init pkgtemp_init(void)
 	if (err)
 		goto exit;
 
-	for_each_online_cpu(i) {
-		err = pkgtemp_device_add(i);
-		if (err)
-			goto exit_devices_unreg;
-	}
+	for_each_online_cpu(i)
+		pkgtemp_device_add(i);
+
+#ifndef CONFIG_HOTPLUG_CPU
 	if (list_empty(&pdev_list)) {
 		err = -ENODEV;
 		goto exit_driver_unreg;
 	}
+#endif
 
-#ifdef CONFIG_HOTPLUG_CPU
 	register_hotcpu_notifier(&pkgtemp_cpu_notifier);
-#endif
 	return 0;
 
-exit_devices_unreg:
-	mutex_lock(&pdev_list_mutex);
-	list_for_each_entry_safe(p, n, &pdev_list, list) {
-		platform_device_unregister(p->pdev);
-		list_del(&p->list);
-		kfree(p);
-	}
-	mutex_unlock(&pdev_list_mutex);
+#ifndef CONFIG_HOTPLUG_CPU
 exit_driver_unreg:
 	platform_driver_unregister(&pkgtemp_driver);
+#endif
 exit:
 	return err;
 }
-- 
1.7.2.2.173.g515cc


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

* [PATCH 2/2] hwmon: cleanup some hotplug related macro definition
  2010-09-26  5:59 [PATHC 0/2] update and cleanup patches for coretemp etc Chen Gong
  2010-09-26  5:59 ` [PATCH 1/2] hwmon: uniform the init style of pkgtemp Chen Gong
@ 2010-09-26  6:00 ` Chen Gong
  2010-09-27  7:11   ` Jan Beulich
                     ` (2 more replies)
  1 sibling, 3 replies; 12+ messages in thread
From: Chen Gong @ 2010-09-26  6:00 UTC (permalink / raw)
  To: lm-sensors; +Cc: JBeulich, linux-kernel, Chen Gong

CONFIG_HOTPLUG_CPU is used too much in some drivers.
This patch clean them up and add some proper __cpuinit definitons.

Signed-off-by: Chen Gong <gong.chen@linux.intel.com>
---
 drivers/hwmon/coretemp.c    |    5 ++---
 drivers/hwmon/pkgtemp.c     |    7 ++-----
 drivers/hwmon/via-cputemp.c |    9 ++-------
 3 files changed, 6 insertions(+), 15 deletions(-)

diff --git a/drivers/hwmon/coretemp.c b/drivers/hwmon/coretemp.c
index baa842a..887ab93 100644
--- a/drivers/hwmon/coretemp.c
+++ b/drivers/hwmon/coretemp.c
@@ -489,7 +489,7 @@ exit:
 	return err;
 }
 
-static void coretemp_device_remove(unsigned int cpu)
+static void __cpuinit coretemp_device_remove(unsigned int cpu)
 {
 	struct pdev_entry *p;
 	unsigned int i;
@@ -568,9 +568,8 @@ exit:
 static void __exit coretemp_exit(void)
 {
 	struct pdev_entry *p, *n;
-#ifdef CONFIG_HOTPLUG_CPU
+
 	unregister_hotcpu_notifier(&coretemp_cpu_notifier);
-#endif
 	mutex_lock(&pdev_list_mutex);
 	list_for_each_entry_safe(p, n, &pdev_list, list) {
 		platform_device_unregister(p->pdev);
diff --git a/drivers/hwmon/pkgtemp.c b/drivers/hwmon/pkgtemp.c
index 6186041..0516d52 100644
--- a/drivers/hwmon/pkgtemp.c
+++ b/drivers/hwmon/pkgtemp.c
@@ -339,8 +339,7 @@ exit:
 	return err;
 }
 
-#ifdef CONFIG_HOTPLUG_CPU
-static void pkgtemp_device_remove(unsigned int cpu)
+static void __cpuinit pkgtemp_device_remove(unsigned int cpu)
 {
 	struct pdev_entry *p;
 	unsigned int i;
@@ -387,7 +386,6 @@ static int __cpuinit pkgtemp_cpu_callback(struct notifier_block *nfb,
 static struct notifier_block pkgtemp_cpu_notifier __refdata = {
 	.notifier_call = pkgtemp_cpu_callback,
 };
-#endif				/* !CONFIG_HOTPLUG_CPU */
 
 static int __init pkgtemp_init(void)
 {
@@ -425,9 +423,8 @@ exit:
 static void __exit pkgtemp_exit(void)
 {
 	struct pdev_entry *p, *n;
-#ifdef CONFIG_HOTPLUG_CPU
+
 	unregister_hotcpu_notifier(&pkgtemp_cpu_notifier);
-#endif
 	mutex_lock(&pdev_list_mutex);
 	list_for_each_entry_safe(p, n, &pdev_list, list) {
 		platform_device_unregister(p->pdev);
diff --git a/drivers/hwmon/via-cputemp.c b/drivers/hwmon/via-cputemp.c
index ffb793a..ebbdc25 100644
--- a/drivers/hwmon/via-cputemp.c
+++ b/drivers/hwmon/via-cputemp.c
@@ -237,8 +237,7 @@ exit:
 	return err;
 }
 
-#ifdef CONFIG_HOTPLUG_CPU
-static void via_cputemp_device_remove(unsigned int cpu)
+static void __cpuinit via_cputemp_device_remove(unsigned int cpu)
 {
 	struct pdev_entry *p, *n;
 	mutex_lock(&pdev_list_mutex);
@@ -272,7 +271,6 @@ static int __cpuinit via_cputemp_cpu_callback(struct notifier_block *nfb,
 static struct notifier_block via_cputemp_cpu_notifier __refdata = {
 	.notifier_call = via_cputemp_cpu_callback,
 };
-#endif				/* !CONFIG_HOTPLUG_CPU */
 
 static int __init via_cputemp_init(void)
 {
@@ -313,9 +311,7 @@ static int __init via_cputemp_init(void)
 		goto exit_driver_unreg;
 	}
 
-#ifdef CONFIG_HOTPLUG_CPU
 	register_hotcpu_notifier(&via_cputemp_cpu_notifier);
-#endif
 	return 0;
 
 exit_devices_unreg:
@@ -335,9 +331,8 @@ exit:
 static void __exit via_cputemp_exit(void)
 {
 	struct pdev_entry *p, *n;
-#ifdef CONFIG_HOTPLUG_CPU
+
 	unregister_hotcpu_notifier(&via_cputemp_cpu_notifier);
-#endif
 	mutex_lock(&pdev_list_mutex);
 	list_for_each_entry_safe(p, n, &pdev_list, list) {
 		platform_device_unregister(p->pdev);
-- 
1.7.2.2.173.g515cc


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

* Re: [PATCH 1/2] hwmon: uniform the init style of pkgtemp
  2010-09-26  5:59 ` [PATCH 1/2] hwmon: uniform the init style of pkgtemp Chen Gong
@ 2010-09-27  7:10   ` Jan Beulich
  2010-09-27 14:52     ` [lm-sensors] " Guenter Roeck
  2010-10-02  3:26   ` [1/2] " Guenter Roeck
  1 sibling, 1 reply; 12+ messages in thread
From: Jan Beulich @ 2010-09-27  7:10 UTC (permalink / raw)
  To: Chen Gong, lm-sensors; +Cc: linux-kernel

>>> On 26.09.10 at 07:59, Chen Gong <gong.chen@linux.intel.com> wrote:
> pkgtemp is derived from coretemp, so some reasonable
> logics should be applied onto pkgtemp, too. Such as
> the init logic here.
> 
> Signed-off-by: Chen Gong <gong.chen@linux.intel.com>

Acked-by: Jan Beulich <jbeulich@novell.com>

> ---
>  drivers/hwmon/pkgtemp.c |   23 +++++++----------------
>  1 files changed, 7 insertions(+), 16 deletions(-)
> 
> diff --git a/drivers/hwmon/pkgtemp.c b/drivers/hwmon/pkgtemp.c
> index f119039..6186041 100644
> --- a/drivers/hwmon/pkgtemp.c
> +++ b/drivers/hwmon/pkgtemp.c
> @@ -392,7 +392,6 @@ static struct notifier_block pkgtemp_cpu_notifier 
> __refdata = {
>  static int __init pkgtemp_init(void)
>  {
>  	int i, err = -ENODEV;
> -	struct pdev_entry *p, *n;
>  
>  	/* quick check if we run Intel */
>  	if (cpu_data(0).x86_vendor != X86_VENDOR_INTEL)
> @@ -402,31 +401,23 @@ static int __init pkgtemp_init(void)
>  	if (err)
>  		goto exit;
>  
> -	for_each_online_cpu(i) {
> -		err = pkgtemp_device_add(i);
> -		if (err)
> -			goto exit_devices_unreg;
> -	}
> +	for_each_online_cpu(i)
> +		pkgtemp_device_add(i);
> +
> +#ifndef CONFIG_HOTPLUG_CPU
>  	if (list_empty(&pdev_list)) {
>  		err = -ENODEV;
>  		goto exit_driver_unreg;
>  	}
> +#endif
>  
> -#ifdef CONFIG_HOTPLUG_CPU
>  	register_hotcpu_notifier(&pkgtemp_cpu_notifier);
> -#endif
>  	return 0;
>  
> -exit_devices_unreg:
> -	mutex_lock(&pdev_list_mutex);
> -	list_for_each_entry_safe(p, n, &pdev_list, list) {
> -		platform_device_unregister(p->pdev);
> -		list_del(&p->list);
> -		kfree(p);
> -	}
> -	mutex_unlock(&pdev_list_mutex);
> +#ifndef CONFIG_HOTPLUG_CPU
>  exit_driver_unreg:
>  	platform_driver_unregister(&pkgtemp_driver);
> +#endif
>  exit:
>  	return err;
>  }





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

* Re: [PATCH 2/2] hwmon: cleanup some hotplug related macro definition
  2010-09-26  6:00 ` [PATCH 2/2] hwmon: cleanup some hotplug related macro definition Chen Gong
@ 2010-09-27  7:11   ` Jan Beulich
  2010-09-27 14:58   ` [2/2] " Guenter Roeck
  2010-10-02  3:28   ` Guenter Roeck
  2 siblings, 0 replies; 12+ messages in thread
From: Jan Beulich @ 2010-09-27  7:11 UTC (permalink / raw)
  To: Chen Gong, lm-sensors; +Cc: linux-kernel

>>> On 26.09.10 at 08:00, Chen Gong <gong.chen@linux.intel.com> wrote:
> CONFIG_HOTPLUG_CPU is used too much in some drivers.
> This patch clean them up and add some proper __cpuinit definitons.
> 
> Signed-off-by: Chen Gong <gong.chen@linux.intel.com>

Acked-by: Jan Beulich <jbeulich@novell.com>

> ---
>  drivers/hwmon/coretemp.c    |    5 ++---
>  drivers/hwmon/pkgtemp.c     |    7 ++-----
>  drivers/hwmon/via-cputemp.c |    9 ++-------
>  3 files changed, 6 insertions(+), 15 deletions(-)
> 
> diff --git a/drivers/hwmon/coretemp.c b/drivers/hwmon/coretemp.c
> index baa842a..887ab93 100644
> --- a/drivers/hwmon/coretemp.c
> +++ b/drivers/hwmon/coretemp.c
> @@ -489,7 +489,7 @@ exit:
>  	return err;
>  }
>  
> -static void coretemp_device_remove(unsigned int cpu)
> +static void __cpuinit coretemp_device_remove(unsigned int cpu)
>  {
>  	struct pdev_entry *p;
>  	unsigned int i;
> @@ -568,9 +568,8 @@ exit:
>  static void __exit coretemp_exit(void)
>  {
>  	struct pdev_entry *p, *n;
> -#ifdef CONFIG_HOTPLUG_CPU
> +
>  	unregister_hotcpu_notifier(&coretemp_cpu_notifier);
> -#endif
>  	mutex_lock(&pdev_list_mutex);
>  	list_for_each_entry_safe(p, n, &pdev_list, list) {
>  		platform_device_unregister(p->pdev);
> diff --git a/drivers/hwmon/pkgtemp.c b/drivers/hwmon/pkgtemp.c
> index 6186041..0516d52 100644
> --- a/drivers/hwmon/pkgtemp.c
> +++ b/drivers/hwmon/pkgtemp.c
> @@ -339,8 +339,7 @@ exit:
>  	return err;
>  }
>  
> -#ifdef CONFIG_HOTPLUG_CPU
> -static void pkgtemp_device_remove(unsigned int cpu)
> +static void __cpuinit pkgtemp_device_remove(unsigned int cpu)
>  {
>  	struct pdev_entry *p;
>  	unsigned int i;
> @@ -387,7 +386,6 @@ static int __cpuinit pkgtemp_cpu_callback(struct 
> notifier_block *nfb,
>  static struct notifier_block pkgtemp_cpu_notifier __refdata = {
>  	.notifier_call = pkgtemp_cpu_callback,
>  };
> -#endif				/* !CONFIG_HOTPLUG_CPU */
>  
>  static int __init pkgtemp_init(void)
>  {
> @@ -425,9 +423,8 @@ exit:
>  static void __exit pkgtemp_exit(void)
>  {
>  	struct pdev_entry *p, *n;
> -#ifdef CONFIG_HOTPLUG_CPU
> +
>  	unregister_hotcpu_notifier(&pkgtemp_cpu_notifier);
> -#endif
>  	mutex_lock(&pdev_list_mutex);
>  	list_for_each_entry_safe(p, n, &pdev_list, list) {
>  		platform_device_unregister(p->pdev);
> diff --git a/drivers/hwmon/via-cputemp.c b/drivers/hwmon/via-cputemp.c
> index ffb793a..ebbdc25 100644
> --- a/drivers/hwmon/via-cputemp.c
> +++ b/drivers/hwmon/via-cputemp.c
> @@ -237,8 +237,7 @@ exit:
>  	return err;
>  }
>  
> -#ifdef CONFIG_HOTPLUG_CPU
> -static void via_cputemp_device_remove(unsigned int cpu)
> +static void __cpuinit via_cputemp_device_remove(unsigned int cpu)
>  {
>  	struct pdev_entry *p, *n;
>  	mutex_lock(&pdev_list_mutex);
> @@ -272,7 +271,6 @@ static int __cpuinit via_cputemp_cpu_callback(struct 
> notifier_block *nfb,
>  static struct notifier_block via_cputemp_cpu_notifier __refdata = {
>  	.notifier_call = via_cputemp_cpu_callback,
>  };
> -#endif				/* !CONFIG_HOTPLUG_CPU */
>  
>  static int __init via_cputemp_init(void)
>  {
> @@ -313,9 +311,7 @@ static int __init via_cputemp_init(void)
>  		goto exit_driver_unreg;
>  	}
>  
> -#ifdef CONFIG_HOTPLUG_CPU
>  	register_hotcpu_notifier(&via_cputemp_cpu_notifier);
> -#endif
>  	return 0;
>  
>  exit_devices_unreg:
> @@ -335,9 +331,8 @@ exit:
>  static void __exit via_cputemp_exit(void)
>  {
>  	struct pdev_entry *p, *n;
> -#ifdef CONFIG_HOTPLUG_CPU
> +
>  	unregister_hotcpu_notifier(&via_cputemp_cpu_notifier);
> -#endif
>  	mutex_lock(&pdev_list_mutex);
>  	list_for_each_entry_safe(p, n, &pdev_list, list) {
>  		platform_device_unregister(p->pdev);





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

* Re: [lm-sensors] [PATCH 1/2] hwmon: uniform the init style of pkgtemp
  2010-09-27  7:10   ` Jan Beulich
@ 2010-09-27 14:52     ` Guenter Roeck
  0 siblings, 0 replies; 12+ messages in thread
From: Guenter Roeck @ 2010-09-27 14:52 UTC (permalink / raw)
  To: Jan Beulich; +Cc: Chen Gong, lm-sensors, linux-kernel

On Mon, Sep 27, 2010 at 03:10:57AM -0400, Jan Beulich wrote:
> >>> On 26.09.10 at 07:59, Chen Gong <gong.chen@linux.intel.com> wrote:
> > pkgtemp is derived from coretemp, so some reasonable
> > logics should be applied onto pkgtemp, too. Such as
> > the init logic here.
> > 
> > Signed-off-by: Chen Gong <gong.chen@linux.intel.com>
> 
> Acked-by: Jan Beulich <jbeulich@novell.com>
> 
Applied to.

Thanks,
Guenter

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

* Re: [2/2] hwmon: cleanup some hotplug related macro definition
  2010-09-26  6:00 ` [PATCH 2/2] hwmon: cleanup some hotplug related macro definition Chen Gong
  2010-09-27  7:11   ` Jan Beulich
@ 2010-09-27 14:58   ` Guenter Roeck
  2010-10-02  3:28   ` Guenter Roeck
  2 siblings, 0 replies; 12+ messages in thread
From: Guenter Roeck @ 2010-09-27 14:58 UTC (permalink / raw)
  To: Chen Gong; +Cc: lm-sensors, JBeulich, linux-kernel

On Sun, Sep 26, 2010 at 06:00:00AM -0000, Chen Gong wrote:
> CONFIG_HOTPLUG_CPU is used too much in some drivers.
> This patch clean them up and add some proper __cpuinit definitons.
> 
> Signed-off-by: Chen Gong <gong.chen@linux.intel.com>
> Acked-by: Jan Beulich <jbeulich@novell.com>
> 
I am ok with the changes. However, they interfer with other changes 
made by Jan earlier, which I already applied. 

It would be great if you can rebase this patch to 
	git://git.kernel.org/pub/scm/linux/kernel/git/groeck/staging.git hwmon-next

That would help me a lot.

Thanks,
Guenter

> ---
> drivers/hwmon/coretemp.c    |    5 ++---
>  drivers/hwmon/pkgtemp.c     |    7 ++-----
>  drivers/hwmon/via-cputemp.c |    9 ++-------
>  3 files changed, 6 insertions(+), 15 deletions(-)
> 
> diff --git a/drivers/hwmon/coretemp.c b/drivers/hwmon/coretemp.c
> index baa842a..887ab93 100644
> --- a/drivers/hwmon/coretemp.c
> +++ b/drivers/hwmon/coretemp.c
> @@ -489,7 +489,7 @@ exit:
>  	return err;
>  }
>  
> -static void coretemp_device_remove(unsigned int cpu)
> +static void __cpuinit coretemp_device_remove(unsigned int cpu)
>  {
>  	struct pdev_entry *p;
>  	unsigned int i;
> @@ -568,9 +568,8 @@ exit:
>  static void __exit coretemp_exit(void)
>  {
>  	struct pdev_entry *p, *n;
> -#ifdef CONFIG_HOTPLUG_CPU
> +
>  	unregister_hotcpu_notifier(&coretemp_cpu_notifier);
> -#endif
>  	mutex_lock(&pdev_list_mutex);
>  	list_for_each_entry_safe(p, n, &pdev_list, list) {
>  		platform_device_unregister(p->pdev);
> diff --git a/drivers/hwmon/pkgtemp.c b/drivers/hwmon/pkgtemp.c
> index 6186041..0516d52 100644
> --- a/drivers/hwmon/pkgtemp.c
> +++ b/drivers/hwmon/pkgtemp.c
> @@ -339,8 +339,7 @@ exit:
>  	return err;
>  }
>  
> -#ifdef CONFIG_HOTPLUG_CPU
> -static void pkgtemp_device_remove(unsigned int cpu)
> +static void __cpuinit pkgtemp_device_remove(unsigned int cpu)
>  {
>  	struct pdev_entry *p;
>  	unsigned int i;
> @@ -387,7 +386,6 @@ static int __cpuinit pkgtemp_cpu_callback(struct notifier_block *nfb,
>  static struct notifier_block pkgtemp_cpu_notifier __refdata = {
>  	.notifier_call = pkgtemp_cpu_callback,
>  };
> -#endif				/* !CONFIG_HOTPLUG_CPU */
>  
>  static int __init pkgtemp_init(void)
>  {
> @@ -425,9 +423,8 @@ exit:
>  static void __exit pkgtemp_exit(void)
>  {
>  	struct pdev_entry *p, *n;
> -#ifdef CONFIG_HOTPLUG_CPU
> +
>  	unregister_hotcpu_notifier(&pkgtemp_cpu_notifier);
> -#endif
>  	mutex_lock(&pdev_list_mutex);
>  	list_for_each_entry_safe(p, n, &pdev_list, list) {
>  		platform_device_unregister(p->pdev);
> diff --git a/drivers/hwmon/via-cputemp.c b/drivers/hwmon/via-cputemp.c
> index ffb793a..ebbdc25 100644
> --- a/drivers/hwmon/via-cputemp.c
> +++ b/drivers/hwmon/via-cputemp.c
> @@ -237,8 +237,7 @@ exit:
>  	return err;
>  }
>  
> -#ifdef CONFIG_HOTPLUG_CPU
> -static void via_cputemp_device_remove(unsigned int cpu)
> +static void __cpuinit via_cputemp_device_remove(unsigned int cpu)
>  {
>  	struct pdev_entry *p, *n;
>  	mutex_lock(&pdev_list_mutex);
> @@ -272,7 +271,6 @@ static int __cpuinit via_cputemp_cpu_callback(struct notifier_block *nfb,
>  static struct notifier_block via_cputemp_cpu_notifier __refdata = {
>  	.notifier_call = via_cputemp_cpu_callback,
>  };
> -#endif				/* !CONFIG_HOTPLUG_CPU */
>  
>  static int __init via_cputemp_init(void)
>  {
> @@ -313,9 +311,7 @@ static int __init via_cputemp_init(void)
>  		goto exit_driver_unreg;
>  	}
>  
> -#ifdef CONFIG_HOTPLUG_CPU
>  	register_hotcpu_notifier(&via_cputemp_cpu_notifier);
> -#endif
>  	return 0;
>  
>  exit_devices_unreg:
> @@ -335,9 +331,8 @@ exit:
>  static void __exit via_cputemp_exit(void)
>  {
>  	struct pdev_entry *p, *n;
> -#ifdef CONFIG_HOTPLUG_CPU
> +
>  	unregister_hotcpu_notifier(&via_cputemp_cpu_notifier);
> -#endif
>  	mutex_lock(&pdev_list_mutex);
>  	list_for_each_entry_safe(p, n, &pdev_list, list) {
>  		platform_device_unregister(p->pdev);

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

* Re: [1/2] hwmon: uniform the init style of pkgtemp
  2010-09-26  5:59 ` [PATCH 1/2] hwmon: uniform the init style of pkgtemp Chen Gong
  2010-09-27  7:10   ` Jan Beulich
@ 2010-10-02  3:26   ` Guenter Roeck
  2010-10-08  3:42     ` Chen Gong
  1 sibling, 1 reply; 12+ messages in thread
From: Guenter Roeck @ 2010-10-02  3:26 UTC (permalink / raw)
  To: Chen Gong; +Cc: lm-sensors, JBeulich, linux-kernel

On Sun, Sep 26, 2010 at 05:59:59AM -0000, Chen Gong wrote:
> pkgtemp is derived from coretemp, so some reasonable
> logics should be applied onto pkgtemp, too. Such as
> the init logic here.
> 
> Signed-off-by: Chen Gong <gong.chen@linux.intel.com>
> Acked-by: Jan Beulich <jbeulich@novell.com>
> 
Hi,

this patch, when applied with CONFIG_HOTPLUG_CPU undefined, causes a compile failure
because it tries to access pkgtemp_cpu_notifier which is not defined in this case.
 
For that reason, I have removed the patch from the list of applied patches for -next.
Please re-submit a version which compiles for all combinations of HOTPLUG_CPU and SMP
defined/undefined.

Thanks,
Guenter

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

* Re: [2/2] hwmon: cleanup some hotplug related macro definition
  2010-09-26  6:00 ` [PATCH 2/2] hwmon: cleanup some hotplug related macro definition Chen Gong
  2010-09-27  7:11   ` Jan Beulich
  2010-09-27 14:58   ` [2/2] " Guenter Roeck
@ 2010-10-02  3:28   ` Guenter Roeck
  2 siblings, 0 replies; 12+ messages in thread
From: Guenter Roeck @ 2010-10-02  3:28 UTC (permalink / raw)
  To: Chen Gong; +Cc: lm-sensors, JBeulich, linux-kernel

On Sun, Sep 26, 2010 at 06:00:00AM -0000, Chen Gong wrote:
> CONFIG_HOTPLUG_CPU is used too much in some drivers.
> This patch clean them up and add some proper __cpuinit definitons.
> 
> Signed-off-by: Chen Gong <gong.chen@linux.intel.com>
> Acked-by: Jan Beulich <jbeulich@novell.com>
> 
Hi,

this patch fails to compile if SMP is undefined. For this reason, I have removed
it from the list of patches applied for -next.

Please re-submit a corrected version.

Thanks,
Guenter

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

* Re: [1/2] hwmon: uniform the init style of pkgtemp
  2010-10-02  3:26   ` [1/2] " Guenter Roeck
@ 2010-10-08  3:42     ` Chen Gong
  2010-10-08  3:52       ` Guenter Roeck
  0 siblings, 1 reply; 12+ messages in thread
From: Chen Gong @ 2010-10-08  3:42 UTC (permalink / raw)
  To: Guenter Roeck; +Cc: lm-sensors, JBeulich, linux-kernel

于 10/2/2010 11:26 AM, Guenter Roeck 写道:
> On Sun, Sep 26, 2010 at 05:59:59AM -0000, Chen Gong wrote:
>> pkgtemp is derived from coretemp, so some reasonable
>> logics should be applied onto pkgtemp, too. Such as
>> the init logic here.
>>
>> Signed-off-by: Chen Gong<gong.chen@linux.intel.com>
>> Acked-by: Jan Beulich<jbeulich@novell.com>
>>
> Hi,
>
> this patch, when applied with CONFIG_HOTPLUG_CPU undefined, causes a compile failure
> because it tries to access pkgtemp_cpu_notifier which is not defined in this case.
>
> For that reason, I have removed the patch from the list of applied patches for -next.
> Please re-submit a version which compiles for all combinations of HOTPLUG_CPU and SMP
> defined/undefined.
>
> Thanks,
> Guenter
>
Sorry for late. I just come back from my holiday. If only this one patch
is applied, it is broken, but it will be OK after these 2 patches are
applied. I tested the patches when CONFIG_SMP is undefined, it does be
broken again. My suggestion is adding a macro definiton in the pkgtemp.c
like "#include <asm/smp.h>". If it is doable, I will re-post a new patch
series

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

* Re: [1/2] hwmon: uniform the init style of pkgtemp
  2010-10-08  3:42     ` Chen Gong
@ 2010-10-08  3:52       ` Guenter Roeck
  2010-10-08  5:25         ` Chen Gong
  0 siblings, 1 reply; 12+ messages in thread
From: Guenter Roeck @ 2010-10-08  3:52 UTC (permalink / raw)
  To: Chen Gong; +Cc: lm-sensors, JBeulich, linux-kernel

On Thu, Oct 07, 2010 at 11:42:05PM -0400, Chen Gong wrote:
> 于 10/2/2010 11:26 AM, Guenter Roeck 写道:
> > On Sun, Sep 26, 2010 at 05:59:59AM -0000, Chen Gong wrote:
> >> pkgtemp is derived from coretemp, so some reasonable
> >> logics should be applied onto pkgtemp, too. Such as
> >> the init logic here.
> >>
> >> Signed-off-by: Chen Gong<gong.chen@linux.intel.com>
> >> Acked-by: Jan Beulich<jbeulich@novell.com>
> >>
> > Hi,
> >
> > this patch, when applied with CONFIG_HOTPLUG_CPU undefined, causes a compile failure
> > because it tries to access pkgtemp_cpu_notifier which is not defined in this case.
> >
> > For that reason, I have removed the patch from the list of applied patches for -next.
> > Please re-submit a version which compiles for all combinations of HOTPLUG_CPU and SMP
> > defined/undefined.
> >
> > Thanks,
> > Guenter
> >
> Sorry for late. I just come back from my holiday. If only this one patch
> is applied, it is broken, but it will be OK after these 2 patches are
> applied. I tested the patches when CONFIG_SMP is undefined, it does be

Each patch by itself must be compilable, otherwise we break the ability
to bisect. Not a good idea.

> broken again. My suggestion is adding a macro definiton in the pkgtemp.c
> like "#include <asm/smp.h>". If it is doable, I will re-post a new patch
> series

I assume you mean to add the include directive. Yes, that should do it,
but please make sure that it compiles.

Thanks,
Guenter

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

* Re: [1/2] hwmon: uniform the init style of pkgtemp
  2010-10-08  3:52       ` Guenter Roeck
@ 2010-10-08  5:25         ` Chen Gong
  0 siblings, 0 replies; 12+ messages in thread
From: Chen Gong @ 2010-10-08  5:25 UTC (permalink / raw)
  To: Guenter Roeck; +Cc: lm-sensors, JBeulich, linux-kernel

于 10/8/2010 11:52 AM, Guenter Roeck 写道:
> On Thu, Oct 07, 2010 at 11:42:05PM -0400, Chen Gong wrote:
>> 于 10/2/2010 11:26 AM, Guenter Roeck 写道:
>>> On Sun, Sep 26, 2010 at 05:59:59AM -0000, Chen Gong wrote:
>>>> pkgtemp is derived from coretemp, so some reasonable
>>>> logics should be applied onto pkgtemp, too. Such as
>>>> the init logic here.
>>>>
>>>> Signed-off-by: Chen Gong<gong.chen@linux.intel.com>
>>>> Acked-by: Jan Beulich<jbeulich@novell.com>
>>>>
>>> Hi,
>>>
>>> this patch, when applied with CONFIG_HOTPLUG_CPU undefined, causes a compile failure
>>> because it tries to access pkgtemp_cpu_notifier which is not defined in this case.
>>>
>>> For that reason, I have removed the patch from the list of applied patches for -next.
>>> Please re-submit a version which compiles for all combinations of HOTPLUG_CPU and SMP
>>> defined/undefined.
>>>
>>> Thanks,
>>> Guenter
>>>
>> Sorry for late. I just come back from my holiday. If only this one patch
>> is applied, it is broken, but it will be OK after these 2 patches are
>> applied. I tested the patches when CONFIG_SMP is undefined, it does be
>
> Each patch by itself must be compilable, otherwise we break the ability
> to bisect. Not a good idea.

Yes, but in fact it is an existing issue, not new incoming. The 1st 
patch isn't used for this purpose.

>
>> broken again. My suggestion is adding a macro definiton in the pkgtemp.c
>> like "#include<asm/smp.h>". If it is doable, I will re-post a new patch
>> series
>
> I assume you mean to add the include directive. Yes, that should do it,
> but please make sure that it compiles.

Sure, of course

>
> Thanks,
> Guenter
>


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

end of thread, other threads:[~2010-10-08  5:24 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-09-26  5:59 [PATHC 0/2] update and cleanup patches for coretemp etc Chen Gong
2010-09-26  5:59 ` [PATCH 1/2] hwmon: uniform the init style of pkgtemp Chen Gong
2010-09-27  7:10   ` Jan Beulich
2010-09-27 14:52     ` [lm-sensors] " Guenter Roeck
2010-10-02  3:26   ` [1/2] " Guenter Roeck
2010-10-08  3:42     ` Chen Gong
2010-10-08  3:52       ` Guenter Roeck
2010-10-08  5:25         ` Chen Gong
2010-09-26  6:00 ` [PATCH 2/2] hwmon: cleanup some hotplug related macro definition Chen Gong
2010-09-27  7:11   ` Jan Beulich
2010-09-27 14:58   ` [2/2] " Guenter Roeck
2010-10-02  3:28   ` 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).