[updated patch attached]
> Hmm, yes. Although that has been bumped recently it could be changed to
> dynamic, though, but as Dave says,
> we need to impose some kind of limit to avoid DOS.
> Poulsbo is still using a buffer list from user-space, and there's an
> internal kernel array that imposes this limit.
Okay the attached patch lets it dynamic up to 4096, and in theory we could
make it a module parameter or settable via /sys, and possibly add a
getparam for userspace to figure out what the limit is...
> What's a bit different, though, is that the number of relocs is fixed
> (by user space using a fixed-size
> shared memory buffer for the relocs).
What I've done for the reloc numbers is allowed for one reloc per 4-dwords
in a batchbuffer in my Mesa code, and allocated that side.. granted it may
not be that accurate it was just a rough heuristic..
However I have allowed for chaining reloc buffers in the interface if not
in the implementation, if you look are relocation buffer header, the first
word is the relocation count and type of relocation and the second word is
the buffer handle for another buffer of relocations... if this word
contains !zero the code will look it another buffer of relocations.. I
originally meant this for having different types of relocations but I
could see how userspace could "ab"use this to get what you mentioned..