From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pa0-f42.google.com (mail-pa0-f42.google.com [209.85.220.42]) by dpdk.org (Postfix) with ESMTP id C5C044C6E for ; Wed, 31 Jul 2013 23:34:57 +0200 (CEST) Received: by mail-pa0-f42.google.com with SMTP id lj1so1347980pab.29 for ; Wed, 31 Jul 2013 14:35:21 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=date:from:to:cc:subject:message-id:in-reply-to:references:x-mailer :mime-version:content-type:content-transfer-encoding :x-gm-message-state; bh=eHqeY0hzRPBHNkKdJqOYYjTX5SX/8B8G53gSmWIYkuQ=; b=lhCwPR2bZwL3zcBe9b9epud8qiFKmKTonErADr6pymB7dVsr+2oOr0NHwAnhwkb45P S79S0CLHvaF+KfRJqscOFwmbbDKn51Y986TilQCXmKuce8pehcux3BRJNkIMwt8N5EpF 5QKwlSMYKMChvTOp/RQXDDBL1rMS0JSX/Rndft+YT7mvByxXqfSFUnx4apzeE1dYfhjJ qONz3zHzS0v6vAhOo/JO1IJMzdUJKmTo+q2D/Z4h1Fa7t1kC0sDwmbdEKHktbgS8sXlW 3vkkFtDZ6Bh+hQsrD3ZZYPPuTxxOm8W4Yp9ytGQ+dXfuptp6quil53O3/3ogfxeXx3Nv wzrA== X-Received: by 10.68.202.130 with SMTP id ki2mr11732645pbc.43.1375306521859; Wed, 31 Jul 2013 14:35:21 -0700 (PDT) Received: from nehalam.linuxnetplumber.net (static-50-53-71-109.bvtn.or.frontiernet.net. [50.53.71.109]) by mx.google.com with ESMTPSA id dc5sm215514pbc.37.2013.07.31.14.35.20 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Wed, 31 Jul 2013 14:35:21 -0700 (PDT) Date: Wed, 31 Jul 2013 14:35:18 -0700 From: Stephen Hemminger To: Patrick Mahan Message-ID: <20130731143518.7eee47cf@nehalam.linuxnetplumber.net> In-Reply-To: <1486472B-BF17-4A85-887A-806E6DB32480@mahan.org> References: <1486472B-BF17-4A85-887A-806E6DB32480@mahan.org> X-Mailer: Claws Mail 3.8.1 (GTK+ 2.24.10; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Gm-Message-State: ALoCoQk7tGWSZeUQ6FI7TJCuYeCWRNZDz0Nxl++RU2yb1ZbHUtKKLbAK3nzv1VPlEI8BH5ampsrL Cc: dev@dpdk.org Subject: Re: [dpdk-dev] Question regarding PMDs 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, 31 Jul 2013 21:34:58 -0000 On Wed, 31 Jul 2013 14:23:40 -0700 Patrick Mahan wrote: > Okay, I wadding into the process of writing a poll-mode driver for DPDK. > > First question, is the use of the UIO device a requirement (outside of the need for interrupt support) since it is possible to map the PCI bars via /dev/mem? Not really, the 6wind virtio driver doesn't bother (because it uses I/O ports). But if you want link state interrupt then you need UIO support. Plus if you use UIO, then there is protection against overlapping usage between user mode and kernel drivers which matters especially if doing blacklisting. The whole memory mapping approach in DPDK needs to be hardened with something stronger like using the IOMMU. Recent kernels support something called VFIO which could be used. This is a base PCI level change, not a something each driver should have to worry about. http://lwn.net/Articles/474088/ > > Second question, is it expected that the NIC hardware would already have been initialized by the kernel driver for that device? Say to load microcode on an intelligent NIC? If you need firmware then yes, the linux firmware loader is a lot easier than doing it yourself. I wouldn't assume more than that.