linux-mips.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] MIPS: CPU#0 is not hotpluggable
@ 2020-07-15  5:35 Huacai Chen
  2020-07-15  7:56 ` Sergei Shtylyov
  0 siblings, 1 reply; 3+ messages in thread
From: Huacai Chen @ 2020-07-15  5:35 UTC (permalink / raw)
  To: Thomas Bogendoerfer
  Cc: linux-mips, Fuxin Zhang, Zhangjin Wu, Huacai Chen, Jiaxun Yang,
	Huacai Chen, stable

Now CPU#0 is not hotpluggable on MIPS, so prevent to create /sys/devices
/system/cpu/cpu0/online which confusing some user-space tools.

Cc: stable@vger.kernel.org
Signed-off-by: Huacai Chen <chenhc@lemote.com>
---
 arch/mips/kernel/topology.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/mips/kernel/topology.c b/arch/mips/kernel/topology.c
index cd3e1f8..08ad637 100644
--- a/arch/mips/kernel/topology.c
+++ b/arch/mips/kernel/topology.c
@@ -20,7 +20,7 @@ static int __init topology_init(void)
 	for_each_present_cpu(i) {
 		struct cpu *c = &per_cpu(cpu_devices, i);
 
-		c->hotpluggable = 1;
+		c->hotpluggable = !!i;
 		ret = register_cpu(c, i);
 		if (ret)
 			printk(KERN_WARNING "topology_init: register_cpu %d "
-- 
2.7.0


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

* Re: [PATCH] MIPS: CPU#0 is not hotpluggable
  2020-07-15  5:35 [PATCH] MIPS: CPU#0 is not hotpluggable Huacai Chen
@ 2020-07-15  7:56 ` Sergei Shtylyov
  2020-07-15  8:09   ` Huacai Chen
  0 siblings, 1 reply; 3+ messages in thread
From: Sergei Shtylyov @ 2020-07-15  7:56 UTC (permalink / raw)
  To: Huacai Chen, Thomas Bogendoerfer
  Cc: linux-mips, Fuxin Zhang, Zhangjin Wu, Huacai Chen, Jiaxun Yang, stable

Hello!

On 15.07.2020 8:35, Huacai Chen wrote:

> Now CPU#0 is not hotpluggable on MIPS, so prevent to create /sys/devices
> /system/cpu/cpu0/online which confusing some user-space tools.

    Confuses?

> Cc: stable@vger.kernel.org
> Signed-off-by: Huacai Chen <chenhc@lemote.com>
[...]

MBR, Sergei

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

* Re: [PATCH] MIPS: CPU#0 is not hotpluggable
  2020-07-15  7:56 ` Sergei Shtylyov
@ 2020-07-15  8:09   ` Huacai Chen
  0 siblings, 0 replies; 3+ messages in thread
From: Huacai Chen @ 2020-07-15  8:09 UTC (permalink / raw)
  To: Sergei Shtylyov
  Cc: Thomas Bogendoerfer, open list:MIPS, Fuxin Zhang, Zhangjin Wu,
	Jiaxun Yang, stable

Hi, Sergei,

On Wed, Jul 15, 2020 at 3:56 PM Sergei Shtylyov
<sergei.shtylyov@cogentembedded.com> wrote:
>
> Hello!
>
> On 15.07.2020 8:35, Huacai Chen wrote:
>
> > Now CPU#0 is not hotpluggable on MIPS, so prevent to create /sys/devices
> > /system/cpu/cpu0/online which confusing some user-space tools.
>
>     Confuses?
Yes, this is my fault.

>
> > Cc: stable@vger.kernel.org
> > Signed-off-by: Huacai Chen <chenhc@lemote.com>
> [...]
>
> MBR, Sergei

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

end of thread, other threads:[~2020-07-15  8:09 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-15  5:35 [PATCH] MIPS: CPU#0 is not hotpluggable Huacai Chen
2020-07-15  7:56 ` Sergei Shtylyov
2020-07-15  8:09   ` Huacai Chen

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