caps->pci_id = pci_id;
caps->has_tcl = TRUE;
caps->is_r500 = FALSE;
+ caps->num_vert_pipes = 4;
+
/* Note: These are not ordered by PCI ID. I leave that task to GCC,
* which will perform the ordering while collating jump tables. Instead,
switch (pci_id) {
case 0x4144:
caps->family = CHIP_FAMILY_R300;
- caps->num_pipes = 1;
break;
case 0x4145:
case 0x4E46:
case 0x4E47:
caps->family = CHIP_FAMILY_R300;
- caps->num_pipes = 2;
break;
case 0x4150:
case 0x4E54:
case 0x4E56:
caps->family = CHIP_FAMILY_RV350;
- caps->num_pipes = 1;
break;
case 0x4148:
case 0x4E49:
case 0x4E4B:
caps->family = CHIP_FAMILY_R350;
- caps->num_pipes = 2;
break;
case 0x4E4A:
caps->family = CHIP_FAMILY_R360;
- caps->num_pipes = 2;
break;
case 0x5460:
case 0x5B64:
case 0x5B65:
caps->family = CHIP_FAMILY_RV370;
- caps->num_pipes = 1;
break;
case 0x3150:
case 0x3E50:
case 0x3E54:
caps->family = CHIP_FAMILY_RV380;
- caps->num_pipes = 1;
break;
case 0x4A48:
case 0x4A50:
case 0x4A54:
caps->family = CHIP_FAMILY_R420;
- caps->num_pipes = 4;
+ caps->num_vert_pipes = 6;
break;
case 0x5548:
case 0x5554:
case 0x5D57:
caps->family = CHIP_FAMILY_R423;
- caps->num_pipes = 4;
+ caps->num_vert_pipes = 6;
break;
case 0x554C:
case 0x5D49:
case 0x5D4A:
caps->family = CHIP_FAMILY_R430;
- caps->num_pipes = 4;
+ caps->num_vert_pipes = 6;
break;
case 0x5D4C:
case 0x5D50:
case 0x5D52:
caps->family = CHIP_FAMILY_R480;
- caps->num_pipes = 4;
+ caps->num_vert_pipes = 6;
break;
case 0x4B49:
case 0x4B4B:
case 0x4B4C:
caps->family = CHIP_FAMILY_R481;
- caps->num_pipes = 4;
+ caps->num_vert_pipes = 6;
break;
case 0x5E4C:
case 0x5E4B:
case 0x5E4D:
caps->family = CHIP_FAMILY_RV410;
- caps->num_pipes = 1;
+ caps->num_vert_pipes = 6;
break;
case 0x5954:
case 0x5955:
caps->family = CHIP_FAMILY_RS480;
- caps->num_pipes = 1; /* CHECK ME */
caps->has_tcl = FALSE;
break;
case 0x5974:
case 0x5975:
caps->family = CHIP_FAMILY_RS482;
- caps->num_pipes = 1; /* CHECK ME */
caps->has_tcl = FALSE;
break;
case 0x5A41:
case 0x5A42:
caps->family = CHIP_FAMILY_RS400;
- caps->num_pipes = 1; /* CHECK ME */
caps->has_tcl = FALSE;
break;
case 0x5A61:
case 0x5A62:
caps->family = CHIP_FAMILY_RC410;
- caps->num_pipes = 1; /* CHECK ME */
caps->has_tcl = FALSE;
break;
case 0x791E:
case 0x791F:
caps->family = CHIP_FAMILY_RS690;
- caps->num_pipes = 1; /* CHECK ME */
caps->has_tcl = FALSE;
break;
case 0x796E:
case 0x796F:
caps->family = CHIP_FAMILY_RS740;
- caps->num_pipes = 1; /* CHECK ME */
caps->has_tcl = FALSE;
break;
case 0x710E:
case 0x710F:
caps->family = CHIP_FAMILY_R520;
- caps->num_pipes = 4;
+ caps->num_vert_pipes = 8;
caps->is_r500 = TRUE;
break;
case 0x7210:
case 0x7211:
caps->family = CHIP_FAMILY_RV515;
- caps->num_pipes = 1;
+ caps->num_vert_pipes = 2;
caps->is_r500 = TRUE;
break;
case 0x71DA:
case 0x71DE:
caps->family = CHIP_FAMILY_RV530;
- caps->num_pipes = 1;
+ caps->num_vert_pipes = 5;
caps->is_r500 = TRUE;
break;
case 0x724F:
case 0x7284:
caps->family = CHIP_FAMILY_R580;
- caps->num_pipes = 4;
+ caps->num_vert_pipes = 8;
caps->is_r500 = TRUE;
break;
case 0x7280:
caps->family = CHIP_FAMILY_RV570;
- caps->num_pipes = 4;
+ caps->num_vert_pipes = 5;
caps->is_r500 = TRUE;
break;
case 0x7293:
case 0x7297:
caps->family = CHIP_FAMILY_RV560;
- caps->num_pipes = 4;
+ caps->num_vert_pipes = 5;
caps->is_r500 = TRUE;
break;
uint32_t pci_id;
/* Chipset family */
int family;
- /* The number of Graphics Backend (GB) pipes */
- int num_pipes;
+ /* The number of vertex pipes */
+ int num_vert_pipes;
+ /* The number of fragment pipes */
+ int num_frag_pipes;
/* Whether or not TCL is physically present */
boolean has_tcl;
/* Whether or not this is an RV515 or newer; R500s have many features:
void r300_parse_chipset(uint32_t pci_id, struct r300_capabilities* caps);
-#endif /* R300_CHIPSET_H */
\ No newline at end of file
+#endif /* R300_CHIPSET_H */
unsigned w, unsigned h,
unsigned color)
{
- struct r300_context* context = r300_context(pipe);
- CS_LOCALS(context);
- boolean has_tcl = FALSE;
- boolean is_r500 = FALSE;
+ struct r300_context* r300 = r300_context(pipe);
+ CS_LOCALS(r300);
+ struct r300_capabilities* caps = r300_screen(r300->context.screen)->caps;
+ boolean has_tcl = caps->has_tcl;
+ boolean is_r500 = caps->is_r500;
/* For the for loops. */
int i;
/* Emit a shitload of state, and then draw a point to clear the buffer.
(5 << R300_VF_MAX_VTX_NUM_SHIFT));
}
- if (CHIP_FAMILY_RV515)
- vap_cntl |= (2 << R300_PVS_NUM_FPUS_SHIFT);
- else if ((CHIP_FAMILY_RV530) ||
- (CHIP_FAMILY_RV560) ||
- (CHIP_FAMILY_RV570))
- vap_cntl |= (5 << R300_PVS_NUM_FPUS_SHIFT);
- else if ((CHIP_FAMILY_RV410) ||
- (CHIP_FAMILY_R420))
- vap_cntl |= (6 << R300_PVS_NUM_FPUS_SHIFT);
- else if ((CHIP_FAMILY_R520) ||
- (CHIP_FAMILY_R580))
- vap_cntl |= (8 << R300_PVS_NUM_FPUS_SHIFT);
- else
- vap_cntl |= (4 << R300_PVS_NUM_FPUS_SHIFT);
+ vap_cntl |= (caps->num_vert_pipes <<
+ R300_PVS_NUM_FPUS_SHIFT);
OUT_CS_REG(R300_VAP_CNTL, vap_cntl);
OUT_CS_REG(RADEON_WAIT_UNTIL, (1 << 15) | (1 << 17) | (1 << 18));
FLUSH_CS;
+
+ r300->dirty_state = R300_NEW_KITCHEN_SINK;
}
void r300_init_surface_functions(struct r300_context* r300)