Documentation/driver-api/cxl/platform/example-configurations/multi-dev-per-hb.rst GitHub 원문 ↗

Linux 6.18.37 · Driver API / CXL / Platform / Example Configurations

Multiple Devices per Host Bridge

한 CXL host bridge에 연결된 두 memory expander를 단일 CFMWS와 NUMA node로 제시하는 firmware 구성을 설명합니다.

Source pathDocumentation/driver-api/cxl/platform/example-configurations/multi-dev-per-hb.rst
Source versionLinux v6.18.37
TranslationDUJINLABS 전문 번역 + 해설

요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.

1. 요약·해설

원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.

요약과 해설

multi-dev-per-hb.rst:1-90

이 예시는 host bridge 하나 뒤의 4GB expander 두 개를 8GB CFMWS 하나로 묶되 intra-bridge interleave 자체는 기술하지 않습니다. CEDT의 단일 CHBS/CFMWS, SRAT의 공유 proximity domain, HMAT의 단일 CXL node 성능, SLIT distance, DSDT의 `_UID` 0x07이 같은 topology를 일관되게 나타냅니다.

2. 영어 원문 전체

번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.

원문 전체 펼치기
1 .. SPDX-License-Identifier: GPL-2.0
2
3 ================================
4 Multiple Devices per Host Bridge
5 ================================
6
7 In this example system we will have a single socket and one CXL host bridge.
8 There are two CXL memory expanders with 4GB attached to the host bridge.
9
10 Things to note:
11
12 * Intra-Bridge interleave is not described here.
13 * The expanders are described by a single CEDT/CFMWS.
14 * This CEDT/SRAT describes one node for both devices.
15 * There is only one proximity domain the HMAT for both devices.
16
17 :doc:`CEDT <../acpi/cedt>`::
18
19 Subtable Type : 00 [CXL Host Bridge Structure]
20 Reserved : 00
21 Length : 0020
22 Associated host bridge : 00000007
23 Specification version : 00000001
24 Reserved : 00000000
25 Register base : 0000010370400000
26 Register length : 0000000000010000
27
28 Subtable Type : 01 [CXL Fixed Memory Window Structure]
29 Reserved : 00
30 Length : 002C
31 Reserved : 00000000
32 Window base address : 0000001000000000
33 Window size : 0000000200000000
34 Interleave Members (2^n) : 00
35 Interleave Arithmetic : 00
36 Reserved : 0000
37 Granularity : 00000000
38 Restrictions : 0006
39 QtgId : 0001
40 First Target : 00000007
41
42 :doc:`SRAT <../acpi/srat>`::
43
44 Subtable Type : 01 [Memory Affinity]
45 Length : 28
46 Proximity Domain : 00000001
47 Reserved1 : 0000
48 Base Address : 0000001000000000
49 Address Length : 0000000200000000
50 Reserved2 : 00000000
51 Flags (decoded below) : 0000000B
52 Enabled : 1
53 Hot Pluggable : 1
54 Non-Volatile : 0
55
56 :doc:`HMAT <../acpi/hmat>`::
57
58 Structure Type : 0001 [SLLBI]
59 Data Type : 00 [Latency]
60 Target Proximity Domain List : 00000000
61 Target Proximity Domain List : 00000001
62 Entry : 0080
63 Entry : 0100
64
65 Structure Type : 0001 [SLLBI]
66 Data Type : 03 [Bandwidth]
67 Target Proximity Domain List : 00000000
68 Target Proximity Domain List : 00000001
69 Entry : 1200
70 Entry : 0200
71
72 :doc:`SLIT <../acpi/slit>`::
73
74 Signature : "SLIT" [System Locality Information Table]
75 Localities : 0000000000000003
76 Locality 0 : 10 20
77 Locality 1 : FF 0A
78
79 :doc:`DSDT <../acpi/dsdt>`::
80
81 Scope (_SB)
82 {
83 Device (S0D0)
84 {
85 Name (_HID, "ACPI0016" /* Compute Express Link Host Bridge */) // _HID: Hardware ID
86 ...
87 Name (_UID, 0x07) // _UID: Unique ID
88 }
89 ...
90 }
91

3. 한국어 전문 번역

영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.

host bridge 하나에 여러 device가 있는 구성

1-16
.. SPDX-License-Identifier: GPL-2.0

이 example system은 socket 하나와 CXL host bridge 하나를 갖습니다. 이 host bridge에는 각각 4GB memory를 가진 CXL memory expander 두 개가 연결됩니다.

주목할 사항은 다음과 같습니다.

  • 여기서는 Intra-Bridge interleave를 설명하지 않습니다.
  • 두 expander는 단일 CEDT/CFMWS로 설명됩니다.
  • CEDT/SRAT는 두 device 모두에 대해 node 하나를 설명합니다.
  • HMAT에도 두 device를 함께 나타내는 proximity domain이 하나뿐입니다.

CEDT: host bridge 하나와 공유 CFMWS

17-41

CEDT의 CXL Host Bridge Structure는 associated host bridge 00000007을 선언합니다. specification version은 00000001이고 register base는 0000010370400000, register length는 0000000000010000입니다.

           Subtable Type : 00 [CXL Host Bridge Structure]
                Reserved : 00
                  Length : 0020
  Associated host bridge : 00000007
   Specification version : 00000001
                Reserved : 00000000
           Register base : 0000010370400000
         Register length : 0000000000010000

           Subtable Type : 01 [CXL Fixed Memory Window Structure]
                Reserved : 00
                  Length : 002C
                Reserved : 00000000
     Window base address : 0000001000000000
             Window size : 0000000200000000
