Page MenuHomeFreeBSD

Pass the fault type to the pager getpages routine
AbandonedPublic

Authored by markj on Nov 7 2016, 5:53 PM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Apr 5, 5:39 PM
Unknown Object (File)
Mar 23 2024, 1:26 AM
Unknown Object (File)
Mar 5 2024, 8:43 AM
Unknown Object (File)
Jan 23 2024, 2:13 PM
Unknown Object (File)
Dec 20 2023, 5:52 AM
Unknown Object (File)
Nov 27 2022, 1:46 AM
Unknown Object (File)
Apr 13 2017, 6:31 AM
Unknown Object (File)
Apr 3 2017, 11:01 AM
Subscribers

Details

Reviewers
kib
alc
Summary

This is based on some modifications in the freebsd-base-graphics tree,
which updates the in-kernel DRM module, enabling the use of a newer
libdrm and driver support for several newer generations of Intel
graphics chipsets.

The change adds a "prot" parameter to both the getpages and
getpages_async routines. By default, callers specify VM_PROT_ALL, but
vm_fault_hold() is modified to pass the true fault type, providing more
information to the fault handler. The i915 GEM fault handler uses this
hint to optimize the handler and to maintain a dirty state bit on DRM
objects.

Test Plan

I've been running with this patch on an Ivy Bridge laptop for several days.

Diff Detail

Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 5876
Build 6163: arc lint + arc unit

Event Timeline

markj retitled this revision from to Pass the fault type to the pager getpages routine.
markj edited the test plan for this revision. (Show Details)
markj updated this object.
markj edited the test plan for this revision. (Show Details)
markj added reviewers: alc, kib.

See D6620, esp. the discussion. Currently the new interface for GEM/TTM pages is being developed which solves both prot issue, and the prefaulting issue.

In D8466#176055, @kib wrote:

See D6620, esp. the discussion. Currently the new interface for GEM/TTM pages is being developed which solves both prot issue, and the prefaulting issue.

Hm, ok. I remember that discussion but haven't seen any recent developments in the branch.

In D8466#176057, @markj wrote:
In D8466#176055, @kib wrote:

See D6620, esp. the discussion. Currently the new interface for GEM/TTM pages is being developed which solves both prot issue, and the prefaulting issue.

Hm, ok. I remember that discussion but haven't seen any recent developments in the branch.

After you and I got done with the PQ_LAUNDRY work, I started talking to Kostik about this again. Essentially, we're looking to add an optional "fault handler" method to the object.

In D8466#176057, @markj wrote:
In D8466#176055, @kib wrote:

See D6620, esp. the discussion. Currently the new interface for GEM/TTM pages is being developed which solves both prot issue, and the prefaulting issue.

Hm, ok. I remember that discussion but haven't seen any recent developments in the branch.

Which branch ? vm_pager_onfault() lives there https://kib.kiev.ua/git/gitweb.cgi?p=deviant2.git;a=shortlog;h=refs/heads/kms_iic

In D8466#176059, @alc wrote:

After you and I got done with the PQ_LAUNDRY work, I started talking to Kostik about this again. Essentially, we're looking to add an optional "fault handler" method to the object.

Ah, got it.

In D8466#176060, @kib wrote:

I was referring to https://github.com/FreeBSDDesktop/freebsd-base-graphics and just wanted to try and push parts of it along, having spent some time reading and testing the code. But if you have a different approach planned, I'll drop this.