]> git.baikalelectronics.ru Git - kernel.git/commitdiff
net/mlx5e: Do not use netdev_err() before the netdev is registered
authorAchiad Shochat <achiad@mellanox.com>
Wed, 29 Jul 2015 12:05:44 +0000 (15:05 +0300)
committerDavid S. Miller <davem@davemloft.net>
Thu, 30 Jul 2015 06:04:46 +0000 (23:04 -0700)
Since it is un-named at this time.

Signed-off-by: Achiad Shochat <achiad@mellanox.com>
Signed-off-by: Amir Vadai <amirv@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlx5/core/en_main.c

index 550491034356b5ea8c467c81fcad6ad959719608..6581f5896d928d92e7ef2222889ed7999cc2fd6a 100644 (file)
@@ -1893,36 +1893,31 @@ static void *mlx5e_create_netdev(struct mlx5_core_dev *mdev)
 
        err = mlx5_alloc_map_uar(mdev, &priv->cq_uar);
        if (err) {
-               netdev_err(netdev, "%s: mlx5_alloc_map_uar failed, %d\n",
-                          __func__, err);
+               mlx5_core_err(mdev, "alloc_map uar failed, %d\n", err);
                goto err_free_netdev;
        }
 
        err = mlx5_core_alloc_pd(mdev, &priv->pdn);
        if (err) {
-               netdev_err(netdev, "%s: mlx5_core_alloc_pd failed, %d\n",
-                          __func__, err);
+               mlx5_core_err(mdev, "alloc pd failed, %d\n", err);
                goto err_unmap_free_uar;
        }
 
        err = mlx5_alloc_transport_domain(mdev, &priv->tdn);
        if (err) {
-               netdev_err(netdev, "%s: mlx5_alloc_transport_domain failed, %d\n",
-                          __func__, err);
+               mlx5_core_err(mdev, "alloc td failed, %d\n", err);
                goto err_dealloc_pd;
        }
 
        err = mlx5e_create_mkey(priv, priv->pdn, &priv->mr);
        if (err) {
-               netdev_err(netdev, "%s: mlx5e_create_mkey failed, %d\n",
-                          __func__, err);
+               mlx5_core_err(mdev, "create mkey failed, %d\n", err);
                goto err_dealloc_transport_domain;
        }
 
        err = register_netdev(netdev);
        if (err) {
-               netdev_err(netdev, "%s: register_netdev failed, %d\n",
-                          __func__, err);
+               mlx5_core_err(mdev, "register_netdev failed, %d\n", err);
                goto err_destroy_mkey;
        }