From patchwork Thu Sep 22 05:44:05 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jianfeng Tan X-Patchwork-Id: 16011 X-Patchwork-Delegate: thomas@monjalon.net 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 2B82358C3; Thu, 22 Sep 2016 07:43:52 +0200 (CEST) Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by dpdk.org (Postfix) with ESMTP id 005A45689 for ; Thu, 22 Sep 2016 07:43:50 +0200 (CEST) Received: from orsmga004.jf.intel.com ([10.7.209.38]) by orsmga104.jf.intel.com with ESMTP; 21 Sep 2016 22:43:49 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.30,377,1470726000"; d="scan'208";a="12419093" Received: from dpdk06.sh.intel.com ([10.239.129.195]) by orsmga004.jf.intel.com with ESMTP; 21 Sep 2016 22:43:48 -0700 From: Jianfeng Tan To: dev@dpdk.org Cc: ferruh.yigit@intel.com, david.marchand@6wind.com, thomas.monjalon@6wind.com, Jianfeng Tan Date: Thu, 22 Sep 2016 05:44:05 +0000 Message-Id: <1474523045-2674-1-git-send-email-jianfeng.tan@intel.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1472696197-37614-1-git-send-email-jianfeng.tan@intel.com> References: <1472696197-37614-1-git-send-email-jianfeng.tan@intel.com> Subject: [dpdk-dev] [PATCH] doc: remove iomem and ioport handling in igb_uio 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" In igb_uio, iomem is mapped, and both ioport and io mem are recorded into uio framework (then into sysfs files), which is duplicated with what Linux has already provided for user space, and makes the code too complex. For iomem, DPDK user space code never opens or reads files under /sys/pci/bus/devices/xxxx:xx:xx.x/uio/uioY/maps/. Instead, /sys/pci/bus/devices/xxxx:xx:xx.x/resourceY are used to map device memory. For ioport, non-x86 platforms cannot read from files under /sys/pci/bus/devices/xxxx:xx:xx.x/uio/uioY/portio/ directly, because non-x86 platforms need to map port region for access in user space, see non-x86 version pci_uio_ioport_map(). x86 platforms can use the the same way as uio_pci_generic. This will remove iomem and ioport mapping in igb_uio kernel module, and adjusts the iomem implementation in both igb_uio and uio_pci_generic: - for x86 platform, get ports info from /proc/ioports; - for non-x86 platform, map and get ports info by pci_uio_ioport_map(). Note: this will affect those applications who are using files under /sys/pci/bus/devices/xxxx:xx:xx.x/uio/uioY/maps/ and /sys/pci/bus/devices/xxxx:xx:xx.x/uio/uioY/portio/. Suggested-by: Yigit, Ferruh Signed-off-by: Jianfeng Tan Acked-by: Ferruh Yigit Acked-by: Remy Horton --- doc/guides/rel_notes/deprecation.rst | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/doc/guides/rel_notes/deprecation.rst b/doc/guides/rel_notes/deprecation.rst index 1a3831f..60f6e60 100644 --- a/doc/guides/rel_notes/deprecation.rst +++ b/doc/guides/rel_notes/deprecation.rst @@ -57,3 +57,8 @@ Deprecation Notices * API will change for ``rte_port_source_params`` and ``rte_port_sink_params`` structures. The member ``file_name`` data type will be changed from ``char *`` to ``const char *``. This change targets release 16.11. + +* igb_uio: iomem mapping and sysfs files created for iomem and ioport in + igb_uio will be removed, because we are able to detect these from what Linux + has exposed, like the way we have done with uio-pci-generic. This change + targets release 17.02.