lkml.org 
[lkml]   [2019]   [Feb]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH v9 2/3] x86,/proc/pid/status: Add AVX-512 usage elapsed time
From
Date
On 2019/2/12 16:22, Thomas Gleixner wrote:
> On Tue, 12 Feb 2019, Aubrey Li wrote:
>> diff --git a/arch/x86/include/asm/processor.h b/arch/x86/include/asm/processor.h
>> index d53c54b842da..60ee932070fe 100644
>> --- a/arch/x86/include/asm/processor.h
>> +++ b/arch/x86/include/asm/processor.h
>> @@ -996,5 +996,7 @@ enum l1tf_mitigations {
>> };
>>
>> extern enum l1tf_mitigations l1tf_mitigation;
>> +/* Add support for architecture specific output in /proc/pid/status */
>> +extern void arch_proc_pid_status(struct seq_file *m, struct task_struct *task);
>
> Sigh. This is absolutely the wrong place. The weak function is declared and
> used in fs/proc/... So the prototype wants to be in a header which is
> included from there independent of x86...

Can the prototype be in the architecture header if they want to call the function?
Like the following? arch_report_meminfo() is used in fs/proc/... as well.

$ find . -name *.h | xargs grep arch_report_meminfo
./arch/s390/include/asm/pgtable.h:void arch_report_meminfo(struct seq_file *m);
./arch/x86/include/asm/pgtable_types.h:extern void arch_report_meminfo(struct seq_file *m);
./arch/parisc/include/asm/pgtable.h:extern void arch_report_meminfo(struct seq_file *m);

Thanks,
-Aubrey

\
 
 \ /
  Last update: 2019-02-12 10:15    [W:1.934 / U:0.004 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site