mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-02 10:08:08 +02:00
vc4: Detect and report kernel support for branching.
This commit is contained in:
parent
16985eb308
commit
83b8ca58e1
1 changed files with 12 additions and 2 deletions
|
|
@ -32,6 +32,8 @@
|
|||
#include "util/u_format.h"
|
||||
#include "util/ralloc.h"
|
||||
|
||||
#include <xf86drm.h>
|
||||
#include "vc4_drm.h"
|
||||
#include "vc4_screen.h"
|
||||
#include "vc4_context.h"
|
||||
#include "vc4_resource.h"
|
||||
|
|
@ -502,9 +504,17 @@ vc4_supports_branches(struct vc4_screen *screen)
|
|||
{
|
||||
#if USE_VC4_SIMULATOR
|
||||
return true;
|
||||
#else
|
||||
return false;
|
||||
#endif
|
||||
|
||||
struct drm_vc4_get_param p = {
|
||||
.param = DRM_VC4_PARAM_SUPPORTS_BRANCHES,
|
||||
};
|
||||
int ret = drmIoctl(screen->fd, DRM_IOCTL_VC4_GET_PARAM, &p);
|
||||
|
||||
if (ret != 0)
|
||||
return false;
|
||||
|
||||
return p.value;
|
||||
}
|
||||
|
||||
struct pipe_screen *
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue