public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* PCI bus do 2 Enumeration when 2 root bridges under 1 host bridge
@ 2017-08-17  4:50 Eric Song
  2017-08-17  9:18 ` Laszlo Ersek
       [not found] ` <734D49CCEBEEF84792F5B80ED585239D5B9F07CC@SHSMSX104.ccr.corp.intel.com>
  0 siblings, 2 replies; 4+ messages in thread
From: Eric Song @ 2017-08-17  4:50 UTC (permalink / raw)
  To: edk2-devel@lists.01.org; +Cc: Tiger Liu

Hi, experts
         If there is 2 root bridges under 1 host bridge on the PCI hierarchy, whether EDK2 Pci bus driver can support it ? the answer is YES, but some confused things in it.

1)       On BDS phase, ConnectController is called for every root bridge, so Pci bus start() will be called for every root bridge.

  VisitAllInstancesOfProtocol (&gEfiPciRootBridgeIoProtocolGuid, ConnectRootBridge, NULL);

2)       In PCI bus driver, Pci start() will do enumeration on the entire host bridge

PciEnumerator()->PciHostBridgeEnumerator->”PciResAlloc->GetNextRootBridge()”

That means Do enumeration on entire host bridge for every one root bridge. So there are 2 enumerations on entire host bridge for my PCI hierarchy.
         What I confused is why do 2 enumerations on entire host bridge by every one root bridge. Since BDS connect controller by one root bridge , Pci bus driver should enumerate corresponding root bridge, But it do the entire host bridge which is the parent of the root bridge.
Or BDS should connect controller by one host bridge, then it will match the pci bus driver ‘s enumeration policy.
In a word, I think it is illogical for current EDKII code.

         Well, the current code execution will do 2 enumerations on host bridge for 2 root bridges under 1 host bridge. Even though 2rd enumeration would be not full enumeration, but do PciEnumeratorLight(), I think it is still not necessary. Whether there is any side effect ?  In another word, current PCI bus driver enumeration can’t be Suitable for 2 root bridges under 1 host bridge or not? It indeed match the PCI hierarchy of 2 host bridges and 1 root bridge under 1 host bridge.

Thanks
Eric



保密声明:
本邮件含有保密或专有信息,仅供指定收件人使用。严禁对本邮件或其内容做任何未经授权的查阅、使用、复制或转发。
CONFIDENTIAL NOTE:
This email contains confidential or legally privileged information and is for the sole use of its intended recipient. Any unauthorized review, use, copying or forwarding of this email or the content of this email is strictly prohibited.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2017-08-17 10:57 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-08-17  4:50 PCI bus do 2 Enumeration when 2 root bridges under 1 host bridge Eric Song
2017-08-17  9:18 ` Laszlo Ersek
2017-08-17  9:37   ` 答复: " Eric Song
     [not found] ` <734D49CCEBEEF84792F5B80ED585239D5B9F07CC@SHSMSX104.ccr.corp.intel.com>
2017-08-17 10:59   ` Eric Song

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox