From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pa0-f43.google.com (mail-pa0-f43.google.com [209.85.220.43]) by dpdk.org (Postfix) with ESMTP id 2784B5937 for ; Wed, 12 Mar 2014 21:18:37 +0100 (CET) Received: by mail-pa0-f43.google.com with SMTP id bj1so27939pad.30 for ; Wed, 12 Mar 2014 13:20:07 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:subject:date:message-id; bh=xp8mEs6BiJEXvZaIXy9+v+cj8nFW4ooRiush4sWZfYw=; b=MdqbkHKcPgdArrKRzyA3YHyH+ktSSiOBsnfkVGHCWERBk8QXGIK4bdKqCpCe98zj/y JFpnJYr0T2x+PbX+I3PcIzxfVwuNTm8LpzqocBRSIc1lYX3Aw+s2SvyjEb5K4OHAQ+h4 jiFu1bn77IL69qsvDwFP6Utpu96tqeww5agVOSiTPe1SJkKQKWTtOOtPMOutiRknWt1Y g25eACGmZf5Bxy5lPWyMa2sq+duIyrh9jzYsFPt0C9gwWtT73j+ORjplQ+L4V222Y6Og 446vxLlEjdzG70XWEPAX0hWFWxaNd+YmIi5VtTQzJwDdRrE19R4b1f2QDxxz2FvCdlQx AA6g== X-Gm-Message-State: ALoCoQk4u3bPjKafQxV0z1JcTwxGQAJmhs4QjnP0J5yOpCQXTcWF011C8xfYIBiVzPyu54Org985 X-Received: by 10.67.5.39 with SMTP id cj7mr7354533pad.7.1394655607360; Wed, 12 Mar 2014 13:20:07 -0700 (PDT) Received: from localhost.localdomain ([50.242.95.29]) by mx.google.com with ESMTPSA id yo9sm26525748pab.16.2014.03.12.13.20.05 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 12 Mar 2014 13:20:06 -0700 (PDT) From: Daniel Kan To: dev@dpdk.org Date: Wed, 12 Mar 2014 13:19:59 -0700 Message-Id: <1394655599-5991-1-git-send-email-dan@nyansa.com> X-Mailer: git-send-email 1.7.9.5 Subject: [dpdk-dev] [PATCH] vmxnet3: fixed segfault when initializing vmxnet3 pmd on linux platform X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 12 Mar 2014 20:18:38 -0000 The vmxnet3 PCI hardware resources were never memory mapped when RE_EAL_UNBIND_PORTS is not defined. Specifically, pci_dev->mem_resource is not mapped. The fix is to always set drv_flags with RTE_PCI_DRV_NEED_IGU for vmxnet3. This ensures pci_uio_map_resource() is called. Signed-off-by: Daniel Kan --- lib/librte_pmd_vmxnet3/vmxnet3_ethdev.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/lib/librte_pmd_vmxnet3/vmxnet3_ethdev.c b/lib/librte_pmd_vmxnet3/vmxnet3_ethdev.c index 6757aa2..8259cfe 100644 --- a/lib/librte_pmd_vmxnet3/vmxnet3_ethdev.c +++ b/lib/librte_pmd_vmxnet3/vmxnet3_ethdev.c @@ -267,9 +267,7 @@ static struct eth_driver rte_vmxnet3_pmd = { { .name = "rte_vmxnet3_pmd", .id_table = pci_id_vmxnet3_map, -#ifdef RTE_EAL_UNBIND_PORTS .drv_flags = RTE_PCI_DRV_NEED_IGB_UIO, -#endif }, .eth_dev_init = eth_vmxnet3_dev_init, .dev_private_size = sizeof(struct vmxnet3_adapter), -- 1.7.9.5