From 87bd28210f2b314978989fdcecedc596d17ac856 Mon Sep 17 00:00:00 2001 From: George Kyriazis Date: Thu, 17 Nov 2016 16:21:12 -0600 Subject: swr: renamed duplicate swr_create_screen() There are 2 swr_create_screen() functions. One in swr_loader.cpp, which is used during driver init, and the other is hiding in swr_screen.cpp, which ends up in the arch-specific .dll/.so. Rename the second one to swr_create_screen_internal(), to avoid confusion in header files. Reviewed-by: Emil Velikov --- src/gallium/drivers/swr/swr_loader.cpp | 2 +- src/gallium/drivers/swr/swr_public.h | 4 ++++ src/gallium/drivers/swr/swr_screen.cpp | 2 +- 3 files changed, 6 insertions(+), 2 deletions(-) (limited to 'src/gallium') diff --git a/src/gallium/drivers/swr/swr_loader.cpp b/src/gallium/drivers/swr/swr_loader.cpp index 2113c371c5f..9d79fa5fb0d 100644 --- a/src/gallium/drivers/swr/swr_loader.cpp +++ b/src/gallium/drivers/swr/swr_loader.cpp @@ -54,7 +54,7 @@ swr_create_screen(struct sw_winsys *winsys) exit(-1); } - util_dl_proc pScreenProc = util_dl_get_proc_address(pLibrary, "swr_create_screen"); + util_dl_proc pScreenProc = util_dl_get_proc_address(pLibrary, "swr_create_screen_internal"); if (!pScreenProc) { fprintf(stderr, "SWR library search failure: %s\n", util_dl_error()); diff --git a/src/gallium/drivers/swr/swr_public.h b/src/gallium/drivers/swr/swr_public.h index 0814c3b85d6..7ef81bf8430 100644 --- a/src/gallium/drivers/swr/swr_public.h +++ b/src/gallium/drivers/swr/swr_public.h @@ -32,8 +32,12 @@ struct sw_displaytarget; extern "C" { #endif +// driver entry point struct pipe_screen *swr_create_screen(struct sw_winsys *winsys); +// arch-specific dll entry point +PUBLIC struct pipe_screen *swr_create_screen_internal(struct sw_winsys *winsys); + struct sw_winsys *swr_get_winsys(struct pipe_screen *pipe); struct sw_displaytarget *swr_get_displaytarget(struct pipe_resource *resource); diff --git a/src/gallium/drivers/swr/swr_screen.cpp b/src/gallium/drivers/swr/swr_screen.cpp index cc79f28bad1..8a851286031 100644 --- a/src/gallium/drivers/swr/swr_screen.cpp +++ b/src/gallium/drivers/swr/swr_screen.cpp @@ -986,7 +986,7 @@ swr_destroy_screen(struct pipe_screen *p_screen) PUBLIC struct pipe_screen * -swr_create_screen(struct sw_winsys *winsys) +swr_create_screen_internal(struct sw_winsys *winsys) { struct swr_screen *screen = CALLOC_STRUCT(swr_screen); -- cgit v1.2.3