mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-06 07:18:17 +02:00
gallium: refactor to use DETECT_OS_ANDROID
Signed-off-by: Yiwei Zhang <zzyiwei@chromium.org> Reviewed-by: Yonggang Luo <luoyonggang@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27374>
This commit is contained in:
parent
8762b2fca1
commit
569437221d
3 changed files with 8 additions and 4 deletions
|
|
@ -31,6 +31,7 @@
|
|||
|
||||
#include "pipe_loader_priv.h"
|
||||
|
||||
#include "util/detect_os.h"
|
||||
#include "util/os_file.h"
|
||||
#include "util/u_memory.h"
|
||||
#include "util/u_dl.h"
|
||||
|
|
@ -78,7 +79,7 @@ static const struct sw_driver_descriptor driver_descriptors = {
|
|||
.create_winsys_kms_dri = kms_dri_create_winsys,
|
||||
},
|
||||
#endif
|
||||
#ifndef __ANDROID__
|
||||
#if !DETECT_OS_ANDROID
|
||||
{
|
||||
.name = "null",
|
||||
.create_winsys = null_sw_create,
|
||||
|
|
@ -107,7 +108,7 @@ static const struct sw_driver_descriptor kopper_driver_descriptors = {
|
|||
.create_winsys_kms_dri = kms_dri_create_winsys,
|
||||
},
|
||||
#endif
|
||||
#ifndef __ANDROID__
|
||||
#if !DETECT_OS_ANDROID
|
||||
{
|
||||
.name = "null",
|
||||
.create_winsys = null_sw_create,
|
||||
|
|
|
|||
|
|
@ -34,6 +34,7 @@
|
|||
#include "pipe/p_state.h"
|
||||
#include "pipe/p_context.h"
|
||||
#include "pipe/p_screen.h"
|
||||
#include "util/detect_os.h"
|
||||
#include "util/os_memory.h"
|
||||
#include "util/u_cpu_detect.h"
|
||||
#include "util/u_inlines.h"
|
||||
|
|
@ -2081,7 +2082,7 @@ iris_map_copy_region(struct iris_transfer *map)
|
|||
|
||||
unsigned row_pitch_B = 0;
|
||||
|
||||
#ifdef ANDROID
|
||||
#if DETECT_OS_ANDROID
|
||||
/* Staging buffers for stall-avoidance blits don't always have the
|
||||
* same restrictions on stride as the original buffer. For example,
|
||||
* the original buffer may be used for scanout, while the staging
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
#include "util/detect_os.h"
|
||||
|
||||
#include "target-helpers/drm_helper.h"
|
||||
#include "target-helpers/sw_helper.h"
|
||||
|
||||
|
|
@ -137,7 +139,7 @@ DEFINE_LOADER_DRM_ENTRYPOINT(lima)
|
|||
#endif
|
||||
|
||||
#if defined(GALLIUM_ZINK) && !defined(__APPLE__)
|
||||
#if defined(ANDROID)
|
||||
#if DETECT_OS_ANDROID
|
||||
DEFINE_LOADER_DRM_ENTRYPOINT(zink);
|
||||
#else
|
||||
const __DRIextension **__driDriverGetExtensions_zink(void);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue