我已经了解了端口映射 IO 和内存映射 IO 之间的区别,但我无法弄清楚内存映射 Io 在现代操作系统(windows 或 linux)中是如何实现的
我所知道的是,物理内存的一部分被保留用于与硬件通信,并且有一个 MMIO 单元负责处理总线通信和其他与内存相关的内容
驱动程序如何与底层硬件通信?驱动程序会使用哪些功能?与视频卡通信的地址是固定的还是在使用它们之前有某种“协议”?
我还是比较困惑
你的问题中的以下说法是错误的:
What I know is that a part of the physical memory is reserved to communicate with the hardware
物理内存的一部分是not保留用于与硬件通信。身体的一部分地址空间,物理内存和内存映射IO所映射到的,是。这种内存布局是永久性的,但用户程序无法直接看到它 - 相反,它们会遇到自己的内存布局虚拟地址空间内核可以决定将物理内存和 IO 范围映射到任意位置。
您可能想阅读以下文章,我相信这些文章包含了您大部分问题的答案:
- http://duartes.org/gustavo/blog/post/motherboard-chipsets-memory-map http://duartes.org/gustavo/blog/post/motherboard-chipsets-memory-map
-
http://duartes.org/gustavo/blog/post/memory-translation-and-segmentation http://duartes.org/gustavo/blog/post/memory-translation-and-segmentation
- http://duartes.org/gustavo/blog/post/how-the-kernel-manages-your-memory http://duartes.org/gustavo/blog/post/how-the-kernel-manages-your-memory
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)