Page MenuHomeFreeBSD

Allow framebuffer driver control memory mapping type for mmap(2) call
ClosedPublic

Authored by gonzo on Sep 29 2016, 2:31 AM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Apr 26, 6:38 AM
Unknown Object (File)
Fri, Apr 26, 6:22 AM
Unknown Object (File)
Wed, Apr 24, 7:53 PM
Unknown Object (File)
Sun, Apr 21, 4:15 PM
Unknown Object (File)
Mar 15 2024, 3:24 PM
Unknown Object (File)
Mar 15 2024, 3:24 PM
Unknown Object (File)
Jan 26 2024, 5:14 PM
Unknown Object (File)
Dec 22 2023, 2:35 PM
Subscribers

Details

Summary

At the moment framebuffer driver does not have control over
mapping type for mmap(2). So when on ARM userland app mmaps
/dev/fb0 it gets default mapping which is write-back. So most of
the changes to fb region show up seconds later when respective
cache lines are evicted.

Proposed patch adds one more flag to fb_flags field that indicates
whether hardware driver need special type of mapping and adds one
more field with actual mapping type. bcm2835_fbd.c was used as an
example of the driver that requests VM_MEMATTR_WRITE_COMBINING.

Another possibility - always use VM_MEMATTR_WRITE_COMBINING, but
make sure that all platforms have it defined.

Diff Detail

Event Timeline

gonzo retitled this revision from to Allow framebuffer driver control memory mapping type for mmap(2) call.
gonzo updated this object.
gonzo edited the test plan for this revision. (Show Details)
gonzo added reviewers: ray, dumbbell, emaste.
ray edited edge metadata.

Cool! Thank you Oleksandr!

This revision is now accepted and ready to land.Sep 29 2016, 6:45 AM
This revision was automatically updated to reflect the committed changes.