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/
This archive was generated by hypermail 2b29 : Thu Feb 15 2001 - 21:00:17 EST