Re: [PATCH iproute2 v4 1/2] tc: u32: add support for json output
From: Stephen Hemminger <stephen@networkplumber.org>
Date: 2022-01-18 04:30:50
On Mon, 17 Jan 2022 21:42:20 -0500 Wen Liang [off-list ref] wrote:
Currently u32 filter output does not support json. This commit uses proper json functions to add support for it. Signed-off-by: Wen Liang <redacted>
Minor warnings from checkpatch, please fix: WARNING: Missing a blank line after declarations #88: FILE: tc/f_u32.c:1231: + __u32 htdivisor = rta_getattr_u32(tb[TCA_U32_DIVISOR]); + print_int(PRINT_ANY, "ht_divisor", "ht divisor %d ", htdivisor); ERROR: space required after that ',' (ctx:VxV) #114: FILE: tc/f_u32.c:1250: + char *link = sprint_u32_handle(rta_getattr_u32(tb[TCA_U32_LINK]),b1); ^ WARNING: Missing a blank line after declarations #115: FILE: tc/f_u32.c:1251: + char *link = sprint_u32_handle(rta_getattr_u32(tb[TCA_U32_LINK]),b1); + print_string(PRINT_ANY, "link", "link %s ", link); WARNING: Missing a blank line after declarations #202: FILE: tc/f_u32.c:1323: + unsigned int hmask = (unsigned int)htonl(sel->hmask); + print_hex(PRINT_ANY, "hash_mask", " hash mask %08x ", hmask); total: 1 errors, 3 warnings, 151 lines checked