Interleave Members (2^n) : 00
   Interleave Arithmetic : 00
                Reserved : 0000
             Granularity : 00000000
            Restrictions : 0006
                   QtgId : 0001
            First Target : 00000007
단일 host bridge CEDT presentation
StructureIdentifier / BaseSize / LengthTarget
CHBSUID 00000007 / 00000103704000000000000000010000Host Bridge 07
CFMWS00000010000000000000000200000000First Target 00000007

두 memory expander의 총 8GB가 host bridge UID 07을 target으로 하는 CFMWS 하나에 포함됩니다.

CFMWS의 window base address는 0000001000000000이고 window size는 0000000200000000입니다. `Interleave Members (2^n)`가 00이므로 firmware table에서 target은 하나이며, arithmetic은 00, granularity는 00000000입니다. `Restrictions`는 0006, `QtgId`는 0001이고 First Target은 00000007입니다.

따라서 두 expander가 host bridge 아래에 존재하지만 CEDT는 device별 window나 intra-bridge interleave를 따로 기술하지 않고 host bridge를 향하는 단일 8GB window로 제시합니다.

SRAT: 두 device가 공유하는 memory affinity

42-55

SRAT Memory Affinity entry는 proximity domain 00000001 하나를 CFMWS 전체 range에 연결합니다. base address 0000001000000000과 address length 0000000200000000은 CEDT의 8GB window와 일치합니다.

        Subtable Type : 01 [Memory Affinity]
               Length : 28
     Proximity Domain : 00000001
            Reserved1 : 0000
         Base Address : 0000001000000000
       Address Length : 0000000200000000
            Reserved2 : 00000000
Flags (decoded below) : 0000000B
            Enabled : 1
      Hot Pluggable : 1
       Non-Volatile : 0
공유 SRAT proximity domain
DomainBase AddressAddress LengthFlags
0000000100000010000000000000000200000000Enabled, Hot Pluggable, Volatile

host bridge 뒤의 두 device가 운영체제에는 하나의 memory affinity node로 노출됩니다.

flags 값 0000000B에서 `Enabled`와 `Hot Pluggable`은 1이고 `Non-Volatile`은 0입니다. 이 range는 활성화된 hot-pluggable volatile memory입니다.

HMAT: 공유 node의 latency와 bandwidth

56-71

HMAT은 SLLBI structure 두 개로 proximity domain 00000000과 00000001의 latency 및 bandwidth entry를 제공합니다. 별도 device domain이 없으므로 두 expander는 같은 CXL node 성능으로 표현됩니다.

              Structure Type : 0001 [SLLBI]
                   Data Type : 00   [Latency]
Target Proximity Domain List : 00000000
Target Proximity Domain List : 00000001
                       Entry : 0080
                       Entry : 0100

              Structure Type : 0001 [SLLBI]
                   Data Type : 03   [Bandwidth]
Target Proximity Domain List : 00000000
Target Proximity Domain List : 00000001
                       Entry : 1200
                       Entry : 0200
HMAT SLLBI 성능 대응
Target DomainLatency EntryBandwidth EntryRole
0000000000801200local DRAM domain
0000000101000200shared CXL domain

각 data type의 두 entry를 source에 나열된 proximity domain 순서에 맞췄습니다.

data type 00은 latency를 나타내며 entry는 0080과 0100입니다. data type 03은 bandwidth를 나타내며 entry는 1200과 0200입니다.

SLIT: locality distance

72-78

SLIT(System Locality Information Table)는 locality 수를 3으로 선언합니다. source dump에 표시된 locality 0의 값은 10과 20이고 locality 1의 값은 FF와 0A입니다.

   Signature : "SLIT"    [System Locality Information Table]
  Localities : 0000000000000003
Locality   0 : 10 20
Locality   1 : FF 0A
SLIT source dump 거리
Locality RowFirst ValueSecond ValueInterpretation
01020local CPU와 remote CXL 방향 거리
1FF0Ainitiator 경로 없음과 local CXL 거리

원문에 표시된 locality row의 abstract distance를 순서대로 보존합니다.

DSDT: 단일 CXL host bridge identity

79-90

DSDT의 `_SB` scope에는 S0D0 device 하나가 CXL host bridge로 선언됩니다. `_HID`는 Compute Express Link Host Bridge를 뜻하는 `ACPI0016`이고 `_UID`는 0x07입니다.

Scope (_SB)
{
  Device (S0D0)
  {
      Name (_HID, "ACPI0016" /* Compute Express Link Host Bridge */)  // _HID: Hardware ID
      ...
      Name (_UID, 0x07)  // _UID: Unique ID
  }
  ...
}
DSDT와 CEDT identity 연결
DSDT Device_HID_UIDCEDT Role
S0D0ACPI00160x07CHBS / First Target 00000007

DSDT의 유일한 CXL host bridge가 CEDT CHBS와 CFMWS target에 같은 UID로 연결됩니다.

이 `_UID` 0x07은 CEDT의 associated host bridge 00000007 및 CFMWS First Target과 일치합니다. firmware table은 두 memory expander를 개별 DSDT device로 구분하지 않고 같은 host bridge 뒤의 공유 range로 연결합니다.