diff options
author | Francisco Jerez <currojerez@riseup.net> | 2010-09-28 22:45:27 +0200 |
---|---|---|
committer | Francisco Jerez <currojerez@riseup.net> | 2010-10-12 04:10:09 +0200 |
commit | 09b1062628f2cbddb3ebae20e7b3b8a0a93acebf (patch) | |
tree | fba939828713bc549be66aa2fb97feff65468a49 /nouveau/nouveau_pushbuf.c | |
parent | 1b9187c43a0c17600611edb9e299141748e87974 (diff) |
nouveau: Let the user choose the push buffer size.
Signed-off-by: Francisco Jerez <currojerez@riseup.net>
Acked-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'nouveau/nouveau_pushbuf.c')
-rw-r--r-- | nouveau/nouveau_pushbuf.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/nouveau/nouveau_pushbuf.c b/nouveau/nouveau_pushbuf.c index 28b8018a..90836bcd 100644 --- a/nouveau/nouveau_pushbuf.c +++ b/nouveau/nouveau_pushbuf.c @@ -78,7 +78,7 @@ nouveau_pushbuf_fini_call(struct nouveau_channel *chan) } static int -nouveau_pushbuf_init_call(struct nouveau_channel *chan) +nouveau_pushbuf_init_call(struct nouveau_channel *chan, int buf_size) { struct drm_nouveau_gem_pushbuf req; struct nouveau_channel_priv *nvchan = nouveau_channel(chan); @@ -101,7 +101,7 @@ nouveau_pushbuf_init_call(struct nouveau_channel *chan) for (i = 0; i < CALPB_BUFFERS; i++) { ret = nouveau_bo_new(dev, flags | NOUVEAU_BO_MAP, - 0, CALPB_BUFSZ, &nvpb->buffer[i]); + 0, buf_size, &nvpb->buffer[i]); if (ret) { nouveau_pushbuf_fini_call(chan); return ret; @@ -114,13 +114,13 @@ nouveau_pushbuf_init_call(struct nouveau_channel *chan) } int -nouveau_pushbuf_init(struct nouveau_channel *chan) +nouveau_pushbuf_init(struct nouveau_channel *chan, int buf_size) { struct nouveau_channel_priv *nvchan = nouveau_channel(chan); struct nouveau_pushbuf_priv *nvpb = &nvchan->pb; int ret; - ret = nouveau_pushbuf_init_call(chan); + ret = nouveau_pushbuf_init_call(chan, buf_size); if (ret) return ret; |