From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ben Hutchings Subject: RE: [PATCH net-next 2/5] be2net: use common method to check for sriov function type Date: Thu, 07 Apr 2011 14:37:39 +0100 Message-ID: <1302183459.2878.7.camel@bwh-desktop> References: <20110407040801.GA4199@akhaparde-VBox> ,<1302164041.5282.3.camel@localhost> <49395329523DD64492581B505F80C86D5A5BCD3946@EXMAIL.ad.emulex.com> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit Cc: netdev@vger.kernel.org To: Ajit.Khaparde@Emulex.Com Return-path: Received: from mail.solarflare.com ([216.237.3.220]:25046 "EHLO exchange.solarflare.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751279Ab1DGNhm (ORCPT ); Thu, 7 Apr 2011 09:37:42 -0400 In-Reply-To: <49395329523DD64492581B505F80C86D5A5BCD3946@EXMAIL.ad.emulex.com> Sender: netdev-owner@vger.kernel.org List-ID: On Thu, 2011-04-07 at 05:34 -0700, Ajit.Khaparde@Emulex.Com wrote: > ________________________________________ > > From: Ben Hutchings [bhutchings@solarflare.com] > > Sent: Thursday, April 07, 2011 3:14 AM > > To: Khaparde, Ajit > > Cc: netdev@vger.kernel.org > > Subject: Re: [PATCH net-next 2/5] be2net: use common method to check for sriov function type > > > On Wed, 2011-04-06 at 23:08 -0500, Ajit Khaparde wrote: > >> Lancer and BE can both use SLI_INTF_REG to check a VF or a PF. > > [...] > > > This seems pretty unreliable (both in the previous and the current > > version). You cannot rely on the whole of PCI config space being mapped > > to a VM guest. KVM certainly didn't do this when I used PCI pass- > > through. > > That's interesting. I have been using the new method for a while now. > And the older one has worked pretty well for a long time. > Can you give some details about the adapter used? > Let's start with the firmware version, lspci output. I've tried this with PFs on Solarflare adapters. This is how the PF looks in the KVM host: # lspci -vv -xxx -s 06:00.1 06:00.1 Ethernet controller: Solarflare Communications SFC9020 [Solarstorm] Subsystem: Solarflare Communications SFN5122F-R5 Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- SERR- TAbort- SERR-