Skip to content

tipc: kill off struct print_buf/log

Paul Gortmaker netdev 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest8 patches 0 repliesNew

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/8tipc: factor stats struct out of the larger link structnet/tipc/link.h+32 -300 replies
2/8tipc: limit error messages relating to memory leak to one linenet/tipc/name_table.c+4 -20 replies
3/8tipc: use standard printk shortcut macros (pr_err etc.)net/tipc/bcast.c net/tipc/bearer.c net/tipc/config.c +15 more+168 -1661 reply
4/8tipc: remove TIPC packet debugging functions and macrosnet/tipc/Kconfig net/tipc/core.h net/tipc/link.c +1 more+0 -3120 replies
5/8tipc: simplify link_print by divorcing it from using tipc_printfnet/tipc/link.c+7 -170 replies
6/8tipc: simplify print buffer handling in tipc_printfnet/tipc/log.c+10 -420 replies
7/8tipc: phase out most of the struct print_buf usagenet/tipc/bcast.c net/tipc/bearer.c net/tipc/bearer.h +7 more+213 -2220 replies
8/8tipc: remove print_buf and deprecated log buffer codeinclude/linux/tipc_config.h net/tipc/Kconfig net/tipc/config.c +5 more+4 -3350 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH net-next 0/8] tipc: kill off struct print_buf/log

Dave,

The main thrust of what happens in this series is to deal with the request you'd made a while ago about making it so TIPC did not have its own specific (and complex) logging infrastructure.

It used to have tipc_printf taking an arg of this struct print_buf thing, with a length field in it. There was also a function to set/validate string lengths etc. So the approach was to first wean off as many users of tipc_printf as possible (e.g. by deleting old debug code, etc.) and then changing tipc_printf into something much simpler that conveyed string lengths via normal return values one would expect from snprintf-like functions. Finally, with the core code no longer using the print_buf struct, it and the log code associated with it are removed.

A side bonus is that we get rid of a couple TIPC related Kconfig options along the way, and about 600 lines of code too.

The folks at Ericsson did most of the work here, and I just refactored things a bit and made a few suggestions here and there. I've also run the server/client tests on this series atop of the net-next baseline of 48ee3569f "ipv6: Move ipv6 twsk accessors outside of CONFIG_IPV6 ifdefs."

If there no obvious problems spotted by anyone in the next day or so, I would like to issue a pull request for these.

Thanks,
Paul.
---

Erik Hugne (5):
tipc: use standard printk shortcut macros (pr_err etc.)
tipc: remove TIPC packet debugging functions and macros
tipc: simplify print buffer handling in tipc_printf
tipc: phase out most of the struct print_buf usage
tipc: remove print_buf and deprecated log buffer code

Paul Gortmaker (3):
tipc: factor stats struct out of the larger link struct
tipc: limit error messages relating to memory leak to one line
tipc: simplify link_print by divorcing it from using tipc_printf

 include/linux/tipc_config.h |    4 +-
 net/tipc/Kconfig            |   25 ----
 net/tipc/bcast.c            |   65 +++++-----
 net/tipc/bearer.c           |   62 +++++----
 net/tipc/bearer.h           |    2 +-
 net/tipc/config.c           |   41 +++---
 net/tipc/core.c             |   15 +--
 net/tipc/core.h             |   63 +--------
 net/tipc/discover.c         |   10 +-
 net/tipc/handler.c          |    4 +-
 net/tipc/link.c             |  297 ++++++++++++++++++------------------------
 net/tipc/link.h             |   63 ++++-----
 net/tipc/log.c              |  302 ++-----------------------------------------
 net/tipc/log.h              |   66 ----------
 net/tipc/msg.c              |  242 ----------------------------------
 net/tipc/name_distr.c       |   25 ++--
 net/tipc/name_table.c       |  132 ++++++++++---------
 net/tipc/net.c              |    8 +-
 net/tipc/netlink.c          |    2 +-
 net/tipc/node.c             |   23 ++--
 net/tipc/node_subscr.c      |    3 +-
 net/tipc/port.c             |   66 +++++-----
 net/tipc/ref.c              |   10 +-
 net/tipc/socket.c           |    4 +-
 net/tipc/subscr.c           |   14 +-
 25 files changed, 430 insertions(+), 1118 deletions(-)
 delete mode 100644 net/tipc/log.h
Signature · 1 line
1.7.9.7