lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <C5551D9AAB213A418B7FD5E4A6F30A0702F86242@ORSMSX106.amr.corp.intel.com>
Date:	Wed, 8 Feb 2012 23:42:37 +0000
From:	"Rose, Gregory V" <gregory.v.rose@...el.com>
To:	"Kirsher, Jeffrey T" <jeffrey.t.kirsher@...el.com>,
	"davem@...emloft.net" <davem@...emloft.net>
CC:	"netdev@...r.kernel.org" <netdev@...r.kernel.org>,
	"gospo@...hat.com" <gospo@...hat.com>,
	"sassmann@...hat.com" <sassmann@...hat.com>,
	"stable@...r.kernel.org" <stable@...r.kernel.org>
Subject: RE: [net 2/8] igb: fix vf lookup

> -----Original Message-----
> From: Kirsher, Jeffrey T
> Sent: Wednesday, February 08, 2012 1:37 AM
> To: davem@...emloft.net
> Cc: Rose, Gregory V; netdev@...r.kernel.org; gospo@...hat.com;
> sassmann@...hat.com; stable@...r.kernel.org; Kirsher, Jeffrey T
> Subject: [net 2/8] igb: fix vf lookup
> 
> From: Greg Rose <gregory.v.rose@...el.com>
> 
> Recent addition of code to find already allocated VFs failed to take
> account that systems with 2 or more multi-port SR-IOV capable controllers
> might have already enabled VFs.  Make sure that the VFs the function is
> finding are actually subordinate to the particular instance of the adapter
> that is looking for them and not subordinate to some device that has
> previously enabled SR-IOV.
> 
> This is applicable to 3.2+ kernels.
> 
> CC: stable@...r.kernel.org
> Reported-by: David Ahern <daahern@...co.com>
> Signed-off-by: Greg Rose <gregory.v.rose@...el.com>
> Tested-by: Robert E Garrett <robertX.e.garrett@...el.com>
> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@...el.com>
> ---
>  drivers/net/ethernet/intel/igb/igb_main.c |    3 ++-
>  1 files changed, 2 insertions(+), 1 deletions(-)
> 
> diff --git a/drivers/net/ethernet/intel/igb/igb_main.c
> b/drivers/net/ethernet/intel/igb/igb_main.c
> index e91d73c..94be6c3 100644
> --- a/drivers/net/ethernet/intel/igb/igb_main.c
> +++ b/drivers/net/ethernet/intel/igb/igb_main.c
> @@ -5012,7 +5012,8 @@ static int igb_find_enabled_vfs(struct igb_adapter
> *adapter)
>  	vf_devfn = pdev->devfn + 0x80;
>  	pvfdev = pci_get_device(hw->vendor_id, device_id, NULL);
>  	while (pvfdev) {
> -		if (pvfdev->devfn == vf_devfn)
> +		if (pvfdev->devfn == vf_devfn &&
> +		    (pvfdev->bus->number >= pdev->bus->number))
>  			vfs_found++;
>  		vf_devfn += vf_stride;
>  		pvfdev = pci_get_device(hw->vendor_id,
> --
> 1.7.7.6

I'll fix this one too.  You start leaning on checkpatch and you get lazy I guess.

- Greg

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