> -----Original Message----- > From: linux-pci-owner@xxxxxxxxxxxxxxx [mailto:linux-pci- > > On 01/08/14 04:51, Ethan Zhao wrote: > > Though I like this patch, it shows direct style, but it will change > > the meaning of a function not mentioned here. > > > > int pci_sriov_set_totalvfs(struct pci_dev *dev, u16 numvfs) > Am I missing something here, or is that exactly the function mentioned > in the patch title / subject line? > > > So far seems no driver call pci_sriov_set_totalvfs() with numvfs = 0 > > and the patch will change the behavior of the drivers, but it will > > definitely change the test cases and documents related to IOV. > As for test cases and documents, I can't find any in the kernel tree - > if I grep for pci_sriov_set_totalvfs, the only mentions I find are: > * The declaration in include/linux/pci.h. Doesn't have any comments. > * The definition in drivers/pci/iov.c. The comment doesn't document the > behaviour in the numvfs = 0 case. > * Documentation/ABI/testing/sysfs-bus-pci. Describes the function's > purpose "reduce the value read from [the sriov_totalvfs sysfs file]" but > doesn't say anything about the numvfs = 0 case. > * the Intel igb and ixgbe ethernet drivers. Both pass nonzero constants > for numvfs. > * the Emulex benet driver. This went into Dave Miller's net-next branch > on 30/06/2014 (so hasn't hit Linus' or other trees yet), but it looks to > me like it might call with numvfs = 0. CCing the author of that patch > (Vasundhara Volam) for comments. > Incidentally, after my most recent patch - commit d3d18312 ("be2net: ignore get/set profile FW cmd failures"), be2net no longer calls pci_sriov_set_totalvfs() with num_vfs=0. Hope this helps. thanks, -Sathya ��.n��������+%������w��{.n�����{���"�)��jg��������ݢj����G�������j:+v���w�m������w�������h�����٥