drm/nouveau/mmu: support initialisation of client-managed address-spaces
NVKM is currently responsible for managing the allocation of a client's GPU address-space, but there's various use-cases (ie. HMM address-space mirroring) where giving a client more direct control is desirable. This commit allows for a VMM to be created where the area allocated for NVKM is limited to a client-specified window, the remainder of address- space is controlled directly by the client. Leaving a window is necessary to support various internal requirements, but also to support existing allocation interfaces as not all of the HW is capable of working with a HMM allocation. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
这个提交包含在:
@@ -3,7 +3,8 @@
|
||||
struct nvif_vmm_v0 {
|
||||
__u8 version;
|
||||
__u8 page_nr;
|
||||
__u8 pad02[6];
|
||||
__u8 managed;
|
||||
__u8 pad03[5];
|
||||
__u64 addr;
|
||||
__u64 size;
|
||||
__u8 data[];
|
||||
|
@@ -30,8 +30,8 @@ struct nvif_vmm {
|
||||
int page_nr;
|
||||
};
|
||||
|
||||
int nvif_vmm_init(struct nvif_mmu *, s32 oclass, u64 addr, u64 size,
|
||||
void *argv, u32 argc, struct nvif_vmm *);
|
||||
int nvif_vmm_init(struct nvif_mmu *, s32 oclass, bool managed, u64 addr,
|
||||
u64 size, void *argv, u32 argc, struct nvif_vmm *);
|
||||
void nvif_vmm_fini(struct nvif_vmm *);
|
||||
int nvif_vmm_get(struct nvif_vmm *, enum nvif_vmm_get, bool sparse,
|
||||
u8 page, u8 align, u64 size, struct nvif_vma *);
|
||||
|
在新工单中引用
屏蔽一个用户