[FPGA 实现及PCIe IP 核知识点] x86架构与PCI架构的关系

Most people think that PCI architecture is no use anymore and PCI slots have been removed from motherboard. However, this is not completed true. Actually, PCI architeture concept is used in whole x86 architecture.
PCI architecture include two parts: hardware and software.
x86 architecture uses PCI software architecture all the time. For example, the latest Intel client processor skylake.
Let me tell you more.
Intel CPU is not ‘CPU’ anymore.
Traditionally, CPU means Centre Processor Unit, it is mainly for calculating. However, modern CPU is not ‘CPU’ anymore. We give a new name to traditional ‘CPU’ - core. So after that, we integrated many units into a CPU. such as memory controller, Integrated IO…
So question is coming: how to access these components inside a CPU?
Intel Architect is very smart that we treat all internal components as PCI devices to connect to internal PCI buses. Totally, we have two interna PCI buses here. BUS0 and BUS1. Frankly, you should consider BUS0 and BUS1 to BUSA and BUSB. what’s that mean? That means there are two different buses inside, we can assign real bus number to them.
So after configuration, BUS0(A) may be 0x0 or 0x80, BUS1(B) may be 0x7F or 0xFF, depends on what values you configurate to relative registers.
In the end, you can easly to access all components as accessing traditional PCI devices. (Actually, they are PCIe device, as most of the devices have more than 256B config space)
So you know now, why PCI spec is very important in learning x86 architecture. You can get PCI spec from http://www.pci-scg.com and make sure you will finish to read charpter 6 - Configuration Space.

机器翻译一下吧:

大多数人认为PCI架构不再有用,并且PCI插槽已从主板上移除。然而,这并不完全正确。实际上,整个 x86 架构都使用 PCI 架构概念。 PCI体系结构包括硬件和软件两部分。 x86 架构一直使用 PCI 软件架构。例如,最新的 Intel 客户端处理器 Skylake。让我告诉你更多。英特尔 CPU 不再是“CPU”。传统上,CPU 是指中央处理器单元,主要用于计算。但是,现代 CPU 不再是“CPU”。我们给传统的“CPU”取了一个新名字——核心。所以在那之后,我们将许多单元集成到一个 CPU 中。比如内存控制器、集成IO……那么问题来了:如何访问CPU内部的这些组件? Intel Architect 非常聪明,我们将所有内部组件都视为 PCI 设备以连接到内部 PCI 总线。总的来说,我们这里有两个内部 PCI 总线。 BUS0 和 BUS1。坦率地说,你应该考虑BUS0和BUS1到BUSA和BUSB。那是什么意思?这意味着里面有两个不同的总线,我们可以为它们分配实际的总线编号。所以配置后,BUS0(A) 可能是0x0 或0x80,BUS1(B) 可能是0x7F 或0xFF,这取决于你配置的相关寄存器的值。最后,您可以像访问传统 PCI 设备一样轻松访问所有组件。 (实际上,它们是 PCIe 设备,因为大多数设备具有超过 256B 的配置空间)所以您现在知道为什么 PCI 规范在学习 x86 架构时非常重要。您可以从 http://www.pci-scg.com 获取 PCI 规范,并确保您将完成阅读第 6 章 - 配置空间。

编辑 重设标签(回车键确认) 标为违禁 关闭 合并 删除
匿名用户

匿名