r600c: add support for llano
authorAlex Deucher <alexdeucher@gmail.com>
Mon, 4 Apr 2011 16:29:50 +0000 (12:29 -0400)
committerAlex Deucher <alexdeucher@gmail.com>
Tue, 31 May 2011 22:10:01 +0000 (18:10 -0400)
Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
src/mesa/drivers/dri/r600/evergreen_blit.c
src/mesa/drivers/dri/r600/evergreen_chip.c
src/mesa/drivers/dri/r600/evergreen_state.c
src/mesa/drivers/dri/radeon/radeon_chipset.h
src/mesa/drivers/dri/radeon/radeon_common_context.c
src/mesa/drivers/dri/radeon/radeon_screen.c

index 0e4da54..95ac4ae 100644 (file)
@@ -1525,6 +1525,48 @@ eg_set_default_state(context_t *context)
            num_hs_stack_entries = 42;
            num_ls_stack_entries = 42;
            break;
+    case CHIP_FAMILY_SUMO:
+           num_ps_gprs = 93;
+           num_vs_gprs = 46;
+           num_temp_gprs = 4;
+           num_gs_gprs = 31;
+           num_es_gprs = 31;
+           num_hs_gprs = 23;
+           num_ls_gprs = 23;
+           num_ps_threads = 96;
+           num_vs_threads = 25;
+           num_gs_threads = 25;
+           num_es_threads = 25;
+           num_hs_threads = 25;
+           num_ls_threads = 25;
+           num_ps_stack_entries = 42;
+           num_vs_stack_entries = 42;
+           num_gs_stack_entries = 42;
+           num_es_stack_entries = 42;
+           num_hs_stack_entries = 42;
+           num_ls_stack_entries = 42;
+           break;
+    case CHIP_FAMILY_SUMO2:
+           num_ps_gprs = 93;
+           num_vs_gprs = 46;
+           num_temp_gprs = 4;
+           num_gs_gprs = 31;
+           num_es_gprs = 31;
+           num_hs_gprs = 23;
+           num_ls_gprs = 23;
+           num_ps_threads = 96;
+           num_vs_threads = 25;
+           num_gs_threads = 25;
+           num_es_threads = 25;
+           num_hs_threads = 25;
+           num_ls_threads = 25;
+           num_ps_stack_entries = 85;
+           num_vs_stack_entries = 85;
+           num_gs_stack_entries = 85;
+           num_es_stack_entries = 85;
+           num_hs_stack_entries = 85;
+           num_ls_stack_entries = 85;
+           break;
     case CHIP_FAMILY_BARTS:
            num_ps_gprs = 93;
            num_vs_gprs = 46;
@@ -1592,6 +1634,8 @@ eg_set_default_state(context_t *context)
 
     if ((context->radeon.radeonScreen->chip_family == CHIP_FAMILY_CEDAR) ||
        (context->radeon.radeonScreen->chip_family == CHIP_FAMILY_PALM) ||
+       (context->radeon.radeonScreen->chip_family == CHIP_FAMILY_SUMO) ||
+       (context->radeon.radeonScreen->chip_family == CHIP_FAMILY_SUMO2) ||
        (context->radeon.radeonScreen->chip_family == CHIP_FAMILY_CAICOS))
            CLEARbit(sq_config, EG_SQ_CONFIG__VC_ENABLE_bit);
     else
index 42566e5..388a96f 100644 (file)
@@ -287,7 +287,9 @@ static void evergreenSetupVTXConstants(struct gl_context  * ctx,
            return;
 
     if ((context->radeon.radeonScreen->chip_family == CHIP_FAMILY_CEDAR) ||
-       (context->radeon.radeonScreen->chip_family == CHIP_FAMILY_PALM))
+       (context->radeon.radeonScreen->chip_family == CHIP_FAMILY_PALM) ||
+       (context->radeon.radeonScreen->chip_family == CHIP_FAMILY_SUMO) ||
+       (context->radeon.radeonScreen->chip_family == CHIP_FAMILY_SUMO2))
            r700SyncSurf(context, paos->bo, RADEON_GEM_DOMAIN_GTT, 0, TC_ACTION_ENA_bit);
     else
            r700SyncSurf(context, paos->bo, RADEON_GEM_DOMAIN_GTT, 0, VC_ACTION_ENA_bit);
