]> git.baikalelectronics.ru Git - kernel.git/commit
ionic: VF initial random MAC address if no assigned mac
authorR Mohamed Shah <mohamed@pensando.io>
Wed, 24 Aug 2022 16:50:51 +0000 (09:50 -0700)
committerJakub Kicinski <kuba@kernel.org>
Thu, 25 Aug 2022 19:39:54 +0000 (12:39 -0700)
commit8effcfe09b7c4ff6d72d6404883bab71ca88263d
tree0a87f70ab916b4047f2f32c055ee08116c0e1c62
parentab81dab2eb28c16aed5b514250d8fa782b737397
ionic: VF initial random MAC address if no assigned mac

Assign a random mac address to the VF interface station
address if it boots with a zero mac address in order to match
similar behavior seen in other VF drivers.  Handle the errors
where the older firmware does not allow the VF to set its own
station address.

Newer firmware will allow the VF to set the station mac address
if it hasn't already been set administratively through the PF.
Setting it will also be allowed if the VF has trust.

Fixes: a1287907419d ("ionic: support sr-iov operations")
Signed-off-by: R Mohamed Shah <mohamed@pensando.io>
Signed-off-by: Shannon Nelson <snelson@pensando.io>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/pensando/ionic/ionic_lif.c