lkml.org 
[lkml]   [2017]   [Aug]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH net-next] net-next/hinic: Fix MTU limitation
On Thu, Aug 24, 2017 at 09:21:25PM +0800, Aviad Krawczyk wrote:
> Fix the hw MTU limitation by setting min/max_mtu
>
> Signed-off-by: Aviad Krawczyk <aviad.krawczyk@huawei.com>
> Signed-off-by: Zhao Chen <zhaochen6@huawei.com>
> ---
> drivers/net/ethernet/huawei/hinic/hinic_main.c | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/drivers/net/ethernet/huawei/hinic/hinic_main.c b/drivers/net/ethernet/huawei/hinic/hinic_main.c
> index ae7ad48..7a14963 100644
> --- a/drivers/net/ethernet/huawei/hinic/hinic_main.c
> +++ b/drivers/net/ethernet/huawei/hinic/hinic_main.c
> @@ -980,6 +980,9 @@ static int nic_dev_init(struct pci_dev *pdev)
> hinic_hwdev_cb_register(nic_dev->hwdev, HINIC_MGMT_MSG_CMD_LINK_STATUS,
> nic_dev, link_status_event_handler);
>
> + netdev->min_mtu = ETH_MIN_MTU;

You don't need to set the min_mtu. See:

http://elixir.free-electrons.com/linux/latest/source/net/ethernet/eth.c#L354

Andrew

\
 
 \ /
  Last update: 2017-08-24 17:21    [W:0.066 / U:6.172 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site