summaryrefslogtreecommitdiffstats
path: root/src/gallium/winsys/r600
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium/winsys/r600')
-rw-r--r--src/gallium/winsys/r600/drm/r600_drm.c17
-rw-r--r--src/gallium/winsys/r600/drm/r600_priv.h5
-rw-r--r--src/gallium/winsys/r600/drm/radeon_pciid.c79
3 files changed, 12 insertions, 89 deletions
diff --git a/src/gallium/winsys/r600/drm/r600_drm.c b/src/gallium/winsys/r600/drm/r600_drm.c
index e83cc44290a..8c847122f84 100644
--- a/src/gallium/winsys/r600/drm/r600_drm.c
+++ b/src/gallium/winsys/r600/drm/r600_drm.c
@@ -40,6 +40,9 @@
#ifndef RADEON_INFO_TILING_CONFIG
#define RADEON_INFO_TILING_CONFIG 0x6
#endif
+
+static struct radeon *radeon_new(int fd, unsigned device);
+
static int radeon_get_device(struct radeon *radeon)
{
struct drm_radeon_info info;
@@ -108,7 +111,7 @@ static int radeon_drm_get_tiling(struct radeon *radeon)
return 0;
}
-struct radeon *radeon_new(int fd, unsigned device)
+static struct radeon *radeon_new(int fd, unsigned device)
{
struct radeon *radeon;
int r;
@@ -249,14 +252,14 @@ struct radeon *radeon_decref(struct radeon *radeon)
return NULL;
}
- if (radeon->cman)
- radeon->cman->destroy(radeon->cman);
+ if (radeon->cman)
+ radeon->cman->destroy(radeon->cman);
- if (radeon->kman)
- radeon->kman->destroy(radeon->kman);
+ if (radeon->kman)
+ radeon->kman->destroy(radeon->kman);
- if (radeon->fd >= 0)
- drmClose(radeon->fd);
+ if (radeon->fd >= 0)
+ drmClose(radeon->fd);
free(radeon);
return NULL;
diff --git a/src/gallium/winsys/r600/drm/r600_priv.h b/src/gallium/winsys/r600/drm/r600_priv.h
index 9fd77b71c77..193af984f8e 100644
--- a/src/gallium/winsys/r600/drm/r600_priv.h
+++ b/src/gallium/winsys/r600/drm/r600_priv.h
@@ -78,7 +78,7 @@ struct r600_bo {
struct pb_buffer *pb;
unsigned size;
unsigned tiling_flags;
- unsigned kernel_pitch;
+ unsigned kernel_pitch;
unsigned domains;
};
@@ -86,9 +86,6 @@ struct r600_bo {
/* radeon_pciid.c */
unsigned radeon_family_from_device(unsigned device);
-/* r600_drm.c */
-struct radeon *radeon_decref(struct radeon *radeon);
-
/* radeon_bo.c */
struct radeon_bo *radeon_bo(struct radeon *radeon, unsigned handle,
unsigned size, unsigned alignment);
diff --git a/src/gallium/winsys/r600/drm/radeon_pciid.c b/src/gallium/winsys/r600/drm/radeon_pciid.c
index 18bddc1a7ab..92560a488ae 100644
--- a/src/gallium/winsys/r600/drm/radeon_pciid.c
+++ b/src/gallium/winsys/r600/drm/radeon_pciid.c
@@ -24,7 +24,7 @@
* Jerome Glisse
*/
#include <stdlib.h>
-#include "r600.h"
+#include "r600_priv.h"
struct pci_id {
unsigned vendor;
@@ -460,80 +460,3 @@ unsigned radeon_family_from_device(unsigned device)
}
return CHIP_UNKNOWN;
}
-
-int radeon_is_family_compatible(unsigned family1, unsigned family2)
-{
- switch (family1) {
- case CHIP_R600:
- case CHIP_RV610:
- case CHIP_RV630:
- case CHIP_RV670:
- case CHIP_RV620:
- case CHIP_RV635:
- case CHIP_RS780:
- case CHIP_RS880:
- case CHIP_RV770:
- case CHIP_RV730:
- case CHIP_RV710:
- case CHIP_RV740:
- case CHIP_CEDAR:
- case CHIP_REDWOOD:
- case CHIP_JUNIPER:
- case CHIP_CYPRESS:
- case CHIP_HEMLOCK:
- case CHIP_PALM:
- switch (family2) {
- case CHIP_R600:
- case CHIP_RV610:
- case CHIP_RV630:
- case CHIP_RV670:
- case CHIP_RV620:
- case CHIP_RV635:
- case CHIP_RS780:
- case CHIP_RS880:
- case CHIP_RV770:
- case CHIP_RV730:
- case CHIP_RV710:
- case CHIP_RV740:
- case CHIP_CEDAR:
- case CHIP_REDWOOD:
- case CHIP_JUNIPER:
- case CHIP_CYPRESS:
- case CHIP_HEMLOCK:
- case CHIP_PALM:
- return 1;
- default:
- return 0;
- }
- break;
- case CHIP_R100:
- case CHIP_RV100:
- case CHIP_RS100:
- case CHIP_RV200:
- case CHIP_RS200:
- case CHIP_R200:
- case CHIP_RV250:
- case CHIP_RS300:
- case CHIP_RV280:
- case CHIP_R300:
- case CHIP_R350:
- case CHIP_RV350:
- case CHIP_RV380:
- case CHIP_R420:
- case CHIP_R423:
- case CHIP_RV410:
- case CHIP_RS400:
- case CHIP_RS480:
- case CHIP_RS600:
- case CHIP_RS690:
- case CHIP_RS740:
- case CHIP_RV515:
- case CHIP_R520:
- case CHIP_RV530:
- case CHIP_RV560:
- case CHIP_RV570:
- case CHIP_R580:
- default:
- return 0;
- }
-}