[edk2-devel] [edk2] question about : DmaBufferAlignment in CPU Arch driver

Tiger Liu(BJ-RD) tigerliu at zhaoxin.com
Fri Nov 22 03:28:02 UTC 2019


Dear All:
I have a question about DmaBufferAlignment in CPU Arch driver.

Based on PI Spec:
......
This is typically the size of the largest data cache line in the platform.
This value can be determined by looking at the data cache line sizes of all the caches present in the platform, and returning the largest.
This is used by the root bridge I/O abstraction protocols to guarantee that no two DMA buffers ever share the same cache line.
The value in this field is a constant that must not be modified after the CPU Architectural Protocol is installed. All consumers must treat this as a read-only field.

But, I study Kabylake sample code, it uses UefiCpuPkg/CpuDxe/CpuDxe.inf,
And it declares  4 (DmaBufferAlignment).

For x86 cpu, the cache line size is usually 64 bytes.

Why not set 64 in CPU Arch protocol interface struct?

Thanks


保密声明:
本邮件含有保密或专有信息,仅供指定收件人使用。严禁对本邮件或其内容做任何未经授权的查阅、使用、复制或转发。
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.

-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#51128): https://edk2.groups.io/g/devel/message/51128
Mute This Topic: https://groups.io/mt/61342276/1813853
Group Owner: devel+owner at edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [edk2-devel-archive at redhat.com]
-=-=-=-=-=-=-=-=-=-=-=-





More information about the edk2-devel-archive mailing list