Re: [PATCH] avoid using smp_processor_id() in preemptible code (nr_iowait_cpu)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 15 Jun 2010 19:13:03 +0300
Sergey Senozhatsky <sergey.senozhatsky@xxxxxxxxx> wrote:

> 
> I've changed struct tick_sched to match passed *ts and cpu. Also
> changed "&per_cpu(tick_cpu_sched, cpu)" call to "struct tick_sched
> *tick_get_tick_sched(int cpu)" which we already have.
> 
> But I don't really like this part:
> struct tick_sched *tick_get_tick_sched(int cpu)
> {
> 	struct tick_sched *ts = &per_cpu(tick_cpu_sched, cpu);
> 	ts->cpu = cpu;
> 	^^^^^^^^^^^^^
> 	return ts;
> }
> 
> Please kindly review.


can we do this bit once, when the ts structure gets initialized?
it's not like the cpu value will ever change...


-- 
Arjan van de Ven 	Intel Open Source Technology Centre
For development, discussion and tips for power savings, 
visit http://www.lesswatts.org
_______________________________________________
linux-pm mailing list
linux-pm@xxxxxxxxxxxxxxxxxxxxxxxxxx
https://lists.linux-foundation.org/mailman/listinfo/linux-pm


[Index of Archives]     [Linux ACPI]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [CPU Freq]     [Kernel Newbies]     [Fedora Kernel]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux