From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pf0-f170.google.com (mail-pf0-f170.google.com [209.85.192.170]) by dpdk.org (Postfix) with ESMTP id 7ED689A92 for ; Mon, 7 Dec 2015 18:08:25 +0100 (CET) Received: by pfu207 with SMTP id 207so67705055pfu.2 for ; Mon, 07 Dec 2015 09:08:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-type:content-transfer-encoding; bh=mj3/FLr0QkcU8Ytafg29C2vA3fm/5YKB1MO8jROK9A8=; b=OIVGHqdf7liHEi+6yv6Hj3nZxgwPPVI/kR4IdQrcCIVKRggz5/7lERPv5Zkv79Y8rA SRNt7D+N1wiAyWStU+Xsa1ZsKNOnklj4GxLk7aQ1S3yT9LFz+JjpgMTMEjfhG9dycraR t0H0GkLQ6sMA/WrkWTx4H4WwnhdqPDck8XB9Fr7BpkWZmae7F5/8408Ds8j/3Dx5W8Sb sdmc0Y+h8++FqIB9eZz3835WTYzA9Hi+gTfXPrLb2MyH2vSbn59lYOIqw739jSpA+cHJ OmxdSv4otPl7RloJTIztzJOpJscKd3x58TT8+dxTbicp06kbVYDdXDYIwor08dbRElo9 OGZQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version:content-type:content-transfer-encoding; bh=mj3/FLr0QkcU8Ytafg29C2vA3fm/5YKB1MO8jROK9A8=; b=L3pqCobhUEpNqaOLz6pMiLKms/Qzg7Qq0biKzAHLzAeB9kfauaBE/zyYO/oNAPdrRp VdoE8zB4cKhddYwXBs6H8UiQ5lkii+EywAkRA6MeFcbIV+3lYtDfqOH0Rm/KtsZC6NlJ 35eUYaaD6ZwaueauQlNCndzMKeBUJsIYPPwd2/o+9AFdTneMSzKKm1bM4uNN7cutoMGz Vg1QfbJbzjthfa0Y4UqRYU6uYC3fnm/2d4yCui5gIkfYij0rEMK7pEFqB9Gs7IrV13cT 72O+/gW6EGXthBg6xLyIC10nhsMC6c1H4WqfUjxpvJzAowrjowI5f0QAcujaJfncH/Uu U93A== X-Gm-Message-State: ALoCoQl+6XwBJrKu/sGO/YV22oIsYG5HsJGSYiSMndZQ9GqPDYv6OinQQxT/J68kKBVNw4SUHZvR X-Received: by 10.98.86.10 with SMTP id k10mr44833619pfb.85.1449508104816; Mon, 07 Dec 2015 09:08:24 -0800 (PST) Received: from xeon-e3 (static-50-53-82-155.bvtn.or.frontiernet.net. [50.53.82.155]) by smtp.gmail.com with ESMTPSA id f76sm35789824pfd.49.2015.12.07.09.08.24 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 07 Dec 2015 09:08:24 -0800 (PST) Date: Mon, 7 Dec 2015 09:08:33 -0800 From: Stephen Hemminger To: Santosh Shukla Message-ID: <20151207090833.03f65d63@xeon-e3> In-Reply-To: <1449250519-28372-7-git-send-email-sshukla@mvista.com> References: <1449250519-28372-1-git-send-email-sshukla@mvista.com> <1449250519-28372-7-git-send-email-sshukla@mvista.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: dev@dpdk.org, Rizwan Ansari Subject: Re: [dpdk-dev] [PATCH 6/6] virtio: arm/arm64: memory mapped IO support in pmd driver 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: Mon, 07 Dec 2015 17:08:25 -0000 On Fri, 4 Dec 2015 23:05:19 +0530 Santosh Shukla wrote: > > +#ifdef RTE_EXEC_ENV_LINUXAPP > +/* start address of first pci_iobar slot (user-space virtual-addres) */ > +void *ioport_map; > +#if defined(RTE_ARCH_ARM) || defined(RTE_ARCH_ARM64) > + > +#include > +#define DEV_NAME "/dev/igb_ioport" > + > +/* Keeping pci_ioport_size = 4k. > + * So maximum mmaped pci_iobar supported = > + * (ioport_size/pci_dev->mem_resource[0].len) > + * > + * note: kernel could allow maximum 32 virtio-net-pci interface, that mean > + * maximum 32 PCI_IOBAR(s) where each PCI_IOBAR_LEN=0x20, so virtio_map_ioport() > + * func by theory gonna support 4k/0x20 ==> 128 PCI_IOBAR(s), more than > + * max-virtio-net-pci interface. > + */ > +#define PAGE_SIZE 4096 > +#define PCI_IOPORT_SIZE PAGE_SIZE > +#define PCI_IOPORT_MAX 128 /* 4k / 0x20 */ > + > +int ioport_map_cnt; > +#endif /* ARM, ARM64 */ > +#endif /* RTE_EXEC_ENV_LINUXAPP */ These variables should be static. Also, it is should be possible to extract the I/O bar stuff in a generic way through sysfs and not depend on a character device. The long term goal for DPDK acceptance is to eliminate (or at least reduce to a minumum) any requirement for special kernel drivers.