]> git.baikalelectronics.ru Git - kernel.git/commit
net/smc: rework peer ID handling
authorHans Wippel <ndev@hwipl.net>
Tue, 25 Feb 2020 21:41:21 +0000 (22:41 +0100)
committerDavid S. Miller <davem@davemloft.net>
Thu, 27 Feb 2020 04:27:06 +0000 (20:27 -0800)
commit0522ffea70ed4429bf4acfd1dc8ae68e3a8a8e97
treecb1fe57818629f7b2d6e999af04ea1d717c462a5
parent6be85df59950ba73ec12c6f97a014b69a6f6d0e6
net/smc: rework peer ID handling

This patch initializes the peer ID to a random instance ID and a zero
MAC address. If a RoCE device is in the host, the MAC address part of
the peer ID is overwritten with the respective address. Also, a function
for checking if the peer ID is valid is added. A peer ID is considered
valid if the MAC address part contains a non-zero MAC address.

Signed-off-by: Hans Wippel <ndev@hwipl.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/smc/smc_ib.c