summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/northbridge/amd/amdfam10/northbridge.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/northbridge/amd/amdfam10/northbridge.c b/src/northbridge/amd/amdfam10/northbridge.c
index a42362682e..727a5ba10c 100644
--- a/src/northbridge/amd/amdfam10/northbridge.c
+++ b/src/northbridge/amd/amdfam10/northbridge.c
@@ -865,6 +865,9 @@ static void disable_hoist_memory(unsigned long hole_startk, int node_id)
#if CONFIG_WRITE_HIGH_TABLES==1
#define HIGH_TABLES_SIZE 64 // maximum size of high tables in KB
extern uint64_t high_tables_base, high_tables_size;
+#if CONFIG_GFXUMA == 1
+extern uint64_t uma_memory_base, uma_memory_size;
+#endif
#endif
static void amdfam10_domain_set_resources(device_t dev)
@@ -1038,7 +1041,11 @@ static void amdfam10_domain_set_resources(device_t dev)
#if CONFIG_WRITE_HIGH_TABLES==1
if (high_tables_base==0) {
/* Leave some space for ACPI, PIRQ and MP tables */
+#if CONFIG_GFXUMA == 1
+ high_tables_base = uma_memory_base - (HIGH_TABLES_SIZE * 1024);
+#else
high_tables_base = (mmio_basek - HIGH_TABLES_SIZE) * 1024;
+#endif
high_tables_size = HIGH_TABLES_SIZE * 1024;
printk(BIOS_DEBUG, " split: %dK table at =%08llx\n", HIGH_TABLES_SIZE,
high_tables_base);
@@ -1073,7 +1080,11 @@ static void amdfam10_domain_set_resources(device_t dev)
i, mmio_basek, basek, limitk);
if (high_tables_base==0) {
/* Leave some space for ACPI, PIRQ and MP tables */
+#if CONFIG_GFXUMA == 1
+ high_tables_base = uma_memory_base - (HIGH_TABLES_SIZE * 1024);
+#else
high_tables_base = (limitk - HIGH_TABLES_SIZE) * 1024;
+#endif
high_tables_size = HIGH_TABLES_SIZE * 1024;
}
#endif