Mesa (main): dri: Remove unused driGetRendererString

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Thu Dec 16 01:20:32 UTC 2021


Module: Mesa
Branch: main
Commit: 6c5b3c6bb56b12ae1e0f04e7bb62e2e60abe991d
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=6c5b3c6bb56b12ae1e0f04e7bb62e2e60abe991d

Author: Adam Jackson <ajax at redhat.com>
Date:   Thu Dec  9 15:53:27 2021 -0500

dri: Remove unused driGetRendererString

Reviewed-by: Emma Anholt <emma at anholt.net>
Reviewed-by: Marek Olšák <marek.olsak at amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14199>

---

 src/gallium/frontends/dri/utils.c | 53 ---------------------------------------
 src/gallium/frontends/dri/utils.h |  3 ---
 2 files changed, 56 deletions(-)

diff --git a/src/gallium/frontends/dri/utils.c b/src/gallium/frontends/dri/utils.c
index 241bade2e15..e44647eeafc 100644
--- a/src/gallium/frontends/dri/utils.c
+++ b/src/gallium/frontends/dri/utils.c
@@ -53,59 +53,6 @@
 #define GLX_NON_CONFORMANT_CONFIG                               0x800D
 #define GLX_DONT_CARE                                           0xFFFFFFFF
 
-/**
- * Create the \c GL_RENDERER string for DRI drivers.
- * 
- * Almost all DRI drivers use a \c GL_RENDERER string of the form:
- *
- *    "Mesa DRI <chip> <driver date> <AGP speed) <CPU information>"
- *
- * Using the supplied chip name, driver data, and AGP speed, this function
- * creates the string.
- * 
- * \param buffer         Buffer to hold the \c GL_RENDERER string.
- * \param hardware_name  Name of the hardware.
- * \param agp_mode       AGP mode (speed).
- * 
- * \returns
- * The length of the string stored in \c buffer.  This does \b not include
- * the terminating \c NUL character.
- */
-unsigned
-driGetRendererString( char * buffer, const char * hardware_name,
-		      GLuint agp_mode )
-{
-   unsigned offset;
-   char *cpu;
-
-   offset = sprintf( buffer, "Mesa DRI %s", hardware_name );
-
-   /* Append any AGP-specific information.
-    */
-   switch ( agp_mode ) {
-   case 1:
-   case 2:
-   case 4:
-   case 8:
-      offset += sprintf( & buffer[ offset ], " AGP %ux", agp_mode );
-      break;
-	
-   default:
-      break;
-   }
-
-   /* Append any CPU-specific information.
-    */
-   cpu = _mesa_get_cpu_string();
-   if (cpu) {
-      offset += sprintf(buffer + offset, " %s", cpu);
-      free(cpu);
-   }
-
-   return offset;
-}
-
-
 /**
  * Creates a set of \c struct gl_config that a driver will expose.
  * 
diff --git a/src/gallium/frontends/dri/utils.h b/src/gallium/frontends/dri/utils.h
index 7be0465c261..772f335b0af 100644
--- a/src/gallium/frontends/dri/utils.h
+++ b/src/gallium/frontends/dri/utils.h
@@ -32,9 +32,6 @@
 #include <GL/internal/dri_interface.h>
 #include "main/context.h"
 
-extern unsigned driGetRendererString( char * buffer,
-    const char * hardware_name, GLuint agp_mode );
-
 struct __DRIconfigRec {
     struct gl_config modes;
 };



More information about the mesa-commit mailing list