Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

tools/testing/cxl: Expand CFMWS windows

For the x2 host-bridge interleave windows, allow for a
x8-endpoint-interleave configuration per memory-type with each device
contributing the minimum 256MB extent. Similarly, for the x1 host-bridge
interleave windows, allow for a x4-endpoint-interleave configuration per
memory-type.

Bump up the number of decoders per-port to support hosting 8 regions.

Reviewed-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Link: https://lore.kernel.org/r/165603886721.551046.8682583835505795210.stgit@dwillia2-xfh
Signed-off-by: Dan Williams <dan.j.williams@intel.com>

+5 -5
+5 -5
tools/testing/cxl/test/cxl.c
··· 14 14 #define NR_CXL_HOST_BRIDGES 2 15 15 #define NR_CXL_ROOT_PORTS 2 16 16 #define NR_CXL_SWITCH_PORTS 2 17 - #define NR_CXL_PORT_DECODERS 2 17 + #define NR_CXL_PORT_DECODERS 8 18 18 19 19 static struct platform_device *cxl_acpi; 20 20 static struct platform_device *cxl_host_bridge[NR_CXL_HOST_BRIDGES]; ··· 118 118 .restrictions = ACPI_CEDT_CFMWS_RESTRICT_TYPE3 | 119 119 ACPI_CEDT_CFMWS_RESTRICT_VOLATILE, 120 120 .qtg_id = 0, 121 - .window_size = SZ_256M, 121 + .window_size = SZ_256M * 4UL, 122 122 }, 123 123 .target = { 0 }, 124 124 }, ··· 133 133 .restrictions = ACPI_CEDT_CFMWS_RESTRICT_TYPE3 | 134 134 ACPI_CEDT_CFMWS_RESTRICT_VOLATILE, 135 135 .qtg_id = 1, 136 - .window_size = SZ_256M * 2, 136 + .window_size = SZ_256M * 8UL, 137 137 }, 138 138 .target = { 0, 1, }, 139 139 }, ··· 148 148 .restrictions = ACPI_CEDT_CFMWS_RESTRICT_TYPE3 | 149 149 ACPI_CEDT_CFMWS_RESTRICT_PMEM, 150 150 .qtg_id = 2, 151 - .window_size = SZ_256M, 151 + .window_size = SZ_256M * 4UL, 152 152 }, 153 153 .target = { 0 }, 154 154 }, ··· 163 163 .restrictions = ACPI_CEDT_CFMWS_RESTRICT_TYPE3 | 164 164 ACPI_CEDT_CFMWS_RESTRICT_PMEM, 165 165 .qtg_id = 3, 166 - .window_size = SZ_256M * 2, 166 + .window_size = SZ_256M * 8UL, 167 167 }, 168 168 .target = { 0, 1, }, 169 169 },