Lines Matching refs:pgmap
216 return (addr + adev->kfd.dev->pgmap.range.start) >> PAGE_SHIFT; in svm_migrate_addr_to_pfn()
247 return (addr - adev->kfd.dev->pgmap.range.start); in svm_migrate_addr()
935 struct dev_pagemap *pgmap; in svm_migrate_init() local
944 pgmap = &kfddev->pgmap; in svm_migrate_init()
945 memset(pgmap, 0, sizeof(*pgmap)); in svm_migrate_init()
955 pgmap->type = MEMORY_DEVICE_PRIVATE; in svm_migrate_init()
956 pgmap->nr_range = 1; in svm_migrate_init()
957 pgmap->range.start = res->start; in svm_migrate_init()
958 pgmap->range.end = res->end; in svm_migrate_init()
959 pgmap->ops = &svm_migrate_pgmap_ops; in svm_migrate_init()
960 pgmap->owner = SVM_ADEV_PGMAP_OWNER(adev); in svm_migrate_init()
961 pgmap->flags = MIGRATE_VMA_SELECT_DEVICE_PRIVATE; in svm_migrate_init()
966 r = devm_memremap_pages(adev->dev, pgmap); in svm_migrate_init()
971 pgmap->type = 0; in svm_migrate_init()