lkml.org 
[lkml]   [2001]   [Feb]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH] Hot swap CPU support for 2.4.1
Date
In message <20010211002955.I7877@bug.ucw.cz> you write:
> This is not quite right:
>
> @@ -1643,7 +1643,7 @@
> printk(KERN_NOTICE "apm: disabled on user
> request.\n");
> return -ENODEV;
> }
> - if ((smp_num_cpus > 1) && !power_off) {
> + if ((num_online_cpus() > 1) && !power_off) {
> printk(KERN_NOTICE "apm: disabled - APM is not SMP
>
> I do not think it is safe to call APM when there is just CPU #5
> running. smp_num_cpus in this context means "if we ever had more than
> boot cpu".

Um, it's not safe to call APM in SMP full stop: we try anyway.
However, this code changes nothing since it's only run at boot.

Cheers,
Rusty.
--
Premature optmztion is rt of all evl. --DK
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:13    [W:0.095 / U:6.488 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site