[MPlayer-dev-eng] [patch] try mmap(MAP_PRIVATE) fallback for no-mmu systems in fbdev vo

Rich Felker dalias at aerifal.cx
Thu Feb 1 16:58:09 CET 2007

On Thu, Feb 01, 2007 at 11:10:26AM +0100, Reimar Döffinger wrote:
> > Benjamin Z., you are probably a better fit to test it, what  do you
> > think about it?
> Any why is MAP_SHARED used in the first place anyway? Actually, upon
> reading the documentation on mmap, I see no way this could work with
> MAP_PRIVATE unless they have a non-conforming mmap...

I don't think MAP_PRIVATE is correct for mapping devices. It certainly
has strange behavior. MAP_SHARED _should_ work with devices on no-mmu
systems (actually with files too) but the ucLinux folks won't
implement it for some reason, even tho supporting it for devices is
just a matter of removing the "check-for-MAP_SHARED-and-fail" lines.

In any case, the approach of trying MAP_SHARED first and falling back
to MAP_PRIVATE is fine IMO.


More information about the MPlayer-dev-eng mailing list