lkml.org 
[lkml]   [2020]   [Jan]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH 4.14 65/74] coresight: tmc-etf: Do not call smp_processor_id from preemptible
From
Date
Hi Nathan,

On 07/01/2020 23:08, Nathan Chancellor wrote:
> On Tue, Jan 07, 2020 at 09:55:30PM +0100, Greg Kroah-Hartman wrote:
>> From: Suzuki K Poulose <suzuki.poulose@arm.com>
>>
>> [ Upstream commit 024c1fd9dbcc1d8a847f1311f999d35783921b7f ]
>>

...

>> diff --git a/drivers/hwtracing/coresight/coresight-tmc-etf.c b/drivers/hwtracing/coresight/coresight-tmc-etf.c
>> index 336194d059fe..329a201c0c19 100644
>> --- a/drivers/hwtracing/coresight/coresight-tmc-etf.c
>> +++ b/drivers/hwtracing/coresight/coresight-tmc-etf.c
>> @@ -308,9 +308,7 @@ static void *tmc_alloc_etf_buffer(struct coresight_device *csdev, int cpu,
>> int node;
>> struct cs_buffers *buf;
>>
>> - if (cpu == -1)
>> - cpu = smp_processor_id();
>> - node = cpu_to_node(cpu);
>> + node = (event->cpu == -1) ? NUMA_NO_NODE : cpu_to_node(event->cpu);
>
> This breaks the build on 4.14 (and I believe 4.19 from the looks of it)
> because the event variable is not available without
> commit a0f08a6a9fee ("coresight: Communicate perf event to sink buffer
> allocation functions") from upstream. I am not sure how this should be
> fixed (either backporting the above commit or changing this one somehow)
> but it should be dropped in the meantime.

Thanks for the report. I will send a separate fix for the version where
it breaks. We should be able to use the "cpu" argument directly in these
cases, where event was not introduced.

Cheers
Suzuki

\
 
 \ /
  Last update: 2020-01-08 10:28    [W:0.119 / U:0.100 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site