From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Monjalon Subject: Re: [PATCH v5 8/9] virtio: add 1.0 support Date: Thu, 21 Jan 2016 12:49:10 +0100 Message-ID: <4677246.JVjdGphvhY@xps13> References: <1452832571-6156-1-git-send-email-yuanhan.liu@linux.intel.com> <1453191125-26335-1-git-send-email-yuanhan.liu@linux.intel.com> <1453191125-26335-9-git-send-email-yuanhan.liu@linux.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7Bit Cc: dev@dpdk.org To: Yuanhan Liu Return-path: Received: from mail-wm0-f46.google.com (mail-wm0-f46.google.com [74.125.82.46]) by dpdk.org (Postfix) with ESMTP id BB2F28E64 for ; Thu, 21 Jan 2016 12:50:11 +0100 (CET) Received: by mail-wm0-f46.google.com with SMTP id n5so76420340wmn.0 for ; Thu, 21 Jan 2016 03:50:11 -0800 (PST) In-Reply-To: <1453191125-26335-9-git-send-email-yuanhan.liu@linux.intel.com> List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" 2016-01-19 16:12, Yuanhan Liu: > int > vtpci_init(struct rte_pci_device *dev, struct virtio_hw *hw) > { > - hw->vtpci_ops = &legacy_ops; > + hw->dev = dev; > + > + /* > + * Try if we can succeed reading virtio pci caps, which exists > + * only on modern pci device. If failed, we fallback to legacy > + * virtio handling. > + */ > + if (virtio_read_caps(dev, hw) == 0) { > + PMD_INIT_LOG(INFO, "modern virtio pci detected."); > + hw->vtpci_ops = &modern_ops; > + hw->modern = 1; > + dev->driver->drv_flags |= RTE_PCI_DRV_INTR_LSC; > + return 0; > + } RTE_PCI_DRV_INTR_LSC is already set by virtio_resource_init_by_uio(). Do you mean interrupt was not supported with legacy virtio?