lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <87efozop2c.fsf@vitty.brq.redhat.com>
Date:   Wed, 15 Nov 2017 10:42:51 +0100
From:   Vitaly Kuznetsov <vkuznets@...hat.com>
To:     Haiyang Zhang <haiyangz@...rosoft.com>
Cc:     Stephen Hemminger <stephen@...workplumber.org>,
        "netdev\@vger.kernel.org" <netdev@...r.kernel.org>,
        "linux-kernel\@vger.kernel.org" <linux-kernel@...r.kernel.org>,
        "devel\@linuxdriverproject.org" <devel@...uxdriverproject.org>,
        KY Srinivasan <kys@...rosoft.com>,
        Stephen Hemminger <sthemmin@...rosoft.com>,
        "Mohammed Gamal" <mmorsy@...hat.com>
Subject: Re: [PATCH net] hv_netvsc: preserve hw_features on mtu/channels/ringparam changes

Haiyang Zhang <haiyangz@...rosoft.com> writes:

>> -----Original Message-----
>> From: Vitaly Kuznetsov [mailto:vkuznets@...hat.com]
>> Sent: Tuesday, November 14, 2017 11:58 AM
>> To: Stephen Hemminger <stephen@...workplumber.org>
>> Cc: netdev@...r.kernel.org; linux-kernel@...r.kernel.org;
>> devel@...uxdriverproject.org; KY Srinivasan <kys@...rosoft.com>; Haiyang
>> Zhang <haiyangz@...rosoft.com>; Stephen Hemminger
>> <sthemmin@...rosoft.com>; Mohammed Gamal <mmorsy@...hat.com>
>> Subject: Re: [PATCH net] hv_netvsc: preserve hw_features on
>> mtu/channels/ringparam changes
>> 
>> Stephen Hemminger <stephen@...workplumber.org> writes:
>> 
>> > On Tue, 14 Nov 2017 16:22:05 +0100
>> > Vitaly Kuznetsov <vkuznets@...hat.com> wrote:
>> >
>> > Yes, this looks like a real issue.
>> >
>> >> +	/* Query hardware capabilities if we're called from netvsc_probe() */
>> >> +	if (!net->hw_features) {
>> >> +		ret = rndis_netdev_set_hwcaps(net_device, rndis_device);
>> >> +		if (ret != 0)
>> >> +			goto err_dev_remv;
>> >> +	}
>> >> +
>> >
>> > Rather than conditional behavior in rndis_filter_device_add, it would
>> > be cleaner to make the call to get hardware capabilities there.
>> >
>> > Please respin and make the query of host a separate function.
>> 
>> You mean call rndis_netdev_set_hwcaps() from netvsc_probe()? Will do.
>> 
>> One question though: in case we'll be avoiding
>> rndis_filter_set_offload_params() call on mtu/channels/ringparam changes -
>> - can we trust the host to preserve what was there before the RNDIS reset?
>> In case not we'll have to untangle what is
>> rndis_netdev_set_hwcaps() in my patch splitting it into two: hw_features
>> setup and rndis_filter_set_offload_params() and leaving the later in
>> rndis_filter_device_add().
>
> After remove/re-add RNDIS dev, you should pass the parameters to the host
> again.
>

Thanks, this changes a lot. I'll prepare v2.

-- 
  Vitaly

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