Created attachment 257515 [details] The patch to add more flag names in db_print_sbflags Current db_print_sbflags() prints only a few flag names in sys/sys/sockbuf.h. This patch adds more flags to display more names. e.g. after the patch applied. ``` sb_flags: 0x2161 (SB_TLS_RX, SB_UPCALL, SB_KNOTE, SB_AIO_RUNNING, SBS_CANTRCVMORE, SBS_RCVATMARK) ```
Hi! Do you use ddb(4) commands to look at the socket buffer in practice or it is just desire to make a function right as long as it exists? In my daily development in this area, I don't use it for over a decade. Today bhyve allows a gdb port and this is how I look at the debugged kernel. On a live system I would use dtrace to print desired values. I'm tending to remove uipc_debug.c entirely actually.
Thank you for your reply. Yes, itβs just that I want it to work correctly as long as it exists. Therefore, I agree with the direction of completely removing uipc_debug.c. Would you like to send the patch, or should I update this Bugzilla with the patch instead?
I'd vote for just removing these functions as well. They're not very useful in this day and age. Alternately we could add flag name strings that can be passed to the %b format in printf(9), but IMO it's probably not worth the effort.