summaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/cavium/liquidio
diff options
context:
space:
mode:
authorJoe Perches <joe@perches.com>2018-06-22 10:51:00 -0700
committerDavid S. Miller <davem@davemloft.net>2018-06-23 10:49:14 +0900
commit6c1f0a1ffb7c2b0501521b9fc1f53b4109f1791b (patch)
tree681b06d46c984ad460150cb9ac4011e8b58c686e /drivers/net/ethernet/cavium/liquidio
parentd55207e37a35f811e1d93ae83d4dcaaaecde053d (diff)
downloadblackbird-op-linux-6c1f0a1ffb7c2b0501521b9fc1f53b4109f1791b.tar.gz
blackbird-op-linux-6c1f0a1ffb7c2b0501521b9fc1f53b4109f1791b.zip
net: drivers/net: Convert random_ether_addr to eth_random_addr
random_ether_addr is a #define for eth_random_addr which is generally preferred in kernel code by ~3:1 Convert the uses of random_ether_addr to enable removing the #define Miscellanea: o Convert &vfmac[0] to equivalent vfmac and avoid unnecessary line wrap Signed-off-by: Joe Perches <joe@perches.com> Acked-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/cavium/liquidio')
-rw-r--r--drivers/net/ethernet/cavium/liquidio/lio_main.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/net/ethernet/cavium/liquidio/lio_main.c b/drivers/net/ethernet/cavium/liquidio/lio_main.c
index 8a815bb57177..7cb4e753829b 100644
--- a/drivers/net/ethernet/cavium/liquidio/lio_main.c
+++ b/drivers/net/ethernet/cavium/liquidio/lio_main.c
@@ -3569,9 +3569,8 @@ static int setup_nic_devices(struct octeon_device *octeon_dev)
for (j = 0; j < octeon_dev->sriov_info.max_vfs; j++) {
u8 vfmac[ETH_ALEN];
- random_ether_addr(&vfmac[0]);
- if (__liquidio_set_vf_mac(netdev, j,
- &vfmac[0], false)) {
+ eth_random_addr(vfmac);
+ if (__liquidio_set_vf_mac(netdev, j, vfmac, false)) {
dev_err(&octeon_dev->pci_dev->dev,
"Error setting VF%d MAC address\n",
j);
OpenPOWER on IntegriCloud