From: Aaradhana Sahu <quic_aarasahu@xxxxxxxxxxx> Add support to print tx power per link for an ML interface Sample output: phy#0 Interface wlp88s0 ifindex 5 wdev 0x1 addr 00:03:7f:01:54:92 ssid tx_power_123 type AP multicast TXQ: qsz-byt qsz-pkt flows drops marks overlmt hashcol tx-bytes tx-packets 0 0 0 0 0 0 0 0 0 MLD with links: - link ID 0 link addr 00:03:7f:01:54:92 channel 36 (5180 MHz), width: 80 MHz, center1: 5210 MHz txpower 30.00 dBm Signed-off-by: Aaradhana Sahu <quic_aarasahu@xxxxxxxxxxx> Signed-off-by: Rameshkumar Sundaram <quic_ramess@xxxxxxxxxxx> --- interface.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/interface.c b/interface.c index bb1a1d30385c..0d4ff042c7a6 100644 --- a/interface.c +++ b/interface.c @@ -490,6 +490,11 @@ static int print_iface_handler(struct nl_msg *msg, void *arg) printf("\n%s\t ", indent); print_channel(tb); } + if (tb[NL80211_ATTR_WIPHY_TX_POWER_LEVEL]) { + int32_t txp = nla_get_u32(tb[NL80211_ATTR_WIPHY_TX_POWER_LEVEL]); + + printf("\n%s\t txpower %d.%.2d dBm", indent, txp / 100, txp % 100); + } printf("\n"); } } base-commit: 478ddd470cce0302e928c089062365ca69aa36f9 -- 2.34.1