[vlc-devel] [PATCH] v4l/v4l2: add mmap() fall back for nommu systems

Mike Frysinger vapier.adi at gmail.com
Sun Mar 15 09:27:13 CET 2009


On Thu, Mar 12, 2009 at 09:00, Rémi Denis-Courmont wrote:
> Le mercredi 11 mars 2009 19:36:38 Mike Frysinger, vous avez écrit :
>> >> I'm not really sure how MAP_PRIVATE works. According to the man page it
>> >> creates a private copy on write mapping. Won't that mean that the
>> >> original memory area doesn't get updated?
>> >
>> > Yes. That's the whole point of MAP_PRIVATE - doing copy-on-write to not
>> > share your modifications with others.
>>
>> which is why i made it a fallback.  attempting to use MAP_SHARED on a
>> nommu system results in a failure.  generally nommu does not have
>> multiple programs running simultaneously because it's an embedded
>> system, not a desktop, so only having one application run
>> simultaneously is the norm.
>
> I guess Antoine meant to ask how it works at all in case of v4l(2). In other
> words, how can the kernel driver update the content of memory if we use
> MAP_PRIVATE? (Note that I don't know V4L myself at all)

i imagine the nommu kernel code simply lies.  we know it works because
we've used v4l on a nommu system.  we have vlc capture via v4l from a
black & white sensor and stream it via rtp across the network to a
desktop system.
-mike



More information about the vlc-devel mailing list