summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorFelix Held <felix-coreboot@felixheld.de>2023-08-03 16:03:17 +0200
committerFelix Held <felix-coreboot@felixheld.de>2023-08-08 19:44:51 +0000
commit5606a12f90107f82acfb19ff07a9c870744ef383 (patch)
tree52860322b8d67f894d0ec0466293f968d5c35ee6 /src
parent1b02483ab6e152c9987b384849f42d21eb5c4d92 (diff)
soc/amd/cezanne/include/data_fabric: add data fabric IO decode registers
PPR #56569 Rev 3.04 was used as a reference. Signed-off-by: Felix Held <felix-coreboot@felixheld.de> Change-Id: Ifcae9c9ad664d50100cd40692fd9631845f76671 Reviewed-on: https://review.coreboot.org/c/coreboot/+/76956 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Martin L Roth <gaumless@gmail.com>
Diffstat (limited to 'src')
-rw-r--r--src/soc/amd/cezanne/include/soc/data_fabric.h34
1 files changed, 34 insertions, 0 deletions
diff --git a/src/soc/amd/cezanne/include/soc/data_fabric.h b/src/soc/amd/cezanne/include/soc/data_fabric.h
index 3cb0fd71ed..7787e19728 100644
--- a/src/soc/amd/cezanne/include/soc/data_fabric.h
+++ b/src/soc/amd/cezanne/include/soc/data_fabric.h
@@ -8,6 +8,40 @@
#define IOMS0_FABRIC_ID 10
+#define DF_IO_BASE0 DF_REG_ID(0, 0xc0)
+#define DF_IO_LIMIT0 DF_REG_ID(0, 0xc4)
+
+#define DF_IO_REG_COUNT 8
+
+#define DF_IO_REG_OFFSET(instance) ((instance) * 2 * sizeof(uint32_t))
+#define DF_IO_BASE(reg) (DF_IO_BASE0 + DF_IO_REG_OFFSET(reg))
+#define DF_IO_LIMIT(reg) (DF_IO_LIMIT0 + DF_IO_REG_OFFSET(reg))
+
+union df_io_base {
+ struct {
+ uint32_t re : 1; /* [ 0.. 0] */
+ uint32_t we : 1; /* [ 1.. 1] */
+ uint32_t : 3; /* [ 2.. 4] */
+ uint32_t ie : 1; /* [ 5.. 5] */
+ uint32_t : 6; /* [ 6..11] */
+ uint32_t io_base : 13; /* [12..24] */
+ uint32_t : 7; /* [25..31] */
+ };
+ uint32_t raw;
+};
+
+union df_io_limit {
+ struct {
+ uint32_t dst_fabric_id : 10; /* [ 0.. 9] */
+ uint32_t : 2; /* [10..11] */
+ uint32_t io_limit : 13; /* [12..24] */
+ uint32_t : 7; /* [25..31] */
+ };
+ uint32_t raw;
+};
+
+#define DF_IO_ADDR_SHIFT 12
+
#define DF_MMIO_BASE0 DF_REG_ID(0, 0x200)
#define DF_MMIO_LIMIT0 DF_REG_ID(0, 0x204)
#define DF_MMIO_SHIFT 16