| /linux/drivers/gpu/drm/msm/ |
| H A D | msm_gem_vma.c | 1 // SPDX-License-Identifier: GPL-2.0-only 21 MODULE_PARM_DESC(vm_log_shift, "Length of VM op log"); 25 * struct msm_vm_map_op - create new pgtable mapping 30 /** @range: size of the region to map */ 32 /** @offset: offset into @sgt to map */ 34 /** @sgt: pages to map, or NULL for a PRR mapping */ 48 * struct msm_vm_unmap_op - unmap a range of pages from pgtable 68 * struct msm_vma_op - A MAP or UNMAP operation 77 /** @map: Parameters used if op == MSM_VMA_OP_MAP */ 78 struct msm_vm_map_op map; member [all …]
|
| /linux/drivers/gpu/drm/xe/ |
| H A D | xe_vm_types.h | 1 /* SPDX-License-Identifier: MIT */ 12 #include <linux/dma-resv.h> 52 * struct xe_vma_mem_attr - memory attributes associated with vma 95 * Locking: vm lock in write mode OR vm lock in read mode and the vm's 99 /** @rebind: link into VM if this VMA needs rebinding. */ 101 /** @destroy: link to contested list when VM is being closed. */ 114 * protected by BO's resv and for userptrs, vm->svm.gpusvm.notifier_lock in 115 * write mode for writing or vm->svm.gpusvm.notifier_lock in read mode and 116 * the vm->resv. For stable reading, BO's resv or userptr 117 * vm->svm.gpusvm.notifier_lock in read mode is required. Can be [all …]
|
| H A D | xe_vm.c | 1 // SPDX-License-Identifier: MIT 8 #include <linux/dma-fence-array.h> 45 static struct drm_gem_object *xe_vm_obj(struct xe_vm *vm) in xe_vm_obj() argument 47 return vm->gpuvm.r_obj; in xe_vm_obj() 51 * xe_vm_drm_exec_lock() - Lock the vm's resv with a drm_exec transaction 52 * @vm: The vm whose resv is to be locked. 55 * Helper to lock the vm's resv as part of a drm_exec transaction. 59 int xe_vm_drm_exec_lock(struct xe_vm *vm, struct drm_exec *exec) in xe_vm_drm_exec_lock() argument 61 return drm_exec_lock_obj(exec, xe_vm_obj(vm)); in xe_vm_drm_exec_lock() 64 static bool preempt_fences_waiting(struct xe_vm *vm) in preempt_fences_waiting() argument [all …]
|
| H A D | xe_migrate_doc.h | 1 /* SPDX-License-Identifier: MIT */ 14 * a migrate engine, and uses a special VM for all generated jobs. 16 * Special VM details 19 * The special VM is configured with a page structure where we can dynamically 20 * map BOs which need to be copied and cleared, dynamically map other VM's page 21 * table BOs for updates, and identity map the entire device's VRAM with 1 GB 37 * VM of the engine is the migrate VM. 39 * The first batch is used to update the migration VM page structure to point to 40 * the bind VM page table BOs which need to be updated. A physical page is 46 * has VRAM the bind VM page table BOs are in VRAM and the identity mapping can [all …]
|
| /linux/drivers/irqchip/ |
| H A D | irq-gic-v4.c | 1 // SPDX-License-Identifier: GPL-2.0-only 14 #include <linux/irqchip/arm-gic-v4.h> 26 * agnostic actually means KVM-specific - what were you thinking?). 31 * - Any guest-visible VLPI is backed by a Linux interrupt (and a 37 * - Enabling/disabling a VLPI is done by issuing mask/unmask calls. 39 * - Guest INT/CLEAR commands are implemented through 42 * - The *bizarre* stuff (mapping/unmapping an interrupt to a VLPI, or 46 * confines the crap to a single location. And map/unmap really is 62 * interrupts which are delivered when a VLPI targeting a non-running 71 * - VMs (or rather the VM abstraction that matters to the GIC) [all …]
|
| H A D | irq-gic-v3-its.c | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * Copyright (C) 2013-2017 ARM Limited, All Rights Reserved. 37 #include <linux/irqchip/arm-gic-v3.h> 38 #include <linux/irqchip/arm-gic-v4.h> 43 #include "irq-gic-common.h" 44 #include "irq-gic-its-msi-parent.h" 45 #include <linux/irqchip/irq-msi-lib.h> 72 * Collection structure - just an ID, and a redistributor address to 82 * The ITS_BASER structure - contains memory information, cached 95 * The ITS structure - contains most of the infrastructure, with the [all …]
|
| /linux/tools/testing/selftests/mm/ |
| H A D | compaction_test.c | 1 // SPDX-License-Identifier: GPL-2.0 25 void *map; member 32 char *cmd = "cat /proc/meminfo | grep -i memfree | grep -o '[0-9]*'"; in read_memory_info() 37 return -1; in read_memory_info() 43 cmd = "cat /proc/meminfo | grep -i hugepagesize | grep -o '[0-9]*'"; in read_memory_info() 48 return -1; in read_memory_info() 62 fd = open("/proc/sys/vm/compact_unevictable_allowed", in prereq() 65 ksft_print_msg("Failed to open /proc/sys/vm/compact_unevictable_allowed: %s\n", in prereq() 67 return -1; in prereq() 71 ksft_print_msg("Failed to read from /proc/sys/vm/compact_unevictable_allowed: %s\n", in prereq() [all …]
|
| /linux/drivers/virt/acrn/ |
| H A D | mm.c | 1 // SPDX-License-Identifier: GPL-2.0 19 static int modify_region(struct acrn_vm *vm, struct vm_memory_region_op *region) in modify_region() argument 26 return -ENOMEM; in modify_region() 28 regions->vmid = vm->vmid; in modify_region() 29 regions->regions_num = 1; in modify_region() 30 regions->regions_gpa = virt_to_phys(region); in modify_region() 35 "Failed to set memory region for VM[%u]!\n", vm->vmid); in modify_region() 42 * acrn_mm_region_add() - Set up the EPT mapping of a memory region. 43 * @vm: User VM. 44 * @user_gpa: A GPA of User VM. [all …]
|
| /linux/Documentation/devicetree/bindings/hwmon/ |
| H A D | moortec,mr75203.yaml | 1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 3 --- 5 $schema: http://devicetree.org/meta-schemas/core.yaml# 10 - Rahul Tanwar <rtanwar@maxlinear.com> 19 *) Temperature Sensor (TS) - used to monitor core temperature (e.g. mr74137). 20 *) Voltage Monitor (VM) - used to monitor voltage levels (e.g. mr74138). 21 *) Process Detector (PD) - used to assess silicon speed (e.g. mr74139). 22 *) Delay Chain - ring oscillator connected to the PD, used to measure IO 25 *) Pre Scaler - provides divide-by-X scaling of input voltage, which can then 26 be presented for VM for measurement within its range (e.g. mr76006 - [all …]
|
| /linux/include/uapi/drm/ |
| H A D | panthor_drm.h | 1 /* SPDX-License-Identifier: MIT */ 19 * - Structures must be aligned on 64-bit/8-byte. If the object is not 21 * - Fields must be explicitly aligned to their natural type alignment with 23 * - All padding fields will be checked by the driver to make sure they are 25 * - Flags can be added, but not removed/replaced. 26 * - New fields can be added to the main structures (the structures 31 * - Ne [all...] |
| /linux/arch/arm/mm/ |
| H A D | mmu.c | 1 // SPDX-License-Identifier: GPL-2.0-only 5 * Copyright (C) 1995-2005 Russell King 35 #include <asm/mach/map.h> 46 * zero-initialized data and COW. 52 * The pmd table for the upper-most set of pages. 143 int i, selected = -1; in early_cachepolicy() 154 if (selected == -1) in early_cachepolicy() 240 [MT_DEVICE_NONSHARED] = { /* ARMv6 non-shared device */ 467 pr_warn("Forcing write-allocate cache policy for SMP\n"); in build_mem_type_table() 478 * Pre-ARMv5 CPUs don't have TEX bits. Pre-ARMv6 CPUs or those in build_mem_type_table() [all …]
|
| /linux/include/linux/irqchip/ |
| H A D | arm-gic-v4.h | 1 /* SPDX-License-Identifier: GPL-2.0-only */ 14 * ITSList mechanism to perform inter-ITS synchronization. 30 * and map/unmap when using the ITSList mechanism. 33 * vmapp_lock -> vpe_lock ->vmovp_lock. 43 /* per-vPE VLPI tracking */ 77 * vPE and vLPI operations using vpe->col_idx. 86 /* Unique (system-wide) VPE identifier */ 98 * @vm: Pointer to the GICv4 notion of a VM 105 struct its_vm *vm; member 127 struct its_vlpi_map *map; member [all …]
|
| /linux/tools/testing/selftests/kvm/s390/ |
| H A D | ucontrol_test.c | 1 // SPDX-License-Identifier: GPL-2.0-only 43 TEST_REQUIRE((data->effective & CAP_TO_MASK(CAP_SYS_ADMIN)) > 0); in require_ucontrol_admin() 122 * create VM with single vcpu, map kvm_run and SIE control block for easy access 131 self->kvm_fd = open_kvm_dev_path_or_exit(); in FIXTURE_SETUP() 132 self->vm_fd = ioctl(self->kvm_fd, KVM_CREATE_VM, KVM_VM_S390_UCONTROL); in FIXTURE_SETUP() 133 ASSERT_GE(self->vm_fd, 0); in FIXTURE_SETUP() 135 kvm_device_attr_get(self->vm_fd, KVM_S390_VM_CPU_MODEL, in FIXTURE_SETUP() 137 TH_LOG("create VM 0x%llx", info.cpuid); in FIXTURE_SETUP() 139 self->vcpu_fd = ioctl(self->vm_fd, KVM_CREATE_VCPU, 0); in FIXTURE_SETUP() 140 ASSERT_GE(self->vcpu_fd, 0); in FIXTURE_SETUP() [all …]
|
| /linux/sound/pci/ctxfi/ |
| H A D | ctvmem.c | 1 // SPDX-License-Identifier: GPL-2.0-only 26 * Find or create vm block based on requested @size. 30 get_vm_block(struct ct_vm *vm, unsigned int size, struct ct_atc *atc) in get_vm_block() argument 36 if (size > vm->size) { in get_vm_block() 37 dev_err(atc->card->de in get_vm_block() 75 put_vm_block(struct ct_vm * vm,struct ct_vm_block * block) put_vm_block() argument 124 ct_vm_map(struct ct_vm * vm,struct snd_pcm_substream * substream,int size) ct_vm_map() argument 152 ct_vm_unmap(struct ct_vm * vm,struct ct_vm_block * block) ct_vm_unmap() argument 164 ct_get_ptp_phys(struct ct_vm * vm,int index) ct_get_ptp_phys() argument 171 struct ct_vm *vm; ct_vm_create() local 215 ct_vm_destroy(struct ct_vm * vm) ct_vm_destroy() argument [all...] |
| /linux/Documentation/mm/ |
| H A D | overcommit-accounting.rst | 31 The overcommit policy is set via the sysctl ``vm.overcommit_memory``. 33 The overcommit amount can be set via ``vm.overcommit_ratio`` (percentage) 34 or ``vm.overcommit_kbytes`` (absolute value). These only have an effect 35 when ``vm.overcommit_memory`` is set to 2. 56 For a file backed map 57 | SHARED or READ-only - 0 cost (the file is the map not swap) 58 | PRIVATE WRITABLE - size of mapping per instance 60 For an anonymous or ``/dev/zero`` map 61 | SHARED - size of mapping 62 | PRIVATE READ-only - 0 cost (but of little use) [all …]
|
| /linux/drivers/gpu/drm/xe/tests/ |
| H A D | xe_bo.c | 1 // SPDX-License-Identifier: GPL-2.0 AND MIT 9 #include <linux/iosys-map.h> 46 fence = xe_migrate_clear(tile->migrate, bo, bo->ttm.resource, in ccs_test_migrate() 56 return -ETIME; in ccs_test_migrate() 70 timeout = dma_resv_wait_timeout(bo->ttm.base.resv, in ccs_test_migrate() 76 return -ETIME; in ccs_test_migrate() 82 * we still have a CPU map. in ccs_test_migrate() 84 ttm = bo->ttm.ttm; in ccs_test_migrate() 87 return -EINVAL; in ccs_test_migrate() 91 if (ccs_page >= ttm->num_pages) { in ccs_test_migrate() [all …]
|
| /linux/drivers/gpu/drm/ |
| H A D | drm_gpuvm.c | 1 // SPDX-License-Identifier: GPL-2.0-only OR MIT 48 * The GPU VA manager internally uses a rb-tree to manage the 63 * entries from within dma-fence signalling critical sections it is enough to 64 * pre-allocate the &drm_gpuva structures. 66 * &drm_gem_objects which are private to a single VM can share a common 89 * lists are maintained in order to accelerate locking of dma-resv locks and 108 * sequence of operations to satisfy a given map or unmap request. 113 * implement Vulkan 'Sparse Memory Bindings' - drivers UAPIs often refer to this 114 * as VM BIND. 117 * containing map, unmap and remap operations for a given newly requested [all …]
|
| /linux/mm/ |
| H A D | vmalloc.c | 1 // SPDX-License-Identifier: GPL-2.0-only 5 * SMP-safe vmalloc/vfree/ioremap, Tigran Aivazian <tigran@veritas.com>, May 2000 51 #include "pgalloc-track.h" 54 static unsigned int __ro_after_init ioremap_max_page_shift = BITS_PER_LONG - 1; 106 return -ENOMEM; in vmap_pte_range() 149 if ((end - addr) != PMD_SIZE) in vmap_try_huge_pmd() 173 return -ENOMEM; in vmap_pmd_range() 184 return -ENOMEM; in vmap_pmd_range() 185 } while (pmd++, phys_addr += (next - addr), addr = next, addr != end); in vmap_pmd_range() 199 if ((end - addr) != PUD_SIZE) in vmap_try_huge_pud() [all …]
|
| /linux/Documentation/arch/s390/ |
| H A D | monreader.rst | 2 Linux API for read access to z/VM Monitor Records 5 Date : 2004-Nov-26 15 usable from user space and allows read access to the z/VM Monitor Records 16 collected by the `*MONITOR` System Service of z/VM. 21 The z/VM guest on which you want to access this API needs to be configured in 25 This item will use the IUCV device driver to access the z/VM services, so you 26 need a kernel with IUCV support. You also need z/VM version 4.4 or 5.1. 30 location of the monitor DCSS with the Class E privileged CP command Q NSS MAP 33 See also "CP Command and Utility Reference" (SC24-6081-00) for more information 34 on the DEF STOR and Q NSS MAP commands, as well as "Saved Segments Planning [all …]
|
| /linux/Documentation/gpu/rfc/ |
| H A D | i915_vm_bind.rst | 9 specified address space (VM). These mappings (also referred to as persistent 18 User has to opt-in for VM_BIND mode of binding for an address space (VM) 19 during VM creation time via I915_VM_CREATE_FLAGS_USE_VM_BIND extension. 27 * Multiple Virtual Address (VA) mappings can map to the same physical pages 29 * VA mapping can map to a partial section of the BO (partial binding). 34 ------------------------ 38 submissions on that VM and will not be in the working set for currently running 42 ------------------------------- 43 A VM in VM_BIND mode will not support older execbuf mode of binding. 52 "dma-buf: Add an API for exporting sync files" [all …]
|
| /linux/drivers/hwmon/ |
| H A D | mr75203.c | 1 // SPDX-License-Identifier: GPL-2.0 8 * voltage monitor(VM) & process detector(PD) modules. 74 /* VM Individual Macro Register */ 76 #define VM_SDIF_DONE(vm) (VM_COM_REG_SIZE + 0x34 + 0x200 * (vm)) argument 77 #define VM_SDIF_DATA(vm, ch) \ argument 78 (VM_COM_REG_SIZE + 0x40 + 0x200 * (vm) + 0x4 * (ch)) 111 #define PVT_TEMP_MIN_mC -40000 117 #define PVT_SERIES5_J_CONST -100 133 * struct voltage_device - VM single input parameters. 134 * @vm_map: Map channel number to VM index. [all …]
|
| /linux/drivers/gpu/drm/amd/amdgpu/ |
| H A D | amdgpu_userq.c | 1 // SPDX-License-Identifier: MIT 40 if (adev->userq_funcs[i]) in amdgpu_userq_get_supported_ip_mask() 47 int amdgpu_userq_input_va_validate(struct amdgpu_vm *vm, u64 addr, in amdgpu_userq_input_va_validate() argument 58 r = amdgpu_bo_reserve(vm->root.bo, false); in amdgpu_userq_input_va_validate() 62 va_map = amdgpu_vm_bo_lookup_mapping(vm, user_addr); in amdgpu_userq_input_va_validate() 64 r = -EINVAL; in amdgpu_userq_input_va_validate() 67 /* Only validate the userq whether resident in the VM mapping range */ in amdgpu_userq_input_va_validate() 68 if (user_addr >= va_map->start && in amdgpu_userq_input_va_validate() 69 va_map->last - user_addr + 1 >= size) { in amdgpu_userq_input_va_validate() 70 amdgpu_bo_unreserve(vm->root.bo); in amdgpu_userq_input_va_validate() [all …]
|
| /linux/drivers/gpu/drm/lima/ |
| H A D | lima_sched.c | 1 // SPDX-License-Identifier: GPL-2.0 OR MIT 2 /* Copyright 2017-2019 Qiang Yu <yuq825@gmail.com> */ 5 #include <linux/iosys-map.h> 35 return -ENOMEM; in lima_sched_slab_init() 44 if (!--lima_fence_slab_refcnt) { in lima_sched_slab_fini() 64 return f->pipe->base.name; in lima_fence_get_timeline_name() 79 call_rcu(&f->base.rcu, lima_fence_release_rcu); in lima_fence_release() 96 fence->pipe = pipe; in lima_fence_create() 97 dma_fence_init(&fence->base, &lima_fence_ops, &pipe->fence_lock, in lima_fence_create() 98 pipe->fence_context, ++pipe->fence_seqno); in lima_fence_create() [all …]
|
| /linux/drivers/gpu/drm/i915/gem/selftests/ |
| H A D | i915_gem_coherency.c | 2 * SPDX-License-Identifier: MIT 30 i915_gem_object_lock(ctx->obj, NULL); in cpu_set() 31 err = i915_gem_object_prepare_write(ctx->obj, &needs_clflush); in cpu_set() 35 page = i915_gem_object_get_page(ctx->obj, offset >> PAGE_SHIFT); in cpu_set() 47 i915_gem_object_finish_access(ctx->obj); in cpu_set() 50 i915_gem_object_unlock(ctx->obj); in cpu_set() 61 i915_gem_object_lock(ctx->obj, NULL); in cpu_get() 62 err = i915_gem_object_prepare_read(ctx->obj, &needs_clflush); in cpu_get() 66 page = i915_gem_object_get_page(ctx->obj, offset >> PAGE_SHIFT); in cpu_get() 75 i915_gem_object_finish_access(ctx->obj); in cpu_get() [all …]
|
| /linux/tools/testing/selftests/kvm/include/ |
| H A D | memstress.h | 1 // SPDX-License-Identifier: GPL-2.0 33 struct kvm_vm *vm; member 47 /* The vCPU=>pCPU pinning map. Only valid if pin_vcpus is true. */ 62 void memstress_destroy_vm(struct kvm_vm *vm); 64 void memstress_set_write_percent(struct kvm_vm *vm, uint32_t write_percent); 65 void memstress_set_random_access(struct kvm_vm *vm, bool random_access); 72 void memstress_setup_nested(struct kvm_vm *vm, int nr_vcpus, struct kvm_vcpu *vcpus[]); 74 void memstress_enable_dirty_logging(struct kvm_vm *vm, int slots); 75 void memstress_disable_dirty_logging(struct kvm_vm *vm, int slots); 76 void memstress_get_dirty_log(struct kvm_vm *vm, unsigned long *bitmaps[], int slots); [all …]
|