lkml.org 
[lkml]   [2015]   [Apr]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [tip:timers/core] timer: Allocate per-cpu tvec_base's statically
From
Date
On Thu, 2015-04-02 at 11:47 -0700, tip-bot for Peter Zijlstra wrote:
> Commit-ID: b337a9380f7effd60d082569dd7e0b97a7549730
> Gitweb: http://git.kernel.org/tip/b337a9380f7effd60d082569dd7e0b97a7549730
> Author: Peter Zijlstra <peterz@infradead.org>
> AuthorDate: Tue, 31 Mar 2015 20:49:00 +0530
> Committer: Ingo Molnar <mingo@kernel.org>
> CommitDate: Thu, 2 Apr 2015 17:46:00 +0200
>
> timer: Allocate per-cpu tvec_base's statically
>
...

> This will also guarantee that tvec_base is cacheline aligned. Even
> though tvec_base has ____cacheline_aligned stuck on, kzalloc_node() does
> not actually respect that (but guarantees a minimum u64 alignment).

...

> +static DEFINE_PER_CPU(struct tvec_base, __tvec_bases);


This should probably use DEFINE_PER_CPU_ALIGNED() to avoid holes in
percpu section.


$ objdump -h kernel/time/built-in.o | grep percpu
111 .data..percpu 00002592 0000000000000000 0000000000000000 0001cbc0
2**6


instead of :

$ objdump -h kernel/time/built-in.o | grep percpu
111 .data..percpu 00000532 0000000000000000 0000000000000000 0001cbc0
2**5
113 .data..percpu..shared_aligned 00002040 0000000000000000
0000000000000000 0001d140 2**6

I'll send a patch.




\
 
 \ /
  Last update: 2015-04-14 16:21    [W:0.055 / U:0.628 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site