P2P: Add device address to the debug entry on oldest peer removal

This makes it easier to understand debug logs with large number of peer
entries.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
This commit is contained in:
Jouni Malinen 2020-12-09 00:13:15 +02:00 committed by Jouni Malinen
parent 8460e32309
commit 184c824689
1 changed files with 3 additions and 1 deletions

View File

@ -428,7 +428,9 @@ static struct p2p_device * p2p_create_device(struct p2p_data *p2p,
oldest = dev;
}
if (count + 1 > p2p->cfg->max_peers && oldest) {
p2p_dbg(p2p, "Remove oldest peer entry to make room for a new peer");
p2p_dbg(p2p,
"Remove oldest peer entry to make room for a new peer "
MACSTR, MAC2STR(oldest->info.p2p_device_addr));
dl_list_del(&oldest->list);
p2p_device_free(p2p, oldest);
}