lkml.org 
[lkml]   [2021]   [Aug]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2 bpf-next 1/3] perf: enable branch record for software events
On Mon, Aug 30, 2021 at 05:41:46PM +0000, Song Liu wrote:
> DECLARE_STATIC_CALL(perf_snapshot_branch_stack,
> int (*)(struct perf_branch_snapshot *));

> Something like
>
> typedef int (perf_snapshot_branch_stack_t)(struct perf_branch_snapshot *);
> DECLARE_STATIC_CALL(perf_snapshot_branch_stack, perf_snapshot_branch_stack_t);
>
> seems to work fine.

Oh urg, indeed. It wants a function type, not a function pointer type.
I've been bitten by that before. Go with the typedef, that's the sanest.

\
 
 \ /
  Last update: 2021-08-30 20:08    [W:0.137 / U:0.364 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site