Messages in this thread | | | Date | Fri, 02 Nov 2012 23:25:51 +0800 | From | Shan Wei <> | Subject | Re: [PATCH 8/9] trace: use this_cpu_ptr per-cpu helper |
| |
Christoph Lameter said, at 2012/11/1 1:50: >> >> - buffer = per_cpu_ptr(percpu_buffer, smp_processor_id()); >> + buffer = this_cpu_ptr(percpu_buffer); >> >> return buffer->buffer; > > > Just do a > > return this_cpu_read(percpu_buffer->buffer); > > and get rid of the this_cpu_ptr op
can not do that. kernel/trace/trace.c:1515: error: incompatible types when assigning to type 'char[1024]' from type 'char *'
| |