21#define INTEL_CXL_DVSEC_VENDOR_ID 0x8086
44#define CXL_11_SIZE_ASSERT(TypeName, ExpectedSize) \
46 sizeof (TypeName) == ExpectedSize, \
47 "Size of " #TypeName \
48 " does not meet CXL 1.1 Specification requirements." \
62#define CXL_11_OFFSET_ASSERT(TypeName, FieldName, ExpectedOffset) \
64 OFFSET_OF (TypeName, FieldName) == ExpectedOffset, \
65 "Offset of " #TypeName "." #FieldName \
66 " does not meet CXL 1.1 Specification requirements." \
74 UINT16 CacheCapable : 1;
76 UINT16 MemCapable : 1;
77 UINT16 MemHwInitMode : 1;
80 UINT16 ViralCapable : 1;
88 UINT16 CacheEnable : 1;
91 UINT16 CacheSfCoverage : 5;
92 UINT16 CacheSfGranularity : 3;
93 UINT16 CacheCleanEviction : 1;
95 UINT16 ViralEnable : 1;
103 UINT16 Reserved1 : 14;
104 UINT16 ViralStatus : 1;
105 UINT16 Reserved2 : 1;
112 UINT16 Reserved1 : 1;
113 UINT16 Reserved2 : 1;
114 UINT16 Reserved3 : 1;
115 UINT16 Reserved4 : 13;
122 UINT16 Reserved1 : 1;
123 UINT16 Reserved2 : 1;
124 UINT16 Reserved3 : 14;
131 UINT16 ConfigLock : 1;
132 UINT16 Reserved1 : 15;
139 UINT32 MemorySizeHigh : 32;
146 UINT32 MemoryInfoValid : 1;
147 UINT32 MemoryActive : 1;
148 UINT32 MediaType : 3;
149 UINT32 MemoryClass : 3;
150 UINT32 DesiredInterleave : 3;
151 UINT32 Reserved : 17;
152 UINT32 MemorySizeLow : 4;
159 UINT32 MemoryBaseHigh : 32;
166 UINT32 Reserved : 28;
167 UINT32 MemoryBaseLow : 4;
174 UINT32 MemorySizeHigh : 32;
181 UINT32 MemoryInfoValid : 1;
182 UINT32 MemoryActive : 1;
183 UINT32 MediaType : 3;
184 UINT32 MemoryClass : 3;
185 UINT32 DesiredInterleave : 3;
186 UINT32 Reserved : 17;
187 UINT32 MemorySizeLow : 4;
194 UINT32 MemoryBaseHigh : 32;
201 UINT32 Reserved : 28;
202 UINT32 MemoryBaseLow : 4;
211#define FLEX_BUS_DEVICE_DVSEC_ID 0
263 UINT16 CacheCapable : 1;
264 UINT16 IoCapable : 1;
265 UINT16 MemCapable : 1;
266 UINT16 Reserved : 13;
273 UINT16 CacheEnable : 1;
275 UINT16 MemEnable : 1;
276 UINT16 CxlSyncBypassEnable : 1;
277 UINT16 DriftBufferEnable : 1;
279 UINT16 Retimer1Present : 1;
280 UINT16 Retimer2Present : 1;
281 UINT16 Reserved2 : 6;
288 UINT16 CacheEnable : 1;
290 UINT16 MemEnable : 1;
291 UINT16 CxlSyncBypassEnable : 1;
292 UINT16 DriftBufferEnable : 1;
294 UINT16 CxlCorrectableProtocolIdFramingError : 1;
295 UINT16 CxlUncorrectableProtocolIdFramingError : 1;
296 UINT16 CxlUnexpectedProtocolIdDropped : 1;
297 UINT16 Reserved2 : 5;
306#define FLEX_BUS_PORT_DVSEC_ID 7
338#define CXL_CAPABILITY_HEADER_OFFSET 0
341 UINT32 CxlCapabilityId : 16;
342 UINT32 CxlCapabilityVersion : 4;
343 UINT32 CxlCacheMemVersion : 4;
344 UINT32 ArraySize : 8;
349#define CXL_RAS_CAPABILITY_HEADER_OFFSET 4
352 UINT32 CxlCapabilityId : 16;
353 UINT32 CxlCapabilityVersion : 4;
354 UINT32 CxlRasCapabilityPointer : 12;
359#define CXL_SECURITY_CAPABILITY_HEADER_OFFSET 8
362 UINT32 CxlCapabilityId : 16;
363 UINT32 CxlCapabilityVersion : 4;
364 UINT32 CxlSecurityCapabilityPointer : 12;
369#define CXL_LINK_CAPABILITY_HEADER_OFFSET 0xC
372 UINT32 CxlCapabilityId : 16;
373 UINT32 CxlCapabilityVersion : 4;
374 UINT32 CxlLinkCapabilityPointer : 12;
381 UINT32 CacheDataParity : 1;
382 UINT32 CacheAddressParity : 1;
383 UINT32 CacheByteEnableParity : 1;
384 UINT32 CacheDataEcc : 1;
385 UINT32 MemDataParity : 1;
386 UINT32 MemAddressParity : 1;
387 UINT32 MemByteEnableParity : 1;
388 UINT32 MemDataEcc : 1;
389 UINT32 ReInitThreshold : 1;
390 UINT32 RsvdEncodingViolation : 1;
391 UINT32 PoisonReceived : 1;
392 UINT32 ReceiverOverflow : 1;
393 UINT32 Reserved : 20;
400 UINT32 CacheDataParityMask : 1;
401 UINT32 CacheAddressParityMask : 1;
402 UINT32 CacheByteEnableParityMask : 1;
403 UINT32 CacheDataEccMask : 1;
404 UINT32 MemDataParityMask : 1;
405 UINT32 MemAddressParityMask : 1;
406 UINT32 MemByteEnableParityMask : 1;
407 UINT32 MemDataEccMask : 1;
408 UINT32 ReInitThresholdMask : 1;
409 UINT32 RsvdEncodingViolationMask : 1;
410 UINT32 PoisonReceivedMask : 1;
411 UINT32 ReceiverOverflowMask : 1;
412 UINT32 Reserved : 20;
419 UINT32 CacheDataParitySeverity : 1;
420 UINT32 CacheAddressParitySeverity : 1;
421 UINT32 CacheByteEnableParitySeverity : 1;
422 UINT32 CacheDataEccSeverity : 1;
423 UINT32 MemDataParitySeverity : 1;
424 UINT32 MemAddressParitySeverity : 1;
425 UINT32 MemByteEnableParitySeverity : 1;
426 UINT32 MemDataEccSeverity : 1;
427 UINT32 ReInitThresholdSeverity : 1;
428 UINT32 RsvdEncodingViolationSeverity : 1;
429 UINT32 PoisonReceivedSeverity : 1;
430 UINT32 ReceiverOverflowSeverity : 1;
431 UINT32 Reserved : 20;
438 UINT32 CacheDataEcc : 1;
439 UINT32 MemoryDataEcc : 1;
440 UINT32 CrcThreshold : 1;
441 UINT32 RetryThreshold : 1;
442 UINT32 CachePoisonReceived : 1;
443 UINT32 MemoryPoisonReceived : 1;
444 UINT32 PhysicalLayerError : 1;
445 UINT32 Reserved : 25;
452 UINT32 CacheDataEccMask : 1;
453 UINT32 MemoryDataEccMask : 1;
454 UINT32 CrcThresholdMask : 1;
455 UINT32 RetryThresholdMask : 1;
456 UINT32 CachePoisonReceivedMask : 1;
457 UINT32 MemoryPoisonReceivedMask : 1;
458 UINT32 PhysicalLayerErrorMask : 1;
459 UINT32 Reserved : 25;
466 UINT32 FirstErrorPointer : 4;
467 UINT32 Reserved1 : 5;
468 UINT32 MultipleHeaderRecordingCapability : 1;
469 UINT32 Reserved2 : 3;
470 UINT32 PoisonEnabled : 1;
471 UINT32 Reserved3 : 18;
483 UINT32 HeaderLog[16];
497 UINT32 DeviceTrustLevel : 2;
498 UINT32 Reserved : 30;
512 UINT64 CxlLinkVersionSupported : 4;
513 UINT64 CxlLinkVersionReceived : 4;
514 UINT64 LlrWrapValueSupported : 8;
515 UINT64 LlrWrapValueReceived : 8;
516 UINT64 NumRetryReceived : 5;
517 UINT64 NumPhyReinitReceived : 5;
518 UINT64 WrPtrReceived : 8;
519 UINT64 EchoEseqReceived : 8;
520 UINT64 NumFreeBufReceived : 8;
529 UINT16 LlInitStall : 1;
530 UINT16 LlCrdStall : 1;
531 UINT16 InitState : 2;
532 UINT16 LlRetryBufferConsumed : 8;
540 UINT64 CacheReqCredits : 10;
541 UINT64 CacheRspCredits : 10;
542 UINT64 CacheDataCredits : 10;
543 UINT64 MemReqRspCredits : 10;
544 UINT64 MemDataCredits : 10;
551 UINT64 CacheReqCredits : 10;
552 UINT64 CacheRspCredits : 10;
553 UINT64 CacheDataCredits : 10;
554 UINT64 MemReqRspCredits : 10;
555 UINT64 MemDataCredits : 10;
562 UINT64 CacheReqCredits : 10;
563 UINT64 CacheRspCredits : 10;
564 UINT64 CacheDataCredits : 10;
565 UINT64 MemReqRspCredits : 10;
566 UINT64 MemDataCredits : 10;
573 UINT32 AckForceThreshold : 8;
574 UINT32 AckFLushRetimer : 10;
581 UINT32 MdhDisable : 1;
582 UINT32 Reserved : 31;
606#define CXL_IO_ARBITRATION_CONTROL_OFFSET 0x180
609 UINT32 Reserved1 : 4;
610 UINT32 WeightedRoundRobinArbitrationWeight : 4;
611 UINT32 Reserved2 : 24;
618#define CXL_CACHE_MEMORY_ARBITRATION_CONTROL_OFFSET 0x1C0
621 UINT32 Reserved1 : 4;
622 UINT32 WeightedRoundRobinArbitrationWeight : 4;
623 UINT32 Reserved2 : 24;
637 UINT64 RcrbEnable : 1;
638 UINT64 Reserved : 12;
639 UINT64 RcrbBaseAddress : 51;
654#define CXL_PORT_RCRB_MEMBAR0_LOW_OFFSET 0x010
655#define CXL_PORT_RCRB_MEMBAR0_HIGH_OFFSET 0x014
656#define CXL_PORT_RCRB_EXTENDED_CAPABILITY_BASE_OFFSET 0x100
#define CXL_11_OFFSET_ASSERT(TypeName, FieldName, ExpectedOffset)
#define CXL_11_SIZE_ASSERT(TypeName, ExpectedSize)