Hi Simon, On Wed, 21 Aug 2024 at 20:10, Simon Horman <horms@xxxxxxxxxx> wrote: > > On Thu, Aug 15, 2024 at 10:32:27PM +0100, Dmitry Safonov via B4 Relay wrote: > > From: Dmitry Safonov <0x7f454c46@xxxxxxxxx> > > > > Instead of pre-allocating a fixed-sized buffer of TEST_MSG_BUFFER_SIZE > > and printing into it, call vsnprintf() with str = NULL, which will > > return the needed size of the buffer. This hack is documented in > > man 3 vsnprintf. > > > > Essentially, in C++ terms, it re-invents std::stringstream, which is > > going to be used to print different tracing paths and formatted strings. > > Use it straight away in __test_print() - which is thread-safe version of > > printing in selftests. > > > > Signed-off-by: Dmitry Safonov <0x7f454c46@xxxxxxxxx> > > Hi Dmitry, > > Some minor nits, as it looks like there will be a v4. Thanks, both seem reasonable. Did you get them with checkpatch.pl or with your trained eyes? :) These days I run b4 prep --check and on latest version it just gave a bunch of fmt-strings with columns > 100. Thanks, Dmitry