Re: [PATCH] printf: Remove unused 'bprintf'

From: Dr. David Alan Gilbert
Date: Wed Oct 02 2024 - 13:33:14 EST


* Steven Rostedt (rostedt@xxxxxxxxxxx) wrote:
> On Wed, 2 Oct 2024 14:31:19 +0000
> "Dr. David Alan Gilbert" <linux@xxxxxxxxxxx> wrote:
>
> > > I am not familiar with tricks in BPF or ftrace code where this actually might
> > > be implicitly called via a macro, but brief grep gives nothing that might point
> > > to that.
> >
> > I've got an all-yes build (well, most after I took out broken stuff) booting
> > with it, and it has CONFIG_BINARY_PRINTF=y and CONFIG_FTRACE=y .
> >
> > trace_seq.c uses seq_buf_bprintf which uses bstr_printf rather than the plain
> > bprintf() that I've deleted.
> > Not sure where to dig in BPF, but I've had a fairly good grep around.
>
> I believe it is safe to delete. It looks like bprintf() was added for
> completeness, where as everything is just using the vbin_printf() directly.
> bprintf() is nothing more than a wrapper around it in case someone wanted
> to use binary prints directly. But I'm not sure there's a good use case for
> it, as all users would likely need to add some code around it for
> processing (like trace.c does).
>
> Send a v2 and I could take it for v6.13.

Thanks,

Just posted, message-id 20241002173147.210107-1-linux@xxxxxxxxxxx

Dave

> -- Steve
>
--
-----Open up your eyes, open up your mind, open up your code -------
/ Dr. David Alan Gilbert | Running GNU/Linux | Happy \
\ dave @ treblig.org | | In Hex /
\ _________________________|_____ http://www.treblig.org |_______/