From: Alexander Duyck <alexander.h.duyck@intel.com>
To: Edward Cree <ecree@solarflare.com>, Don Dutile <ddutile@redhat.com>
Cc: linux-pci@vger.kernel.org
Subject: Re: pci_sriov_set_totalvfs again
Date: Wed, 30 Jul 2014 14:14:18 -0700 [thread overview]
Message-ID: <53D9602A.4010406@intel.com> (raw)
In-Reply-To: <53D93848.7070203@solarflare.com>
On 07/30/2014 11:24 AM, Edward Cree wrote:
> On 30/07/14 19:05, Don Dutile wrote:
>> On 07/30/2014 01:16 PM, Edward Cree wrote:
>>> Calling pci_sriov_set_totalvfs(dev, 0) has no effect, because
>>> pci_sriov_get_totalvfs ignores dev->sriov->driver_max_VFs if it's 0,
>>> as that is used as the 'not set' value.
>>> So, three questions:
>>> a) is this a bug?
>>> b) if not, should the comment on pci_sriov_set_totalvfs mention that
>>> passing numvfs=0 will be interpreted as numvfs=dev->sriov->total_VFs?
>>> c) is there a better way of indicating "current configuration doesn't
>>> support VFs" rather than calling set_totalvfs(0)?
>>>
>>> Thanks,
>>> -Edward
>>
>> The file shouldn't exist if the device doesn't provide an SRIOV
>> capability.
>> If it does, and it's not supported, then add a patch in quirks.c.
>>
>>
> I don't know much about quirks, but I'm not sure they're the answer
> here, as it's not quite as simple as "driver doesn't support it".
> It's a firmware / configuration issue, that if the device (it's a NIC)
> is configured a certain way [1], the VFs - while appearing fine from a
> PCI perspective - don't actually work (they can't pass traffic).
> We can't detect this misconfiguration until PF probe time, and we need a
> way to report that the VFs aren't usable.
>
> Can quirks handle this?
>
> -Edward
>
> [1] SFC9120-based NICs support multiple PFs per port and these can be
> used as a kind of "poor-man's SR-IOV" (we're calling it 'PF-IOV') by
> placing the firmware v-switch below the PFs. However, this then
> precludes adding a v-switch above the PF to direct VF traffic, meaning
> that VFs are useless in this configuration. Consequently, our
> configuration tools won't allow VFs and PF-IOV to be enabled
> simultaneously, but bugs or corruption could cause this to happen.
My $.02 on the issue would be to simply have sriov_configure return an
error indicating the resources are not available if you have the PF-IOV
mode enabled it is consuming the VF v-switch resources.
Thanks,
Alex
next prev parent reply other threads:[~2014-07-30 21:14 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <53D9288B.5030302@solarflare.com>
2014-07-30 18:05 ` pci_sriov_set_totalvfs again Don Dutile
2014-07-30 18:24 ` Edward Cree
2014-07-30 21:14 ` Alexander Duyck [this message]
2014-07-31 12:07 ` Edward Cree
2014-07-31 14:24 ` [PATCH] PCI: handle pci_sriov_set_totalvfs(dev, 0) Edward Cree
2014-07-31 15:21 ` Alexander Duyck
2014-07-31 15:56 ` Edward Cree
2014-07-31 16:40 ` Alexander Duyck
2014-07-31 16:57 ` Edward Cree
2014-07-31 17:53 ` Don Dutile
2014-07-31 18:13 ` Edward Cree
2014-08-04 14:03 ` Edward Cree
2014-08-04 14:37 ` Alexander Duyck
2014-08-04 15:22 ` Edward Cree
2014-08-06 9:38 ` Don Dutile
2014-07-31 17:55 ` Alexander Duyck
2014-07-31 18:24 ` Edward Cree
2014-08-01 3:18 ` Ethan Zhao
2014-08-01 11:51 ` Edward Cree
2014-08-02 0:34 ` Ethan Zhao
2014-08-01 3:51 ` Ethan Zhao
2014-08-01 12:15 ` Edward Cree
2014-08-02 0:25 ` Ethan Zhao
2014-08-04 15:45 ` Edward Cree
2014-08-04 16:40 ` Alexander Duyck
2014-08-04 17:08 ` Edward Cree
2014-08-04 6:53 ` Sathya Perla
2014-07-30 17:23 pci_sriov_set_totalvfs again Edward Cree
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=53D9602A.4010406@intel.com \
--to=alexander.h.duyck@intel.com \
--cc=ddutile@redhat.com \
--cc=ecree@solarflare.com \
--cc=linux-pci@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.