Re: [RFC] seq_buf: Export symbols to external modules
From: Steven Rostedt
Date: Thu Apr 16 2020 - 09:10:05 EST
On Thu, 16 Apr 2020 09:21:24 +0530
Vaibhav Jain <vaibhav@xxxxxxxxxxxxx> wrote:
> 'seq_buf' provides a very useful abstraction for writing to a string
> buffer without needing to worry about it over-flowing. However even
> though the API has been stable for couple of years now its stills not
> exported to external modules limiting its usage.
>
> Hence this patch proposes update to 'seq_buf.c' to mark all functions
> seq_buf_X() which are part of the seq_seq API to be exported to
> external GPL modules.
>
> Earlier work:
> There was an earlier proposal by Borislav Petkov <bp@xxxxxxxxx> to
> export seq_buf_printf() to modules at [1], as part of his EDAC
> patch-set "EDAC, mce_amd: Add a tracepoint for the decoded
> error". However the proposed patch was never merged and its fate is
> unknown as I couldn't locate any subsequent discussion as to why patch
> in [1] was dropped.
>
> References:
> [1]: https://lore.kernel.org/lkml/20170825102411.8682-5-bp@xxxxxxxxx/
> [2]: https://lore.kernel.org/lkml/20170825092757.434f1eda@xxxxxxxxxxxxxxxxxx/
>
> Cc: Steven Rostedt <rostedt@xxxxxxxxxxx>
> Cc: Piotr Maziarz <piotrx.maziarz@xxxxxxxxxxxxxxx>
> Cc: Cezary Rojewski <cezary.rojewski@xxxxxxxxx>
> Cc: Borislav Petkov <bp@xxxxxxxxx>
> Signed-off-by: Vaibhav Jain <vaibhav@xxxxxxxxxxxxx>
> ---
> lib/seq_buf.c | 11 +++++++++++
> 1 file changed, 11 insertions(+)
>
>
I'm perfectly fine with this change, but recently there's been a lot of
discussion about doing something like this for out-of-tree modules. Is
there going to be a use case for in tree modules for this? It will make the
case much easier to get this accepted.
-- Steve