So I pushed out the whole series of vsprintf cleanups into the 'vsnprintf' branch. It's rebased on top of 6.13-rc4, and if it works for people, I'll keep it stable. But note that last commit, which makes the 'binary' version pack numerical arguments (but not '%c') with the traditional and simpler C type expansion (ie 'at least int sized'). Everything else is *supposed* to be a complete no-op, and only clean up code (and make it generate a lot better code, btw). The main objective having been to make it possibly easier to do fairly straightforward printf code with while (*fmt.str) { fmt = format_decode(fmt, &spec); switch (fmt.state) { case FORMAT_STATE_NONE: ... } } with a lot fewer case statements (particularly cutting down the number handling to the point where you *really* don't need to worry about all the special cases). It's still obviously not usable from outside the vsprintf.c code itself (none of these interfaces are exported to modules, and are in fact still 'static'). But it's at the point where maybe it's clean enough that some day it *could* be exposed. Anyway, comments? Particularly any of the strange vbin_printf / bstr_printf users, because that last commit does change the encoding of %hd / %hhd in the binary buffer. It does look like bpf can't care, and tracing hopefully always pairs up vbin_printf with bstr_printf, but maybe some horrid thing exposes the raw buffer to user space.