From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by dpdk.org (Postfix) with ESMTP id 38A3B8E6D; Fri, 4 Dec 2015 11:54:27 +0100 (CET) Received: from int-mx14.intmail.prod.int.phx2.redhat.com (int-mx14.intmail.prod.int.phx2.redhat.com [10.5.11.27]) by mx1.redhat.com (Postfix) with ESMTPS id 27F2D47D5; Fri, 4 Dec 2015 10:54:26 +0000 (UTC) Received: from sopuli.koti.laiskiainen.org (vpn1-5-52.ams2.redhat.com [10.36.5.52]) by int-mx14.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id tB4AsOIi003817; Fri, 4 Dec 2015 05:54:25 -0500 From: Panu Matilainen To: "dev@dpdk.org" , "users@dpdk.org" , "dev@openvswitch.org" , discuss@openvswitch.org Message-ID: <566170E0.8080102@redhat.com> Date: Fri, 4 Dec 2015 12:54:24 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.4.0 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.68 on 10.5.11.27 Subject: [dpdk-users] [announce] driverctl: utility for persistent alternative driver binding X-BeenThere: users@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: usage discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 04 Dec 2015 10:54:27 -0000 Hi all, While this is not directly related to DPDK or OVS, it is potentially useful for users of both, so excuse me for cross-posting. Quoting from the project README (for the full text see http://laiskiainen.org/git/?p=driverctl.git;a=blob_plain;f=README) > driverctl is a tool for manipulating and inspecting the system > device driver choices. > > Devices are normally assigned to their sole designated kernel driver > by default. However in some situations it may be desireable to > override that default, for example to try an older driver to > work around a regression in a driver or to try an experimental > alternative driver. Another common use-case is pass-through > drivers and driver stubs to allow userspace to drive the device, > such as in case of virtualization. > > driverctl integrates with udev to support overriding > driver selection for both cold- and hotplugged devices from the > moment of discovery, but can also change already assigned drivers, > assuming they are not in use by the system. The driver overrides > created by driverctl are persistent across system reboots > by default. > > Usage > ----- > > Find devices currently driven by ixgbe driver: > > # driverctl -v list-devices | grep ixgbe > 0000:01:00.0 ixgbe (Ethernet 10G 4P X520/I350 rNDC) > 0000:01:00.1 ixgbe (Ethernet 10G 4P X520/I350 rNDC) > > Change them to use the vfio-pci driver: > # driverctl set-override 0000:01:00.0 vfio-pci > # driverctl set-override 0000:01:00.1 vfio-pci > > Find devices with driver overrides: > # driverctl -v list-devices|grep \\* > 0000:01:00.0 vfio-pci [*] (Ethernet 10G 4P X520/I350 rNDC) > 0000:01:00.1 vfio-pci [*] (Ethernet 10G 4P X520/I350 rNDC) > > Remove the override from slot 0000:01:00.1: > # driverctl unset-override 0000:01:00.1 DPDK of course has its own dpdk_nic_bind(.py) tool for this purpose, the main differences to driverctl are: - driverctl bindings are persistent across system boots - driverctl bindings take place immediately on cold- and hotplug - driverctl is a generic tool not limited to network adapters - dpdk_nic_bind being a special purpose tool has many more sanity checks for its supported use-cases - dpdk_nic_bind supports binding multiple NICs at once The project currently lives at http://laiskiainen.org/git/?p=driverctl.git Feedback, patches etc are welcome. - Panu -