i915: Compute maximum number of verts using the actual batchbuffer size.
We were looking at the size of batch.map for how big the batchbuffer was, but on 865 we just use a single-page batchbuffer due to hardware limits. v2: Removed check for sizeof map < bo->size, since that's always false. [change by anholt] NOTE: This is a candidate for release branches. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=41495
This commit is contained in:
parent
33b07893e9
commit
024ece7523
|
@ -125,9 +125,9 @@ static INLINE GLuint intel_get_vb_max(struct intel_context *intel)
|
|||
{
|
||||
GLuint ret;
|
||||
|
||||
if (intel->intelScreen->no_vbo)
|
||||
ret = sizeof(intel->batch.map) - INTEL_NO_VBO_STATE_RESERVED;
|
||||
else
|
||||
if (intel->intelScreen->no_vbo) {
|
||||
ret = intel->batch.bo->size - INTEL_NO_VBO_STATE_RESERVED;
|
||||
} else
|
||||
ret = INTEL_VB_SIZE;
|
||||
ret /= (intel->vertex_size * 4);
|
||||
return ret;
|
||||
|
|
Loading…
Reference in New Issue