index 309c93f..81bf117 100644 (file)
@@ -1470,6 +1470,22 @@ static void evergreenInitSQConfig(struct gl_context * ctx)
         uMaxThreads = 192;
         uMaxStackEntries = 256;
            break;
+    case CHIP_FAMILY_SUMO:
+           uSqNumCfInsts       = 2;
+        bVC_ENABLE = GL_FALSE;
+        uMaxGPRs = 256;
+        uPSThreadCount = 96;
+        uMaxThreads = 248;
+        uMaxStackEntries = 256;
+           break;
+    case CHIP_FAMILY_SUMO2:
+           uSqNumCfInsts       = 2;
+        bVC_ENABLE = GL_FALSE;
+        uMaxGPRs = 256;
+        uPSThreadCount = 96;
+        uMaxThreads = 248;
+        uMaxStackEntries = 512;
+           break;
     case CHIP_FAMILY_BARTS:
            uSqNumCfInsts       = 2;
         bVC_ENABLE = GL_TRUE;
index 9145023..bd23662 100644 (file)
 #define PCI_CHIP_PALM_9806              0x9806
 #define PCI_CHIP_PALM_9807              0x9807
 
+#define PCI_CHIP_SUMO_9640              0x9640
+#define PCI_CHIP_SUMO_9641              0x9641
+#define PCI_CHIP_SUMO2_9642             0x9642
+#define PCI_CHIP_SUMO2_9643             0x9643
+#define PCI_CHIP_SUMO2_9644             0x9644
+#define PCI_CHIP_SUMO2_9645             0x9645
+#define PCI_CHIP_SUMO_9647              0x9647
+#define PCI_CHIP_SUMO_9648              0x9648
+#define PCI_CHIP_SUMO_964A              0x964a
+#define PCI_CHIP_SUMO_964E              0x964e
+#define PCI_CHIP_SUMO_964F              0x964f
+
 #define PCI_CHIP_BARTS_6720             0x6720
 #define PCI_CHIP_BARTS_6721             0x6721
 #define PCI_CHIP_BARTS_6722             0x6722
@@ -534,6 +546,8 @@ enum {
    CHIP_FAMILY_CYPRESS,
    CHIP_FAMILY_HEMLOCK,
    CHIP_FAMILY_PALM,
+   CHIP_FAMILY_SUMO,
+   CHIP_FAMILY_SUMO2,
    CHIP_FAMILY_BARTS,
    CHIP_FAMILY_TURKS,
    CHIP_FAMILY_CAICOS,
index 5d7b397..bf8925f 100644 (file)
@@ -98,6 +98,8 @@ static const char* get_chip_family_name(int chip_family)
        case CHIP_FAMILY_CYPRESS: return "CYPRESS";
        case CHIP_FAMILY_HEMLOCK: return "HEMLOCK";
        case CHIP_FAMILY_PALM: return "PALM";
+       case CHIP_FAMILY_SUMO: return "SUMO";
+       case CHIP_FAMILY_SUMO2: return "SUMO2";
        case CHIP_FAMILY_BARTS: return "BARTS";
        case CHIP_FAMILY_TURKS: return "TURKS";
        case CHIP_FAMILY_CAICOS: return "CAICOS";
index 6449229..6cf8434 100644 (file)
@@ -1168,6 +1168,25 @@ static int radeon_set_screen_flags(radeonScreenPtr screen, int device_id)
        screen->chip_flags = RADEON_CHIPSET_TCL;
        break;
 
+    case PCI_CHIP_SUMO_9640:
+    case PCI_CHIP_SUMO_9641:
+    case PCI_CHIP_SUMO_9647:
+    case PCI_CHIP_SUMO_9648:
+    case PCI_CHIP_SUMO_964A:
+    case PCI_CHIP_SUMO_964E:
+    case PCI_CHIP_SUMO_964F:
+       screen->chip_family = CHIP_FAMILY_SUMO;
+       screen->chip_flags = RADEON_CHIPSET_TCL;
+       break;
+
+    case PCI_CHIP_SUMO2_9642:
+    case PCI_CHIP_SUMO2_9643:
+    case PCI_CHIP_SUMO2_9644:
+    case PCI_CHIP_SUMO2_9645:
+       screen->chip_family = CHIP_FAMILY_SUMO2;
+       screen->chip_flags = RADEON_CHIPSET_TCL;
+       break;
+
    case PCI_CHIP_BARTS_6720:
    case PCI_CHIP_BARTS_6721:
    case PCI_CHIP_BARTS_6722: