From patchwork Fri Feb 27 11:21:27 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Cunming Liang X-Patchwork-Id: 3769 Return-Path: X-Original-To: patchwork@dpdk.org Delivered-To: patchwork@dpdk.org Received: from [92.243.14.124] (localhost [IPv6:::1]) by dpdk.org (Postfix) with ESMTP id C887F376E; Fri, 27 Feb 2015 12:21:46 +0100 (CET) Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by dpdk.org (Postfix) with ESMTP id 625DE3208 for ; Fri, 27 Feb 2015 12:21:44 +0100 (CET) Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by fmsmga102.fm.intel.com with ESMTP; 27 Feb 2015 03:21:32 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.09,659,1418112000"; d="scan'208,217";a="460242313" Received: from pgsmsx101.gar.corp.intel.com ([10.221.44.78]) by FMSMGA003.fm.intel.com with ESMTP; 27 Feb 2015 03:05:53 -0800 Received: from kmsmsx154.gar.corp.intel.com (172.21.73.14) by PGSMSX101.gar.corp.intel.com (10.221.44.78) with Microsoft SMTP Server (TLS) id 14.3.195.1; Fri, 27 Feb 2015 19:21:29 +0800 Received: from shsmsx101.ccr.corp.intel.com (10.239.4.153) by KMSMSX154.gar.corp.intel.com (172.21.73.14) with Microsoft SMTP Server (TLS) id 14.3.195.1; Fri, 27 Feb 2015 19:21:29 +0800 Received: from shsmsx102.ccr.corp.intel.com ([169.254.2.62]) by SHSMSX101.ccr.corp.intel.com ([169.254.1.192]) with mapi id 14.03.0195.001; Fri, 27 Feb 2015 19:21:28 +0800 From: "Liang, Cunming" To: David Marchand Thread-Topic: [PATCH v6 3/8] eal/bsd: dummy for new intr definition Thread-Index: AQHQUknLGGa9M8FfWEe4UzypeR8XYZ0DvY6AgACXOBA= Date: Fri, 27 Feb 2015 11:21:27 +0000 Message-ID: References: <1424710542-14637-1-git-send-email-danny.zhou@intel.com> <1425012976-10173-1-git-send-email-cunming.liang@intel.com> <1425012976-10173-4-git-send-email-cunming.liang@intel.com> In-Reply-To: Accept-Language: zh-CN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] MIME-Version: 1.0 X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Cc: "dev@dpdk.org" Subject: Re: [dpdk-dev] [PATCH v6 3/8] eal/bsd: dummy for new intr definition 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: , Errors-To: dev-bounces@dpdk.org Sender: "dev" From: David Marchand [mailto:david.marchand@6wind.com] Sent: Friday, February 27, 2015 6:00 PM To: Liang, Cunming Cc: dev@dpdk.org; Stephen Hemminger; Thomas Monjalon Subject: Re: [PATCH v6 3/8] eal/bsd: dummy for new intr definition Hello, On Fri, Feb 27, 2015 at 5:56 AM, Cunming Liang > wrote: [Liang, Cunming] max_intr is used in dev_init for pci_dev->intr_handle init. Vec_num is used in ethdev API rx_intr_vec_get. Without it, BSD macro will used for each of the reference place. As they’re quite generic, even bsd will require either max_intr or vec mapping table. -- David Marchand diff --git a/lib/librte_eal/bsdapp/eal/include/exec-env/rte_interrupts.h b/lib/librte_eal/bsdapp/eal/include/exec-env/rte_interrupts.h index 87a9cf6..b114aac 100644 --- a/lib/librte_eal/bsdapp/eal/include/exec-env/rte_interrupts.h +++ b/lib/librte_eal/bsdapp/eal/include/exec-env/rte_interrupts.h @@ -38,6 +38,8 @@ #ifndef _RTE_LINUXAPP_INTERRUPTS_H_ #define _RTE_LINUXAPP_INTERRUPTS_H_ +#define VFIO_MAX_RXTX_INTR_ID 32 + enum rte_intr_handle_type { RTE_INTR_HANDLE_UNKNOWN = 0, RTE_INTR_HANDLE_UIO, /**< uio device handle */ @@ -49,6 +51,8 @@ enum rte_intr_handle_type { struct rte_intr_handle { int fd; /**< file descriptor */ enum rte_intr_handle_type type; /**< handle type */ + int max_intr; /**< max interrupt requested */ + uint32_t vec_num[VFIO_MAX_QUEUE_ID]; /**< rxtx intr vector number */ }; No need to add those since this is not supported for bsd.