In parse_identifier, it doesn't stop copying '*pcur'
untill encounter the NULL. As the 'ret' has a
fixed-size buffer, if the '*pcur' has a long string,
there will be a buffer overflow. This patch avoid this.
Signed-off-by: Li Qiang <liq3ea@gmail.com>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
They should mostly be fine, as long the shader compiles. The reported
error should be enough to diagnose something going wrong in case of
failure.
This should help avoiding temporary regressions when new properties are
introduced in mesa.git before they are either handled or filtered out by
virgl, as was the case with commit fbe6e92899.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
There are places in the code where we use pthread_* functions,
but forgot to add corresponding bits onto the compiler command
line. Because of that the build fails:
CCLD virgl_test_server
../src/.libs/libvirglrenderer.so: undefined reference to `pthread_sigmask'
../src/.libs/libvirglrenderer.so: undefined reference to `pthread_join'
../src/.libs/libvirglrenderer.so: undefined reference to `pthread_create'
../src/.libs/libvirglrenderer.so: undefined reference to `pthread_mutexattr_init'
../src/.libs/libvirglrenderer.so: undefined reference to `pthread_mutexattr_destroy'
collect2: error: ld returned 1 exit status
Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Acked-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Some american fuzzy lop tests managed to replace resources, however the
old values got leaked (I am not sure if this should be allowed)
In all cases, introduce a destroy callback to the hashtable, used when a
value is removed, replaced or the table is cleared. This simplifies a
bit resource management and help avoid potential errors by using simply
refcounts.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
we aren't using this currently bring it back later if required.
Signed-off-by: Marc-André Lureau <marcandre.lureau@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
We aren't using this currently, bring it back if we need it later.
Signed-off-by: Marc-André Lureau <marcandre.lureau@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
This updates the tgsi code from mesa, it introduces
changes necessary to deal with tessellation and doubles.
It also drops an unused saturate feature, which we didn't
use anyways.
we don't need the accessor methods in virgl so far, only
the description tables, so drop all the extra stuff for now.
this introduces the python from mesa to generate our cut down
table
This adds support to the parser to accept hex values as floats,
and then adds support to the dumper to allow the user to select
to dump float as 32-bit hex numbers.
[pulled from virgl driver repo]
Signed-off-by: Dave Airlie <airlied@redhat.com>