net: ethernet: intel: Demote MTU change prints to debug
Changing a network device MTU can be a fairly frequent operation, and failure to change the MTU is reflected to user-space properly, both by an appropriate message as well as by looking at whether the device's MTU matches the configuration. Demote the prints to debug prints by using netdev_dbg(), making all Intel wired LAN drivers consistent, since they used a mixture of PCI device and network device prints before. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Acked-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Родитель
693bd8b7ae
Коммит
12299132b3
|
@ -3565,8 +3565,8 @@ static int e1000_change_mtu(struct net_device *netdev, int new_mtu)
|
||||||
(max_frame == MAXIMUM_ETHERNET_VLAN_SIZE)))
|
(max_frame == MAXIMUM_ETHERNET_VLAN_SIZE)))
|
||||||
adapter->rx_buffer_len = MAXIMUM_ETHERNET_VLAN_SIZE;
|
adapter->rx_buffer_len = MAXIMUM_ETHERNET_VLAN_SIZE;
|
||||||
|
|
||||||
pr_info("%s changing MTU from %d to %d\n",
|
netdev_dbg(netdev, "changing MTU from %d to %d\n",
|
||||||
netdev->name, netdev->mtu, new_mtu);
|
netdev->mtu, new_mtu);
|
||||||
netdev->mtu = new_mtu;
|
netdev->mtu = new_mtu;
|
||||||
|
|
||||||
if (netif_running(netdev))
|
if (netif_running(netdev))
|
||||||
|
|
|
@ -6031,7 +6031,8 @@ static int e1000_change_mtu(struct net_device *netdev, int new_mtu)
|
||||||
usleep_range(1000, 1100);
|
usleep_range(1000, 1100);
|
||||||
/* e1000e_down -> e1000e_reset dependent on max_frame_size & mtu */
|
/* e1000e_down -> e1000e_reset dependent on max_frame_size & mtu */
|
||||||
adapter->max_frame_size = max_frame;
|
adapter->max_frame_size = max_frame;
|
||||||
e_info("changing MTU from %d to %d\n", netdev->mtu, new_mtu);
|
netdev_dbg(netdev, "changing MTU from %d to %d\n",
|
||||||
|
netdev->mtu, new_mtu);
|
||||||
netdev->mtu = new_mtu;
|
netdev->mtu = new_mtu;
|
||||||
|
|
||||||
pm_runtime_get_sync(netdev->dev.parent);
|
pm_runtime_get_sync(netdev->dev.parent);
|
||||||
|
|
|
@ -2664,8 +2664,8 @@ static int i40e_change_mtu(struct net_device *netdev, int new_mtu)
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
}
|
}
|
||||||
|
|
||||||
netdev_info(netdev, "changing MTU from %d to %d\n",
|
netdev_dbg(netdev, "changing MTU from %d to %d\n",
|
||||||
netdev->mtu, new_mtu);
|
netdev->mtu, new_mtu);
|
||||||
netdev->mtu = new_mtu;
|
netdev->mtu = new_mtu;
|
||||||
if (netif_running(netdev))
|
if (netif_running(netdev))
|
||||||
i40e_vsi_reinit_locked(vsi);
|
i40e_vsi_reinit_locked(vsi);
|
||||||
|
|
|
@ -6236,7 +6236,6 @@ static void igb_get_stats64(struct net_device *netdev,
|
||||||
static int igb_change_mtu(struct net_device *netdev, int new_mtu)
|
static int igb_change_mtu(struct net_device *netdev, int new_mtu)
|
||||||
{
|
{
|
||||||
struct igb_adapter *adapter = netdev_priv(netdev);
|
struct igb_adapter *adapter = netdev_priv(netdev);
|
||||||
struct pci_dev *pdev = adapter->pdev;
|
|
||||||
int max_frame = new_mtu + ETH_HLEN + ETH_FCS_LEN + VLAN_HLEN;
|
int max_frame = new_mtu + ETH_HLEN + ETH_FCS_LEN + VLAN_HLEN;
|
||||||
|
|
||||||
/* adjust max frame to be at least the size of a standard frame */
|
/* adjust max frame to be at least the size of a standard frame */
|
||||||
|
@ -6252,8 +6251,8 @@ static int igb_change_mtu(struct net_device *netdev, int new_mtu)
|
||||||
if (netif_running(netdev))
|
if (netif_running(netdev))
|
||||||
igb_down(adapter);
|
igb_down(adapter);
|
||||||
|
|
||||||
dev_info(&pdev->dev, "changing MTU from %d to %d\n",
|
netdev_dbg(netdev, "changing MTU from %d to %d\n",
|
||||||
netdev->mtu, new_mtu);
|
netdev->mtu, new_mtu);
|
||||||
netdev->mtu = new_mtu;
|
netdev->mtu = new_mtu;
|
||||||
|
|
||||||
if (netif_running(netdev))
|
if (netif_running(netdev))
|
||||||
|
|
|
@ -2437,8 +2437,8 @@ static int igbvf_change_mtu(struct net_device *netdev, int new_mtu)
|
||||||
adapter->rx_buffer_len = ETH_FRAME_LEN + VLAN_HLEN +
|
adapter->rx_buffer_len = ETH_FRAME_LEN + VLAN_HLEN +
|
||||||
ETH_FCS_LEN;
|
ETH_FCS_LEN;
|
||||||
|
|
||||||
dev_info(&adapter->pdev->dev, "changing MTU from %d to %d\n",
|
netdev_dbg(netdev, "changing MTU from %d to %d\n",
|
||||||
netdev->mtu, new_mtu);
|
netdev->mtu, new_mtu);
|
||||||
netdev->mtu = new_mtu;
|
netdev->mtu = new_mtu;
|
||||||
|
|
||||||
if (netif_running(netdev))
|
if (netif_running(netdev))
|
||||||
|
|
|
@ -2272,7 +2272,6 @@ static int igc_change_mtu(struct net_device *netdev, int new_mtu)
|
||||||
{
|
{
|
||||||
int max_frame = new_mtu + ETH_HLEN + ETH_FCS_LEN + VLAN_HLEN;
|
int max_frame = new_mtu + ETH_HLEN + ETH_FCS_LEN + VLAN_HLEN;
|
||||||
struct igc_adapter *adapter = netdev_priv(netdev);
|
struct igc_adapter *adapter = netdev_priv(netdev);
|
||||||
struct pci_dev *pdev = adapter->pdev;
|
|
||||||
|
|
||||||
/* adjust max frame to be at least the size of a standard frame */
|
/* adjust max frame to be at least the size of a standard frame */
|
||||||
if (max_frame < (ETH_FRAME_LEN + ETH_FCS_LEN))
|
if (max_frame < (ETH_FRAME_LEN + ETH_FCS_LEN))
|
||||||
|
@ -2287,8 +2286,8 @@ static int igc_change_mtu(struct net_device *netdev, int new_mtu)
|
||||||
if (netif_running(netdev))
|
if (netif_running(netdev))
|
||||||
igc_down(adapter);
|
igc_down(adapter);
|
||||||
|
|
||||||
dev_info(&pdev->dev, "changing MTU from %d to %d\n",
|
netdev_dbg(netdev, "changing MTU from %d to %d\n",
|
||||||
netdev->mtu, new_mtu);
|
netdev->mtu, new_mtu);
|
||||||
netdev->mtu = new_mtu;
|
netdev->mtu = new_mtu;
|
||||||
|
|
||||||
if (netif_running(netdev))
|
if (netif_running(netdev))
|
||||||
|
|
|
@ -6725,7 +6725,8 @@ static int ixgbe_change_mtu(struct net_device *netdev, int new_mtu)
|
||||||
(new_mtu > ETH_DATA_LEN))
|
(new_mtu > ETH_DATA_LEN))
|
||||||
e_warn(probe, "Setting MTU > 1500 will disable legacy VFs\n");
|
e_warn(probe, "Setting MTU > 1500 will disable legacy VFs\n");
|
||||||
|
|
||||||
e_info(probe, "changing MTU from %d to %d\n", netdev->mtu, new_mtu);
|
netdev_dbg(netdev, "changing MTU from %d to %d\n",
|
||||||
|
netdev->mtu, new_mtu);
|
||||||
|
|
||||||
/* must set new MTU before calling down or up */
|
/* must set new MTU before calling down or up */
|
||||||
netdev->mtu = new_mtu;
|
netdev->mtu = new_mtu;
|
||||||
|
|
Загрузка…
Ссылка в новой задаче