From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id CE933A04A9; Tue, 25 Jan 2022 07:53:50 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id B33AC4288B; Tue, 25 Jan 2022 07:53:28 +0100 (CET) Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by mails.dpdk.org (Postfix) with ESMTP id 26EDC4286D for ; Tue, 25 Jan 2022 07:53:27 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1643093607; x=1674629607; h=from:to:cc:subject:date:message-id:in-reply-to: references; bh=f9iIhO50rLyIGKCTBiUd876H7y7ZRQkY7IipgetRm0o=; b=I0IM+A/ic+PZO9D5sh90VTACg41Voa7WDlE51HLicoQTv8NGNUR76lGA JUwl8KpuYzHgRlqyjHpOpX3OIr6Z9IdtOOTDLZALVAtOJwOb9qaQD5jZu YgcK5jYvC0g4quFZsiZFvclndq1AcvXcGFRzf9f4Tpq/Q9gj35eiZ2uVj jdPo7eXOXwiQp8M/4zNjUl7RXTMPT7acC9Rarcz+AbJwm8oQ10uBYhTCI GTztX1ioQOaqgMxdO5naLIDDbuWA0SUEXuxWasb2mi/Xna/4HcdHMs/m9 SU0j4BBG/ptuzEC2iDBA0BeGOqVIjAoVxTEGe5rxYIoa9xFR3lTw6fyeU Q==; X-IronPort-AV: E=McAfee;i="6200,9189,10237"; a="246181326" X-IronPort-AV: E=Sophos;i="5.88,314,1635231600"; d="scan'208";a="246181326" Received: from orsmga005.jf.intel.com ([10.7.209.41]) by orsmga103.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 24 Jan 2022 22:53:26 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.88,314,1635231600"; d="scan'208";a="695724302" Received: from dpdk-dipei.sh.intel.com ([10.67.111.91]) by orsmga005.jf.intel.com with ESMTP; 24 Jan 2022 22:53:25 -0800 From: Andy Pei To: dev@dpdk.org Cc: chenbo.xia@intel.com, maxime.coquelin@redhat.com, gang.cao@intel.com, changpeng.liu@intel.com Subject: [PATCH 07/15] usertools: add support for virtio blk device Date: Tue, 25 Jan 2022 14:47:30 +0800 Message-Id: <1643093258-47258-8-git-send-email-andy.pei@intel.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1643093258-47258-1-git-send-email-andy.pei@intel.com> References: <1643093258-47258-1-git-send-email-andy.pei@intel.com> X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Signed-off-by: Andy Pei --- usertools/dpdk-devbind.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/usertools/dpdk-devbind.py b/usertools/dpdk-devbind.py index ace4627..cbe336f 100755 --- a/usertools/dpdk-devbind.py +++ b/usertools/dpdk-devbind.py @@ -14,6 +14,8 @@ from os.path import join as path_join # The PCI base class for all devices +virtio_blk_class = {'Class': '01', 'Vendor': "1af4", 'Device': '1001', + 'SVendor': '8086', 'SDevice': '0002'} network_class = {'Class': '02', 'Vendor': None, 'Device': None, 'SVendor': None, 'SDevice': None} acceleration_class = {'Class': '12', 'Vendor': None, 'Device': None, @@ -72,6 +74,7 @@ cn9k_ree = {'Class': '08', 'Vendor': '177d', 'Device': 'a0f4', 'SVendor': None, 'SDevice': None} +virtio_blk_devices = [virtio_blk_class] network_devices = [network_class, cavium_pkx, avp_vnic, ifpga_class] baseband_devices = [acceleration_class] crypto_devices = [encryption_class, intel_processor_class] @@ -587,6 +590,9 @@ def show_status(): Displays to the user what devices are bound to the igb_uio driver, the kernel driver or to no driver''' + if status_dev in ["virtio_blk", "all"]: + show_device_status(virtio_blk_devices, "virtio_blk") + if status_dev in ["net", "all"]: show_device_status(network_devices, "Network", if_field=True) @@ -746,6 +752,7 @@ def do_arg_actions(): if b_flag is not None: clear_data() # refresh if we have changed anything + get_device_details(virtio_blk_devices) get_device_details(network_devices) get_device_details(baseband_devices) get_device_details(crypto_devices) @@ -769,6 +776,7 @@ def main(): parse_args() check_modules() clear_data() + get_device_details(virtio_blk_devices) get_device_details(network_devices) get_device_details(baseband_devices) get_device_details(crypto_devices) -- 1.8.3.1