audk/MdeModulePkg
Joseph Shifflett 25a2664625 MdeModulePkg: exit pci function loops early if device is not multi-function
When looping through all PCI functions, code should not look for functions
1-7 if function 0 is not present or if function 0 indicates the device is
not multifunction.  Prior to this fix the code would use stale data in a
buffer to determine if a device is multifunction even if function 0 is not
present.  This fixes a code bug and provides very small performance
improvements.

PCI 2.3 Specification states: They [multifunction devices] are also
required to always implement function 0 in the device. Implementing other
functions is optional and may be assigned in any order.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Joseph Shifflett <joseph.shifflett@hpe.com>
Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@18574 6f19259b-4bc3-4df7-8a09-765794883524
2015-10-06 20:55:31 +00:00
..
Application MdeModulePkg: Add the missing module UNI files. 2015-08-28 02:46:46 +00:00
Bus MdeModulePkg: exit pci function loops early if device is not multi-function 2015-10-06 20:55:31 +00:00
Core MdeModulePkg: Remove event from protocol database only if registered 2015-09-21 01:53:34 +00:00
Include MdeModulePkg: Convert the UNIX to DOS end of line format 2015-08-27 01:04:59 +00:00
Library MdeModulePkg UefiBootManagerLib: Do not assume perf entry count has no change 2015-09-30 04:29:50 +00:00
Logo MdeModulePkg: Convert non DOS format files to DOS format and remove unused module UNI files. 2014-09-03 08:39:12 +00:00
Universal MdeModulePkg Ip4Dxe: Ip4Config2 to request DHCP Option6 DNS server IP 2015-09-30 03:01:13 +00:00
Contributions.txt */Contributions.txt: Update example email address 2015-02-03 17:29:14 +00:00
License.txt Update copyright format 2012-04-24 06:49:39 +00:00
MdeModulePkg.dec MdeModulePkg: PcdSetNxForStack: enable dynamism 2015-09-15 08:34:57 +00:00
MdeModulePkg.dsc Not support EBC arch for regular expression protocol driver. 2015-09-09 06:28:32 +00:00
MdeModulePkg.uni MdeModulePkg PiDxeS3BootScriptLib: Remove a hidden assumption. 2015-09-15 07:49:12 +00:00
MdeModulePkgExtra.uni MdeModulePkg: INF/DEC file updates to EDK II packages 2014-08-28 06:55:48 +00:00