mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 16:08:04 +02:00
v3d: Move v3d_ioctl(..) to src/broadcom/common
It will be re-used by libbroadcom_perfcntrs. Signed-off-by: Christian Gmeiner <cgmeiner@igalia.com> Reviewed-by: Iago Toral Quiroga <itoral@igalia.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32277>
This commit is contained in:
parent
fadcea80c0
commit
0d4313951f
3 changed files with 16 additions and 11 deletions
|
|
@ -29,6 +29,12 @@
|
|||
#include "compiler/shader_enums.h"
|
||||
#include "util/format/u_formats.h"
|
||||
|
||||
#if USE_V3D_SIMULATOR
|
||||
# include "simulator/v3d_simulator.h"
|
||||
#else
|
||||
# include "xf86drm.h"
|
||||
#endif
|
||||
|
||||
uint32_t
|
||||
v3d_csd_choose_workgroups_per_supergroup(struct v3d_device_info *devinfo,
|
||||
bool has_subgroups,
|
||||
|
|
@ -80,4 +86,13 @@ uint32_t
|
|||
v3d_compute_rt_row_row_stride_128_bits(uint32_t tile_width,
|
||||
uint32_t bpp);
|
||||
|
||||
static inline int
|
||||
v3d_ioctl(int fd, unsigned long request, void *arg)
|
||||
{
|
||||
#if USE_V3D_SIMULATOR
|
||||
return v3d_simulator_ioctl(fd, request, arg);
|
||||
#else
|
||||
return drmIoctl(fd, request, arg);
|
||||
#endif
|
||||
}
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -70,7 +70,7 @@ libbroadcom_v3d = static_library(
|
|||
link_whole : v3d_libs + per_version_libs,
|
||||
link_with: [libv3d_neon],
|
||||
build_by_default : false,
|
||||
dependencies: [dep_valgrind, dep_thread, idep_mesautil],
|
||||
dependencies: [dep_valgrind, dep_thread, idep_mesautil, dep_libdrm],
|
||||
)
|
||||
|
||||
if with_broadcom_vk
|
||||
|
|
|
|||
|
|
@ -765,16 +765,6 @@ void v3d_program_init(struct pipe_context *pctx);
|
|||
void v3d_program_fini(struct pipe_context *pctx);
|
||||
void v3d_query_init(struct pipe_context *pctx);
|
||||
|
||||
static inline int
|
||||
v3d_ioctl(int fd, unsigned long request, void *arg)
|
||||
{
|
||||
#if USE_V3D_SIMULATOR
|
||||
return v3d_simulator_ioctl(fd, request, arg);
|
||||
#else
|
||||
return drmIoctl(fd, request, arg);
|
||||
#endif
|
||||
}
|
||||
|
||||
static inline bool
|
||||
v3d_transform_feedback_enabled(struct v3d_context *v3d)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue