Message ID | 48284d15bf68cb154cf3948f3fd0b8ea11981ff3.1265314112.git.root@sanx1002.austin.ibm.com |
---|---|
State | Accepted, archived |
Delegated to: | David Miller |
Headers | show |
On Thu, Feb 04, 2010 at 12:11:18PM -0800, leitao@linux.vnet.ibm.com wrote: > Currently the qlge_change_mtu() is never called if the new_mtu is > equal current MTU, due this condition on dev_set_mtu(): Both look good. Thanks Signed-off-by: Ron Mercer <ron.mercer@qlogic.com> -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
From: Ron Mercer <ron.mercer@qlogic.com> Date: Thu, 4 Feb 2010 15:11:30 -0800 > On Thu, Feb 04, 2010 at 12:11:18PM -0800, leitao@linux.vnet.ibm.com wrote: >> Currently the qlge_change_mtu() is never called if the new_mtu is >> equal current MTU, due this condition on dev_set_mtu(): > > Both look good. Thanks > > > Signed-off-by: Ron Mercer <ron.mercer@qlogic.com> Both patches applied, thanks everyone. -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/drivers/net/qlge/qlge_main.c b/drivers/net/qlge/qlge_main.c index 7e00029..c583fb5 100644 --- a/drivers/net/qlge/qlge_main.c +++ b/drivers/net/qlge/qlge_main.c @@ -4123,9 +4123,6 @@ static int qlge_change_mtu(struct net_device *ndev, int new_mtu) QPRINTK(qdev, IFUP, ERR, "Changing to jumbo MTU.\n"); } else if (ndev->mtu == 9000 && new_mtu == 1500) { QPRINTK(qdev, IFUP, ERR, "Changing to normal MTU.\n"); - } else if ((ndev->mtu == 1500 && new_mtu == 1500) || - (ndev->mtu == 9000 && new_mtu == 9000)) { - return 0; } else return -EINVAL;
Currently the qlge_change_mtu() is never called if the new_mtu is equal current MTU, due this condition on dev_set_mtu(): if (new_mtu == dev->mtu) return 0; So, this block of code is never reached and is being removed. Signed-off-by: Breno Leitao <leitao@linux.vnet.ibm.com> --- drivers/net/qlge/qlge_main.c | 3 --- 1 files changed, 0 insertions(+), 3 deletions(-)