On Fri, 2 Sep 2011 12:33:44 -0300, Eugeni Dodonov <eug...@dodonov.net> wrote: > From: Eugeni Dodonov <eugeni.dodo...@intel.com> > > This could happen in 3 different cases, and ERRNO can explain what > happened. First case would be EIO (gpu hang), second EINVAL (something is > wrong inside the batch), and we also discovered that sometimes it happens > with ENOSPACE. All of those cases are different it it could be worth to at > least know what happened. > > Signed-off-by: Eugeni Dodonov <eugeni.dodo...@intel.com> > --- > src/mesa/drivers/dri/intel/intel_batchbuffer.c | 1 + > 1 files changed, 1 insertions(+), 0 deletions(-) > > diff --git a/src/mesa/drivers/dri/intel/intel_batchbuffer.c > b/src/mesa/drivers/dri/intel/intel_batchbuffer.c > index db4343b..73367f3 100644 > --- a/src/mesa/drivers/dri/intel/intel_batchbuffer.c > +++ b/src/mesa/drivers/dri/intel/intel_batchbuffer.c > @@ -138,6 +138,7 @@ do_flush_locked(struct intel_context *intel) > } > > if (ret != 0) { > + _mesa_warning(NULL, "do_flush_locked: %d\n", ret); > exit(1); > } > intel->vtbl.new_batch(intel);
I would make it fprintf(stderr, "intel_batchbuffer_flush failed: %s\n", strerror(ret)); You want the output even if built without Mesa debugging enabled, and strings are nicer than numbers.
pgpkm864V0mQM.pgp
Description: PGP signature
_______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev