mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-31 11:20:26 +01:00
nouveau: support nv67
This commit is contained in:
parent
d342a6eecc
commit
ae7dcae81b
2 changed files with 21 additions and 12 deletions
|
|
@ -81,6 +81,7 @@ nouveau_pipe_create(struct nouveau_context *nv)
|
|||
|
||||
switch (nv->chipset & 0xf0) {
|
||||
case 0x40:
|
||||
case 0x60:
|
||||
hw_create = nv40_create;
|
||||
break;
|
||||
case 0x50:
|
||||
|
|
|
|||
|
|
@ -188,26 +188,34 @@ nv40_init_hwctx(struct nv40_context *nv40, int curie_class)
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
#define GRCLASS4097_CHIPSETS 0x00000baf
|
||||
#define GRCLASS4497_CHIPSETS 0x00005450
|
||||
#define NV4X_GRCLASS4097_CHIPSETS 0x00000baf
|
||||
#define NV4X_GRCLASS4497_CHIPSETS 0x00005450
|
||||
#define NV6X_GRCLASS4497_CHIPSETS 0x00000080
|
||||
|
||||
struct pipe_context *
|
||||
nv40_create(struct pipe_winsys *pipe_winsys, struct nouveau_winsys *nvws,
|
||||
unsigned chipset)
|
||||
{
|
||||
struct nv40_context *nv40;
|
||||
int curie_class, ret;
|
||||
int curie_class = 0, ret;
|
||||
|
||||
if ((chipset & 0xf0) != 0x40) {
|
||||
NOUVEAU_ERR("Not a NV4X chipset\n");
|
||||
return NULL;
|
||||
switch (chipset & 0xf0) {
|
||||
case 0x40:
|
||||
if (NV4X_GRCLASS4097_CHIPSETS & (1 << (chipset & 0x0f)))
|
||||
curie_class = NV40TCL;
|
||||
else
|
||||
if (NV4X_GRCLASS4497_CHIPSETS & (1 << (chipset & 0x0f)))
|
||||
curie_class = NV44TCL;
|
||||
break;
|
||||
case 0x60:
|
||||
if (NV6X_GRCLASS4497_CHIPSETS & (1 << (chipset & 0x0f)))
|
||||
curie_class = NV44TCL;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
if (GRCLASS4097_CHIPSETS & (1 << (chipset & 0x0f))) {
|
||||
curie_class = NV40TCL;
|
||||
} else
|
||||
if (GRCLASS4497_CHIPSETS & (1 << (chipset & 0x0f))) {
|
||||
curie_class = NV44TCL;
|
||||
} else {
|
||||
if (!curie_class) {
|
||||
NOUVEAU_ERR("Unknown NV4x chipset: NV%02x\n", chipset);
|
||||
return NULL;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue