public inbox for linux-media@vger.kernel.org
 help / color / mirror / Atom feed
* [videobuf] Query: Condition bytesize limit in videobuf_reqbufs -> buf_setup() call?
@ 2010-05-05 20:53 Aguirre, Sergio
  2010-05-05 23:24 ` Mauro Carvalho Chehab
  2010-05-06  7:13 ` Pawel Osciak
  0 siblings, 2 replies; 12+ messages in thread
From: Aguirre, Sergio @ 2010-05-05 20:53 UTC (permalink / raw)
  To: linux-media@vger.kernel.org

Hi all,

While working on an old port of the omap3 camera-isp driver,
I have faced some problem.

Basically, when calling VIDIOC_REQBUFS with a certain buffer
Count, we had a software limit for total size, calculated depending on:

  Total bytesize = bytesperline x height x count

So, we had an arbitrary limit to, say 32 MB, which was generic.

Now, we want to condition it ONLY when MMAP buffers will be used.
Meaning, we don't want to keep that policy when the kernel is not
allocating the space

But the thing is that, according to videobuf documentation, buf_setup is
the one who should put a RAM usage limit. BUT the memory type passed to
reqbufs is not propagated to buf_setup, therefore forcing me to go to a
non-standard memory limitation in my reqbufs callback function, instead
of doing it properly inside buf_setup.

Is this scenario a good consideration to change buf_setup API, and
propagate buffers memory type aswell?

I'll appreciate your inputs on this matter.

Regards,
Sergio

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2010-05-06 14:51 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-05-05 20:53 [videobuf] Query: Condition bytesize limit in videobuf_reqbufs -> buf_setup() call? Aguirre, Sergio
2010-05-05 23:24 ` Mauro Carvalho Chehab
2010-05-05 23:29   ` Aguirre, Sergio
2010-05-05 23:52     ` Mauro Carvalho Chehab
2010-05-06  8:09     ` Laurent Pinchart
2010-05-06 12:38       ` Mauro Carvalho Chehab
2010-05-06 13:03         ` Laurent Pinchart
2010-05-06 13:23           ` Mauro Carvalho Chehab
2010-05-06 14:52             ` Laurent Pinchart
2010-05-06  7:13 ` Pawel Osciak
2010-05-06 13:10   ` Mauro Carvalho Chehab
2010-05-06 13:29     ` Pawel Osciak

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox