Print the value of DEVLINK_ATTR_SB_POOL_CELL_SIZE, if reported.
Example:
pci/0000:82:00.0:
sb 1 pool 0 type egress size
40945664 thtype static cell_size 2048
sb 2 pool 0 type egress size
258867200 thtype static cell_size 10240
...
v3: - don't double space.
v2: - fix spelling.
Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Reviewed-by: Quentin Monnet <quentin.monnet@netronome.com>
Acked-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David Ahern <dsahern@gmail.com>
mnl_attr_get_u32(tb[DEVLINK_ATTR_SB_POOL_SIZE]));
pr_out_str(dl, "thtype",
threshold_type_name(mnl_attr_get_u8(tb[DEVLINK_ATTR_SB_POOL_THRESHOLD_TYPE])));
+ if (tb[DEVLINK_ATTR_SB_POOL_CELL_SIZE])
+ pr_out_uint(dl, "cell_size",
+ mnl_attr_get_u32(tb[DEVLINK_ATTR_SB_POOL_CELL_SIZE]));
pr_out_handle_end(dl);
}
- specifies the devlink device to show pools.
If this argument is omitted all pools of all devices are listed.
+Display available pools listing their
+.B type, size, thtype
+and
+.B cell_size. cell_size
+is the allocation granularity of memory within the shared buffer. Drivers
+may round up, round down or reject
+.B size
+passed to the set command if it is not multiple of
+.B cell_size.
+
.SS devlink sb pool set - set attributes of pool
.PP